diff --git a/src/ConservationLaws/euler_navierstokes.jl b/src/ConservationLaws/euler_navierstokes.jl index c0b7886e..17ac85d5 100644 --- a/src/ConservationLaws/euler_navierstokes.jl +++ b/src/ConservationLaws/euler_navierstokes.jl @@ -284,15 +284,17 @@ Domain should be [0,2π]³. """ struct TaylorGreenVortex <: AbstractGridFunction{3} γ::Float64 + Ma::Float64 N_c::Int - function TaylorGreenVortex(conservation_law::EulerEquations{3}) - return new(conservation_law.γ,5) + function TaylorGreenVortex(conservation_law::EulerEquations{3}, + Ma::Float64=0.1) + return new(conservation_law.γ,Ma,5) end end @inline function evaluate(f::TaylorGreenVortex, x::NTuple{3,Float64}, t::Float64=0.0) - p = (100/f.γ) + 0.0625*(2*cos(2*x[1]) + 2*cos(2*x[2]) + + p = (1/(f.Ma^2*f.γ)) + 0.0625*(2*cos(2*x[1]) + 2*cos(2*x[2]) + cos(2*x[1])*cos(2*x[3]) + cos(2*x[2])*cos(2*x[3])) u = sin(x[1])*cos(x[2])*cos(x[3]) v = -cos(x[1])*sin(x[2])*cos(x[3])