30 int ndims = solver->
ndims;
31 int nvars = solver->
nvars;
33 int ghosts = solver->
ghosts;
35 int index_outer[ndims], index_inter[ndims], bounds_outer[ndims], bounds_inter[ndims];
37 _ArrayCopy1D_(dim,bounds_inter,ndims); bounds_inter[dir] += 1;
42 for (index_inter[dir] = 0; index_inter[dir] < bounds_inter[dir]; index_inter[dir]++) {
45 int indexL[ndims];
_ArrayCopy1D_(index_inter,indexL,ndims); indexL[dir]--;
50 for (v = 0; v < nvars; v++) {
51 double eigL = u[nvars*pL+v],
54 if ((eigL > 0) && (eigR > 0)) {
55 fI[nvars*p+v] = fL[nvars*p+v];
56 }
else if ((eigL < 0) && (eigR < 0)) {
57 fI[nvars*p+v] = fR[nvars*p+v];
60 fI[nvars*p+v] = 0.5 * (fL[nvars*p+v] + fR[nvars*p+v] - alpha * (uR[nvars*p+v] - uL[nvars*p+v]));
Contains function definitions for common mathematical functions.
int BurgersUpwind(double *fI, double *fL, double *fR, double *uL, double *uR, double *u, int dir, void *s, double t)
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)
#define _ArrayCopy1D_(x, y, size)
Contains macros and function definitions for common array operations.