PLUTO  4.4-patch2
Functions
rhs_source.c File Reference

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)
 

Detailed Description

Add source terms to the right hand side of RHD or RMHD equations in conservative form. These include

  1. Body forces;
  2. Powell's 8-waves source terms;

Care is taken to ensure that gravity components are included even when a direction is not active. The following table summarizes:

1D (x):

Sweepgx gy gz
x o o o

2D (x,y):

Sweepgx gy gz
x o
y o o

2D (x,z):

Sweepgx gy gz
x o
z o o

3D (x,y,z):

Sweepgx gy gz
x o
y o
z o

For consistency, the same approach must be used in PrimSource().

Author
A. Mignone (migno.nosp@m.ne@t.nosp@m.o.inf.nosp@m.n.it)
Date
Apr 25, 2020

Function Documentation

◆ RightHandSideSource()

void RightHandSideSource ( const Sweep sweep,
timeStep Dts,
int  beg,
int  end,
double  dt,
double *  phi_p,
Grid grid 
)
Parameters
[in,out]statepointer to State_1D structure
[in]Dtspointer to time step structure
[in]beginitial index of computation
[in]endfinal index of computation
[in]dttime increment
[in]phi_pforce potential at interfaces
[in]gridpointer to Grid structure
Returns
This function has no return value.