Data Structures | Files | Defines | Typedefs | Functions

Vmgrid class

Oracle for Cartesian mesh data. More...

Data Structures

struct  sVmgrid
 Multiresoltion oracle for Cartesian mesh data. More...

Files

file  vmgrid.h
 

Multiresolution oracle for Cartesian mesh data.


file  vmgrid.c
 

Class Vmgrid methods.


Defines

#define VMGRIDMAX   20
 The maximum number of levels in the grid hiearchy.

Typedefs

typedef struct sVmgrid Vmgrid
 Declaration of the Vmgrid class as the Vgmrid structure.

Functions

VEXTERNC VmgridVmgrid_ctor ()
 Construct Vmgrid object.
VEXTERNC int Vmgrid_ctor2 (Vmgrid *thee)
 Initialize Vmgrid object.
VEXTERNC int Vmgrid_value (Vmgrid *thee, double x[3], double *value)
 Get potential value (from mesh or approximation) at a point.
VEXTERNC void Vmgrid_dtor (Vmgrid **thee)
 Object destructor.
VEXTERNC void Vmgrid_dtor2 (Vmgrid *thee)
 FORTRAN stub object destructor.
VEXTERNC int Vmgrid_addGrid (Vmgrid *thee, Vgrid *grid)
 Add a grid to the hierarchy.
VEXTERNC int Vmgrid_curvature (Vmgrid *thee, double pt[3], int cflag, double *curv)
 Get second derivative values at a point.
VEXTERNC int Vmgrid_gradient (Vmgrid *thee, double pt[3], double grad[3])
 Get first derivative values at a point.
VEXTERNC VgridVmgrid_getGridByNum (Vmgrid *thee, int num)
 Get specific grid in hiearchy.
VEXTERNC VgridVmgrid_getGridByPoint (Vmgrid *thee, double pt[3])
 Get grid in hiearchy which contains specified point or VNULL.

Detailed Description

Oracle for Cartesian mesh data.


Function Documentation

VEXTERNC int Vmgrid_addGrid ( Vmgrid thee,
Vgrid grid 
)

Add a grid to the hierarchy.

Author:
Nathan Baker
Parameters:
theePointer to object to be destroyed
gridGrid to be added. As mentioned above, we would prefer to have the finest grid added first, next-finest second, ..., coarsest last -- this is how the grid will be searched when looking up values for points. However, this is not enforced to provide flexibility for cases where the dataset is decomposed into disjoint partitions, etc.
Returns:
1 if successful, 0 otherwise

Definition at line 196 of file vmgrid.c.

VEXTERNC Vmgrid* Vmgrid_ctor (  )

Construct Vmgrid object.

Author:
Nathan Baker
Returns:
Newly allocated and initialized Vmgrid object

Definition at line 58 of file vmgrid.c.

VEXTERNC int Vmgrid_ctor2 ( Vmgrid thee )

Initialize Vmgrid object.

Author:
Nathan Baker
Parameters:
theeNewly allocated Vmgrid object
Returns:
Newly allocated and initialized Vmgrid object

Definition at line 73 of file vmgrid.c.

VEXTERNC int Vmgrid_curvature ( Vmgrid thee,
double  pt[3],
int  cflag,
double *  curv 
)

Get second derivative values at a point.

Author:
Nathan Baker (wrapper for Vgrid routine by Steve Bond)
Parameters:
theePointer to Vmgrid object
ptLocation to evaluate second derivative
cflag
  • 0: Reduced Maximal Curvature
  • 1: Mean Curvature (Laplace)
  • 2: Gauss Curvature
  • 3: True Maximal Curvature
curvSpecified curvature value
Returns:
1 if successful, 0 if off grid

Definition at line 139 of file vmgrid.c.

VEXTERNC void Vmgrid_dtor ( Vmgrid **  thee )

Object destructor.

Author:
Nathan Baker
Parameters:
theePointer to memory location of object to be destroyed

Definition at line 89 of file vmgrid.c.

VEXTERNC void Vmgrid_dtor2 ( Vmgrid thee )

FORTRAN stub object destructor.

Author:
Nathan Baker
Parameters:
theePointer to object to be destroyed

Definition at line 102 of file vmgrid.c.

VEXTERNC Vgrid* Vmgrid_getGridByNum ( Vmgrid thee,
int  num 
)

Get specific grid in hiearchy.

Author:
Nathan Baker
Parameters:
theePointer to Vmgrid object
numNumber of grid in hiearchy
Returns:
Pointer to specified grid
VEXTERNC Vgrid* Vmgrid_getGridByPoint ( Vmgrid thee,
double  pt[3] 
)

Get grid in hiearchy which contains specified point or VNULL.

Author:
Nathan Baker
Parameters:
theePointer to Vmgrid object
ptPoint to check
Returns:
Pointer to specified grid
VEXTERNC int Vmgrid_gradient ( Vmgrid thee,
double  pt[3],
double  grad[3] 
)

Get first derivative values at a point.

Author:
Nathan Baker and Steve Bond
Parameters:
theePointer to Vmgrid object
ptLocation to evaluate gradient
gradGradient
Returns:
1 if successful, 0 if off grid

Definition at line 168 of file vmgrid.c.

VEXTERNC int Vmgrid_value ( Vmgrid thee,
double  x[3],
double *  value 
)

Get potential value (from mesh or approximation) at a point.

Author:
Nathan Baker
Parameters:
theeVmgrid obejct
xPoint at which to evaluate potential
valueValue of data at point x
Returns:
1 if successful, 0 if off grid

Definition at line 108 of file vmgrid.c.