Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2001
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2001

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Declaring variables

  • To: mathgroup at smc.vnet.net
  • Subject: [mg29924] Re: Declaring variables
  • From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
  • Date: Thu, 19 Jul 2001 03:56:52 -0400 (EDT)
  • Organization: Universitaet Leipzig
  • References: <9j39ic$ijk$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Hi,

there is *no* way to set the type of the value
of a symbol ! Mathematica is an untyped language.

Your statement "x must be a list" is not clear --
what must be a list ? The symbol x or it's value ?

Since Mathematica knows nothing about type definitions
it will not speed up your computation.

For CompiledFunction[] objects you can give types
and tensor degrees.

What will reduce your runtime ? This can't be sayed without
the programming code. A MathLink program will do it, if you just
do numerics. But a general hint is impossible.


Regards
  Jens

Etienne wrote:
> 
> I am trying to speed up a genetic algorithm and was wondering if there is an
> efficient way of declaring variables (e.g. x must be a list). Will it reduce
> my run time? If not, what will?
> 
> Thanks in advance.
> 
> Etienne Ayotte-Sauvé


  • Prev by Date: Re: slow integration
  • Next by Date: Re: Admissible values for variables
  • Previous by thread: Declaring variables
  • Next by thread: Admissible values for variables