Re: Curl
- To: mathgroup at smc.vnet.net
- Subject: [mg34907] Re: Curl
- From: lalu_bhatt at yahoo.com (Bhuvanesh)
- Date: Wed, 12 Jun 2002 02:15:45 -0400 (EDT)
- References: <ae4f76$9d2$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
John Deacon <jdeacon at jdl.co.uk> wrote:
> I must be getting the coordinate system wrong. I want to
> calculate something like curl F where
> F(x,y,z) = ixz + jyz + ky^2
> where i, j and k are the unit vectors in the x, y and z
> directions respectively.
>
> << Calculus`VectorAnalysis`
> SetCoordinates[Cartesian[x, y, z ]]
> Curl[{xz, yz, -y^2}]
> produces
> {-2 y, 0, 0}
> Yet I would swear it should be -3yi + xj
>
> What am I doing wrong?
>
> John
You need a space or a multiplication sign between variables that you
are multiplying (i.e. xz is a single variable, while x*z is
Times[x,z]).
In[1]:= <<Calculus`VectorAnalysis`
In[2]:= SetCoordinates[Cartesian[x, y, z]]
Out[2]= Cartesian[x, y, z]
In[3]:= Curl[{x*z, y*z, -y^2}]
Out[3]= {-3 y, x, 0}
--
Bhuvanesh,
Wolfram Research.