104 integer,
intent(in) :: igrid
105 type(state),
target :: psb(max_blocks)
110 integer,
intent(in) :: ixI^L, ixO^L
111 double precision,
intent(inout) :: w(ixI^S, nw)
112 double precision,
intent(in) :: x(ixI^S, 1:^ND)
117 integer,
intent(in) :: ixI^L, ixO^L, idir
118 double precision,
intent(in) :: qt
119 double precision,
intent(inout) :: wLC(ixI^S,1:nw), wRC(ixI^S,1:nw)
120 double precision,
intent(inout) :: wLp(ixI^S,1:nw), wRp(ixI^S,1:nw)
126 integer,
intent(in) :: ixI^L, ixO^L, idim
127 double precision,
intent(in) :: w(ixI^S, nw), x(ixI^S, 1:^ND)
128 double precision,
intent(inout) :: cmax(ixI^S)
133 integer,
intent(in) :: ixI^L, ixO^L
134 double precision,
intent(inout) :: w(ixI^S, nw)
135 double precision,
intent(in) :: x(ixI^S, 1:^ND)
136 double precision,
intent(out) :: tco_local, Tmax_local
140 double precision,
intent(in) :: trac_alfa,tco,T_peak,T_bott
145 integer,
intent(in) :: ixI^L, ixO^L
146 double precision,
intent(in) :: w(ixI^S,nw), x(ixI^S,1:^ND)
147 double precision,
intent(out) :: v(ixI^S,1:ndir)
152 integer,
intent(in) :: ixI^L, ixO^L
153 double precision,
intent(in) :: w(ixI^S,nw), x(ixI^S,1:^ND)
154 double precision,
intent(out) :: rho(ixI^S)
159 integer,
intent(in) :: ixI^L, ixO^L, idim
160 double precision,
intent(in) :: wprim(ixI^S, nw)
161 double precision,
intent(in) :: x(ixI^S,1:ndim)
162 double precision,
intent(out) :: Hspeed(ixI^S,1:number_species)
165 subroutine sub_get_cbounds(wLC, wRC, wLp, wRp, x, ixI^L, ixO^L, idim, Hspeed, cmax, cmin)
168 integer,
intent(in) :: ixI^L, ixO^L, idim
169 double precision,
intent(in) :: wLC(ixI^S, nw), wRC(ixI^S, nw)
170 double precision,
intent(in) :: wLp(ixI^S, nw), wRp(ixI^S, nw)
171 double precision,
intent(in) :: x(ixI^S, 1:^ND)
172 double precision,
intent(inout) :: cmax(ixI^S,1:number_species)
173 double precision,
intent(inout),
optional :: cmin(ixI^S,1:number_species)
174 double precision,
intent(in) :: Hspeed(ixI^S,1:number_species)
179 integer,
intent(in) :: ixI^L, ixO^L, idim
180 double precision,
intent(in) :: wC(ixI^S, 1:nw)
181 double precision,
intent(in) :: w(ixI^S, 1:nw)
182 double precision,
intent(in) :: x(ixI^S, 1:^ND)
183 double precision,
intent(out) :: f(ixI^S, nwflux)
188 integer,
intent(in) :: ixI^L, ixO^L
189 double precision,
intent(in) :: qdt, dtfactor, x(ixI^S, 1:^ND)
190 double precision,
intent(inout) :: wCT(ixI^S, 1:nw), wprim(ixI^S, 1:nw), w(ixI^S, 1:nw)
194 qsourcesplit, active)
196 integer,
intent(in) :: ixI^L, ixO^L
197 double precision,
intent(in) :: qdt, dtfactor
198 double precision,
intent(in) :: wCT(ixI^S, 1:nw), wCTprim(ixI^S,1:nw), x(ixI^S, 1:ndim)
199 double precision,
intent(inout) :: w(ixI^S, 1:nw)
200 logical,
intent(in) :: qsourcesplit
201 logical,
intent(inout) :: active
207 double precision,
intent(in) :: qdt
208 double precision,
intent(in) :: qt
209 logical,
intent(inout) :: active
215 double precision,
intent(in) :: qdt
216 double precision,
intent(in) :: qt
217 logical,
intent(inout) :: active
222 integer,
intent(in) :: igrid
229 double precision,
intent(in) :: qt
230 type(state),
target :: psa(max_blocks)
235 integer,
intent(in) :: ixI^L, ixO^L
236 double precision,
intent(in) :: dx^D, x(ixI^S, 1:^ND)
237 double precision,
intent(in) :: w(ixI^S, 1:nw)
238 double precision,
intent(inout) :: dtnew
243 logical,
intent(in) :: primitive
244 integer,
intent(in) :: ixI^L, ixO^L
245 double precision,
intent(in) :: w(ixI^S,1:nw)
246 logical,
intent(inout) :: w_flag(ixI^S,1:nw)
251 integer,
intent(in) :: ixI^L, ixO^L
252 double precision,
intent(in) :: w(ixI^S,nw)
253 double precision,
intent(in) :: x(ixI^S,1:ndim)
254 double precision,
intent(out):: pth(ixI^S)
259 integer,
intent(in) :: ixI^L, ixO^L
260 double precision,
intent(inout) :: w(ixI^S,nw)
261 double precision,
intent(in) :: x(ixI^S,1:ndim)
266 integer,
intent(in) :: ixI^L, ixO^L
267 double precision,
intent(inout) :: w(ixI^S,nw)
272 integer,
intent(in) :: ixI^L, ixO^L
273 double precision,
intent(in) :: w(ixI^S,nw)
274 double precision,
intent(in) :: x(ixI^S,1:ndim)
275 double precision,
intent(out):: tgas(ixI^S)
280 integer,
intent(in) :: ixI^L, ixO^L
281 double precision,
intent(in) :: w(ixI^S,nw)
282 double precision,
intent(in) :: x(ixI^S,1:ndim)
283 double precision,
intent(out):: cmax(ixI^S)
288 integer,
intent(in) :: ixI^L, ixO^L
289 double precision,
intent(in) :: w(ixI^S,nw)
290 double precision,
intent(in) :: x(ixI^S,1:ndim)
291 double precision,
intent(out):: cmax(ixI^S)
295 integer,
intent(in) :: file_handle
300 logical,
intent(in) :: primitive
301 integer,
intent(in) :: ixI^L,ixO^L
302 double precision,
intent(inout) :: w(ixI^S,1:nw)
303 double precision,
intent(in) :: x(ixI^S,1:ndim)
304 character(len=*),
intent(in) :: subname
310 integer,
intent(in) :: ixI^L, ixO^L, idim
311 double precision,
intent(in) :: wLp(ixI^S, nw), wRp(ixI^S, nw)
312 double precision,
intent(in) :: cmax(ixI^S)
313 double precision,
intent(in),
optional :: cmin(ixI^S)
314 type(ct_velocity),
intent(inout):: vcts
319 integer,
intent(in) :: ixI^L, ixO^L
320 double precision,
intent(in) :: qt, qdt
322 double precision,
intent(in) :: wprim(ixI^S,1:nw)
324 type(state) :: sCT, s
325 type(ct_velocity) :: vcts
326 double precision,
intent(in) :: fC(ixI^S,1:nwflux,1:ndim)
327 double precision,
intent(inout) :: fE(ixI^S,sdim:3)
332 integer,
intent(in) :: ixO^L
338 type(state),
target :: psa(max_blocks)
339 double precision,
intent(in) :: qtC
344 type(state),
target :: psa(max_blocks)
345 type(state),
target :: psb(max_blocks)
346 double precision,
intent(in) :: qdt
347 double precision,
intent(in) :: qtC
348 double precision,
intent(in) :: dtfactor
353 integer,
intent(in) :: ixI^L, ixO^L
354 double precision,
intent(in) :: wCT(ixI^S,nw),x(ixI^S,1:ndim)
355 double precision,
intent(inout) :: w(ixI^S,nw)
379 call mpistop(
"Error: phys_to_conserved not defined")
382 call mpistop(
"Error: phys_to_primitive not defined")
388 call mpistop(
"Error: no phys_get_cmax not defined")
394 call mpistop(
"Error: no phys_get_cbounds not defined")
397 call mpistop(
"Error: no phys_get_flux not defined")
400 call mpistop(
"Error: no phys_get_dt not defined")
452 integer,
intent(in) :: ixI^L, ixO^L, idir
453 double precision,
intent(in) :: qt
454 double precision,
intent(inout) :: wLC(ixI^S,1:nw), wRC(ixI^S,1:nw)
455 double precision,
intent(inout) :: wLp(ixI^S,1:nw), wRp(ixI^S,1:nw)
461 integer,
intent(in) :: ixI^L, ixO^L, idim
462 double precision,
intent(in) :: wprim(ixI^S, nw)
463 double precision,
intent(in) :: x(ixI^S,1:ndim)
464 double precision,
intent(out) :: Hspeed(ixI^S,1:number_species)
469 integer,
intent(in) :: ixI^L, ixO^L
470 double precision,
intent(in) :: qdt, dtfactor, x(ixI^S, 1:^ND)
471 double precision,
intent(inout) :: wCT(ixI^S, 1:nw), wprim(ixI^S,1:nw),w(ixI^S, 1:nw)
475 qsourcesplit, active)
477 integer,
intent(in) :: ixI^L, ixO^L
478 double precision,
intent(in) :: qdt,dtfactor
479 double precision,
intent(in) :: wCT(ixI^S, 1:nw), wCTprim(ixI^S,1:nw), x(ixI^S, 1:ndim)
480 double precision,
intent(inout) :: w(ixI^S, 1:nw)
481 logical,
intent(in) :: qsourcesplit
482 logical,
intent(inout) :: active
488 logical,
intent(in) :: primitive
489 integer,
intent(in) :: ixI^L, ixO^L
490 double precision,
intent(in) :: w(ixI^S,1:nw)
491 logical,
intent(inout) :: w_flag(ixI^S,1:nw)
500 integer,
intent(in) :: ixI^L, ixO^L
501 double precision,
intent(in) :: w(ixI^S, nw)
502 double precision,
intent(in) :: x(ixI^S, 1:ndim)
503 double precision,
intent(out):: pth(ixI^S)
505 call mpistop(
"No get_pthermal method specified")
512 integer,
intent(in) :: ixI^L, ixO^L
513 double precision,
intent(inout) :: w(ixI^S, nw)
514 double precision,
intent(in) :: x(ixI^S, 1:ndim)
523 integer,
intent(in) :: ixI^L, ixO^L
524 double precision,
intent(inout) :: w(ixI^S, nw)
526 call mpistop(
"No get_auxiliary_prim method specified")
531 integer,
intent(in) :: igrid
532 type(state),
target :: psb(max_blocks)
537 integer,
intent(in) :: fh
538 integer,
dimension(MPI_STATUS_SIZE) :: st
542 integer,
parameter :: n_par = 0
544 call mpi_file_write(fh, n_par, 1, mpi_integer, st, er)
549 logical,
intent(in) :: primitive
550 integer,
intent(in) :: ixI^L,ixO^L
551 double precision,
intent(inout) :: w(ixI^S,1:nw)
552 double precision,
intent(in) :: x(ixI^S,1:ndim)
553 character(len=*),
intent(in) :: subname
559 integer,
intent(in) :: ixI^L, ixO^L, idim
560 double precision,
intent(in) :: wLp(ixI^S, nw), wRp(ixI^S, nw)
561 double precision,
intent(in) :: cmax(ixI^S)
562 double precision,
intent(in),
optional :: cmin(ixI^S)
563 type(ct_velocity),
intent(inout):: vcts
568 integer,
intent(in) :: ixI^L, ixO^L
569 double precision,
intent(in) :: qt, qdt
571 double precision,
intent(in) :: wprim(ixI^S,1:nw)
572 type(state) :: sCT, s
573 type(ct_velocity) :: vcts
574 double precision,
intent(in) :: fC(ixI^S,1:nwflux,1:ndim)
575 double precision,
intent(inout) :: fE(ixI^S,sdim:3)
580 integer,
intent(in) :: ixO^L
586 type(state),
target :: psa(max_blocks)
587 double precision,
intent(in) :: qtC
588 integer :: iigrid, igrid
592 do iigrid=1,igridstail; igrid=igrids(iigrid);
593 psa(igrid)%w = 0.0d0*psa(igrid)%w
602 type(state),
target :: psa(max_blocks)
603 type(state),
target :: psb(max_blocks)
604 double precision,
intent(in) :: qdt
605 double precision,
intent(in) :: qtC
606 double precision,
intent(in) :: dtfactor
607 integer :: iigrid, igrid
611 do iigrid=1,igridstail; igrid=igrids(iigrid);
612 psa(igrid)%w = psb(igrid)%w
Add global source terms on complete domain (potentially implicit)
set equilibrium variables other than b0 (e.g. p0 and rho0)
Add special advance in each advect step.
subroutine, public mpistop(message)
Exit MPI-AMRVAC with an error message.
This module contains definitions of global parameters and variables and some generic functions/subrou...
logical stagger_grid
True for using stagger grid.
integer ndir
Number of spatial dimensions (components) for vector variables.
subroutine phys_hllc_check
subroutine phys_roe_check()
This module defines the procedures of a physics module. It contains function pointers for the various...
procedure(sub_get_ct_velocity), pointer phys_get_ct_velocity
subroutine dummy_implicit_update(dtfactor, qdt, qtc, psa, psb)
subroutine dummy_boundary_adjust(igrid, psb)
procedure(sub_convert), pointer phys_to_primitive
procedure(sub_get_tgas), pointer phys_get_tgas
integer, parameter flux_tvdlf
Indicates the flux should be treated with tvdlf.
procedure(sub_small_values), pointer phys_handle_small_values
procedure(sub_write_info), pointer phys_write_info
procedure(sub_get_flux), pointer phys_get_flux
procedure(sub_evaluate_implicit), pointer phys_evaluate_implicit
subroutine dummy_get_auxiliary(ixil, ixol, w, x)
subroutine dummy_face_to_center(ixol, s)
subroutine dummy_modify_wlr(ixil, ixol, qt, wlc, wrc, wlp, wrp, s, idir)
procedure(sub_get_cbounds), pointer phys_get_cbounds
procedure(sub_check_params), pointer phys_te_images
procedure(sub_get_dt), pointer phys_get_dt
subroutine dummy_update_faces(ixil, ixol, qt, qdt, wprim, fc, fe, sct, s, vcts)
logical phys_partial_ionization
Solve partially ionized one-fluid plasma.
logical phys_total_energy
Solve total energy equation or not.
integer, parameter flux_hll
Indicates the flux should be treated with hll.
procedure(sub_get_pthermal), pointer phys_get_pthermal
procedure(sub_update_temperature), pointer phys_update_temperature
procedure(sub_get_tcutoff), pointer phys_get_tcutoff
subroutine dummy_get_pthermal(w, x, ixil, ixol, pth)
procedure(sub_add_source_geom), pointer phys_add_source_geom
procedure(sub_check_params), pointer phys_check_params
integer, parameter flux_default
Indicates a normal flux.
procedure(sub_get_auxiliary), pointer phys_get_auxiliary
integer transverse_ghost_cells
extra ghost cells in the transverse dimensions for fluxes of CT
subroutine dummy_get_h_speed(wprim, x, ixil, ixol, idim, hspeed)
subroutine dummy_small_values(primitive, w, x, ixil, ixol, subname)
procedure(sub_get_auxiliary_prim), pointer phys_get_auxiliary_prim
integer, parameter flux_special
Indicates the flux should be specially treated.
procedure(sub_trac_after_setdt), pointer phys_trac_after_setdt
integer, parameter flux_no_dissipation
Indicates dissipation should be omitted.
subroutine dummy_add_source_geom(qdt, dtfactor, ixil, ixol, wct, wprim, w, x)
procedure(sub_set_equi_vars), pointer phys_set_equi_vars
integer, dimension(:, :), allocatable flux_type
Array per direction per variable, which can be used to specify that certain fluxes have to be treated...
procedure(sub_get_rfactor), pointer phys_get_rfactor
integer phys_wider_stencil
To use wider stencils in flux calculations. A value of 1 will extend it by one cell in both direction...
subroutine dummy_init_params
procedure(sub_update_faces), pointer phys_update_faces
procedure(sub_convert), pointer phys_to_conserved
character(len=name_len) physics_type
String describing the physics type of the simulation.
procedure(sub_check_w), pointer phys_check_w
subroutine dummy_get_ct_velocity(vcts, wlp, wrp, ixil, ixol, idim, cmax, cmin)
procedure(sub_set_mg_bounds), pointer phys_set_mg_bounds
procedure(sub_implicit_update), pointer phys_implicit_update
subroutine dummy_evaluate_implicit(qtc, psa)
subroutine dummy_check_params
procedure(sub_clean_divb), pointer phys_clean_divb
procedure(sub_boundary_adjust), pointer phys_boundary_adjust
subroutine dummy_add_source(qdt, dtfactor, ixil, ixol, wct, wctprim, w, x, qsourcesplit, active)
double precision phys_gamma
procedure(sub_global_source), pointer phys_global_source_after
procedure(sub_add_source), pointer phys_add_source
procedure(sub_face_to_center), pointer phys_face_to_center
procedure(sub_modify_wlr), pointer phys_modify_wlr
subroutine dummy_write_info(fh)
procedure(sub_get_h_speed), pointer phys_get_h_speed
subroutine dummy_get_auxiliary_prim(ixil, ixol, w)
logical phys_internal_e
Solve internal energy instead of total energy.
procedure(sub_get_cmax), pointer phys_get_cmax
procedure(sub_get_rho), pointer phys_get_rho
procedure(sub_get_v), pointer phys_get_v
subroutine dummy_check_w(primitive, ixil, ixol, w, w_flag)
procedure(sub_get_csrad2), pointer phys_get_csrad2
logical phys_energy
Solve energy equation or not.
procedure(sub_special_advance), pointer phys_special_advance
Module with all the methods that users can customize in AMRVAC.