From d38b66d8f5746a952f8af7672a343a4598789721 Mon Sep 17 00:00:00 2001 From: Dominic Kempf <dominic.kempf@iwr.uni-heidelberg.de> Date: Tue, 8 Aug 2017 16:48:11 +0200 Subject: [PATCH] Add stabilization parameter to shallow water example --- test/hyperbolic/shallowwater.ufl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/hyperbolic/shallowwater.ufl b/test/hyperbolic/shallowwater.ufl index 9fca496e..076ab49f 100644 --- a/test/hyperbolic/shallowwater.ufl +++ b/test/hyperbolic/shallowwater.ufl @@ -27,7 +27,8 @@ bflux = as_matrix([[-q0, -q1], # Define numerical fluxes to choose from -llf_flux = dot(avg(flux), n) - 0.5*jump(u) +alpha = Max(abs(n[0]*q0('+') + n[1]*q1('+')) + sqrt(g*h('+')), abs(n[0]*q0('-') + n[1]*q1('-')) + sqrt(g*h('-'))) +llf_flux = dot(avg(flux), n) - 0.5*alpha*jump(u) boundary_flux = 0.5*dot(flux + bflux, n) + as_vector([0., q0, q1]) numerical_flux = llf_flux -- GitLab