Structure‐preserving discretization of a port‐Hamiltonian formulation of the non‐isothermal Euler equations

The port‐Hamiltonian (pH) formulation of partial‐differential equations (pdes) and their numerical treatment have been elaborately studied lately. In this context we consider the non‐isothermal flow of a compressible fluid. Starting from the pdes we derive a pH formulation for Euler‐type equations in the weak sense on one pipe. One advantage of pH systems is that fundamental physical properties, like energy dissipation and mass conservation, are encoded in the system structure. Therefore, structure‐preservation during approximation is most important. Based on the weak form we introduce a structure‐preserving Galerkin approximation with mixed finite elements. A numerical example supports the theoretical results.


Introduction
PH modeling of fluid flow through pipe networks has been studied elaborately lately, e.g., in the gas context for the damped wave equations [2] or the non-linear isothermal Euler equations [1]. As these, as well as most of the literature, only treat the pH formulation of mass and momentum conservation, the next natural step is to include energy. Thus, we consider the non-isothermal Euler equations with friction and an energy balance equation on Ω = [0, L] for t ≥ 0 System (1) describes a fluid flow through a pipe of length L, diameter d and friction factor λ. The state is given by the mass density ρ, the velocity v and the inner energy density e. The system has to be closed with appropriate boundary and initial conditions and a state equation for the pressure p. The associated Hamiltonian is given by H(ρ, v, e) = L 0 ρ v 2 2 + e d x.

Port-Hamiltonian variational formulation
To achieve a pH formulation of (1) in variational form we first need to establish a dependence on the effort variables on the right side of (1), which are given by the functional derviative of the Hamiltonian with respect to the state z = [ρ v e] T , i.e., δH δz (z) = [ v 2 2 ρv 1] T . Furthermore, the friction term in (1b) has to be incorporated in a symmetric positive semi-definite operator R(z) and a skew-symmetric operator J (z) has to built by the transport and pressure terms, see, e.g., [3]. To achieve the latter, the term e ρ ∂ x 1 = 0, which depends on the effort variable with respect to e, has to be inserted into (1b). After partial integration of (1b) and (1c) we get the following variational principle. Here, (·, ·) denotes the L 2 inner product.
For a strong solution z = [ρ v e] T of (1), The proof of the following theorem is analogous to [1]. Theorem 2.1 Let z be a strong solution of (1). Then the following energy dissipation and global mass conservation hold 3 Structure-preserving space discreization A structure-preserving Galerkin discretization of system (1) can be obtained almost analogously to [1]. Thus, we only sum up the main steps. First, a variable transformation is introduced, such that we can approximate the momentum m = ρv and not only the velocity v. We choose the test spaces as ansatz spaces, i.e., V 1 ⊂ L 2 (Ω) and V 2 , V 3 ⊂ H 1 (Ω). Furthermore, these spaces have to fulfill the compatibility conditions ∂ x V 2 = V 1 and 1 ∈ V 3 . The second condition is a consequence of the additional energy balance. These adjustments help us to prove energy dissipation and mass conservation of the space discretized system. The Galerkin approximation is given by: is fulfilled for all φ ∈ V 1 , ϕ ∈ V 2 , ψ ∈ V 3 and t ∈ [0, T ]. To close the system appropriate boundary and initial conditions, as well as a state equation for the pressure have to be chosen. Energy dissipation and mass conservation can be proved as in [1].

Numerical example
We assume the flow of an ideal gas through a pipe. We choose p = 2 3 e and the pipe parameters are given by L = 1m, d = 0.04m, λ = 1.6. Furthermore, for the space discretization we choose P0P1P1 finite elements and a step size of ∆x = 1/100.  Fig.1 depicts the conservation of mass, which was expectable due to the boundary conditions for the momentum. The left plot depicts the total energy in the pipe at time t ∈ [0, 60]s. Due to the periodic boundary condition also the total energy shows almost periodic behavior over time. Due to the dissipative bahavior of the implicit Euler method, the euqality in (2) turns into an inequality. This effect can be made smaller by reducing the time step size, see Table 1.

Outlook
As a next step, fluid flow through large networks of pipes will be considered. This leads naturally to the need of structurepreserving model order reduction methods, which has to be accompanied by structure-preserving complexity reduction procedures, as System (1) is highly non-linear. Furthermore, adding friction and cooling through pipe walls to the energy balance equation and keeping the pH structure during approximation is a topic of current research.