Services & Resources / Wolfram Forums / MathGroup Archive

MathGroup Archive 2010

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

Search the Archive

Re: loop for with plot

  • To: mathgroup at
  • Subject: [mg110041] Re: loop for with plot
  • From: "David Park" <djmpark at>
  • Date: Sun, 30 May 2010 23:44:31 -0400 (EDT)

You can use the much simpler Table instead of For. It is usually good to
evaluate the functions you are plotting before putting them into a Plot
statement. So:

R3 = 6; 
functions = Table[2*R3*Sin[ArcCos[x/R3]]*e3, {e3, 0, 3}] 
Plot[functions, {x, -2 R3, 2 R3}] 

David Park
djmpark at  

From: maria giovanna dainotti [mailto:mariagiovannadainotti at] 

Dear Mathgroup,

when I am using the loop for with plot is not working.

here is the example
For[e3=0,e3<4,e3++,Plot[{2*R3*Sin[ArcCos[x/R3]]*e3}, {x, -2R3,2 R3}]]
How can I sort out the problem?
Best regards

  • Prev by Date: Re: Eric Weisstein's MathWorld packages
  • Next by Date: Big memory needed
  • Previous by thread: Re: Mathematica help (plotting solutions of transendental equation from
  • Next by thread: Re: loop for with plot