Skip to content

Commit

Permalink
Add ver-1ja to TMAP8 as verification case
Browse files Browse the repository at this point in the history
(Ref. #145)
  • Loading branch information
simopier committed Jun 1, 2024
1 parent 0e25230 commit afd2cfb
Showing 1 changed file with 89 additions and 0 deletions.
89 changes: 89 additions & 0 deletions test/tests/ver-1ja/ver-1ja.i
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
# Verification Problem #1a from TMAP7 V&V document
# Radioactive Decay of Mobile Tritium in a Slab

# Case and model parameters (adapted from TMAP7)
tritium_concentration_initial = 1.5e5 # atoms/m3
half_life = 12.3232 # years
conversion_years_to_s = ${fparse 365.25*24*60*60}
half_life_s = ${fparse half_life*conversion_years_to_s} # s
decay_rate_constant = ${fparse 0.693/half_life_s} # 1/s

# Simulation parameters
end_time = ${fparse 100*conversion_years_to_s} # s
dt_start = ${fparse end_time/250} # s

[Mesh]
type = GeneratedMesh
dim = 1
[]

[Variables]
# tritium concentration in atoms/m^3
[tritium_concentration]
initial_condition = ${tritium_concentration_initial}
[]
# helium concentration in atoms/m^3
[helium_concentration]
[]
[]

[Kernels]
# kernels for the tritium concentration equation
[time_tritium]
type = TimeDerivative
variable = tritium_concentration
[]
[decay_tritium]
type = MatReaction
variable = tritium_concentration
v = tritium_concentration
mob_name = '${fparse -decay_rate_constant}'
[]
# kernels for the tritium concentration equation
[time_helium]
type = TimeDerivative
variable = helium_concentration
[]
[decay_helium]
type = MatReaction
variable = helium_concentration
v = tritium_concentration
mob_name = '${decay_rate_constant}'
[]
[]

[Postprocessors]
# Average concentration of tritium in the sample in atoms/m^3
[tritium_concentration]
type = ElementAverageValue
variable = tritium_concentration
execute_on = 'INITIAL TIMESTEP_END'
[]
# Average concentration of helium in the sample in atoms/m^3
[helium_concentration]
type = ElementAverageValue
variable = helium_concentration
execute_on = 'INITIAL TIMESTEP_END'
[]
[]

[Executioner]
type = Transient
dt = ${dt_start}
end_time = ${end_time}
solve_type = PJFNK
scheme = 'bdf2'
dtmin = 1
l_max_its = 10
nl_max_its = 5
nl_rel_tol = 1e-07
petsc_options = '-snes_converged_reason -ksp_monitor_true_residual'
petsc_options_iname = '-pc_type -mat_mffd_err'
petsc_options_value = 'lu 1e-5'
line_search = 'bt'
[]

[Outputs]
perf_graph = true
csv = true
[]

0 comments on commit afd2cfb

Please sign in to comment.