Package Scientific :: Package Geometry :: Module TensorAnalysis :: Class VectorField
[hide private]
[frames] | no frames]

Class VectorField



Functions.Interpolation.InterpolatingFunction --+    
                                                |    
                                      TensorField --+
                                                    |
                                                   VectorField

Vector field (tensor field of rank 1)

A subclass of TensorField.

Nested Classes [hide private]
  _constructor
Vector field (tensor field of rank 1)

Instance Methods [hide private]
  __init__(self, axes, values, default=None, check=True)
  _curl(self, x, y, z)
  _divergence(self, x, y, z)
  _strain(self, x, y, z)
  curl(self)
Returns the curl @rtype VectorField
  divergence(self)
Returns the divergence @rtype ScalarField
  divergenceCurlAndStrain(self)
Returns all derivative fields: divergence, curl, and strain @rtype (ScalarField, VectorField, TensorField)
  laplacian(self)
Returns the laplacian @rtype VectorField
ScalarField length(self)
Returns a scalar field corresponding to the length (norm) of the vector field.
  strain(self)
Returns the strain @rtype TensorField of rank 2
Scientifc.Geometry.Tensor zero(self)
Returns a tensor of the same rank as the field values with all elements equal to zero

Inherited from TensorField: __add__, __call__, __getitem__, __sub__, allDerivatives, derivative

Inherited from TensorField (private): _checkCompatibility, _reduceAxis

Inherited from Functions.Interpolation.InterpolatingFunction: __abs__, __getattr__, __getslice__, __len__, arccos, arcsin, arctan, cos, cosh, definiteIntegral, exp, fitPolynomial, integral, log, selectInterval, sin, sinh, sqrt, tan, tanh


Method Details [hide private]

__init__(self, axes, values, default=None, check=True)
(Constructor)

 
Parameters:
  • axes (sequence of Numeric.array of rank 1) - three arrays specifying the axis ticks for the three axes
  • values (Numeric.array of four dimensions) - an array containing the field values. Its first three dimensions correspond to the x, y, z directions and must have lengths compatible with the axis arrays. The fourth dimension must have length 3.
  • default (Scientific.Geometry.Vector or NoneType) - the value of the field for points outside the grid. A value of 'None' means that an exception will be raised for an attempt to evaluate the field outside the grid. Any other value must a vector
Raises:
  • ValueError - if the arguments are not consistent
Overrides: TensorField.__init__

_curl(self, x, y, z)

 

_divergence(self, x, y, z)

 

_strain(self, x, y, z)

 

curl(self)

 
Returns:
the curl @rtype VectorField

divergence(self)

 
Returns:
the divergence @rtype ScalarField

divergenceCurlAndStrain(self)

 
Returns:
all derivative fields: divergence, curl, and strain @rtype (ScalarField, VectorField, TensorField)

laplacian(self)

 
Returns:
the laplacian @rtype VectorField

length(self)

 
Returns: ScalarField
a scalar field corresponding to the length (norm) of the vector field.

strain(self)

 
Returns:
the strain @rtype TensorField of rank 2

zero(self)

 
Returns: Scientifc.Geometry.Tensor
a tensor of the same rank as the field values with all elements equal to zero
Overrides: TensorField.zero
(inherited documentation)