From 376e84d055dbc9daa707716cf1018ca08605268d Mon Sep 17 00:00:00 2001 From: Andrew Winters Date: Tue, 5 Mar 2024 06:31:35 +0100 Subject: [PATCH] run formatter --- .../elixir_euler_free_stream_upwind.jl | 8 +++---- .../elixir_euler_source_terms_upwind.jl | 18 +++++++------- src/equations/compressible_euler_2d.jl | 24 ++++++++++++------- 3 files changed, 29 insertions(+), 21 deletions(-) diff --git a/examples/unstructured_2d_fdsbp/elixir_euler_free_stream_upwind.jl b/examples/unstructured_2d_fdsbp/elixir_euler_free_stream_upwind.jl index 351f1dc7df1..4f391f81f89 100644 --- a/examples/unstructured_2d_fdsbp/elixir_euler_free_stream_upwind.jl +++ b/examples/unstructured_2d_fdsbp/elixir_euler_free_stream_upwind.jl @@ -24,10 +24,10 @@ boundary_conditions = Dict(:outerCircle => boundary_condition_free_stream, # of interpolation routines from `calc_node_coordinates!` to create # the physical coordinates in the mappings. D_upw = upwind_operators(SummationByPartsOperators.Mattsson2017, - derivative_order=1, - accuracy_order=8, - xmin=-1.0, xmax=1.0, - N=17) + derivative_order = 1, + accuracy_order = 8, + xmin = -1.0, xmax = 1.0, + N = 17) flux_splitting = splitting_vanleer_haenel solver = FDSBP(D_upw, diff --git a/examples/unstructured_2d_fdsbp/elixir_euler_source_terms_upwind.jl b/examples/unstructured_2d_fdsbp/elixir_euler_source_terms_upwind.jl index 250dccc4cbf..8a4cc70e764 100644 --- a/examples/unstructured_2d_fdsbp/elixir_euler_source_terms_upwind.jl +++ b/examples/unstructured_2d_fdsbp/elixir_euler_source_terms_upwind.jl @@ -13,10 +13,10 @@ source_term = source_terms_convergence_test boundary_condition_eoc = BoundaryConditionDirichlet(initial_condition) -boundary_conditions = Dict( :Top => boundary_condition_eoc, - :Bottom => boundary_condition_eoc, - :Right => boundary_condition_eoc, - :Left => boundary_condition_eoc ) +boundary_conditions = Dict(:Top => boundary_condition_eoc, + :Bottom => boundary_condition_eoc, + :Right => boundary_condition_eoc, + :Left => boundary_condition_eoc) ############################################################################### # Get the Upwind FDSBP approximation space @@ -25,10 +25,10 @@ boundary_conditions = Dict( :Top => boundary_condition_eoc, # of interpolation routines from `calc_node_coordinates!` to create # the physical coordinates in the mappings. D_upw = upwind_operators(SummationByPartsOperators.Mattsson2017, - derivative_order=1, - accuracy_order=4, - xmin=-1.0, xmax=1.0, - N=9) + derivative_order = 1, + accuracy_order = 4, + xmin = -1.0, xmax = 1.0, + N = 9) flux_splitting = splitting_steger_warming solver = FDSBP(D_upw, @@ -77,7 +77,7 @@ callbacks = CallbackSet(summary_callback, ############################################################################### # run the simulation -sol = solve(ode, SSPRK43(), abstol=1.0e-6, reltol=1.0e-6, +sol = solve(ode, SSPRK43(), abstol = 1.0e-6, reltol = 1.0e-6, save_everystep = false, callback = callbacks) summary_callback() # print the timer summary diff --git a/src/equations/compressible_euler_2d.jl b/src/equations/compressible_euler_2d.jl index 69a7f777f49..616f133c737 100644 --- a/src/equations/compressible_euler_2d.jl +++ b/src/equations/compressible_euler_2d.jl @@ -714,8 +714,10 @@ function signature with argument `which` set to `Val{:minus}()` or `Val{:plus}() """ @inline function splitting_steger_warming(u, orientation_or_normal_direction, equations::CompressibleEulerEquations2D) - fm = splitting_steger_warming(u, Val{:minus}(), orientation_or_normal_direction, equations) - fp = splitting_steger_warming(u, Val{:plus}(), orientation_or_normal_direction, equations) + fm = splitting_steger_warming(u, Val{:minus}(), orientation_or_normal_direction, + equations) + fp = splitting_steger_warming(u, Val{:plus}(), orientation_or_normal_direction, + equations) return fm, fp end @@ -997,8 +999,10 @@ function signature with argument `which` set to `Val{:minus}()` or `Val{:plus}() """ @inline function splitting_vanleer_haenel(u, orientation_or_normal_direction, equations::CompressibleEulerEquations2D) - fm = splitting_vanleer_haenel(u, Val{:minus}(), orientation_or_normal_direction, equations) - fp = splitting_vanleer_haenel(u, Val{:plus}(), orientation_or_normal_direction, equations) + fm = splitting_vanleer_haenel(u, Val{:minus}(), orientation_or_normal_direction, + equations) + fp = splitting_vanleer_haenel(u, Val{:plus}(), orientation_or_normal_direction, + equations) return fm, fp end @@ -1129,8 +1133,10 @@ function signature with argument `which` set to `Val{:minus}()` or `Val{:plus}() """ @inline function splitting_lax_friedrichs(u, orientation_or_normal_direction, equations::CompressibleEulerEquations2D) - fm = splitting_lax_friedrichs(u, Val{:minus}(), orientation_or_normal_direction, equations) - fp = splitting_lax_friedrichs(u, Val{:plus}(), orientation_or_normal_direction, equations) + fm = splitting_lax_friedrichs(u, Val{:minus}(), orientation_or_normal_direction, + equations) + fp = splitting_lax_friedrichs(u, Val{:plus}(), orientation_or_normal_direction, + equations) return fm, fp end @@ -1188,7 +1194,8 @@ end return SVector(f1m, f2m, f3m, f4m) end -@inline function splitting_lax_friedrichs(u, ::Val{:plus}, normal_direction::AbstractVector, +@inline function splitting_lax_friedrichs(u, ::Val{:plus}, + normal_direction::AbstractVector, equations::CompressibleEulerEquations2D) rho_e = last(u) rho, v1, v2, p = cons2prim(u, equations) @@ -1208,7 +1215,8 @@ end return SVector(f1p, f2p, f3p, f4p) end -@inline function splitting_lax_friedrichs(u, ::Val{:minus}, normal_direction::AbstractVector, +@inline function splitting_lax_friedrichs(u, ::Val{:minus}, + normal_direction::AbstractVector, equations::CompressibleEulerEquations2D) rho_e = last(u) rho, v1, v2, p = cons2prim(u, equations)