MathGroup Archive 2006

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

Search the Archive

Re: Simple Plot3D/Function Syntax issue


"JTolman" <jtolman at gmail.com> wrote in message 
news:ebeb66$ldv$1 at smc.vnet.net...
> When I enter
> f = e^-(x^2 + y^2) (x^2 + 2y^2)
> It gives me a syntax::noinfo error but the output looks like the
> correct textbook style function.
>
> Also, when I try to plot it
> Plot3D[e^-(x^2 + y^2) (x^2 + 2y^2), {x, -3, 3}, {y, -3, 3}]
> It of course gives me not machines-size real number errors, which I am
> assuming have more to do with my original syntax error.  I've tried
> several variations but can't figure out what needs to be corrected.
>

Define "f" as a function with two variables (because it is a function of two 
variables).  Then try graphing the function in Plot 3D.  Like this:

f[x_, y_] =e^-(x^2 + y^2) (x^2 + 2y^2);


Plot3D[f[x,y],{x, -3, 3}, {y, -3, 3}]


Does it look good now?  Practice defining functions.


  • Prev by Date: Re: SImple Plot3D issue
  • Next by Date: RE: Re: MemberQ
  • Previous by thread: RE: Simple Plot3D/Function Syntax issue
  • Next by thread: Re: Simple Plot3D/Function Syntax issue