34.2. FVM for hyperbolic problems#
Approach
Integral equations, often from balance or conservation laws
First, problems in 1-dimensional domains are treated. Most of the features of a finite volume method are treated for 1-dimensional problems
flux: characteristics and common schemes
implementation: evaluation of flux at interfaces and distribution on cells
boundary conditions
…
then everything is naturally generalized to multi-dimensional domain: each interface of a cell in a multi-dimensional domain is locally treated as a 1-dimensional domain.
-
features:
must be conservative…
must satisfy entropy condition, i.e. produce the physical solution (the limit of viscous problem for negligible viscosity) among the infinite possible solutions
schemes:
low-order
Godunov: the numerical flux is evaluated after solving a Riemann problem at each cell interface, taking the \(x = 0\) state \(\mathbf{u}(x=0, t)\) to evaluate the flux \(\mathbf{F}(\mathbf{u})\) at that cell boundary
Roe (~ linearized Godunov) + entropy fix required for the numerical method to select the physical solution
high-order schemes:
improve accuracy of differentiable solutions (no shock, no discontinuity) on regular grids
fail to represent the physical solution
high-resolution, (TVD schemes with flux limiters, MUSCL,…):
high-order methods where the solution is differentiable
low order method where the solution has discontinuities
high-resolution achieved as a linear combination of a low and high order flux
\[F(u_{i+1/2}) = f^{low}_{i+1/2} + \phi(r_{i-1,i}) \left( f^{high}_{i+1/2} - f^{low}_{i+1/2} \right) \ ,\]being \(\phi(r_{i,i+1})\) the flux limiter, i.e. a function of the gradient \(r_i\) of the solution on the grid
Theorems about numerics:
CFL (Courant-Friedrichs-Lewy) condition for explicit-time schemes (it could hold locally…),
\[\Delta t \le \frac{\Delta x}{|\lambda|_{\max}}\]…results about fluxes…
34.2.1. Numerical fluxes#
34.2.1.1. Godunov flux#
The numerical flux in Godunov scheme is the flux \(\mathbf{F}\) evaluated with the state at the interface of two neighboring cells, resulting from the solution of the Riemann problem between the two cells.
For a piecewise constant approximation of the fields (like in standard finite volume methods), the evolution at each cell interface can be treated as a Riemann problem
In order to calculate the numerical flux at the interface \(i\), separating cells \(A\), \(B\)
The Riemann problem is solved at interface \(i\) separating the two cells with uniform fields \(\mathbf{u}_A(t)\), \(\mathbf{u}_B(t)\). Let \(\mathbf{u}_i(x,t+\Delta t)\) be the solution, being \(x\) a local coordinate (orthogonal to the interface for multi-dimensional domains) with \(x=0\) at the interface, and \(\Delta t > 0\). Riemann problem is a non-linear problem, so a non-linear solver is required. In order to avoid (expensive) non-linear methods, Roe scheme is introduced in the next section.
The state at interface \(\mathbf{u}_i(x=0,t+\Delta t)\) is retrieved from the solution of the Riemann problem
The numerical flux is evaluated with the state at the interface
\[\mathbf{F}_i(t) = \mathbf{F}(\mathbf{u}_i(0,t)) \ .\]
34.2.1.2. Roe flux#
Instead of solving the original non-linear problem,
a Roe solver aims at solving a linearized problem at each interface, namely
being \(\hat{\mathbf{A}}(\mathbf{u}_L, \mathbf{u}_R)\) an approximation of the convection matrix \(\mathbf{A}(\mathbf{u})\) built with the states in the cells sharing the interface of interest: in time-explicit schemes, states in the cells \(\mathbf{u}_L\), \(\mathbf{u}_R\) are known, and so it is the linearized matrix \(\hat{\mathbf{A}}(\mathbf{u}_L, \mathbf{u}_R)\).
Intermediate state, \(\hat{\mathbf{u}}\). The linearized matrix can be written as the original matrix evaluated for an intermediate state \(\hat{\mathbf{u}}(\mathbf{u}_L, \mathbf{u}_R)\),
Roe flux. Roe flux looks similar to upwind scheme,
Properties. Roe matrix needs to satisfy the following properties:
diagonalization: \(\hat{\mathbf{A}}\) is diagonalizable
consistency: if \(\mathbf{u}_L, \mathbf{u}_R \rightarrow \mathbf{u}\), then \(\hat{\mathbf{u}} \rightarrow \mathbf{u}\)
conservation: \(\mathbf{A}(\hat{\mathbf{u}}) \left( \mathbf{u}_L - \mathbf{u}_R \right) = \mathbf{F}(\mathbf{u}_L) - \mathbf{F}(\mathbf{u}_R)\)
Example 34.1 (P-sys. Intermediate state)
Intermediate state. For each value of \(\hat{\rho}\),
and thus
Details
Conservation
explicitly, using conservative variables
The first equation is identically satisfied. The second equation in \(\hat{u}\) reads
and collecting terms
or, with \(\rho > 0\),
so that the solution that avoids singularities for \(\rho_L = \rho_R\) (the one with the minus sign above) reads
Consistency. From this choice of sign, consistency of the velocity follows immediately,
Arbitrary intermediate value of the density \(\hat{\rho}\) needs to satisfy consistency, as well. Just as an example, if \(\hat{\rho}\) is chosen to be the average of the densities, \(\hat{\rho} = \frac{1}{2}(\rho_L + \rho_R)\), this is consistent choice.
Example 34.2 (Euler equations. Intermediate state)
Intermediate state. For each value of \(\hat{\rho}\),
while \(\hat{\rho}\) can be found (if not trivial) solving an additional condition
If this condition is an identity - as it is for a perfect ideal gas - any value of \(\hat{\rho}\) satisfying consistency is allowed.
Details
Conservation
explicitly, using conservative variables
or
The first equation is an identity
The second equation in \(\hat{u}\) gives
\[\begin{aligned} 0 & = - \left.\left[ \rho ( \hat{u} - u )^2 \right]\right|_R^L + \left.\left( \rho \partial_\rho \hat{\Pi} + \rho u \partial_m \hat{\Pi} + E^t \partial_{E^t} \hat{\Pi} - \Pi \right)\right|_{R}^{L} \ , \end{aligned}\]The third equation in \(\hat{h}^t\) gives
\[\begin{split}\begin{aligned} 0 & = \left.\left[ \rho ( u - \hat{u} ) \hat{h}^t \right]\right|_R^L + \left.\left[ \hat{u} \rho \partial_\rho \hat{\Pi} + \hat{u} m \partial_m \hat{\Pi} + \hat{u} E^t \partial_{E^t} \hat{\Pi} + \hat{u} \underbrace{E^t}_{= \rho h^t - p} - \rho u h^t \right]\right|_L^R = \\ & = \left.\left[ \rho ( u - \hat{u} ) \hat{h}^t + \rho h^t ( \hat{u} - u ) \right]\right|_R^L + \hat{u} \left.\left[ \rho \partial_\rho \hat{\Pi} + m \partial_m \hat{\Pi} + E^t \partial_{E^t} \hat{\Pi} - \Pi \right]\right|_L^R = \\ & = \left.\left[ \rho ( u - \hat{u} ) ( \hat{h}^t - h^t ) \right]\right|_R^L + \hat{u} \left.\left[ \rho \partial_\rho \hat{\Pi} + m \partial_m \hat{\Pi} + E^t \partial_{E^t} \hat{\Pi} - \Pi \right]\right|_L^R \ . \end{aligned}\end{split}\]
Adding the condition \(\Delta P = \Delta \rho \partial_\rho \hat{\Pi} + m \partial_m \hat{\Pi} + E^t \partial_{E^t} \hat{\Pi}\), the second equation can be solved for \(\hat{u}\) (choosing the solution providing consistency - see P-sys example for a brief discussion)
and the third equation can be solved for \(\hat{h}^t\) (using \(\sqrt{\rho_L}(u_L - \hat{u}) = - \sqrt{\rho_R}(u_R - \hat{u})\) from the expression of \(\hat{u}\) to get the equation \(\sqrt{\rho}(\hat{h}^t - h^t_L) = - \sqrt{\rho_R}(\hat{h}^t - h^t_R)\)),
For a medium with generic equations of state, the condition about \(\Delta p\) introduced above can be eventually solved to find the value of \(\hat{\rho}\). For a perfect ideal gas (PIG), this condition is an identity providing no additional information on the value of \(\hat{\rho}\)
Consistency. …
34.2.1.3. Entropy fix#
Entropy fix is required to exploit numerical dissipation in choosing the physical solution, when some eigenvalue is close to zero. As an example, a threshold is set as a ratio of the local speed of sound \(a\), e.g. \(\delta = 0.1 \div 0.2\) and the Roe matrix is modified as
with
todo Add discussion about numerical dissipation and some numerical examples…