PLUTO  4.4-patch2
Functions
ct_emf_average.c File Reference

Collects different EMF averaging schemes. More...

#include "pluto.h"

Functions

void CT_EMF_ArithmeticAverage (const EMF *Z1, const double w)
 
void CT_EMF_IntegrateToCorner (const Data *d, const EMF *emf, Grid *grid)
 
void CT_EMF_Riemann2D (const Data *d, const EMF *emf, Grid *grid)
 
void CT_EMF_Flux (const Data *d, const EMF *emf, Grid *grid)
 

Detailed Description

Author
A. Mignone
Date
Dec 09, 2020

Function Documentation

◆ CT_EMF_ArithmeticAverage()

void CT_EMF_ArithmeticAverage ( const EMF Z1,
const double  w 
)

Compute arithmetic average of EMF at cell edges by combining the four electric field values computed at zone faces as upwind Godunov fluxes into an edge-centered value.
The face-centered EMF should have been stored by previous calls to CT_StoreEMF() during the one-dimensional sweeps.
This function employs a simple arithmetic averaging of the face-centered electric field.

References:

  • "A Staggered Mesh Algorithm Using High Order Godunov Fluxes to Ensure Solenoidal Magnetic Fields in Magnetohydrodynamic Simulations"
    Balsara & Spicer, JCP (1999) 149, 270.
Parameters
[in]Z1pointer to EMF structure
[in]wweighting factor
Returns
This function has no return value.

◆ CT_EMF_Flux()

void CT_EMF_Flux ( const Data d,
const EMF emf,
Grid grid 
)

Reconstruct electric field at faces to the edges. The electric field interpolated from the 1D Riemann solver and defined as E = E(pnt) + 2*E(diff), that is, the sum of the smooth flux term plust twice the diffusive part.

◆ CT_EMF_IntegrateToCorner()

void CT_EMF_IntegrateToCorner ( const Data d,
const EMF emf,
Grid grid 
)

Add derivatives to the 4-point arithmetic average of magnetic fields. Obtain the electric field at corners.

References:

  • "An unsplit Godunov method for ideal MHD via constrained transport"
    Gardiner & Stone, JCP (2005) 205, 509. See Eq. (41), (45) and (50).
Parameters
[in]dpointer to PLUTO Data structure
[in]emfpointer to EMF structure
[in]gridpointer to Grid structure
Returns
This function has no return value.

◆ CT_EMF_Riemann2D()

void CT_EMF_Riemann2D ( const Data d,
const EMF emf,
Grid grid 
)

Reconstruct the electric field to zone edge using the general UCT formalism,

E = (aL*vL[i]*bL[i] + aR*vR[i]*bR[i]) +- (dR*bR - dL*bL)

where the a and d coefficients are retrieved from the 1D Riemann solver at zone edges. This function is used by UCT_HLL, UCT_HLLD and UCT_GFORCE