MoDeNa  1.0
Software framework facilitating sequential multi-scale modelling
differenceTable.h File Reference

Calculate difference table for the moments realizability check. More...

Go to the source code of this file.

Functions

void enterMoments (double *mom, const int nNodes)
 input the moments More...
 
void enterWeightsNodes (double *we, double *vi, int nNodes)
 inputs weights and nodes of quadrature More...
 
void weightsNodesToMoms (double *mom, double *we, double *vi, int nNodes)
 converts weights and nodes to moments More...
 
void printMoms (const double *m, int nNodes)
 prints moments More...
 
bool momentsPositivite (const double *moments, int &nNodes)
 
void normalizeMom (double *m, int nNodes)
 normalizes the moments More...
 
void denormalizeMom (double *m, double M0, int nNodes)
 de-normalizes the moments More...
 
void initializeDifferenceTable (double **differenceTable, int nNodes)
 initializes the difference table More...
 
void printDifferenceTable (double **differenceTable, int nNodes)
 prints the difference table More...
 
void buildDifferenceTable (double **differenceTable, double *mom, int nNodes)
 constructs the difference table More...
 
int isRealizable (double **differenceTable, int nNodes)
 checks if the moments are realizable More...
 
double vectorNorm (vector< double > const &v)
 normalized vector used in McGraw correction algorithm More...
 

Detailed Description

Calculate difference table for the moments realizability check.

Definition in file differenceTable.h.

Function Documentation

◆ buildDifferenceTable()

void buildDifferenceTable ( double **  differenceTable,
double *  mom,
int  nNodes 
)

constructs the difference table

Parameters
differenceTablepointer to difference table
mommoments of different orders
nNodesnumber of nodes
Returns
void

Definition at line 183 of file differenceTable.h.

◆ denormalizeMom()

void denormalizeMom ( double *  m,
double  M0,
int  nNodes 
)

de-normalizes the moments

Parameters
mmoments of different orders
M0moment of order zero based on unit volume of the foam
nNodesnumber of nodes
Returns
void

Definition at line 147 of file differenceTable.h.

◆ enterMoments()

void enterMoments ( double *  mom,
const int  nNodes 
)

input the moments

Parameters
mommoments of different orders
nNodesnumber of nodes
Returns
void

Definition at line 82 of file differenceTable.h.

◆ enterWeightsNodes()

void enterWeightsNodes ( double *  we,
double *  vi,
int  nNodes 
)

inputs weights and nodes of quadrature

Parameters
weweights of quadrature
vinodes of quadrature
nNodesnumber of nodes
Returns
void

Definition at line 90 of file differenceTable.h.

◆ initializeDifferenceTable()

void initializeDifferenceTable ( double **  differenceTable,
int  nNodes 
)

initializes the difference table

Parameters
differenceTablepointer to difference table
nNodesnumber of nodes
Returns
void

Definition at line 155 of file differenceTable.h.

◆ isRealizable()

int isRealizable ( double **  differenceTable,
int  nNodes 
)

checks if the moments are realizable

Parameters
differenceTablepointer to the difference table
nNodesnumber of nodes
Returns
1 if the moments are realizable

Definition at line 198 of file differenceTable.h.

◆ momentsPositivite()

bool momentsPositivite ( const double *  moments,
int &  nNodes 
)
Parameters
momentsmoments of different orders
nNodesnumber of nodes
Returns
true if moments are positive

Definition at line 124 of file differenceTable.h.

◆ normalizeMom()

void normalizeMom ( double *  m,
int  nNodes 
)

normalizes the moments

Parameters
mmoments of different orders
nNodesnumber of nodes
Returns
void

Definition at line 139 of file differenceTable.h.

◆ printDifferenceTable()

void printDifferenceTable ( double **  differenceTable,
int  nNodes 
)

prints the difference table

Parameters
differenceTablepointer to difference table
nNodesnumber of nodes
Returns
void

Definition at line 166 of file differenceTable.h.

◆ printMoms()

void printMoms ( const double *  m,
int  nNodes 
)

prints moments

Parameters
mmoments of different orders
nNodesnumber of nodes
Returns
void

Definition at line 116 of file differenceTable.h.

◆ vectorNorm()

double vectorNorm ( vector< double > const &  v)

normalized vector used in McGraw correction algorithm

Parameters
vinput vector
Returns
normalized vector

Definition at line 212 of file differenceTable.h.

◆ weightsNodesToMoms()

void weightsNodesToMoms ( double *  mom,
double *  we,
double *  vi,
int  nNodes 
)

converts weights and nodes to moments

Parameters
mommoments of different orders
weweights of quadrature
vinodes of quadrature
nNodesnumber of nodes
Returns
void

Definition at line 99 of file differenceTable.h.