Parameters

class pyR2D2.Parameters(data)[source]

Bases: object

Class for managing R2D2 basic parameters

Variables:
  • data (pyR2D2.data.Data) – pyR2D2.Data instance

  • datadir (str) – location of the data files

  • nd (int) – current time step for low cadence data

  • nd_tau (int) – current time step for high cadence data

  • xdcheck (int) – if 1: x direction is solved, otherwise 0

  • ydcheck (int) – if 1: y direction is solved, otherwise 0

  • zdcheck (int) – if 1: z direction is solved, otherwise 0

  • margin (int) – margin

  • nx (int) – no. of grid points in x direction in a MPI process

  • ny (int) – no. of grid points in y direction in a MPI process

  • nz (int) – no. of grid points in z direction in a MPI process

  • npe (int) – no. of MPI processes, npe = ix0*jx0*kx0

  • ix0 (int) – no. of MPI processes in x direction

  • jx0 (int) – no. of MPI processes in y direction

  • kx0 (int) – no. of MPI processes in z direction

  • mtype (int) – no. of variable kinds

  • xmax (float) – maximum value of x

  • xmin (float) – minimum value of x

  • ymax (float) – maximum value of y

  • ymin (float) – minimum value of y

  • zmax (float) – maximum value of z

  • zmin (float) – minimum value of z

  • dtout (float) – time interval for low cadence output

  • tend (float) – end time for calculation

  • swap (int) – endianness of the data

  • ix_e (int) – no. of grid point in ro of table EoS

  • jx_e (int) – no. of grid point in te of table EoS

  • ixr (int) – number of MPI process in x direction in remap coordinate

  • jxr (int) – number of MPI process in y direction in remap coordinate

  • m_in (int) – no. of variable kinds for intensity variables

  • m_tu (int) – no. of optical depth slices

  • dtout_tau (float) – time interval for high cadence output

  • ifac (float) – factor for output between low and high cadence. dtout = ifac*dtout_tau

  • omfac (float) – ratio of system rotation rate to the solar rotation rate

  • om00 (float) – system rotation rate

  • jc (int) – slice number in y direction for remap_calc

  • kc (int) – slice number in z direction for remap_calc

  • rstar (float) – Star radius

  • lstar (float) – Star luminosity

  • astar (float) – Star age

  • mstar (float) – Star mass

  • potential_alpha (float) – Alpha factor for top boundary, see Rempel, 2012

  • romin (float) – floor for density

  • semin (float) – floor for entropy

  • semax (float) – floor for entropy

  • camax (float) – Alfven speed limit

  • vxmax (float) – floor for vx

  • vxmin (float) – floor for vx

  • vhmax (float) – floor for horizontal velocity

  • server (str) – Server name

  • rte (bool) – Radiation Transfer Equation flag

  • ununiform_flag (bool) – Univerorm grid flag

  • ix_ununi (int) – no. of uniform grid points in x direction

  • dx00 (float) – grid spacing in uniform grid area in x direction

  • geometry (str) – Cartesian, Spherical, or YinYang

  • deep_flag (int) – Deep calculation flag

  • uuid_stratification (str) – UUID for background stratification

  • uuid_eos (str) – UUID for EoS

  • remap_kind (list) – vairable name for remap/qq

  • remap_kind_add (list) – addiational variable name for remap/qq

  • endian (str) – endianness of the data for Python

  • xyz (numpy.ndarray) – MPI rank in x, y, z direction

  • ix (int) – no. of grid points in x direction

  • jx (int) – no. of grid points in y direction

  • kx (int) – no. of grid points in z direction

  • ixg (int) – no. of grid points in x direction with margin

  • jxg (int) – no. of grid points in y direction with margin

  • kxg (int) – no. of grid points in z direction with margin

  • xg (numpy.ndarray) – x grid with margin

  • yg (numpy.ndarray) – y grid with margin

  • zg (numpy.ndarray) – z grid with margin

  • x_flux (numpy.ndarray) – x grid for flux calculation, i.e., mid point of x grid

  • ro0g (numpy.ndarray) – background density with margin

  • se0g (numpy.ndarray) – background entropy with margin

  • x (numpy.ndarray) – x grid

  • y (numpy.ndarray) – y grid

  • z (numpy.ndarray) – z grid

  • pr0 (numpy.ndarray) – background pressure

  • te0 (numpy.ndarray) – background temperature

  • ro0 (numpy.ndarray) – background density

  • se0 (numpy.ndarray) – background entropy/ unit mass

  • en0 (numpy.ndarray) – background integernal energy/ unit mass

  • op0 (numpy.ndarray) – background opacity

  • tu0 (numpy.ndarray) – background optical depth

  • dsedr0 (numpy.ndarray) – ds/dr

  • dtedr0 (numpy.ndarray) – dT/dr

  • dprdro (numpy.ndarray) – (dp/drho)_s

  • dprdse (numpy.ndarray) – (dp/ds)_rho

  • dtedro (numpy.ndarray) – (dT/drho)_s

  • dtedse (numpy.ndarray) – (dT/ds)_rho

  • dendro (numpy.ndarray) – (de/drho)_s

  • dendse (numpy.ndarray) – (de/ds)_rho

  • gx (numpy.ndarray) – grabitational acceleration

  • cp (numpy.ndarray) – heat capacity at constant pressure

  • fa (numpy.ndarray) – radiative energy flux

  • sa (numpy.ndarray) – radiative heat derivative of fa

  • xi (numpy.ndarray) – RSST factor

  • xr (numpy.ndarray) – normalized x grid with rstar

  • jx_yy (int) – no. of grid points in latitude direction for each Yin Yang grid

  • kx_yy (int) – no. of grid points in longitude direction for each Yin Yang grid

  • jxg_yy (int) – no. of grid points in latitude direction for each Yin Yang grid with margin

  • kxg_yy (int) – no. of grid points in longitude direction for each Yin Yang grid with margin

  • y_yy (numpy.ndarray) – y grid for each Yin Yang grid

  • z_yy (numpy.ndarray) – z grid for each Yin Yang grid

  • yg_yy (numpy.ndarray) – y grid for each Yin Yang grid with margin

  • zg_yy (numpy.ndarray) – z grid for each Yin Yang grid with margin

  • m2d_xy (int) – no. of variables for xy OnTheFly

  • m2d_xz (int) – no. of variables for xz OnTheFly

  • m2d_flux (int) – no. of variables for flux OnTheFly

  • m2d_spex (int) – no. of variables for spectrum OnTheFly

  • cl (list) – variable names for OnTheFly

  • iss (numpy.ndarray) – start index for x direction for each MPI process in remap

  • iee (numpy.ndarray) – end index for x direction for each MPI process in remap

  • jss (numpy.ndarray) – start index for y direction for each MPI process in remap

  • jee (numpy.ndarray) – end index for y direction for each MPI process in remap

  • iixl (numpy.ndarray) – no. of grid points in x direction for each MPI process in remap

  • jjxl (numpy.ndarray) – no. of grid points in y direction for each MPI process in remap

  • np_ijr (numpy.ndarray) – MPI rank in x, y direction in remap

  • ir (numpy.ndarray) – MPI process index in x direction in remap

  • jr (numpy.ndarray) – MPI process index in y direction in remap

  • i2ir (numpy.ndarray) – original grid i to ir

  • j2jr (numpy.ndarray) – original grid j to jr

  • nx_slice (int) – no. of slices in x direction

  • ny_slice (int) – no. of slices in y direction

  • nz_slice (int) – no. of slices in z direction

  • x_slice (numpy.ndarray) – slice location in x direction

  • y_slice (numpy.ndarray) – slice location in y direction

  • z_slice (numpy.ndarray) – slice location in z direction

  • log_ro_e (numpy.ndarray) – log(ro) in table EoS

  • se_e (numpy.ndarray) – se in table EoS

  • log_pr_e (numpy.ndarray) – log(pr) in table EoS

  • log_en_e (numpy.ndarray) – log(en) in table EoS

  • log_te_e (numpy.ndarray) – log(te) in table EoS

  • log_op_e (numpy.ndarray) – log(op) in table EoS

  • dlogro_e (numpy.float64) – grid space in log(ro) in table EoS

  • dse_e (numpy.float64) – grid space in se in table EoS

  • origin (str) – Original caseid if continue calculation

Methods Summary

summary()

Show pyR2D2.Parameter summary.

yinyang_setup()

YinYangSet function sets up the YinYang geometry for YinYang direct plot.

Methods Documentation

summary()[source]

Show pyR2D2.Parameter summary.

yinyang_setup()[source]

YinYangSet function sets up the YinYang geometry for YinYang direct plot.

__init__(data)[source]

Initialize pyR2D2.Parameters

Parameters:

data (pyR2D2.Data) – Instance of pyR2D2.Data