MPI-AMRVAC  3.1
The MPI - Adaptive Mesh Refinement - Versatile Advection Code
Modules List
Here is a list of all modules with brief descriptions:
[detail level 12]
 Nm_octree_mg_1d
 Nm_octree_mg_2d
 Nm_octree_mg_3d
 Nmod_advanceModule containing all the time stepping schemes
 Nmod_afldModule for including anisotropic flux limited diffusion (AFLD)-approximation in Radiation-hydrodynamics simulations using mod_rhd Based on Turner and stone 2001. See [1]Moens, N., Sundqvist, J. O., El Mellah, I., Poniatowski, L., Teunissen, J., and Keppens, R., “Radiation-hydrodynamics with MPI-AMRVAC . Flux-limited diffusion”, Astronomy and Astrophysics, vol. 657, 2022. doi:10.1051/0004-6361/202141023. For more information
 Nmod_amr_fct
 Nmod_amr_grid
 Nmod_amr_neighbors
 Nmod_amr_solution_node
 Nmod_amrvacThis module contains modules that users could want to have in their mod_usr.t code, so that they don't have to include them individually
 Nmod_ardModule activating the advection-reaction-diffusion equation module
 Nmod_ard_physModule containing the physics routines for advection-reaction-diffusion equations
 Nmod_b0
 Nmod_basic_typesModule with basic data types used in amrvac
 Nmod_bc_dataModule to set boundary conditions from user data
 Nmod_boundary_conditions
 Nmod_bremsstrahlung
 Nmod_cak_forceModule to include CAK radiation line force in (magneto)hydrodynamic models Computes both the force from free electrons and the force from an ensemble of lines (various possibilities for the latter). There is an option to only simulate the pure radial CAK force (with various corrections applied) as well as the full vector CAK force. Depending on the chosen option additional output are the CAK line force component(s) and, when doing a 1-D radial force, the finite disc factor
 Nmod_cak_opacityThis module reads in CAK line opacities in the Gayley (1995) notation (alpha, Qbar, Q0, kappae) from corresponding tables. Tabulated values assume LTE conditions and are a function of mass density (D) and temperature (T), which are both given in base 10 logarithm. The construction of the tables is outlined in Poniatowski+ (2021), A&A, 667
 Nmod_calculate_xwHandles computations for coordinates and variables in output
 Nmod_coarsen
 Nmod_coarsen_refineModule to coarsen and refine grids for AMR
 Nmod_collapseCollapses D-dimensional output to D-1 view by line-of-sight integration
 Nmod_comm_lib
 Nmod_con2prim_vars
 Nmod_configModule that allows working with a configuration file
 Nmod_connectivityThis module contains variables that describe the connectivity of the mesh and also data structures for connectivity-related communication
 Nmod_constantsModule for physical and numeric constants
 Nmod_constrained_transport
 Nmod_convert
 Nmod_convert_files
 Nmod_dipoleSets up a magnetic dipole in a 3D cartesian box
 Nmod_dt
 Nmod_dustModule for including dust species, which interact with the gas through a drag force
 Nmod_errest
 Nmod_finite_differenceModule with finite difference methods for fluxes
 Nmod_finite_volumeModule with finite volume methods for fluxes
 Nmod_fix_conserveModule for flux conservation near refinement boundaries
 Nmod_fldNicolas Moens Module for including flux limited diffusion (FLD)-approximation in Radiation-hydrodynamics simulations using mod_rhd Based on Turner and stone 2001. See [1]Moens, N., Sundqvist, J. O., El Mellah, I., Poniatowski, L., Teunissen, J., and Keppens, R., “Radiation-hydrodynamics with MPI-AMRVAC . Flux-limited diffusion”, Astronomy and Astrophysics, vol. 657, 2022. doi:10.1051/0004-6361/202141023. For more information
 Nmod_forestModule with basic grid data structures
 Nmod_functions_bfield
 Nmod_functions_connectivity
 Nmod_functions_forest
 Nmod_geometryModule with geometry-related routines (e.g., divergence, curl)
 Nmod_ghostcells_updateUpdate ghost cells of all blocks including physical boundaries
 Nmod_global_parametersThis module contains definitions of global parameters and variables and some generic functions/subroutines used in AMRVAC
 Nmod_gravityModule for including gravity in (magneto)hydrodynamics simulations
 Nmod_hdModule containing all hydrodynamics
 Nmod_hd_hllcHydrodynamics HLLC module
 Nmod_hd_physHydrodynamics physics module
 Nmod_hd_roeModule with Roe-type Riemann solver for hydrodynamics
 Nmod_hyperdiffusivitySubroutines for Roe-type Riemann solver for HD
 Nmod_init_datafromfileModule to set (or derive) initial conditions from user data We read in a vtk file that provides values on grid
 Nmod_initializeThis module handles the initialization of various components of amrvac
 Nmod_initialize_amr
 Nmod_input_outputModule for reading input and writing output
 Nmod_input_output_helper
 Nmod_interpolation
 Nmod_ionization_degreeModule ionization degree - get ionization degree for given temperature
 Nmod_kdvModule for including kdv source term in simulations adds \(-\delta^2*\sum_i \partial_{iii} \rho \) over dimensions i
 Nmod_lfffProgram to extrapolate linear force-free fields in 3D Cartesian coordinates, based on exact Green function method (Chiu & Hilton 1977 ApJ 212,873)
 Nmod_limiterModule with slope/flux limiters
 Nmod_load_balance
 Nmod_lookup_tableA Fortran 90 module for creating 1D and 2D lookup tables. These tables can be used to efficiently interpolate one or more values
 Nmod_lu
 Nmod_magnetofrictionModule mod_magnetofriction.t Purpose: use magnetofrictional method to relax 3D magnetic field to force-free field 01.04.2016 developed by Chun Xia and Yang Guo 04.10.2017 modulized by Chun Xia Usage: in amrvac.par: &methodlist time_stepper='onestep' ! time marching scheme, or 'twostep','threestep' flux_method=13*'cd4' ! or 'tvdlf', 'fd' limiter= 13*'koren' ! or 'vanleer','cada3','mp5' so on / &meshlist ditregrid=20 ! set iteration interval for adjusting AMR / &mhd_list mhd_magnetofriction=.true. / &mf_list mf_it_max=60000 ! set the maximum iteration number mf_ditsave=20000 ! set iteration interval for data output mf_cc=0.3 ! stability coefficient controls numerical stability mf_cy=0.2 ! frictional velocity coefficient mf_cdivb=0.01 ! divb cleaning coefficient controls diffusion speed of divb /
 Nmod_mf
 Nmod_mf_physMagnetofriction module
 Nmod_mhd
 Nmod_mhd_hllc
 Nmod_mhd_physMagneto-hydrodynamics module
 Nmod_mhd_roeSubroutines for Roe-type Riemann solver for MHD
 Nmod_mp5Module containing the MP5 (fifth order) flux scheme
 Nmod_multigrid_couplingModule to couple the octree-mg library to AMRVAC. This file uses the VACPP preprocessor, but its use is kept to a minimum
 Nmod_nonlinearModule activating the nonlinear scalar equation module allowing to solve Burgers, nonconvex, and KdV equations
 Nmod_nonlinear_physModule containing the physics routines for scalar nonlinear equation
 Nmod_nonlinear_roeModule containing Roe solver for scalar nonlinear equation
 Nmod_odeintThis module packages odeint from numerical recipes
 Nmod_oneblock
 Nmod_opal_opacityThis module reads in Rosseland-mean opacities from OPAL tables. Table opacity values are given in base 10 logarithm and are a function of mass density (R) and temperature (T), which are also both given in base 10 logarithm
 Nmod_particle_advectTracer for advected particles moving with fluid flows By Jannis Teunissen, Bart Ripperda, Oliver Porth, and Fabio Bacchini (2017-2020)
 Nmod_particle_baseModule with shared functionality for all the particle movers
 Nmod_particle_gcaParticle mover with Newtonian/relativistic Guiding Center Approximation (GCA) By Jannis Teunissen, Bart Ripperda, Oliver Porth, and Fabio Bacchini (2016-2020)
 Nmod_particle_lorentzParticle mover with Newtonian/relativistic Boris scheme for Lorentz dynamics By Jannis Teunissen, Bart Ripperda, Oliver Porth, and Fabio Bacchini (2016-2020)
 Nmod_particle_sampleScattered sampling based on fixed- or moving-particle interpolation By Fabio Bacchini (2020)
 Nmod_particlesModule containing all the particle routines
 Nmod_pfssModule mod_pfss.t – potential field source surface model PURPOSE : to extrapolate global potential magnetic field of the sun from synoptic magnetograms 2013.11.04 Developed by S. Moschou and C. Xia 2014.04.01 Allow to change source surface (C. Xia) PRECONDITIONS:
 Nmod_physicaldata
 Nmod_physicsThis module defines the procedures of a physics module. It contains function pointers for the various supported routines. An actual physics module has to set these pointers to its implementation of these routines
 Nmod_physics_hllc
 Nmod_physics_roe
 Nmod_point_searching
 Nmod_ppm
 Nmod_radiative_coolingModule radiative cooling – add optically thin radiative cooling for HD and MHD
 Nmod_randomModule for pseudo random number generation. The internal pseudo random generator is the xoroshiro128plus method
 Nmod_random_heating
 Nmod_rbslTo get a RBSL magnetic flux rope in 3D (Titov 2018 ApJL 852, L21)
 Nmod_rdModule containing all routines for reaction-diffusion
 Nmod_rd_physReaction-diffusion module (physics routines)
 Nmod_refine
 Nmod_rhdModule containing all hydrodynamics
 Nmod_rhd_hllcHydrodynamics HLLC module
 Nmod_rhd_physRadiation-Hydrodynamics physics module Module aims at solving the Hydrodynamic equations toghether with the zeroth moment of the radiative transfer equation. A closure is provided by the flux limited diffusion (FLD)-approximation in the mod_fld.t module. See [1]Moens, N., Sundqvist, J. O., El Mellah, I., Poniatowski, L., Teunissen, J., and Keppens, R., “Radiation-hydrodynamics with MPI-AMRVAC . Flux-limited diffusion”, Astronomy and Astrophysics, vol. 657, 2022. doi:10.1051/0004-6361/202141023. For more information. Another possible closure in the works is the anisotropic flux limited diffusion approximation (AFLD) described in mod_afld.t
 Nmod_rhd_roeModule with Roe-type Riemann solver for hydrodynamics
 Nmod_rhoModule containing all routines for scalar advection
 Nmod_rho_physModule containing the physics routines for scalar advection
 Nmod_rho_roeModule containing Roe solver for scalar advection
 Nmod_rotating_frameModule for including rotating frame in (magneto)hydrodynamics simulations The rotation vector is assumed to be along z direction (both in cylindrical and spherical)
 Nmod_selectgrids
 Nmod_sliceWrites D-1 slice, can do so in various formats, depending on slice_type
 Nmod_small_valuesModule for handling problematic values in simulations, such as negative pressures
 Nmod_solar_atmosphereUser can use subroutine get_atm_para to generate 1D solar stmosphere. User should provide heights (h), number density at h=0, number of points (nh), and the gravity (grav) at each point. User can select temperature profile. This subroutine will return density and pressure at each point
 Nmod_sourceModule for handling split source terms (split from the fluxes)
 Nmod_space_filling_curve
 Nmod_srhdModule containing all special relativistic hydrodynamics (with EOS)
 Nmod_srhd_physSpecial Relativistic Hydrodynamics (with EOS) physics module
 Nmod_supertimesteppingGeneric supertimestepping method 1) in amrvac.par in sts_list set the following parameters which have the default values: sts_dtpar=0.9,sts_ncycles=1000,sts_method=1,sourcetype_sts=2 These parametes are general for all the methods added TODO: check if there is any need to have terms implemented with different sets of parameters, and these cannot be general anymore 2) then add programatically in the code a term with the subroutine add_sts_method This method takes as parameters a function which calculated the explicit timestep associated with the term, a subroutine which sets the source term types for the BC and the BC are generated from the variables startVar:endVar flux conservation (fixconserve) is done for the variables specified by ixChangeStart, ixChangeN, ixChangeFixC The following two steps are done in this way as in fortran it is not allowed to pass null function pointers as parameters: 3)in order to to have hooks before_first_cycle, after_last_cycle (e.g. conversion from e_tot to e_int before first sts cycle and back from e_int to e_tot after the last STS cycle for the thermal conductivity module) add them just afterwards with the subroutine set_conversion_methods_to_head 4) to add the hook for error handling (e.g check small values in the thermal conductivity module ) call set_error_handling_to_head which takes as parameter a subroutine the error handling subroutine is called before setting BC
 Nmod_tdfluxrope
 Nmod_thermal_conductionThermal conduction for HD and MHD Adaptation of mod_thermal_conduction for the mod_supertimestepping In order to use it set use_mhd_tc=1 (for the mhd impl) or 2 (for the hd impl) in mhd_list (for the mhd module both hd and mhd impl can be used) or use_new_hd_tc in hd_list parameters to true (for the hd module, hd implementation has to be used) The TC is set by calling one tc_init_hd_for_total_energy and tc_init_mhd_for_total_energy might The second argument: ixArray has to be [rho_,e_,mag(1)] for mhd (Be aware that the other components of the mag field are assumed consecutive) and [rho_,e_] for hd additionally when internal energy equation is solved, an additional element of this array is eaux_: the index of the internal energy variable
 Nmod_thermal_emission
 Nmod_timing
 Nmod_trac
 Nmod_trace_field
 Nmod_tvdSubroutines for TVD-MUSCL schemes
 Nmod_twofl
 Nmod_twofl_hllc
 Nmod_twofl_physMagneto-hydrodynamics module
 Nmod_twofl_roeSubroutines for Roe-type Riemann solver for HD
 Nmod_usr_methodsModule with all the methods that users can customize in AMRVAC
 Nmod_variables
 Nmod_venk
 Nmod_viscosityThe module add viscous source terms and check time step
 Nmod_weno