Can anyone give me the formula for calculating the cross
product of two vectors in 3D space using spherical
coordinates? If you could reply to my email address I'd
appreciate it. Thanks!
Terry
* Sent from RemarQ http://www.remarq.com The Internet's Discussion Network *
The fastest and easiest way to search and participate in Usenet - Free!
> Hi friends,
>
> Can anyone give me the formula for calculating the cross
> product of two vectors in 3D space using spherical
> coordinates? If you could reply to my email address I'd
> appreciate it. Thanks!
>
> Terry
>
> * Sent from RemarQ http://www.remarq.com The Internet's Discussion Network *
> The fastest and easiest way to search and participate in Usenet - Free!
You might want to check out Olmstead's Real Analysis (or Advanced
Calculus, or one of them anyway.) He has a whole chapter on what all
these things look like in ortogonal coordinates.
Don
| e1 e2 e3 |
| v1 v2 v3 |
| w1 w2 w3 |
as a determinant (the only memorable form IMHO), where:
(e1, e2, e3) are the unit vectors associated with each coordinate,
(v1, v2, v3) are the associated components of the first vector
(w1, w2, w3) are the associated components of the second vector
Where the coordinate system introduces devil in the detail is if you
want to calculate curl, which looks like the cross product of two
vectors but of course is not (the first "vector" is actually a
differential operator). I continue to love the formula:
| h1.e1 h2.e2 h3.e3 |
| d/dx1 d/dx2 d/dx3 | / (h1.h2.h3)
| h1.v1 h2.v2 h3.v3 |
which is valid for curl in _any_ orthogonal coordinate system, in
which other symbols remain as before, and:
(h1, h2, h3) are the scale factors associated with each coordinate,
and whilst I have no trouble remembering this, I can never remember
what the individual scale factors are, even for cylindricals let alone
sphericals, let alone which goes with which coordinate (even though
remembering the product of all three is easy enough), and I always
have to resort to looking _them_ up.
I'm quite sure that this is a personal blind spot, and that other
people can actually _derive_ the scale factors for themselves on
geometrical grounds, even if I can't, but I think it would not be easy
to derive the general curl expression. It'd be earbleedingly difficult
enough in any specific curvilinear coordinate system, would be for me
at any rate. Please spare me any macho mathematical competitiveness on
this one...
Andy
(apologies for all ASCII-related misalignments)
On Tue, 14 Sep 1999 17:28:17 GMT, Bruce Bowen <bru...@my-deja.com>
wrote:
>In article <37DDA64F...@hate.spam.net>,
> Uncl...@hate.spam.net wrote:
>>
>>
>> joaquin wrote:
>> >
>> > Hi friends,
>> >
>> > Can anyone give me the formula for calculating the cross
>> > product of two vectors in 3D space using spherical
>> > coordinates? If you could reply to my email address I'd
>> > appreciate it (remove the NOxxSPAM in my email address to
>> > reply). Thanks!
>>
>> You might look at the Schaum Outline Series for vector analysis or a
>> CRC Handbook math section.
>
>Or you might derive it yourself, or is that beyond you? Decompose the
>vectors into orthonormal unit vectors, ... If you're really into it,
>study exterior algebra.
>
>-Bruce bbo...@pppppppacbell.net
>
>
>Sent via Deja.com http://www.deja.com/
>Share what you know. Learn what you don't.
I think this has to do with the fact that for the two
vectors, the unit vectors associated with each are not
concurrent/parallel/whatever (sorry if I don't have the
lingo down.....no engineer should be subjected to this!).
And yes, I did obtain the result in cartesians, but the
nature of the system is such that I think the result would
be much simpler if I could work entirely in spherical
coordinates............
Terry
In article <37dea67d...@news.globalnet.co.uk>,
Or something like that.
Mark Folsom
joaquin <thmNO...@eng.buffalo.edu> wrote in message
news:283beef1...@usw-ex0102-013.remarq.com...
I think the problem lies in the fact that the basis vectors
of the two arguments are not parallel/concurrent/whatever
(sorry if I don't have the lingo down....no engineer should
be subjected to this!).
And yes, I have already worked out the solution using a
cartesian system but the nature of the problem is such that
expressing my vectors in spherical coordinates would be
much simpler.
In article <37dea67d...@news.globalnet.co.uk>,
spa...@globalnet.co.uk (Andy Spragg) wrote:
> Bit rude, isn't it? I'm assuming the poster "knows the
> result in
> Cartesians" but thinks it's different in sphericals,
> could be wrong
> here. Why has no-one either here or on sci.math yet
> pointed out that
> the spherical coordinate bit is a red herring in this
> context? Sheer
> bloodymindedness? The formula is the same whatever
> coordinate system
> is used:
> | e1 e2 e3 |
> | v1 v2 v3 |
> | w1 w2 w3 |
> as a determinant (the only memorable form IMHO), where:
> (e1, e2, e3) are the unit vectors associated with
> each coordinate,
> (v1, v2, v3) are the associated components of the
> first vector
> (w1, w2, w3) are the associated components of the
> second vector
I can suggest taking your spherical vectors, turning them into Cartesian
vectors, doing the cross-product, and then turning them back into
spherical vectors. You may find that the same determinant method works,
or you may find a general mathematical expression for doing the spherical
vector case.
I'm just guessing here. I haven't actually done that because it seems
like work.
--
"Honey, would you mind opening the window? The police have Daddy's
fingerprints on file." - Homer
>Thanks for your help Andy, but supposing one of the vectors
>has (r, theta, phi) components equal to (1,0,0). Then
>wouldn't the cross product of this vector with any other in
>the determinant equation yield a vector whose r component
>is equal to zero?
Now you come to mention it, yes. Is this necessarily wrong? Hmmm, have
to think about that :-( Why would no-one think it was wrong if it was
in Cartesians?
i x (aj + bk) = ak - bj
with no i component
The cross product does have to be normal to both the vectors that
"parented" it...but the more I think about it the more I get worried
about dimensional inconsistency of what I posted. Also by the fact
that there's nothing special about zero phi in a spherically
symmetrical case...
I nearly posted just the curl result originally, as I was put out on
your behalf by the suggestion that you were an inferior being if you
couldn't derive it yourself - then I noticed at the last minute you
only wanted cross product, and inserted that too but left the curl
result in as I had a feeling that might have been useful (I spent a
_long_time once arsing around with the Navier-Stokes equations in
orthogonal curvilinear coordinates, so curl and cross are indelibly
imprinted on my brain).
Curl is _definitely_ right, I'll have to go back and check up on
cross. Somewhere at work I have a photocopy of a chapter on all eleven
orthogonal curvilinear coordinate systems, highly sexual stuff, and
also Schaum's Vector Analysis, basic but workmanlike. I have an uneasy
feeling neither will help and that words like "physical",
"contravariant" and "covariant" are going to come into this. Oh
bugger.
In article <37e09f7b...@news.globalnet.co.uk>
spa...@globalnet.co.uk (Andy Spragg) writes:
>
>Now you come to mention it, yes. Is this necessarily wrong? Hmmm, have
>to think about that :-( Why would no-one think it was wrong if it was
>in Cartesians?
For the simple reason alluded to in the remainder of his reply:
the direction of a unit vector, say ${\hat r}$, in a curvilinear
coordinate system like spherical coordinates, is different at
different points in that coordinate system. You can see this
rather trivially by looking at ${\hat x} \cross {\hat y}$ with
them expressed in spherical coordinates. Your expression does
not give ${\hat z}$. Or look at ${\hat z} \cross {\hat x}$.
The differential operators act at the same point as what they act
on, so there you only need to take the scaling factors into account.
--
James A. Carr <j...@scri.fsu.edu> | Commercial e-mail is _NOT_
http://www.scri.fsu.edu/~jac/ | desired to this or any address
Supercomputer Computations Res. Inst. | that resolves to my account
Florida State, Tallahassee FL 32306 | for any reason at any time.
There is only one vector with r-component 0. This is the zero vector, the
unique vector with zero length.
Think again.
Goo luck,
Heinz Frey
That was exactly my point. Maybe *you* should think before
you post a message which helps no one.
Goo luck to you too,
joaquin
Eh? Any vector tangent to a sphere centred on the origin
will have r component 0.
Also, any vector at some point P (P can't be the origin,
or polar coordinates break down) with (r,theta,phi)
components (1,0,0) is radial, and so its cross product
with any other vector will be orthogonal to a radial
vector, i.e. will be tangential to the sphere centred
on the origin and passing through P; which is just what
ought to happen.
Maybe you're confused by the fact that the basis vectors
e_r, e_theta and e_phi aren't constant, unlike those
for Cartesian coordinates, e_x, e_y and e_z?
--
---
Robert Low. http://www.mis.coventry.ac.uk/~mtx014/
But going back to the original problem, you're correct in
that since esubtheta and esubphi aren't constant, there is
no easy formula for the cross product like there is for
cartesians.
In article <7s5j2l$c8g$1...@wisteria.csv.warwick.ac.uk>,
>You're forgetting that vectors don't have a "location,"
>only magnitude and direction.
What about a position vector? It has a location; the origin. That's
how it defines a direction.
<snip>
>But going back to the original problem, you're correct in
>that since esubtheta and esubphi aren't constant, there is
>no easy formula for the cross product like there is for
>cartesians.
Next you'll be claiming that because the unit vectors aren't
"constant" that there is no simple formula for dot product in
sphericals either. Am I going mad?
Can I at least retain a vestige of sanity by continuing to cling on
to:
(axb)^2 + (a.b)^2 = (a.a)(b.b)
or is this identity allegedly coordinate-system dependent as well?
I need to go back to a textbook. Sorry but I have now forgotten twice
to look out the photocopy I mentioned. My copy of Schaum seems to have
gone permanent walkabout.
Andy
>There is only one vector with r-component 0. This is the zero vector, the
>unique vector with zero length.
Hmm. So e.g.:
(0, pi/2, 0) = (0, 3.pi/4, 2.pi) = (0, 0, pi/3) = .........ad
infinitum
Have I got this right?
OK, so you just don't understand vectors. Fine.
A vector is an element of a vector space. To each
point of R^3 you can attach a vector space called
the tangent space at that point. Picking a
vector at each point of R^3 you get a vector
field.
Now, given a coordinate system x^\alpha, you have a natural
basis for the tangent space at that point, defined by
keeping two of the coordinates constant and letting the
other increase.
Change the coordinate system and you change the basis.
Next, consider (say) the motion of a fluid through space.
At each point, the fluid has a well-defined velocity.
If you want to know the (r,theta,phi) components of
the velocity at some point, you can find it given
the following information; the standard Cartesian
components, and the matrix of partial derivatives
of the polar coordinates wrt the Cartesian ones at
that point.
But hey, don't take my work for it! Read a book about
it. I suggest Bernd Schmidt's 'Geometrical methods
of mathematical physics'. Or a book on fluid dynamics
if you prefer to see things developed via rather
than for applications.
>But going back to the original problem, you're correct in
>that since esubtheta and esubphi aren't constant, there is
>no easy formula for the cross product like there is for
>cartesians.
Yes there is. e_theta, e_r and e_phi form an orthonormal
basis (away from the z-axis, where e_phi is not
defined). Figure out how that works, and use
linearity.
Yes it defines a direction and a distance but it's not
constrained to the origin. The position vector between
(0,0,0) and (1,1,1) is *exactly* equal to the vector
between (500,500,500) and (501,501,501). The vector
*itself* contains no information regarding position.
> <snip>
> >But going back to the original problem, you're
> correct in
> >that since esubtheta and esubphi aren't constant,
> there is
> >no easy formula for the cross product like there is
> for
> >cartesians.
> Next you'll be claiming that because the unit vectors
> aren't
> "constant" that there is no simple formula for dot
> product in
> sphericals either. Am I going mad?
Perhaps....... :)
> Can I at least retain a vestige of sanity by
> continuing to cling on
> to:
> (axb)^2 + (a.b)^2 = (a.a)(b.b)
> or is this identity allegedly coordinate-system
> dependent as well?
I seem to remember an identity similar to this, but is the
first term supposed to be the *magnitude* of AxB squared?
Regardless, no this is not coordinate-system dependant, the
problem is *defining* those operations for the given
coordinate system. Come to think of it, can one even
easily define *addition* in sphericals? I don't think
so.......
The problem comes back to the fact that the basis vectors
are not "constant." esubr of one vector points in a
different direction than esubr of another. And likewise
for esubphi and esubtheta. Of cousrse the exception is if
the two vectors are parallel. So:
esubr + esubr != 2esubr,
esubr.esubr != 1,
esubr x esubr != 0
Terry
> I need to go back to a textbook. Sorry but I have now
> forgotten twice
> to look out the photocopy I mentioned. My copy of
> Schaum seems to have
> gone permanent walkabout.
> Andy
> OK, so you just don't understand vectors. Fine.
> Or you might derive it yourself, or is that beyond you?
God, I can't f***ing stand some people........
You made a factually incorrect statement. I not only observed
that you just didn't understand the problem you were grappling
with, I also tried to give you a brief description of
what is going on, at least a pointer to some references
that might help you, and a hint as to how to do what you
wanted, since you'd come to the erroneous conclusion
that it was impossible. I notice that you deleted what
explanation etc there was to make it clearer how
unjustly you were being treated.
Now, if you think that is justification for your response,
that's fine too. But you still need to understand that
what you said about vectors in polar coordinates is
flat-out wrong. Ignorance, unlike stupidity, can be cured.
From what I understand, one picks one fixed set of basis
vectors and expresses all the vectors in the system
relative to that single set. Typically the "most
important" vector (A) is used as the basis such that
A = |A|esubr
All the other vectors are then expressed as some
combination of esubr, esubtheta and esubphi. Then one can
calculate the cross product, dot product, etc. with no
problem.
Thanks Andy and everyone else for your help and to those
who think they're smarter than me, kiss my white ass.
Terry
>Ignorance, unlike stupidity, can be cured.
Ignorance in the presence of stupidity is no easier to cure
than stupidity alone, surely? Or would you count purely behavioristic
training (say, with cattleprods and candy treats) as a cure for
ignorance?
Lee Rudolph
Well, it's harder to cure ignorance in the presence
of stupidity, but with enough work it can be done--at
least to some extent. Recall the court room conversation:
Judge: I have examined your evidence, and I am
none the wiser.
Lawyer: Perhaps not, your honour, but you are better
informed.
> Or would you count purely behavioristic
>training (say, with cattleprods and candy treats) as a cure for
>ignorance?
We tend to claim that it works on undergraduates :-)
I'm not so sure.
>From what I understand, one picks one fixed set of basis
>vectors and expresses all the vectors in the system
>relative to that single set. Typically the "most
>important" vector (A) is used as the basis such that
>A = |A|esubr
>All the other vectors are then expressed as some
>combination of esubr, esubtheta and esubphi. Then one can
>calculate the cross product, dot product, etc. with no
>problem.
Not quite.
The only context in which working out the components
of a vector 'in polar coordinates' really makes sense
is when you have a vector field on (some portion of)
R^3. (OK, other dimensions work too, but for many
physics problems it's R^3 we care about.)
Now, a vector field assigns to each point a vector.
This might be velocity at each point along
a path for a particle trajectory, or at each point
in a region for fluid motion, or it might be
an electric field, or various other things.
So at some point, say P, with Cartesian coordinates
(x,y,z) and polar coordinates (r,theta,phi) we
have a vector, v. What does it mean to have the components
of that vector?
To work that out, pretend that you're travelling through
P with velocity v, and see how much your x,y and z
coordinates increase by in a small time interval dt.
The x,y and z components of v are the derivatives of
your x, y and z coordinates with respect to t.
Similarly, the r, theta and phi components of your
velocity are given by the derivatives of your r, theta and
phi coordinates as you pass though P with velocity
v. But since e_r, e_theta and e_phi are unit
vectors in the direction of increasing r (holding
theta and phi constant) etc, using the chain
rule you find that
dx e_x + dy e_y + dz e_z
= dr e_r + r dtheta e_theta + rsin(theta) dphi
so the components are not just the derivatives any
more.
The relationship between the r,theta,phi components
and the x,y,z components can be found using the
chain rule, if you write down x, y and z in terms
of r, theta and phi. Note in particular that the
r component is *not* the magnitude of v. It is the
component of v in the radially outward direction.
In the first case, the basis vectors, e_x, e_y and e_z
are orthonormal, and are constant. In the second case,
the basis vectors e_r, e_theta and e_phi are not
constant; but they're still orthonormal, so once
you figured out whether e_r x e_theta is plus or
minus e_phi, you can still use the determinant
method to find the cross product.