WARPXM v1.10.0
Loading...
Searching...
No Matches
examples.dg.mhd.shock_1d_brio-wu Namespace Reference

Functions

def run_name ()
 

Variables

str torder = 'SSPRK3'
 
int sord = 4
 
str sorder_str = ''
 
int cfl = .8 / (2*sord - 1)
 
float cfl_diffusion = 1.0
 
str num_flux = "Rusanov"
 
int dt = 1e-6
 
int tend = .1
 
int nout = 100
 
int num_elem = 100
 
str gradient_method = "ldg"
 
None penalty_beta = None
 
float penalty_eta = 1.0
 
int gamma = 2
 
float mass = 1.0
 
float charge = 1.0
 
int nu_p_tau = 1.
 
int omega_p_tau = 1.
 
int skin_depth_norm = 1
 
float lnlam = 10.0
 
int jump_fac = 1
 
int rho_L = 1
 
int P_L = 1
 
int v_L = 0
 
int By_L = 1
 
float Bx = 0.75
 
float rho_R = 0.125 / jump_fac
 
int P_R = .1 / jump_fac
 
int v_R = 0
 
int By_R = -1
 
str mhd_str = 'imhd'
 
bool use_resistivity = 'rmhd' else False
 
str resistivity_type = "spitzer-vacuum"
 
int max_resistive_diffusivity = 1e-4
 
float eta_max = 0.01
 
float eta_min = eta_max / 100.0
 
int vacuum_diffusivity = max_resistive_diffusivity
 
float eta_vacuum = eta_max
 
int n_vacuum = 0
 
bool use_pos_limiter = True
 
bool use_moe_ross_limiter = False
 
int moe_ross_alpha = 100
 
bool use_viscosity = False
 
int visc = -5.e-4
 
int kappa = visc
 
bool use_art_diss = True
 
float coeff_art_dens = 20.0
 
float coeff_art_mom = 40.0
 
float coeff_art_heat = 40.0
 
abs art_diss_diff_cap = abs(visc)
 
int dx_cut = 1e-3
 
bool use_v_anom = False
 
None rho_min = None
 
None P_min = None
 
bool use_imhd_floor = True
 
bool use_floors_app = False
 
warpy mesh
 
warpy plasma
 
bool use_gradients = False
 
warpy plasma_gradient
 
warpy plasma_gradient2
 
warpy ic_plasma
 
list ic_va = []
 
warpy ic_ha = warpy.host_actions.va_runner(name='ic_ha', variable_adjusters=ic_va)
 
list variable_adjusters = []
 
list apps = []
 
list limiter_apps = []
 
warpy floors_app
 
 else :
 
list bc_apps = []
 
list bc_apps_dirichlet = []
 
list rho = [rho_L, rho_R]
 
list px = [mass * v_L, mass * v_R]
 
list py = [0.0, 0.0]
 
list pz = [0.0, 0.0]
 
list By = [By_L, By_R]
 
list Bz = [0.0, 0.0]
 
list pressure = [P_L, P_R]
 
list e = [0, 0]
 
list vals = [rho, px, py, pz, e, Bx, By, Bz]
 
list grad_bc_apps = []
 
warpy writer = warpy.host_actions.writer(name='writer', ReadVars=[plasma, plasma_gradient])
 
warpy spatial_solver
 
warpy time_integrator
 
warpy dt_controller = warpy.dt_calc.stability_dt(init_dt=dt)
 
warpy sim
 
 gen_xdmf
 
 True
 
 detect_nonscalar
 

Function Documentation

◆ run_name()

def examples.dg.mhd.shock_1d_brio-wu.run_name ( )

Variable Documentation

◆ apps

list examples.dg.mhd.shock_1d_brio-wu.apps = []

◆ art_diss_diff_cap

abs examples.dg.mhd.shock_1d_brio-wu.art_diss_diff_cap = abs(visc)

◆ bc_apps

list examples.dg.mhd.shock_1d_brio-wu.bc_apps = []

◆ bc_apps_dirichlet

list examples.dg.mhd.shock_1d_brio-wu.bc_apps_dirichlet = []

◆ Bx

list examples.dg.mhd.shock_1d_brio-wu.Bx = 0.75

◆ By

list examples.dg.mhd.shock_1d_brio-wu.By = [By_L, By_R]

◆ By_L

int examples.dg.mhd.shock_1d_brio-wu.By_L = 1

◆ By_R

int examples.dg.mhd.shock_1d_brio-wu.By_R = -1

◆ Bz

list examples.dg.mhd.shock_1d_brio-wu.Bz = [0.0, 0.0]

◆ cfl

int examples.dg.mhd.shock_1d_brio-wu.cfl = .8 / (2*sord - 1)

◆ cfl_diffusion

float examples.dg.mhd.shock_1d_brio-wu.cfl_diffusion = 1.0

◆ charge

float examples.dg.mhd.shock_1d_brio-wu.charge = 1.0

◆ coeff_art_dens

float examples.dg.mhd.shock_1d_brio-wu.coeff_art_dens = 20.0

◆ coeff_art_heat

float examples.dg.mhd.shock_1d_brio-wu.coeff_art_heat = 40.0

◆ coeff_art_mom

float examples.dg.mhd.shock_1d_brio-wu.coeff_art_mom = 40.0

◆ detect_nonscalar

examples.dg.mhd.shock_1d_brio-wu.detect_nonscalar

◆ dt

int examples.dg.mhd.shock_1d_brio-wu.dt = 1e-6

◆ dt_controller

warpy examples.dg.mhd.shock_1d_brio-wu.dt_controller = warpy.dt_calc.stability_dt(init_dt=dt)

◆ dx_cut

int examples.dg.mhd.shock_1d_brio-wu.dx_cut = 1e-3

◆ e

list examples.dg.mhd.shock_1d_brio-wu.e = [0, 0]

◆ else

examples.dg.mhd.shock_1d_brio-wu.else :

◆ eta_max

float examples.dg.mhd.shock_1d_brio-wu.eta_max = 0.01

◆ eta_min

float examples.dg.mhd.shock_1d_brio-wu.eta_min = eta_max / 100.0

◆ eta_vacuum

float examples.dg.mhd.shock_1d_brio-wu.eta_vacuum = eta_max

◆ floors_app

None examples.dg.mhd.shock_1d_brio-wu.floors_app
Initial value:
2 name="set_density_and_pressure_floors_app",
3 mass_density_min=rho_min,
4 pressure_min=P_min,
5 gamma=gamma,
6 fluid=plasma,
7 )
Function which sets mhd density and pressure floors.
Definition: mhd.py:440

◆ gamma

int examples.dg.mhd.shock_1d_brio-wu.gamma = 2

◆ gen_xdmf

examples.dg.mhd.shock_1d_brio-wu.gen_xdmf

◆ grad_bc_apps

list examples.dg.mhd.shock_1d_brio-wu.grad_bc_apps = []

◆ gradient_method

str examples.dg.mhd.shock_1d_brio-wu.gradient_method = "ldg"

◆ ic_ha

warpy examples.dg.mhd.shock_1d_brio-wu.ic_ha = warpy.host_actions.va_runner(name='ic_ha', variable_adjusters=ic_va)

◆ ic_plasma

warpy examples.dg.mhd.shock_1d_brio-wu.ic_plasma
Initial value:
2 name='briowu_ic',
3 fluid=plasma,
4 gamma=gamma,
5 density_left=rho_L,
6 density_right=rho_R,
7 vx_left=v_L,
8 vx_right=v_R,
9 by_left=By_L,
10 by_right=By_R,
11 pressure_left=P_L,
12 pressure_right=P_R,
13 center=[0, 0, 0],
14 transition_width=0.0
15 )

◆ ic_va

list examples.dg.mhd.shock_1d_brio-wu.ic_va = []

◆ jump_fac

int examples.dg.mhd.shock_1d_brio-wu.jump_fac = 1

◆ kappa

int examples.dg.mhd.shock_1d_brio-wu.kappa = visc

◆ limiter_apps

list examples.dg.mhd.shock_1d_brio-wu.limiter_apps = []

◆ lnlam

float examples.dg.mhd.shock_1d_brio-wu.lnlam = 10.0

◆ mass

float examples.dg.mhd.shock_1d_brio-wu.mass = 1.0

◆ max_resistive_diffusivity

int examples.dg.mhd.shock_1d_brio-wu.max_resistive_diffusivity = 1e-4

◆ mesh

warpy examples.dg.mhd.shock_1d_brio-wu.mesh
Initial value:
2 Bounds=[-.5, .5],
3 NumCells=[num_elem],
4 NodeSets=['Left', 'Right'],
5 NumLayers=1,
6 basis_array_set=sorder_str
7 )
block mesh generator
Definition: mesh.py:87

◆ mhd_str

str examples.dg.mhd.shock_1d_brio-wu.mhd_str = 'imhd'

◆ moe_ross_alpha

int examples.dg.mhd.shock_1d_brio-wu.moe_ross_alpha = 100

◆ n_vacuum

int examples.dg.mhd.shock_1d_brio-wu.n_vacuum = 0

◆ nout

int examples.dg.mhd.shock_1d_brio-wu.nout = 100

◆ nu_p_tau

int examples.dg.mhd.shock_1d_brio-wu.nu_p_tau = 1.

◆ num_elem

int examples.dg.mhd.shock_1d_brio-wu.num_elem = 100

◆ num_flux

str examples.dg.mhd.shock_1d_brio-wu.num_flux = "Rusanov"

◆ omega_p_tau

int examples.dg.mhd.shock_1d_brio-wu.omega_p_tau = 1.

◆ P_L

int examples.dg.mhd.shock_1d_brio-wu.P_L = 1

◆ P_min

min examples.dg.mhd.shock_1d_brio-wu.P_min = None

◆ P_R

int examples.dg.mhd.shock_1d_brio-wu.P_R = .1 / jump_fac

◆ penalty_beta

None examples.dg.mhd.shock_1d_brio-wu.penalty_beta = None

◆ penalty_eta

float examples.dg.mhd.shock_1d_brio-wu.penalty_eta = 1.0

◆ plasma

warpy examples.dg.mhd.shock_1d_brio-wu.plasma
Initial value:
2 name='plasma',
3 components=['rho', 'px', 'py', 'pz', 'e', 'Bx', 'By', 'Bz'],
4 basis_array_set=sorder_str
5 )
Definition: variable.py:4

◆ plasma_gradient

warpy examples.dg.mhd.shock_1d_brio-wu.plasma_gradient
Initial value:
2 name='plasma_gradient',
3 components=[
4 prefix + "_" + suffix
5 for prefix in plasma.components()
6 for suffix in ['x', 'y', 'z']
7 ],
8 basis_array_set=sorder_str
9 )

◆ plasma_gradient2

warpy examples.dg.mhd.shock_1d_brio-wu.plasma_gradient2
Initial value:
2 name='plasma_gradient2',
3 components=[
4 prefix + "_" + suffix
5 for prefix in plasma.components()
6 for suffix in ['x', 'y', 'z']
7 ],
8 basis_array_set=sorder_str
9 )

◆ pressure

list examples.dg.mhd.shock_1d_brio-wu.pressure = [P_L, P_R]

◆ px

list examples.dg.mhd.shock_1d_brio-wu.px = [mass * v_L, mass * v_R]

◆ py

list examples.dg.mhd.shock_1d_brio-wu.py = [0.0, 0.0]

◆ pz

list examples.dg.mhd.shock_1d_brio-wu.pz = [0.0, 0.0]

◆ resistivity_type

str examples.dg.mhd.shock_1d_brio-wu.resistivity_type = "spitzer-vacuum"

◆ rho

list examples.dg.mhd.shock_1d_brio-wu.rho = [rho_L, rho_R]

◆ rho_L

int examples.dg.mhd.shock_1d_brio-wu.rho_L = 1

◆ rho_min

min examples.dg.mhd.shock_1d_brio-wu.rho_min = None

◆ rho_R

float examples.dg.mhd.shock_1d_brio-wu.rho_R = 0.125 / jump_fac

◆ sim

warpy examples.dg.mhd.shock_1d_brio-wu.sim
Initial value:
2 name=run_name(),
3 meshes=[mesh],
4 initial_conditions=[ic_ha],
5 temporal_solvers=[time_integrator],
6 writers=[writer],
7 time=[0, tend],
8 dt_controller=dt_controller,
9 flexible_writeout=True,
10 write_steps=nout,
11 verbosity='info'
12 # verbosity='debug'
13 )
Discontinuous finite element RK simulation.
Definition: dg_sim.py:11

◆ skin_depth_norm

int examples.dg.mhd.shock_1d_brio-wu.skin_depth_norm = 1

◆ sord

int examples.dg.mhd.shock_1d_brio-wu.sord = 4

◆ sorder_str

str examples.dg.mhd.shock_1d_brio-wu.sorder_str = ''

◆ spatial_solver

warpy examples.dg.mhd.shock_1d_brio-wu.spatial_solver
Initial value:
1= warpy.spatial_solvers.dg(
2 name="dg",
3 spatial_order=sorder_str,
4 applications=apps,
5 penalty_beta=penalty_beta,
6 penalty_eta=penalty_eta
7 )

◆ tend

int examples.dg.mhd.shock_1d_brio-wu.tend = .1

◆ time_integrator

warpy examples.dg.mhd.shock_1d_brio-wu.time_integrator
Initial value:
2 name="ti",
3 scheme=torder,
4 spatial_solvers=[spatial_solver],
5 variable_adjusters=variable_adjusters
6 )
Explicit Runge-Kutta temporal solver Note: Dormand45 currently will not work correctly with limiters ...
Definition: erk.py:5

◆ torder

str examples.dg.mhd.shock_1d_brio-wu.torder = 'SSPRK3'

◆ True

examples.dg.mhd.shock_1d_brio-wu.True

◆ use_art_diss

bool examples.dg.mhd.shock_1d_brio-wu.use_art_diss = True

◆ use_floors_app

bool examples.dg.mhd.shock_1d_brio-wu.use_floors_app = False

◆ use_gradients

bool examples.dg.mhd.shock_1d_brio-wu.use_gradients = False

◆ use_imhd_floor

bool examples.dg.mhd.shock_1d_brio-wu.use_imhd_floor = True

◆ use_moe_ross_limiter

bool examples.dg.mhd.shock_1d_brio-wu.use_moe_ross_limiter = False

◆ use_pos_limiter

bool examples.dg.mhd.shock_1d_brio-wu.use_pos_limiter = True

◆ use_resistivity

bool examples.dg.mhd.shock_1d_brio-wu.use_resistivity = 'rmhd' else False

◆ use_v_anom

bool examples.dg.mhd.shock_1d_brio-wu.use_v_anom = False

◆ use_viscosity

bool examples.dg.mhd.shock_1d_brio-wu.use_viscosity = False

◆ v_L

int examples.dg.mhd.shock_1d_brio-wu.v_L = 0

◆ v_R

int examples.dg.mhd.shock_1d_brio-wu.v_R = 0

◆ vacuum_diffusivity

int examples.dg.mhd.shock_1d_brio-wu.vacuum_diffusivity = max_resistive_diffusivity

◆ vals

list examples.dg.mhd.shock_1d_brio-wu.vals = [rho, px, py, pz, e, Bx, By, Bz]

◆ variable_adjusters

list examples.dg.mhd.shock_1d_brio-wu.variable_adjusters = []

◆ visc

int examples.dg.mhd.shock_1d_brio-wu.visc = -5.e-4

◆ writer

warpy examples.dg.mhd.shock_1d_brio-wu.writer = warpy.host_actions.writer(name='writer', ReadVars=[plasma, plasma_gradient])