Message Boards Message Boards

0
|
2442 Views
|
1 Reply
|
0 Total Likes
View groups...
Share
Share this post:

Linear Algebra Cross Product

Posted 11 years ago
As part of a retirement project, I have decided to brush up my maths (I have degrees in geology and in maths, but from a long time ago!) and tried some basic vector operations, including the Mathematica Cross product function, but ran into a puzzle.  If you take the cross product of the two vectors:
A = 2i-3j-k
B= i+4j-2k

And work it out by hand, you get AXB= 10i+3j+11k, which is the same as in the book that I took this example from.

The Mathematica function Cross[{2I,-3I,-I},{I,4I,-2I}], which I would expect to get the same answer, gives {-10,-3,-11}, that is the negative of the hand worked and the text book answer.

I had the same result when I tried examples from other text books.

I expect that there is a farirly simple explanation, but I am very new to Mathematica, and haven't figured out what it is, and would appreciate some advice.
POSTED BY: David Elliott
The letter I (capital "i") in Mathematica is a system symbol for the squre root of -1.  So, 
In[1]:= I^2


Out[1]= -1

Since you have a factor of I in all of your vector components of your cross product you get an answer that is a factor of -1 off of what you were expecting.  Here is what you actually want to compute:
In[2]:=  Cross[{2, -3, -1}, {1, 4, -2}]


Out[2]= {10, 3, 11}
POSTED BY: David Reiss
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract