MathGroup Archive 2008

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

Search the Archive

Re: Looping in Mathematica Packages.m

  • To: mathgroup at smc.vnet.net
  • Subject: [mg88386] Re: Looping in Mathematica Packages.m
  • From: Bill Rowe <readnews at sbcglobal.net>
  • Date: Sat, 3 May 2008 06:19:12 -0400 (EDT)

On 5/1/08 at 3:20 AM, ertlejack at sbcglobal.net (John Ertle Jr.) wrote:

>I know mathematica is a one line type software package but is there
>a way of looping in a Package.m file.  You can use % sign or %%% for
>3 lines back but is there a way to go 3 lines back and execute all
>the successive lines in a Package?

You don't want to even consider using % and its kin to reference
previous execution lines in a package file. That would lead to
extremely unpredictable performance. If you did it, the executed
line would vary according to when the package was loaded and
when the function that made the reference was executed.

Mathematica has a variety of methods for performing loops. Paste
the following in to the Documentation Center search box for a
basic description of loops and control structures.

tutorial/LoopsAndControlStructures

More information on programming found starting at

guide/FunctionalProgramming

or

guide/ProceduralProgramming



  • Prev by Date: Re: Wolfram Workbench user experiences
  • Next by Date: MenuView inside Manipulate
  • Previous by thread: Re: Looping in Mathematica Packages.m
  • Next by thread: Re: Complex Plot