Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Daniel Doehring <[email protected]>
Co-authored-by: Joshua Lampert <[email protected]>
  • Loading branch information
3 people authored Mar 20, 2024
1 parent 90ef9a8 commit e3f6cbc
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ equations = CompressibleEulerEquations2D(1.4)
pre_inf() = 1.0
rho_inf() = pre_inf() / (1.0 * 287.87) # pre_inf = 1.0, T = 1, R = 287.87
mach_inf() = 0.85
aoa() = pi / 180.0
aoa() = pi / 180.0 # 1 Degree angle of attack
c_inf(equations) = sqrt(equations.gamma * pre_inf() / rho_inf())
U_inf(equations) = mach_inf() * c_inf(equations)

Expand Down
2 changes: 1 addition & 1 deletion examples/p4est_2d_dgsem/elixir_euler_subsonic_cylinder.jl
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ cells_per_dimension = (64, 64)
# conditions there. However, the image of eta = -1, +1 coincides at the line y = 0. There is no
# physical boundary there so we specify periodicity = true there and the solver treats the
# element across eta = -1, +1 as neighbours which is what we want
mesh = P4estMesh(cells_per_dimension, mapping = mapping2cylinder, polydeg = 3,
mesh = P4estMesh(cells_per_dimension, mapping = mapping2cylinder, polydeg = polydeg,
periodicity = (false, true))

# The boundary conditions of the outer cylinder is constant but subsonic, so we cannot compute the
Expand Down
6 changes: 4 additions & 2 deletions test/test_p4est_2d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -584,7 +584,10 @@ end
base_level=0, med_level=1, max_level=1,
tspan=(0.0, 0.0001),
adapt_initial_condition=false,
adapt_initial_condition_only_refine=false)
adapt_initial_condition_only_refine=false,
# With the default `maxiters = 1` in coverage tests,
# the values for `drag` and `lift` below would differ.
coverage_override=(maxiters = 100_000,))

# Ensure that we do not have excessive memory allocations
# (e.g., from type instabilities)
Expand All @@ -605,7 +608,6 @@ end
lift = Trixi.analyze(lift_coefficient, du, u, tspan[2], mesh, equations, solver,
semi.cache)

@show analysis_callback(sol)

@test isapprox(lift, 0.026397498239816828, atol = 1e-13)
@test isapprox(drag, 0.10908833968266139, atol = 1e-13)
Expand Down

0 comments on commit e3f6cbc

Please sign in to comment.