From afeebeb9f0d0f905456777883c006b0800a0aa84 Mon Sep 17 00:00:00 2001 From: patrickersing Date: Fri, 3 May 2024 12:04:31 +0200 Subject: [PATCH] fix tests --- ...r_shallowwater_multilayer_dam_break_dry.jl | 1 - src/equations/shallow_water_multilayer_2d.jl | 2 +- test/test_tree_2d.jl | 40 +++++++++---------- 3 files changed, 21 insertions(+), 22 deletions(-) diff --git a/examples/unstructured_2d_dgsem/elixir_shallowwater_multilayer_dam_break_dry.jl b/examples/unstructured_2d_dgsem/elixir_shallowwater_multilayer_dam_break_dry.jl index 2a52f0e..266a5db 100644 --- a/examples/unstructured_2d_dgsem/elixir_shallowwater_multilayer_dam_break_dry.jl +++ b/examples/unstructured_2d_dgsem/elixir_shallowwater_multilayer_dam_break_dry.jl @@ -2,7 +2,6 @@ using OrdinaryDiffEq using Trixi using TrixiShallowWater -using StaticArrays: MVector ############################################################################### # Semidiscretization of the multilayer shallow water equations for a dam break test over a dry domain diff --git a/src/equations/shallow_water_multilayer_2d.jl b/src/equations/shallow_water_multilayer_2d.jl index b6fa988..b541b0b 100644 --- a/src/equations/shallow_water_multilayer_2d.jl +++ b/src/equations/shallow_water_multilayer_2d.jl @@ -667,7 +667,7 @@ Use in combination with the generic numerical flux routine [`Trixi.FluxHydrostat v2_rr = MVector(velocity(u_rr, equations)[2]) threshold = equations.threshold_limiter - + # Ensure zero velocity at dry states for i in eachlayer(equations) if h_ll[i] <= threshold diff --git a/test/test_tree_2d.jl b/test/test_tree_2d.jl index f9f1b57..30e0195 100644 --- a/test/test_tree_2d.jl +++ b/test/test_tree_2d.jl @@ -737,28 +737,28 @@ end # 2LSWE @test_trixi_include(joinpath(EXAMPLES_DIR, "elixir_shallowwater_multilayer_dam_break_dry.jl"), l2=[ - 0.0296376504586858, - 0.029447383800955382, - 0.045809400450865546, - 0.017958554059665146, - 0.01768940056895248, - 0.028375881034412867, - 0.0003680912616432293, - 0.00036588338949622657, - 0.000599358794592359, - 0.004003203849568449, + 0.026356012468656164, + 0.02621428612601795, + 0.042300320001952676, + 0.01606031947367902, + 0.01582770551425195, + 0.027013208372389356, + 0.0003522703303861562, + 0.00035168999773049347, + 0.0006359004250032467, + 0.003857583749542185, ], linf=[ - 0.10031245502847894, - 0.10068362169927011, - 0.28430163520755, - 0.04291794214784933, - 0.042481793995433136, - 0.11323698875128625, - 0.0019466030268946305, - 0.001934584018725075, - 0.003700828775145786, - 0.10000000026183736, + 0.10271592301313819, + 0.10300228507297038, + 0.31507821093230826, + 0.04442172693554861, + 0.0439759449832886, + 0.12639663811261576, + 0.001548374110216566, + 0.0015525640413529018, + 0.0038575028834197654, + 0.10000011323773067, ], tspan=(0.0, 0.25)) # Ensure that we do not have excessive memory allocations