Shiokaze Framework
A research-oriented fluid solver for computer graphics
array_derivative2 Class Reference

Class that computes the derivative of physical quantities at arbitrary position. More...

#include <array_derivative2.h>

Static Public Member Functions

static void derivative_interpolate_coef (const shape2 &shape, const vec2d &p, vec2i indices[4], double coef[DIM2][4])
 Get the coefficients for the gradient. More...
 
template<class T >
static void derivative (const array2< T > &array, const vec2d &p, T result[DIM2])
 Computes the the gradient of a physical quantity. More...
 
template<class T >
static vec2< T > derivative (const array2< T > &array, const vec2d &origin, double dx, const vec2d &p)
 Computes the the gradient of a physical quantity. More...
 

Detailed Description

Class that computes the derivative of physical quantities at arbitrary position.

Member Function Documentation

◆ derivative() [1/2]

template<class T >
static vec2<T> array_derivative2::derivative ( const array2< T > &  array,
const vec2d origin,
double  dx,
const vec2d p 
)
inlinestatic

Computes the the gradient of a physical quantity.

Parameters
[in]arrayGrid.
[in]originOrigin.
[in]dxGrid cell size.
[in]pPosition in physical space.
Returns
Gradient output.

◆ derivative() [2/2]

template<class T >
static void array_derivative2::derivative ( const array2< T > &  array,
const vec2d p,
result[DIM2] 
)
inlinestatic

Computes the the gradient of a physical quantity.

Parameters
[in]arrayGrid.
[in]pPosition in index space.
[out]resultGradient output.

◆ derivative_interpolate_coef()

static void array_derivative2::derivative_interpolate_coef ( const shape2 shape,
const vec2d p,
vec2i  indices[4],
double  coef[DIM2][4] 
)
inlinestatic

Get the coefficients for the gradient.

Parameters
[in]shapeShape of the grid.
[in]pPosition in index space.
[out]indicesIndices output.
[out]coefCorresponding coefficents output.

The documentation for this class was generated from the following file: