Derivative class to perform finite difference operations on the data stored in field.
More...
#include "lib/derivative.h"
|
| derivative (const grid &gridData, const field &F) |
| Constructor of the derivative class. More...
|
|
void | calcDerivative1_x (blitz::Array< real, 3 > outArray) |
| Function to compute the first derivative of the field with respect to x. More...
|
|
void | calcDerivative1_y (blitz::Array< real, 3 > outArray) |
| Function to compute the first derivative of the field with respect to y. More...
|
|
void | calcDerivative1_z (blitz::Array< real, 3 > outArray) |
| Function to compute the first derivative of the field with respect to z. More...
|
|
void | calcDerivative2xx (blitz::Array< real, 3 > outArray) |
| Function to compute the second derivative of the field with respect to x. More...
|
|
void | calcDerivative2yy (blitz::Array< real, 3 > outArray) |
| Function to compute the second derivatives of the field with respect to y. More...
|
|
void | calcDerivative2zz (blitz::Array< real, 3 > outArray) |
| Function to compute the second derivatives of the field with respect to z. More...
|
|
Derivative class to perform finite difference operations on the data stored in field.
It contains functions to perform the finite difference operations on fields. For fields on non-uniform grids, the derivatives are transformed with appropriate grid derivatives taken from the grid class. For many classes of SARAS, empty destructors were removed. Refer reference [3] of General Articles in README for more details.
◆ derivative()
derivative::derivative |
( |
const grid & |
gridData, |
|
|
const field & |
F |
|
) |
| |
Constructor of the derivative class.
The constructor assigns values to the two const parameters of the derivative class,
namely <B>grid</B> and <B>F</B>.
It resizes tmpArray, the blitz array used to hold temporary data while calculating
derivatives, computes the factors to be used with blitz stencils, and assigns
the appropriate references to grid derivatives for performing finite-difference
operations on non-uniform grids.
- Parameters
-
gridData | is a const reference to the global data in the grid class |
F | is a reference to the field on which finite-difference operations will be performed |
◆ calcDerivative1_x()
void derivative::calcDerivative1_x |
( |
blitz::Array< real, 3 > |
outArray | ) |
|
Function to compute the first derivative of the field with respect to x.
This function must be called using an output array whose shape and size
should be same as that of the field.
It uses blitz stencils to calculate derivatives using central differencing.
- Parameters
-
outArray | is the blitz array into which result will be written. |
◆ calcDerivative1_y()
void derivative::calcDerivative1_y |
( |
blitz::Array< real, 3 > |
outArray | ) |
|
Function to compute the first derivative of the field with respect to y.
This function must be called using an output array whose shape and size
should be same as that of the field.
It uses blitz stencils to calculate derivatives using central differencing.
- Parameters
-
outArray | is the blitz array into which result will be written. |
◆ calcDerivative1_z()
void derivative::calcDerivative1_z |
( |
blitz::Array< real, 3 > |
outArray | ) |
|
Function to compute the first derivative of the field with respect to z.
This function must be called using an output array whose shape and size
should be same as that of the field.
It uses blitz stencils to calculate derivatives using central differencing.
- Parameters
-
outArray | is the blitz array into which result will be written. |
◆ calcDerivative2xx()
void derivative::calcDerivative2xx |
( |
blitz::Array< real, 3 > |
outArray | ) |
|
Function to compute the second derivative of the field with respect to x.
This function must be called using an output array whose shape and size
should be same as that of the field.
It uses blitz stencils to calculate derivatives using central differencing.
- Parameters
-
outArray | is the blitz array into which result will be written. |
◆ calcDerivative2yy()
void derivative::calcDerivative2yy |
( |
blitz::Array< real, 3 > |
outArray | ) |
|
Function to compute the second derivatives of the field with respect to y.
This function must be called using an output array whose shape and size
should be same as that of the field.
It uses blitz stencils to calculate derivatives using central differencing.
- Parameters
-
outArray | is the blitz array into which result will be written. |
◆ calcDerivative2zz()
void derivative::calcDerivative2zz |
( |
blitz::Array< real, 3 > |
outArray | ) |
|
Function to compute the second derivatives of the field with respect to z.
This function must be called using an output array whose shape and size
should be same as that of the field.
It uses blitz stencils to calculate derivatives using central differencing.
- Parameters
-
outArray | is the blitz array into which result will be written. |
The documentation for this class was generated from the following files: