Skip to content

Commit

Permalink
Added StructuredMeshView{2} to various fluxes.
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonCan committed Jun 18, 2024
1 parent 75d8c67 commit 8823a91
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
10 changes: 5 additions & 5 deletions src/solvers/dgsem_structured/dg_2d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ end

@inline function flux_differencing_kernel!(du, u,
element,
mesh::Union{StructuredMesh{2},
mesh::Union{StructuredMesh{2}, StructuredMeshView{2},
UnstructuredMesh2D, P4estMesh{2},
T8codeMesh{2}},
nonconservative_terms::False, equations,
Expand Down Expand Up @@ -157,7 +157,7 @@ end

@inline function flux_differencing_kernel!(du, u,
element,
mesh::Union{StructuredMesh{2},
mesh::Union{StructuredMesh{2}, StructuredMeshView{2},
UnstructuredMesh2D, P4estMesh{2},
T8codeMesh{2}},
nonconservative_terms::True, equations,
Expand Down Expand Up @@ -226,7 +226,7 @@ end
# "A provably entropy stable subcell shock capturing approach for high order split form DG for the compressible Euler equations"
# [arXiv: 2008.12044v2](https://arxiv.org/pdf/2008.12044)
@inline function calcflux_fv!(fstar1_L, fstar1_R, fstar2_L, fstar2_R, u,
mesh::Union{StructuredMesh{2}, UnstructuredMesh2D,
mesh::Union{StructuredMesh{2}, StructuredMeshView{2}, UnstructuredMesh2D,
P4estMesh{2}, T8codeMesh{2}},
nonconservative_terms::False, equations,
volume_flux_fv, dg::DGSEM, element, cache)
Expand Down Expand Up @@ -296,7 +296,7 @@ end
# Calculate the finite volume fluxes inside curvilinear elements (**with non-conservative terms**).
@inline function calcflux_fv!(fstar1_L, fstar1_R, fstar2_L, fstar2_R,
u::AbstractArray{<:Any, 4},
mesh::Union{StructuredMesh{2}, UnstructuredMesh2D,
mesh::Union{StructuredMesh{2}, StructuredMesh{2}, UnstructuredMesh2D,
P4estMesh{2}, T8codeMesh{2}},
nonconservative_terms::True, equations,
volume_flux_fv, dg::DGSEM, element, cache)
Expand Down Expand Up @@ -475,7 +475,7 @@ end

@inline function calc_interface_flux!(surface_flux_values, left_element, right_element,
orientation, u,
mesh::StructuredMesh{2},
mesh::Union{StructuredMesh{2}, StructuredMeshView{2}},
nonconservative_terms::True, equations,
surface_integral, dg::DG, cache)
# See comment on `calc_interface_flux!` with `nonconservative_terms::False`
Expand Down
4 changes: 2 additions & 2 deletions src/solvers/dgsem_tree/dg_2d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ end

# The methods below are specialized on the volume integral type
# and called from the basic `create_cache` method at the top.
function create_cache(mesh::Union{TreeMesh{2}, StructuredMesh{2}, UnstructuredMesh2D,
function create_cache(mesh::Union{TreeMesh{2}, StructuredMesh{2}, StructuredMeshView{2}, UnstructuredMesh2D,
P4estMesh{2}, T8codeMesh{2}},
equations, volume_integral::VolumeIntegralFluxDifferencing,
dg::DG, uEltype)
Expand Down Expand Up @@ -233,7 +233,7 @@ end
# mapping terms, stored in `cache.elements.contravariant_vectors`, is peeled apart
# from the evaluation of the physical fluxes in each Cartesian direction
function calc_volume_integral!(du, u,
mesh::Union{TreeMesh{2}, StructuredMesh{2},
mesh::Union{TreeMesh{2}, StructuredMesh{2}, StructuredMeshView{2},
UnstructuredMesh2D, P4estMesh{2},
T8codeMesh{2}},
nonconservative_terms, equations,
Expand Down

0 comments on commit 8823a91

Please sign in to comment.