PLUTO
4.4-patch2
|
Add source terms to the right hand side of relativistic HD/MHD eqns. More...
#include "pluto.h"
Functions | |
void | RightHandSideSource (const Sweep *sweep, timeStep *Dts, int beg, int end, double dt, double *phi_p, Grid *grid) |
Add source terms to the right hand side of RHD or RMHD equations in conservative form. These include
Care is taken to ensure that gravity components are included even when a direction is not active. The following table summarizes:
1D (x):
Sweep | gx | gy | gz |
---|---|---|---|
x | o | o | o |
2D (x,y):
Sweep | gx | gy | gz |
---|---|---|---|
x | o | ||
y | o | o |
2D (x,z):
Sweep | gx | gy | gz |
---|---|---|---|
x | o | ||
z | o | o |
3D (x,y,z):
Sweep | gx | gy | gz |
---|---|---|---|
x | o | ||
y | o | ||
z | o |
For consistency, the same approach must be used in PrimSource().
void RightHandSideSource | ( | const Sweep * | sweep, |
timeStep * | Dts, | ||
int | beg, | ||
int | end, | ||
double | dt, | ||
double * | phi_p, | ||
Grid * | grid | ||
) |
[in,out] | state | pointer to State_1D structure |
[in] | Dts | pointer to time step structure |
[in] | beg | initial index of computation |
[in] | end | final index of computation |
[in] | dt | time increment |
[in] | phi_p | force potential at interfaces |
[in] | grid | pointer to Grid structure |