Skip to content

Commit

Permalink
tests
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielDoehring committed Aug 12, 2024
1 parent 0ce6f12 commit 131b5ab
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,9 @@ analysis_callback = AnalysisCallback(semi, interval = analysis_interval)

alive_callback = AliveCallback(analysis_interval = analysis_interval)

# Stepsize callback which selects the timestep to the most restrictive influence
# Stepsize callback which selects the timestep according to the most restrictive CFL condition.
# For coarser grids, linear stability is governed by the convective CFL condition,
# while for high refinements (e.g. initial_refinement_level = 8) the flow becomes diffusion-dominated.
stepsize_callback = StepsizeCallbackHyperbolicParabolic(cfl_convective = 1.8,
cfl_diffusive = 0.3)

Expand Down
15 changes: 15 additions & 0 deletions test/test_parabolic_1d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,21 @@ end
end
end

@trixi_testset "TreeMesh1D: elixir_navierstokes_convergence_periodic_cfl.jl" begin
@test_trixi_include(joinpath(examples_dir(), "tree_1d_dgsem",
"elixir_navierstokes_convergence_periodic_cfl.jl"),
l2=[0.00011338560756751962, 6.240158271610694e-5, 0.0002848510206540238],
linf=[0.0006233189520368221, 0.0003592942992138859, 0.0016105764529221744])
# Ensure that we do not have excessive memory allocations
# (e.g., from type instabilities)
let
t = sol.t[end]
u_ode = sol.u[end]
du_ode = similar(u_ode)
@test (@allocated Trixi.rhs!(du_ode, u_ode, semi, t)) < 1000
end
end

@trixi_testset "TreeMesh1D: elixir_navierstokes_convergence_periodic.jl: GradientVariablesEntropy" begin
@test_trixi_include(joinpath(examples_dir(), "tree_1d_dgsem",
"elixir_navierstokes_convergence_periodic.jl"),
Expand Down

0 comments on commit 131b5ab

Please sign in to comment.