1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Vector analysis in mathematica

  1. Sep 19, 2009 #1
    Hi all,

    I'm trying to do some vector analysis in Mathematica 6. I have the vector analysis package loaded via: << VectorAnalysis`

    I'm working in the default cartesian coordinate system, but just to be on the safe side I have set: SetCoordinates[Cartesian]

    The grad operator seems to work ok, as in the example in the help file:

    Grad[2 Xx^2 + Yy]
    {4 Xx, 1, 0}

    But anything else seems to just return the input. Eg:


    But I know this should be Zz!

    Same for Dot, Curl etc. I'm not too experienced with Mathematica. Hopefully someone can point out a simple mistake I'm making!

    Thanks in advance!
    Last edited: Sep 19, 2009
  2. jcsd
  3. Sep 20, 2009 #2


    User Avatar
    Homework Helper

    Cross is not defined
  4. Sep 20, 2009 #3
    Whoops, that was just a mistake in my copying code over to the forum. I had it as CrossProduct. Still no dice.

    I managed to do what I needed to do by specifying all the components explicitly. Ie:
    x = {1,0,0}; etc.

    It seems there should be a better way of doing this though, else what would even be the purpose of Mathematica recognising the variable names Xx, Yy, Zz as "special"?
    Last edited: Sep 21, 2009
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook