Skip to content
Snippets Groups Projects
Commit 47d8fe53 authored by Florian Atteneder's avatar Florian Atteneder
Browse files

add formulation parameter

parent b16652f0
No related branches found
No related tags found
1 merge request!101Refactor GRHD project
This commit is part of merge request !101. Comments created here will be created in the context of that merge request.
......@@ -76,6 +76,14 @@ dg1d.@parameters GRHD begin
id_atmosphere_density = 1e-11
@check id_atmosphere_density > 0.0
"""
Choice of formulation of evolution equations. Available options:
- `spherical1d` ... singular at `r=0`
- `rescaled_spherical1d` ... regular at `r=0`
"""
formulation = "spherical1d"
@check formulation in [ "spherical1d", "rescaled_spherical1d" ]
end
......
......@@ -7,14 +7,8 @@ function Project(env::Environment, prms)
hrsc = HRSC.make_HRSC(env.mesh, prms["HRSC"])
fixedprms = (;)
formulation = if prms["GRHD"]["id"] == "bondi_accretion"
:spherical1d
elseif prms["GRHD"]["id"] == "tov"
:rescaled_spherical1d
else
TODO()
end
P = Project(formulation, equation, hrsc, tci, fixedprms)
formulation = prms["GRHD"]["formulation"]
P = Project(Symbol(formulation), equation, hrsc, tci, fixedprms)
# register variables
@unpack cache = env
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment