Re: CrossProduct in Spherical Coordinates
- To: mathgroup at smc.vnet.net
- Subject: [mg75330] Re: [mg75298] CrossProduct in Spherical Coordinates
- From: Andrzej Kozlowski <akoz at mimuw.edu.pl>
- Date: Wed, 25 Apr 2007 05:39:21 -0400 (EDT)
- References: <200704240726.DAA27495@smc.vnet.net>
On 24 Apr 2007, at 16:26, gogoant06 at yahoo.com.hk wrote:
> Dear all,
>
> I am really new to mathematica and I have met a damn simple problem.
>
> In[1]:=
> <<Calculus`VectorAnalysis`
>
> In[2]:=
> CrossProduct[{1,0,0},{0,1,0},Spherical]
>
> Out[2]=
> {0,0,0}
>
> Why? Isn't the result supposed to be {0,0,1}, even in spherical
> coordinates?
>
> best regards,
> lion
>
>
The poivectornt that has coordinates {0,1,0} in Spherical coordinates
is simply the vector {0,0,0} in Cartesion coordinates (because the
first coordinate stands for the "radius" and is 0). Hence the cross
product of anything with this vector must be 0.
Persumably what you wanted to do was to compute in spherical
coordiantes the cross product of the vectors which in cartesion
coordiantes (and not in spherical ones) are represented as {1,0,0}
and {0,1,0}? If so, you can do this as follows:
v=CrossProduct[CoordinatesFromCartesian
[{1,0,0}],CoordinatesFromCartesian[{0,\
1,0}],Spherical]
{1,0,0}
Of course this is the answer in spherical coordinates, so to get it
in Cartesian cordinates you need to perfomr another coordinate switch:
CoordinatesToCartesian[v]
{0,0,1}
as expected.
Of course it would make more sense to compute it directly in
Cartesian coordiantes!
Andrzej Kozlowski
- References:
- CrossProduct in Spherical Coordinates
- From: gogoant06@yahoo.com.hk
- CrossProduct in Spherical Coordinates