PLUTO  4.0
 All Data Structures Files Functions Variables Enumerations Macros Pages
Functions
res_flux.c File Reference

Compute the resistive MHD flux. More...

#include "pluto.h"

Functions

void ResistiveFlux (Data_Arr V, double **RF, double **dcoeff, int beg, int end, Grid *grid)
 

Detailed Description

Compute the resistive fluxes for the induction and energy equations. In the induction equation, fluxes are computed by explicitly writing the curl operator in components. In Cartesian components, for instance, one has

\[ \pd{\vec{B}}{t} = - \nabla\times{\vec{E}_{\rm res}} = \pd{}{x}\left(\begin{array}{c} 0 \\ \noalign{\medskip} \eta_z J_z \\ \noalign{\medskip} - \eta_y J_y \end{array}\right) + \pd{}{y}\left(\begin{array}{c} - \eta_z J_z \\ \noalign{\medskip} 0 \\ \noalign{\medskip} \eta_x J_x \end{array}\right) + \pd{}{z}\left(\begin{array}{c} \eta_y J_y \\ \noalign{\medskip} -\eta_x J_x \\ \noalign{\medskip} 0 \end{array}\right) \,,\qquad \left(\vec{E}_{\rm res} = \tens{\eta}\cdot\vec{J}\right) \]

where $\tens{\eta}$ is the resistive diagonal tensor and $J = \nabla\times\vec{B}$ is the current density. The corresponding contribution to the energy equation is

\[ \pd{E}{t} = -\nabla\cdot\Big[(\tens{\eta}\cdot\vec{J})\times\vec{B}\Big] = - \pd{}{x}\left(\eta_yJ_yB_z - \eta_zJ_zB_y\right) - \pd{}{y}\left(\eta_zJ_zB_x - \eta_xJ_xB_z\right) - \pd{}{z}\left(\eta_xJ_xB_y - \eta_yJ_yB_x\right) \]

References

Authors
A. Mignone (migno.nosp@m.ne@p.nosp@m.h.uni.nosp@m.to.i.nosp@m.t)
T. Matsakos
Date
Nov 5, 2012

Function Documentation

void ResistiveFlux ( Data_Arr  V,
double **  RF,
double **  dcoeff,
int  beg,
int  end,
Grid grid 
)

Compute resistive fluxes for the induction and energy equations. Also, compute the diffusion coefficient. Called by either ParabolicFlux or ParabolicRHS.

Parameters
[in]V3D data array of primitive variables
[out]RFthe resistive fluxes
[out]dcoeffthe diffusion coefficients evaluated at cell interfaces
[in]beginitial index of computation
[in]endfinal index of computation
[in]gridpointer to an array of Grid structures.