10 double *u,
int dir,
void *s,
double t)
16 int ndims = solver->
ndims;
17 int nvars = solver->
nvars;
18 int ghosts = solver->
ghosts;
21 int index_outer[ndims], index_inter[ndims], bounds_outer[ndims], bounds_inter[ndims];
23 _ArrayCopy1D_(dim,bounds_inter,ndims); bounds_inter[dir] += 1;
28 for (index_inter[dir] = 0; index_inter[dir] < bounds_inter[dir]; index_inter[dir]++) {
36 x = 0.5 * ( x1 + x2 );
38 }
else if (dir == 1) {
44 y = 0.5 * ( y1 + y2 );
47 for (v = 0; v < nvars; v++)
48 fI[nvars*p+v] =
drift * (
drift > 0 ? fL[nvars*p+v] : fR[nvars*p+v] );
double FPPowerSystemDriftFunction(int, void *, double, double, double)
Some basic definitions and macros.
int FPPowerSystemUpwind(double *fI, double *fL, double *fR, double *uL, double *uR, double *u, int dir, void *s, double t)
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 _GetCoordinate_(dir, i, dim, ghosts, x, coord)
#define _ArrayCopy1D_(x, y, size)
Contains macros and function definitions for common array operations.