14 #undef _MINIMUM_GHOSTS_ 18 #define _MINIMUM_GHOSTS_ 2 47 int ghosts = solver->
ghosts;
48 int ndims = solver->
ndims;
49 int nvars = solver->
nvars;
52 static double one_twelve = 1.0/12.0;
55 fprintf(stderr,
"Error in SecondDerivativeFourthOrder(): input arrays not allocated.\n");
59 fprintf(stderr,
"Error in SecondDerivativeFourthOrder(): insufficient number of ghosts.\n");
65 int indexC[ndims], index_outer[ndims], bounds_outer[ndims];
71 for (i = 0; i < dim[dir]; i++) {
72 int qm2, qm1, qC, qp1, qp2;
78 for (v=0; v<nvars; v++)
79 D2f[qC*nvars+v] = (-f[qm2*nvars+v]+16*f[qm1*nvars+v]-30*f[qC*nvars+v]+16*f[qp1*nvars+v]-f[qp2*nvars+v])*one_twelve;
MPI related function definitions.
Some basic definitions and macros.
Structure containing all solver-specific variables and functions.
Contains structure definition for hypar.
#define _ArrayIndex1D_(N, imax, i, ghost, index)
#define _ArraySetValue_(x, size, value)
#define _ArrayIncrementIndex_(N, imax, i, done)
int SecondDerivativeFourthOrderCentral(double *D2f, double *f, int dir, void *s, void *m)
#define _ArrayCopy1D_(x, y, size)
Contains macros and function definitions for common array operations.
Definitions for the functions computing the second derivative.