PLUTO
int_bound_reset.c
Go to the documentation of this file.
1 /* ///////////////////////////////////////////////////////////////////// */
2 /*!
3  \file
4  \brief Reset to zero the right hand side in the internal boundary.
5 
6  Set to zero the right hand side of the conservative equations
7  in those cells that have been flagged with ::FLAG_INTERNAL_BOUNDARY.
8 
9  \author A. Mignone (mignone@ph.unito.it)
10  \date July 22, 2015
11 */
12 /* ///////////////////////////////////////////////////////////////////// */
13 #include "pluto.h"
14 
15 #if INTERNAL_BOUNDARY == YES
16 /* *********************************************************************** */
17 void InternalBoundaryReset (const State_1D *state, Time_Step *Dts,
18  int beg, int end, Grid *grid)
19 /*!
20  *
21  * \param [in,out] state pointer to State_1D structure
22  * \param [in] Dts pointer to time step structure
23  * \param [in] beg initial index of computation
24  * \param [in] end final index of computation
25  * \param [in] dt time increment
26  * \param [in] grid pointer to Grid structure
27  *
28  * \return This function has no return value.
29  ************************************************************************* */
30 {
31  int i,nv;
32 
33  for (i = beg; i <= end; i++){
34  if (state->flag[i] & FLAG_INTERNAL_BOUNDARY){
35  NVAR_LOOP(nv) state->rhs[i][nv] = 0.0;
36 /* Dts->cmax[i] = 0.0; */
37  }
38  }
39 }
40 #endif
#define FLAG_INTERNAL_BOUNDARY
Zone belongs to an internal boundary region and should be excluded from being updated in time...
Definition: pluto.h:184
#define NVAR_LOOP(n)
Definition: pluto.h:618
Definition: structs.h:78
unsigned char * flag
Definition: structs.h:168
PLUTO main header file.
int i
Definition: analysis.c:2
void InternalBoundaryReset(const State_1D *, Time_Step *, int, int, Grid *)