mod_usr_methods Module

Module with all the methods that users can customize in AMRVAC

Each procedure pointer can be initialized in a user's mod_usr.t


Used by

  • module~~mod_usr_methods~~UsedByGraph module~mod_usr_methods mod_usr_methods module~mod_amrvac mod_amrvac module~mod_amrvac->module~mod_usr_methods proc~advect1 advect1 proc~advect1->module~mod_usr_methods proc~advect_create_particles advect_create_particles proc~advect_create_particles->module~mod_usr_methods proc~advect_integrate_particles advect_integrate_particles proc~advect_integrate_particles->module~mod_usr_methods proc~amr_coarsen_refine amr_coarsen_refine proc~amr_coarsen_refine->module~mod_usr_methods proc~b_from_vector_potentiala b_from_vector_potentialA proc~b_from_vector_potentiala->module~mod_usr_methods proc~calc_grid calc_grid proc~calc_grid->module~mod_usr_methods proc~collapse_subnode collapse_subnode proc~collapse_subnode->module~mod_usr_methods proc~fill_gridvars_default fill_gridvars_default proc~fill_gridvars_default->module~mod_usr_methods proc~gca_create_particles gca_create_particles proc~gca_create_particles->module~mod_usr_methods proc~gca_fill_gridvars gca_fill_gridvars proc~gca_fill_gridvars->module~mod_usr_methods proc~gca_integrate_particles gca_integrate_particles proc~gca_integrate_particles->module~mod_usr_methods proc~generate_plotfile generate_plotfile proc~generate_plotfile->module~mod_usr_methods proc~get_bfield get_bfield proc~get_bfield->module~mod_usr_methods proc~get_efield get_efield proc~get_efield->module~mod_usr_methods proc~get_vec get_vec proc~get_vec->module~mod_usr_methods proc~getheadernames getheadernames proc~getheadernames->module~mod_usr_methods proc~getintbc getintbc proc~getintbc->module~mod_usr_methods proc~igrid_active igrid_active proc~igrid_active->module~mod_usr_methods proc~improve_initial_condition improve_initial_condition proc~improve_initial_condition->module~mod_usr_methods proc~initial_condition initial_condition proc~initial_condition->module~mod_usr_methods proc~initialize_amrvac initialize_amrvac proc~initialize_amrvac->module~mod_usr_methods proc~lorentz_create_particles Lorentz_create_particles proc~lorentz_create_particles->module~mod_usr_methods proc~lorentz_fill_gridvars lorentz_fill_gridvars proc~lorentz_fill_gridvars->module~mod_usr_methods proc~lorentz_integrate_particles Lorentz_integrate_particles proc~lorentz_integrate_particles->module~mod_usr_methods proc~main main proc~main->module~mod_usr_methods proc~modify_ic modify_IC proc~modify_ic->module~mod_usr_methods proc~oneblock oneblock proc~oneblock->module~mod_usr_methods proc~process process proc~process->module~mod_usr_methods proc~process_advanced process_advanced proc~process_advanced->module~mod_usr_methods proc~read_snapshot read_snapshot proc~read_snapshot->module~mod_usr_methods proc~sample_create_particles sample_create_particles proc~sample_create_particles->module~mod_usr_methods proc~sample_get_particle_dt sample_get_particle_dt proc~sample_get_particle_dt->module~mod_usr_methods proc~sample_integrate_particles sample_integrate_particles proc~sample_integrate_particles->module~mod_usr_methods proc~saveamrfile saveamrfile proc~saveamrfile->module~mod_usr_methods proc~selectgrids selectgrids proc~selectgrids->module~mod_usr_methods proc~set_b0_cell set_B0_cell proc~set_b0_cell->module~mod_usr_methods proc~set_j0_cell set_J0_cell proc~set_j0_cell->module~mod_usr_methods proc~timeintegration timeintegration proc~timeintegration->module~mod_usr_methods

Variables

Type Visibility Attributes Name Initial
procedure(Rfactor), public, pointer :: usr_Rfactor => null()
procedure(add_aux_names), public, pointer :: usr_add_aux_names => null()
procedure(after_refine), public, pointer :: usr_after_refine => null()
procedure(aux_output), public, pointer :: usr_aux_output => null()
procedure(p_no_args), public, pointer :: usr_before_main_loop => null()
procedure(check_particle), public, pointer :: usr_check_particle => null()
procedure(create_particles), public, pointer :: usr_create_particles => null()
procedure(phys_dust_get_dt), public, pointer :: usr_dust_get_dt => null()
procedure(flag_grid), public, pointer :: usr_flag_grid => null()
procedure(phys_dust_get_3d_dragforce), public, pointer :: usr_get_3d_dragforce => null()
procedure(get_dt), public, pointer :: usr_get_dt => null()
procedure(phys_gravity), public, pointer :: usr_gravity => null()
procedure(p_no_args), public, pointer :: usr_improve_initial_condition => null()
procedure(init_one_grid), public, pointer :: usr_init_one_grid => null()

Initialize earch grid block data

procedure(init_vector_potential), public, pointer :: usr_init_vector_potential => null()
procedure(internal_bc), public, pointer :: usr_internal_bc => null()
procedure(sub_modify_io), public, pointer :: usr_modify_output => null()
procedure(particle_analytic), public, pointer :: usr_particle_analytic => null()
procedure(particle_fields), public, pointer :: usr_particle_fields => null()
procedure(particle_position), public, pointer :: usr_particle_position => null()
procedure(p_no_args), public, pointer :: usr_print_log => null()
procedure(process_adv_global), public, pointer :: usr_process_adv_global => null()
procedure(process_adv_grid), public, pointer :: usr_process_adv_grid => null()
procedure(process_global), public, pointer :: usr_process_global => null()
procedure(process_grid), public, pointer :: usr_process_grid => null()
procedure(a_refine_threshold), public, pointer :: usr_refine_threshold => null()
procedure(set_B0), public, pointer :: usr_set_B0 => null()
procedure(set_J0), public, pointer :: usr_set_J0 => null()
procedure(set_electric_field), public, pointer :: usr_set_electric_field => null()
procedure(set_equi_vars), public, pointer :: usr_set_equi_vars => null()
procedure(set_field), public, pointer :: usr_set_field => null()
procedure(set_field_w), public, pointer :: usr_set_field_w => null()
procedure(p_no_args), public, pointer :: usr_set_parameters => null()

Initialize the user's settings (after initializing amrvac)

procedure(hd_pthermal), public, pointer :: usr_set_pthermal => null()
procedure(set_surface), public, pointer :: usr_set_surface => null()
procedure(set_wLR), public, pointer :: usr_set_wLR => null()
procedure(phys_visco), public, pointer :: usr_setvisco => null()
procedure(source), public, pointer :: usr_source => null()
procedure(special_aniso_opacity), public, pointer :: usr_special_aniso_opacity => null()
procedure(special_bc), public, pointer :: usr_special_bc => null()
procedure(special_convert), public, pointer :: usr_special_convert => null()
procedure(special_diffcoef), public, pointer :: usr_special_diffcoef => null()
procedure(special_fluxlimiter), public, pointer :: usr_special_fluxlimiter => null()
procedure(special_mg_bc), public, pointer :: usr_special_mg_bc => null()
procedure(special_opacity), public, pointer :: usr_special_opacity => null()
procedure(special_opacity_qdot), public, pointer :: usr_special_opacity_qdot => null()
procedure(special_resistivity), public, pointer :: usr_special_resistivity => null()
procedure(transform_w), public, pointer :: usr_transform_w => null()
procedure(update_payload), public, pointer :: usr_update_payload => null()
procedure(var_for_errest), public, pointer :: usr_var_for_errest => null()
procedure(p_no_args), public, pointer :: usr_write_analysis => null()

Interfaces

interface

  • public subroutine Rfactor(w, x, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, pth)

    Calculation R factor for ideal gas law with partial ionization

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(out) :: pth(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)

interface

  • public subroutine a_refine_threshold(wlocal, xlocal, threshold, qt, level)

    use different threshold in special regions for AMR to reduce/increase resolution there where nothing/something interesting happens.

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: wlocal(1:nw)
    double precision, intent(in) :: xlocal(1:ndim)
    double precision, intent(inout) :: threshold
    double precision, intent(in) :: qt
    integer, intent(in) :: level

interface

  • public subroutine add_aux_names(varnames)

    Add names for the auxiliary variables

    Arguments

    Type IntentOptional Attributes Name
    character(len=*) :: varnames

interface

  • public subroutine after_refine(n_coarsen, n_refine)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: n_coarsen
    integer, intent(in) :: n_refine

interface

  • public subroutine aux_output(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, w, x, normconv)

    this subroutine can be used in convert, to add auxiliary variables to the converted output file, for further analysis using tecplot, paraview, .... these auxiliary values need to be stored in the nw+1:nw+nwauxio slots the array normconv can be filled in the (nw+1:nw+nwauxio) range with corresponding normalization values (default value 1)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,nw+nwauxio)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision :: normconv(0:nw+nwauxio)

interface

  • public subroutine check_particle(igrid, x, v, q, m, follow, check)

    Check arbitrary particle conditions or modifications

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: igrid
    double precision, intent(inout) :: x(1:ndir)
    double precision, intent(inout) :: v(1:ndir)
    double precision, intent(inout) :: q
    double precision, intent(inout) :: m
    logical, intent(inout) :: follow
    logical, intent(out) :: check

interface

  • public subroutine create_particles(n_particles, x, v, q, m, follow)

    Create particles

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: n_particles
    double precision, intent(out) :: x(3,n_particles)
    double precision, intent(out) :: v(3,n_particles)
    double precision, intent(out) :: q(n_particles)
    double precision, intent(out) :: m(n_particles)
    logical, intent(out) :: follow(n_particles)

interface

  • public subroutine flag_grid(qt, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, w, x, flag)

    flag=-1 : Treat all cells active, omit deactivation (onentry, default) flag=0 : Treat as normal domain flag=1 : Treat as passive, but reduce by safety belt flag=2 : Always treat as passive

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: qt
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(inout) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    integer, intent(inout) :: flag

interface

  • public subroutine get_dt(w, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, dtnew, dx1, dx2, dx3, x)

    Limit "dt" further if necessary, e.g. due to the special source terms. The getdt_courant (CFL condition) and the getdt subroutine in the AMRVACPHYS module have already been called.

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(inout) :: dtnew
    double precision, intent(in) :: dx1
    double precision, intent(in) :: dx2
    double precision, intent(in) :: dx3
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)

interface

  • public subroutine hd_pthermal(w, x, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, pth)

    Calculation anormal pressure for hd & energy=.False.

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(out) :: pth(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)

interface

  • public subroutine init_one_grid(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, w, x)

    Initialize one grid

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(inout) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)

interface

  • public subroutine init_vector_potential(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixCmin1, ixCmin2, ixCmin3, ixCmax1, ixCmax2, ixCmax3, xC, A, idir)

    initialize vector potential on cell edges for magnetic field

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixCmin1
    integer, intent(in) :: ixCmin2
    integer, intent(in) :: ixCmin3
    integer, intent(in) :: ixCmax1
    integer, intent(in) :: ixCmax2
    integer, intent(in) :: ixCmax3
    double precision, intent(in) :: xC(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: A(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)
    integer, intent(in) :: idir

interface

  • public subroutine internal_bc(level, qt, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, w, x)

    internal boundary, user defined This subroutine can be used to artificially overwrite ALL conservative variables in a user-selected region of the mesh, and thereby act as an internal boundary region. It is called just before external (ghost cell) boundary regions will be set by the BC selection. Here, you could e.g. want to introduce an extra variable (nwextra, to be distinguished from nwaux) which can be used to identify the internal boundary region location. Its effect should always be local as it acts on the mesh.

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: level
    double precision, intent(in) :: qt
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(inout) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)

interface

  • public subroutine p_no_args()

    Arguments

    None

interface

  • public subroutine particle_analytic(ix, x, tloc, vec)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ix(ndir)

    Indices in gridvars

    double precision, intent(in) :: x(ndir)
    double precision, intent(in) :: tloc
    double precision, intent(out) :: vec(ndir)

interface

  • public subroutine particle_fields(w, x, E, B)

    Associate fields to particle

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: w(ixGlo1:ixGhi1,ixGlo2:ixGhi2,ixGlo3:ixGhi3,1:nw)
    double precision, intent(in) :: x(ixGlo1:ixGhi1,ixGlo2:ixGhi2,ixGlo3:ixGhi3,1:ndim)
    double precision, intent(out) :: E(ixGlo1:ixGhi1,ixGlo2:ixGhi2,ixGlo3:ixGhi3,ndir)
    double precision, intent(out) :: B(ixGlo1:ixGhi1,ixGlo2:ixGhi2,ixGlo3:ixGhi3,ndir)

interface

  • public subroutine particle_position(x, n, tloc, tlocnew)

    User-defined particle movement

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(inout) :: x(3)
    integer, intent(in) :: n
    double precision, intent(in) :: tloc
    double precision, intent(in) :: tlocnew

interface

  • public subroutine phys_dust_get_3d_dragforce(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, w, x, fdrag, ptherm, vgas, dust_n_species)

    Calculate the 3d drag force of gas onto dust

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: fdrag(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndir,1:dust_n_species)
    double precision, intent(in) :: ptherm(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)
    double precision, intent(in) :: vgas(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,ndir)
    integer, intent(in) :: dust_n_species

interface

  • public subroutine phys_dust_get_dt(w, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, dtdust, dx1, dx2, dx3, x, dust_n_species)

    Calculate the time step associated with the usr drag force

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(inout) :: dtdust(1:dust_n_species)
    double precision, intent(in) :: dx1
    double precision, intent(in) :: dx2
    double precision, intent(in) :: dx3
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    integer, intent(in) :: dust_n_species

interface

  • public subroutine phys_gravity(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, wCT, x, gravity_field)

    Calculate gravitational acceleration in each dimension

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: wCT(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: gravity_field(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,ndim)

interface

  • public subroutine phys_visco(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, x, w, mu)

    Calculation anormal viscosity depending on space

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(out) :: mu(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)

interface

  • public subroutine process_adv_global(iit, qt)

    for processing after the advance (PIC-MHD, e.g.)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: iit
    double precision, intent(in) :: qt

interface

  • public subroutine process_adv_grid(igrid, level, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, qt, w, x)

    for processing after the advance (PIC-MHD, e.g.)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: igrid
    integer, intent(in) :: level
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: qt
    double precision, intent(inout) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)

interface

  • public subroutine process_global(iit, qt)

    This subroutine is called at the beginning of each time step by each processor. No communication is specified, so the user has to implement MPI routines if information has to be shared

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: iit
    double precision, intent(in) :: qt

interface

  • public subroutine process_grid(igrid, level, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, qt, w, x)

    this subroutine is ONLY to be used for computing auxiliary variables which happen to be non-local (like div v), and are in no way used for flux computations. As auxiliaries, they are also not advanced

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: igrid
    integer, intent(in) :: level
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: qt
    double precision, intent(inout) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)

interface

  • public subroutine refine_grid(igrid, level, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, qt, w, x, refine, coarsen)

    Enforce additional refinement or coarsening One can use the coordinate info in x and/or time qt=t_n and w(t_n) values w. you must set consistent values for integers refine/coarsen: refine = -1 enforce to not refine refine = 0 doesn't enforce anything refine = 1 enforce refinement coarsen = -1 enforce to not coarsen coarsen = 0 doesn't enforce anything coarsen = 1 enforce coarsen e.g. refine for negative first coordinate x < 0 as if (any(x(ix^S,1) < zero)) refine=1

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: igrid
    integer, intent(in) :: level
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: qt
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    integer, intent(inout) :: refine
    integer, intent(inout) :: coarsen

interface

  • public subroutine set_B0(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, x, wB0)

    Here one can add a steady (time-independent) potential background field

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(inout) :: wB0(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndir)

interface

  • public subroutine set_J0(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, x, wJ0)

    Here one can add a time-independent background current density

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(inout) :: wJ0(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,7-2*ndir:ndir)

interface

  • public subroutine set_electric_field(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, qt, qdt, fE, s)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: qt
    double precision, intent(in) :: qdt
    double precision, intent(inout) :: fE(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,sdim:3)
    type(state) :: s

interface

  • public subroutine set_equi_vars(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, x, w0)

    Here one can add a steady (time-independent) equi vars

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(inout) :: w0(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:number_equi_vars)

interface

  • public subroutine set_field(xfn, igrid, field, ftype)

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: xfn(ndim)
    integer, intent(in) :: igrid
    double precision, intent(inout) :: field(ndim)
    character(len=std_len), intent(in) :: ftype

interface

  • public subroutine set_field_w(igrid, ip, xf, wP, wL, numP, nwP, nwL, dL, forward, ftype, tcondi)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: igrid
    integer, intent(in) :: ip
    double precision, intent(in) :: xf(numP,ndim)
    double precision, intent(inout) :: wP(numP,nwP)
    double precision, intent(inout) :: wL(1+nwL)
    integer, intent(in) :: numP
    integer, intent(in) :: nwP
    integer, intent(in) :: nwL
    double precision, intent(in) :: dL
    logical, intent(in) :: forward
    character(len=std_len), intent(in) :: ftype
    character(len=std_len), intent(in) :: tcondi

interface

  • public subroutine set_surface(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, x, delx, exp_factor, del_exp_factor, exp_factor_primitive)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(in) :: delx(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: exp_factor(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)
    double precision, intent(out) :: del_exp_factor(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)
    double precision, intent(out) :: exp_factor_primitive(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)

interface

  • public subroutine set_wLR(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, qt, wLC, wRC, wLp, wRp, s, idir)

    allow user to specify 'variables' left and right state at physical boundaries to control flux through the boundary surface

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: qt
    double precision, intent(inout) :: wLC(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(inout) :: wRC(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(inout) :: wLp(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(inout) :: wRp(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    type(state) :: s
    integer, intent(in) :: idir

interface

  • public subroutine source(qdt, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, iwmin, iwmax, qtC, wCT, qt, w, x)

    Calculate w(iw)=w(iw)+qdt*SOURCE[wCT,qtC,x] within ixO for all indices iw=iwmin...iwmax. wCT is at time qCT

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: qdt
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    integer, intent(in) :: iwmin
    integer, intent(in) :: iwmax
    double precision, intent(in) :: qtC
    double precision, intent(in) :: wCT(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: qt
    double precision, intent(inout) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)

interface

  • public subroutine special_aniso_opacity(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, w, x, kappa, idir)

    Set user defined, anisotropic opacity for use in diffusion coeff, heating and cooling, and radiation force

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: kappa(ixOmin1:ixOmax1,ixOmin2:ixOmax2,ixOmin3:ixOmax3)
    integer, intent(in) :: idir

interface

  • public subroutine special_bc(qt, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, iB, w, x)

    special boundary types, users must assign conservative variables in boundaries

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: qt
    integer, intent(in) :: ixImin1

    Shape of input arrays

    integer, intent(in) :: ixImin2

    Shape of input arrays

    integer, intent(in) :: ixImin3

    Shape of input arrays

    integer, intent(in) :: ixImax1

    Shape of input arrays

    integer, intent(in) :: ixImax2

    Shape of input arrays

    integer, intent(in) :: ixImax3

    Shape of input arrays

    integer, intent(in) :: ixOmin1

    Region where boundary values have to be set

    integer, intent(in) :: ixOmin2

    Region where boundary values have to be set

    integer, intent(in) :: ixOmin3

    Region where boundary values have to be set

    integer, intent(in) :: ixOmax1

    Region where boundary values have to be set

    integer, intent(in) :: ixOmax2

    Region where boundary values have to be set

    integer, intent(in) :: ixOmax3

    Region where boundary values have to be set

    integer, intent(in) :: iB

    Integer indicating direction of boundary

    double precision, intent(inout) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)

interface

  • public subroutine special_convert(qunitconvert)

    Allow user to use their own data-postprocessing procedures

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: qunitconvert

interface

  • public subroutine special_diffcoef(w, wCT, x, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3)

    Set user defined FLD diffusion coefficient

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(inout) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: wCT(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3

interface

  • public subroutine special_fluxlimiter(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, w, x, fld_lambda, fld_R)

    Set user defined FLD flux limiter, lambda

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: fld_lambda(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)
    double precision, intent(out) :: fld_R(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)

interface

  • public subroutine special_mg_bc(iB)

    Special boundary type for radiation hydrodynamics module, only used to set the boundary conditions for the radiation energy.

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: iB

interface

  • public subroutine special_opacity(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, w, x, kappa)

    Set user defined opacity for use in diffusion coeff, heating and cooling, and radiation force

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: kappa(ixOmin1:ixOmax1,ixOmin2:ixOmax2,ixOmin3:ixOmax3)

interface

  • public subroutine special_opacity_qdot(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, w, x, kappa)

    Set user defined opacity for use in diffusion coeff, heating and cooling, and radiation force. Overwrites special_opacity

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: kappa(ixOmin1:ixOmax1,ixOmin2:ixOmax2,ixOmin3:ixOmax3)

interface

  • public subroutine special_resistivity(w, ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, idirmin, x, current, eta)

    Set the "eta" array for resistive MHD based on w or the "current" variable which has components between idirmin and 3.

    Arguments

    Type IntentOptional Attributes Name
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,nw)
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    integer, intent(in) :: idirmin
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision :: current(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,7-2*ndir:3)
    double precision :: eta(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)

interface

  • public subroutine sub_modify_io(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, qt, w, x)

    If defined, this routine is called before writing output, and it can set/modify the variables in the w array.

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    double precision, intent(in) :: qt
    double precision, intent(inout) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)

interface

  • public subroutine transform_w(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, nw_in, w_in, x, w_out)

    adjust w when restart from dat file with different w variables

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    integer, intent(in) :: nw_in
    double precision, intent(in) :: w_in(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw_in)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: w_out(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)

interface

  • public subroutine update_payload(igrid, x, u, q, m, mypayload, mynpayload, particle_time)

    Update payload of particles

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: igrid
    double precision, intent(in) :: x(1:ndir)
    double precision, intent(in) :: u(1:ndir)
    double precision, intent(in) :: q
    double precision, intent(in) :: m
    double precision, intent(out) :: mypayload(mynpayload)
    integer, intent(in) :: mynpayload
    double precision, intent(in) :: particle_time

interface

  • public subroutine var_for_errest(ixImin1, ixImin2, ixImin3, ixImax1, ixImax2, ixImax3, ixOmin1, ixOmin2, ixOmin3, ixOmax1, ixOmax2, ixOmax3, iflag, w, x, var)

    this is the place to compute a local auxiliary variable to be used as refinement criterion for the Lohner error estimator only -->it is then requiring and iflag>nw note that ixO=ixI=ixG, hence the term local (gradients need special attention!)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: ixImin1
    integer, intent(in) :: ixImin2
    integer, intent(in) :: ixImin3
    integer, intent(in) :: ixImax1
    integer, intent(in) :: ixImax2
    integer, intent(in) :: ixImax3
    integer, intent(in) :: ixOmin1
    integer, intent(in) :: ixOmin2
    integer, intent(in) :: ixOmin3
    integer, intent(in) :: ixOmax1
    integer, intent(in) :: ixOmax2
    integer, intent(in) :: ixOmax3
    integer, intent(in) :: iflag
    double precision, intent(in) :: w(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:nw)
    double precision, intent(in) :: x(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3,1:ndim)
    double precision, intent(out) :: var(ixImin1:ixImax1,ixImin2:ixImax2,ixImin3:ixImax3)