Vector - Maple Help

VectorCalculus

 Vector
 create a free Vector with specified components and a coordinate system

 Calling Sequence Vector[o](n, init, f, c)

Parameters

 o - (optional) one of row or column; specifies Vector orientation n - (optional) non-negative integer or integer range starting at 1; number of elements in the Vector init - (optional) Maple procedure, table, Array, Vector, set of equations, list, or expression of type algebraic; initial values for the Vector f - (optional) equation of the form fill=value; specifies Vector entries at locations not otherwise set c - (optional) name or an equation of the form coords=name or coordinates=name; specify the coordinate system, optionally indexed by coordinate names x1, x2, ... - algebraic expressions; initial values for the Vector

Description

 • The Vector command constructs a free Vector, one of the principal data structures of the Vector Calculus package.
 • The optional argument c specifies a coordinate system that will be attached to the constructed free Vector as an attribute. Commands in the VectorCalculus package understand a comprehensive set of coordinate systems.
 • All other arguments in Vector are passed to the top-level Vector constructor.
 • If c is omitted, the constructed free Vector will inherit the coordinate attribute from the current coordinate system. In this case, if the number of components specified does not match the expected dimension of the current coordinate system, an error will be raised.
 • The $<\mathrm{x1,}\mathrm{x2,}\mathrm{...}>$ syntax calls this command, but only after executing the with(VectorCalculus) command.  If any of the elements xi are not algebraic expressions, then the top-level Vector command is called instead.
 • The display format for free Vectors and vector fields can be controlled by calling BasisFormat. Note that the formatting of position Vectors and rooted Vectors is not affected by BasisFormat.
 • For details on the differences between free Vectors, position Vectors, and rooted Vectors, see VectorCalculus,Details.

Examples

 > $\mathrm{with}\left(\mathrm{VectorCalculus}\right):$
 > $v≔⟨a,b,c⟩$
 ${v}{≔}\left({a}\right){{e}}_{{x}}{+}\left({b}\right){{e}}_{{y}}{+}\left({c}\right){{e}}_{{z}}$ (1)
 > $\mathrm{attributes}\left(v\right)$
 ${\mathrm{coords}}{=}{\mathrm{cartesian}}$ (2)
 > $\mathrm{About}\left(v\right)$
 $\left[\begin{array}{cc}{\mathrm{Type:}}& {\mathrm{Free Vector}}\\ {\mathrm{Components:}}& \left[{a}{,}{b}{,}{c}\right]\\ {\mathrm{Coordinates:}}& {\mathrm{cartesian}}\end{array}\right]$ (3)
 > $\mathrm{GetCoordinates}\left(v\right)$
 ${\mathrm{cartesian}}$ (4)
 > $u≔\mathrm{Vector}\left(\left[a,b\right],'\mathrm{coords}'='\mathrm{polar}'\right)$
 ${u}{≔}\left({a}\right){{e}}_{{r}}{+}\left({b}\right){{e}}_{{\mathrm{θ}}}$ (5)
 > $\mathrm{GetCoordinates}\left(u\right)$
 ${\mathrm{polar}}$ (6)
 > $\mathrm{SetCoordinates}\left('\mathrm{spherical}'\left['r','\mathrm{\phi }','\mathrm{\theta }'\right]\right)$
 ${{\mathrm{spherical}}}_{{r}{,}{\mathrm{\phi }}{,}{\mathrm{\theta }}}$ (7)
 > $w≔\mathrm{VectorField}\left(⟨r|0|0⟩\right)$
 ${w}{≔}\left({r}\right){\stackrel{{_}}{{e}}}_{{r}}{+}\left({0}\right){\stackrel{{_}}{{e}}}_{{\mathrm{φ}}}{+}\left({0}\right){\stackrel{{_}}{{e}}}_{{\mathrm{θ}}}$ (8)
 > $\mathrm{GetCoordinates}\left(w\right)$
 ${{\mathrm{spherical}}}_{{r}{,}{\mathrm{\phi }}{,}{\mathrm{\theta }}}$ (9)