Functions to calculate the diffusion coefficients for resistivity. More...
Go to the source code of this file.
Functions | |
void | convert_diffusion (Real sigma_O, Real sigma_H, Real sigma_P, Real *eta_O, Real *eta_H, Real *eta_A) |
Convert conductivities to diffusivities. | |
void | get_eta (GridS *pG) |
Get magnetic diffusivities. | |
void | eta_single_const (GridS *pG, int i, int j, int k, Real *eta_O, Real *eta_H, Real *eta_A) |
Single-ion prescription with constant diffusivities. | |
void | eta_single_user (GridS *pG, int i, int j, int k, Real *eta_O, Real *eta_H, Real *eta_A) |
Single-ion prescription with user defined diffusivities. | |
void | eta_general_user (GridS *pG, int i, int j, int k, Real *eta_O, Real *eta_H, Real *eta_A) |
Generalized prescription with user defined conductivities. |
Functions to calculate the diffusion coefficients for resistivity.
We provide two standard prescriptions, divided into 3 cases:
CONTAINS PUBLIC FUNCTIONS:
Definition in file get_eta.c.
void convert_diffusion | ( | Real | sigma_O, | |
Real | sigma_H, | |||
Real | sigma_P, | |||
Real * | eta_O, | |||
Real * | eta_H, | |||
Real * | eta_A | |||
) |
Convert conductivities to diffusivities.
NOTE: c^2/4pi factor is NOT included, so (eta x sigma) is dimensionless. The conductivity coefficients should have the right dimension.
Definition at line 177 of file get_eta.c.
Referenced by eta_general_user().
Generalized prescription with user defined conductivities.
This corresponds to CASE 3. Note the same get_eta_user() function is used to calculate conductivities rather than diffusivities here.
Definition at line 155 of file get_eta.c.
References convert_diffusion(), and get_eta_user().
Single-ion prescription with constant diffusivities.
NEED global parameters: eta_Ohm, Q_Hall and Q_AD. ONLY eta_Ohm has the dimension of diffusivity. This correspond to CASE 1.
Definition at line 108 of file get_eta.c.
References ConsS::B1c, ConsS::B2c, ConsS::B3c, ConsS::d, d_ind, eta_Ohm, Q_AD, Q_Hall, and GridS::U.
Single-ion prescription with user defined diffusivities.
This corresponds to CASE 2.
Definition at line 136 of file get_eta.c.
References get_eta_user().
void get_eta | ( | GridS * | pG | ) |
Get magnetic diffusivities.
Definition at line 63 of file get_eta.c.
References GridS::eta_AD, GridS::eta_Hall, GridS::eta_Ohm, get_myeta, GridS::ie, il, GridS::is, iu, GridS::je, jl, GridS::js, ju, GridS::ke, kl, GridS::ks, ku, and GridS::Nx.
Referenced by integrate_diff().