VectorField - Maple Help

Online Help

All Products    Maple    MapleSim


VectorCalculus

  

VectorField

  

create a vector field

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

VectorField(v, c)

Parameters

v

-

list or Vector; components specifying the coefficients of the basis vectors at each point in space

c

-

(optional) symbol[name, name, ...]; specify the coordinate system and coordinate names of the vector field

Description

• 

The VectorField(v, c) command constructs a vector field, which is implemented as a Vector with the vectorfield attribute and a coordinate system attribute.

• 

The vector field is one of the principal data structures of the Vector Calculus package.

• 

Note that some VectorCalculus procedures require their input to be vector fields, but will accept Vector-valued operators as well; in this case, any input operator will be interpreted as a vector field, and the output will generally also be an operator.

• 

The other principal data structures of the Vector Calculus package (free Vectors, position Vectors, and rooted Vectors) are not interpreted as constant vector fields.

• 

If the second parameter, c, is not specified, the default coordinate system is used.  In this case, the default coordinate system must be indexed by coordinate names; otherwise, an error is raised.

• 

If Vectors are displayed in BasisFormat, the basis vectors for a vector field object are displayed using overbars to visually distinguish a vector field from a free Vector.

• 

The routine evalVF can be used to evaluate a vector field at a point.

Examples

withVectorCalculus:

Note the overbars on the basis Vectors

vVectorFieldx,y,z,cartesianx,y,z

vxe_x+ye_y+ze_z

(1)

attributesv

vectorfield,coords=cartesianx,y,z

(2)

Aboutv

Type: Vector FieldComponents: x,y,zCoordinates: cartesianx,y,z

(3)

evalVFv,1,2,3

123

(4)

SetCoordinatessphericalr,φ,θ

sphericalr,φ,θ

(5)

vVectorField1r2,sinφ,cosθ

v1r2e_r+sinφe_φ+cosθe_θ

(6)

Aboutv

Type: Vector FieldComponents: 1r2,sinφ,cosθCoordinates: sphericalr,φ,θ

(7)

evalVFv,1,π2,0

111

(8)

SetCoordinatescylindricalr,θ,z

cylindricalr,θ,z

(9)

vVectorFieldrcosθ,sinθ,z2

vrcosθe_r+sinθe_θ+z2e_z

(10)

Aboutv

Type: Vector FieldComponents: rcosθ,sinθ,z2Coordinates: cylindricalr,θ,z

(11)

Curlv

0e_r+0e_θ+sinθ+rsinθre_z

(12)

Note that the Divergence procedure accepts a Vector-valued operator in place of a vector field.

dDivergencea,b,cb2+a2,1c3,1

da,b,c3a2+b2a

(13)

d2,2,2

8

(14)

See Also

attributes

convert/PhysicsVectors

Physics/Vectors

VectorCalculus

VectorCalculus[AddCoordinates]

VectorCalculus[BasisFormat]

VectorCalculus[Coordinates]

VectorCalculus[evalVF]

VectorCalculus[GetCoordinates]

VectorCalculus[MapToBasis]

VectorCalculus[SetCoordinates]