Skip to content

Inconsistency in boundary conditions for nonconservative terms #2175

@andrewwinters5000

Description

@andrewwinters5000

When computing the boundary conditions for systems with nonconservative terms there is a potential to accidentally add the boundary contribution incorrectly on P4estMesh (https://github.com/trixi-framework/Trixi.jl/blob/main/src/solvers/dgsem_p4est/dg_2d.jl#L365-L371 ) or UnstructuredMesh2D (https://github.com/trixi-framework/Trixi.jl/blob/main/src/solvers/dgsem_unstructured/dg_2d.jl#L443-L449).

If one does not use the surface_flux_function or nonconservative_flux to compute the boundary condition, e.g. as we do for something like the Euler slip walls (https://github.com/trixi-framework/Trixi.jl/blob/main/src/equations/compressible_euler_2d.jl#L299-L337), then the boundary condition will incorrectly be added as something like

surface_flux_values = flux + 0.5 *  noncons

because flux and noncons will be identical and we actually get the boundary flux one and a half times.

It would be better from my perspective if we did not assume / require that the boundary condition is set via a numerical flux for the sake of flexibility.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions