Skip to content

dg-flo v1.0

Latest
Compare
Choose a tag to compare
@acrovato acrovato released this 23 Jan 16:35

Discontinuous Galerkin code to solve hyperbolic PDEs
Adrien Crovato, 2021

dg-flo is a python code that can solve one-dimensional hyperbolic partial differential equations of the form
dU/dt + dF(U)/dx + S(x) = 0
where U is the vector of unknowns, F(U) is the vector of convective fluxes and S(x) is a vector of source terms.

Examples of formulation already implemented in dg-flo:

  • Linear advection equation
    du/dt + a du/dx = 0

  • Burger's equation
    du/dt + u du/dx = 0

  • Euler equations

 [rho]         [   rho u   ]        [ 0 ]
d[ u ] / dt + d[rho u^2 + p] / dx = [ 0 ]
 [ E ]         [ (E + p) u ]        [ 0 ]

Sod's shock tube
sod

  • Saint-Venant (shallow water) equations
 [ h ]         [      h u      ]           [    0    ]   [ 0 ]
d[   ] / dt + d[               ] / dx  +   [         ] = [   ]
 [ u ]         [ g h + u^2 / 2 ]           [ g dz/dx ]   [ 0 ]

Tsunami propagation
h