linalg(deprecated)
vecpotent
compute the vector potential
Calling Sequence
Parameters
Description
Examples
vecpotent(f, var, 'V')
f
-
vector function of length three
var
list of three variables
V
name in which the vector potential is returned
Important: The linalg package has been deprecated. Use the superseding command VectorCalculus[VectorPotential], instead.
- For information on migrating linalg code to the new packages, see examples/LinearAlgebraMigration.
The function vecpotent determines whether a given vector function has a vector potential, and determines that vector potential if it exists.
The function returns true if the function f has a vector potential, and false if it does not. The vector potential exists if and only if the divergence of f is zero.
If a vector potential for f exists, it will be assigned to the name given in the third argument V. If vecpotent returns true, then V will be assigned a vector function such that curl V = f.
The command with(linalg,vecpotent) allows the use of the abbreviated form of this command.
with⁡linalg:
f≔x2⁢y,−12⁢x⁢y2,−x⁢y⁢z
f≔x2⁢y,−x⁢y22,−x⁢y⁢z
vecpotent⁡f,x,y,z,V
true
print⁡V
−x⁢y2⁢z2−x2⁢y⁢z0
g≔x2,y2,z2
vecpotent⁡g,x,y,z,G
false
See Also
linalg(deprecated)[potential]
LinearAlgebra
VectorCalculus[VectorPotential]
Download Help Document