12 #if HAVE_ENERGY && ENTROPY_SWITCH
33 v1d[
i][PRS] = d->
Vc[PRS][
k][
j][
i];
48 #if PHYSICS == MHD && (RESISTIVITY == EXPLICIT)
50 double rho, rhog, gm1, vc[
NVAR];
51 double Jc[3],
eta[3], J2eta;
52 double ***Jx1, *x1, *dx1;
53 double ***Jx2, *x2, *dx2;
54 double ***Jx3, *x3, *dx3;
95 #if GEOMETRY != CARTESIAN
96 print1 (
"! EntropyOhmicHeating: only CT supported in this geometry.\n")
106 VAR_LOOP(nv) vc[nv] = V[nv][k][j][i];
108 rhog = pow(rho,-gm1);
112 for (nv = 0; nv < 3; nv++) J2eta += Jc[nv]*Jc[nv]*eta[nv];
118 UU[k][j][i][ENTR] += dt*rhog*gm1*J2eta;
void EntropyOhmicHeating(const Data *, Data_Arr, double, Grid *)
double **** J
Electric current defined as curl(B).
#define AVERAGE_YZ(q, k, j, i)
void print1(const char *fmt,...)
#define CDIFF_X2(b, k, j, i)
double **** Vc
The main four-index data array used for cell-centered primitive variables.
void ComputeEntropy(const Data *, Grid *)
void Entropy(double **v, double *s, int beg, int end)
#define AVERAGE_XY(q, k, j, i)
void Resistive_eta(double *v, double x1, double x2, double x3, double *J, double *eta)
#define CDIFF_X1(b, k, j, i)
long int NMAX_POINT
Maximum number of points among the three directions, boundaries excluded.
#define AVERAGE_XZ(q, k, j, i)
#define ARRAY_2D(nx, ny, type)
#define CDIFF_X3(b, k, j, i)
#define QUIT_PLUTO(e_code)
long int NX1_TOT
Total number of zones in the X1 direction (boundaries included) for the local processor.