VectorCalculus
CrossProduct
computes the cross product of Vectors and differential operators
Calling Sequence
Parameters
Description
Examples
CrossProduct(v1,v2)
v1 &x v2
v1
-
Vector(algebraic); Vector, Vector-valued procedure, or differential operator
v2
The CrossProduct(v1, v2) function (vector product) computes the cross product of v1 and v2, where v1 and v2 can be either three dimensional free Vectors, rooted Vectors, position Vectors, vector fields, Del or Nabla.
The function and can be accessed through &x or CrossProduct exports.
The behavior of cross product is contained in the following table
coord (v1)
coord (v2)
v1&xv2
coord (v1&xv2)
1
free Vector
cartesian
curved
any
error
2
rooted Vector (root2)
coord2
3
vector field
4
position Vector
5
rooted Vector (root1)
coord1
rooted Vector
rooted Vector (any)
6
v1&xv2⁡root1
7
8
9
10
restart
with⁡VectorCalculus:
Take the cross product of two free Vectors in cartesian coordinates.
1,0,0&x0,−1,0
0ex+0ey+−1ez
v1≔Vector⁡1,4,0,coordinates=cartesianx,y,z
v1≔140
v2≔Vector⁡1,1,1,coordinates=cartesianx,y,z
v2≔111
CrossProduct⁡v1,v2
4ex+−1ey+−3ez
GetCoordinates⁡CrossProduct⁡v1,v2
cartesianx,y,z
Take the cross product of two rooted vectors if they have the same coordinate system and root point.
vs≔VectorSpace⁡1,π3,π3,sphericalr,p,t
vs ≔ modulelocal_origin,_coords,_coords_dim;exportGetCoordinates,GetRootPoint,Vector,eval;end module
v1≔RootedVector⁡root=vs,1,1,1
v1≔111
v2≔RootedVector⁡root=vs,1,0,1
v2≔101
10−1
GetRootPoint⁡v1&xv2
1er+π3ep+π3et
The cross product of a cartesian free Vector and a rooted Vector is valid. The resulting Vector is rooted.
v1≔RootedVector⁡root=1,π4,1,1,1,1,cylindricalr,p,h
v2≔Vector⁡0,0,1,coordinates=cartesianx,y,z
v2≔001
v2&xv1
−110
GetRootPoint⁡v2&xv1
1er+π4ep+1eh
GetCoordinates⁡v2&xv1
cylindricalr,p,h
The cross product of two vector fields is defined if they are in the same coordinate system.
vf1≔VectorField⁡r,φ,θ,sphericalr,φ,θ
vf1≔re_r+φe_φ+θe_θ
vf2≔VectorField⁡r2,φ,φ,sphericalr,φ,θ
vf2≔r2e_r+φe_φ+φe_θ
CrossProduct⁡vf1,vf2
φ2−φ⁢θe_r+r2⁢θ−φ⁢re_φ+−φ⁢r2+φ⁢re_θ
Use differential operators to compute the Curl of a vector field.
F≔VectorField⁡1,−x,y,cartesianx,y,z
F≔1e_x+−xe_y+ye_z
Del&xF
1e_x+0e_y+−1e_z
G≔VectorField⁡r,t,p,sphericalr,p,t
G≔re_r+te_p+pe_t
Del&xG
r⁢cos⁡p⁢p+r⁢sin⁡p−rr2⁢sin⁡pe_r+−pre_p+tre_t
The cross product of two position Vectors is defined. The result is a position Vector.
pv1≔PositionVector⁡1,p,q,sphericalr,φ,θ
pv1≔sin⁡p⁢cos⁡qsin⁡p⁢sin⁡qcos⁡p
pv2≔PositionVector⁡1,p,p,cylindricalr,φ,h
pv2≔cos⁡psin⁡pp
CrossProduct⁡pv1,pv2
sin⁡p⁢sin⁡q⁢p−cos⁡p⁢sin⁡p−sin⁡p⁢cos⁡q⁢p+cos⁡p2sin⁡p2⁢cos⁡q−sin⁡p⁢sin⁡q⁢cos⁡p
About⁡CrossProduct⁡pv1,pv2
Type: Position VectorComponents: sin⁡p⁢sin⁡q⁢p−cos⁡p⁢sin⁡p,−sin⁡p⁢cos⁡q⁢p+cos⁡p2,sin⁡p2⁢cos⁡q−sin⁡p⁢sin⁡q⁢cos⁡pCoordinates: cartesianRoot Point: 0,0,0
See Also
LinearAlgebra[CrossProduct]
VectorCalculus[Curl]
VectorCalculus[Del]
VectorCalculus[PositionVector]
VectorCalculus[RootedVector]
VectorCalculus[Vector]
VectorCalculus[VectorField]
Download Help Document
What kind of issue would you like to report? (Optional)