51 int ghosts = solver->
ghosts;
52 int ndims = solver->
ndims;
53 int nvars = solver->
nvars;
58 fprintf(stderr,
"Error in FirstDerivativeSecondOrder(): input arrays not allocated.\n");
64 int indexC[ndims], index_outer[ndims], bounds_outer[ndims];
68 #pragma omp parallel for schedule(auto) default(shared) private(i,j,v,index_outer,indexC)
69 for (j=0; j<N_outer; j++) {
73 for (i = -ghosts; i < -ghosts+1; i++) {
77 for (v=0; v<nvars; v++) Df[qC*nvars+v] = f[qR*nvars+v]-f[qC*nvars+v];
80 for (i = -ghosts+1; i < dim[dir]+ghosts-1; i++) {
85 for (v=0; v<nvars; v++) Df[qC*nvars+v] =
max(bias,0)*f[qR*nvars+v]-bias*f[qC*nvars+v]+
min(bias,0)*f[qL*nvars+v];
88 for (i = dim[dir]+ghosts-1; i < dim[dir]+ghosts; i++) {
92 for (v=0; v<nvars; v++) Df[qC*nvars+v] = f[qC*nvars+v]-f[qL*nvars+v];
Definitions for the functions computing the first derivative.
#define _ArrayIndexnD_(N, index, imax, i, ghost)
int FirstDerivativeFirstOrder(double *, double *, int, int, void *, void *)
MPI related function definitions.
#define _ArrayIndex1D_(N, imax, i, ghost, index)
Contains function definitions for common mathematical functions.
#define _ArrayCopy1D_(x, y, size)
Contains structure definition for hypar.
Some basic definitions and macros.
Contains macros and function definitions for common array operations.
#define _ArrayProduct1D_(x, size, p)
Structure of MPI-related variables.
Structure containing all solver-specific variables and functions.