Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
trixi-framework
GitHub Repository: trixi-framework/Trixi.jl
Path: blob/main/test/test_tree_1d_linearizedeuler.jl
5582 views
1
2
using Test
3
using Trixi
4
5
include("test_trixi.jl")
6
7
EXAMPLES_DIR = joinpath(examples_dir(), "tree_1d_dgsem")
8
9
@testset "Linearized Euler Equations 1D" begin
10
#! format: noindent
11
12
@trixi_testset "elixir_linearizedeuler_convergence.jl" begin
13
@test_trixi_include(joinpath(EXAMPLES_DIR, "elixir_linearizedeuler_convergence.jl"),
14
l2=[
15
0.00010894927270421941,
16
0.00014295255695912358,
17
0.00010894927270421941
18
],
19
linf=[
20
0.0005154647164193893,
21
0.00048457837684242266,
22
0.0005154647164193893
23
])
24
# Ensure that we do not have excessive memory allocations
25
# (e.g., from type instabilities)
26
@test_allocations(Trixi.rhs!, semi, sol, 1000)
27
end
28
29
@trixi_testset "elixir_linearizedeuler_gauss_wall.jl" begin
30
@test_trixi_include(joinpath(EXAMPLES_DIR, "elixir_linearizedeuler_gauss_wall.jl"),
31
l2=[0.650082087850354, 0.2913911415488769, 0.650082087850354],
32
linf=[
33
1.9999505145390108,
34
0.9999720404625275,
35
1.9999505145390108
36
])
37
# Ensure that we do not have excessive memory allocations
38
# (e.g., from type instabilities)
39
@test_allocations(Trixi.rhs!, semi, sol, 1000)
40
end
41
end
42
43