2

I have a problem in understanding the simulation results of a discretized Modelica.Fluid.Pipes.DynamicPipe when using a compressible gas as medium and taking the dynamic momentum balance into account. To illustrate that I built up a very simple model: pressure source + pipe + pressure sink. The pressure in the pressure source is linearly increased over time. The parameterization of the pipe mainly corresponds to the default values, but the parameter "momentumDynamics" is set to "Modelica.Fluid.Types.Dynamics.FixedInitial".

enter image description here

For lower gas velocities (=smaller inlet pressures) the pressure drop is somehow nearly linear distributed over the discrete elements of the pipe (of course the pressure drop is not the same in every element due to the change in medium properties). As the gas velocity gets higher however, the pressure drop in the last flow model (= resistive element) is dominating by far. The picture below showes the pressures in the different flow models along the pipe. The pressure in the last flow model (green dashed line) corresponds to the constant pressure in the pressure sink.

Pressures in the different flow models along the pipe. The pressure in the last flow model (green dashed line) corresponds to the constant pressure in the pressure sink.

Actually when looking at the pressure distribution along the pipe it looks as if the pipe was choking. This is however not possible since the velocities are still far below the velocity of sound. The velocity in the last flow model is a lot higher than in the rest of the pipe, because the pressure is a lot lower, since it corresponds to atmospheric pressure. This picture below shows the velocity in the flow models in the pipes as well as the velocities of sound. The velocities of sound are nearly constant at ~330 m/s. This picture shows the velocity in the flow models in the pipes as well as the velocities of sound. The velocities of sound are nearly constant at ~330 m/s.

What I do not understand: Does the simulation result represents the physics correctly? If no, where is the "error" in the equations? If yes, what is the the physical behavior which the model represents here?

What I've tried:

  • Changing the discretization of the pipe does not change the phenomenom.
  • It seems to be independent of the medium model, I've also tried it with quite different medium models for compressible gas. (This example shown is using Modelica.Media.Air.ReferenceAir.Air_ph)
  • It only occurs if the dynamic momentum balance is chosen (since despite the name of this flag, using this flag not only "activates" the dynamic term in the momentum balance but also adds the pressure loss due to acceleration).

I'm looking forward to any hints to explain this issue!

Karin
  • 43
  • 4
  • 1
    If this turns out to be a library issue (rather than a modeling fault), please create a new issue at https://github.com/modelica/ModelicaStandardLibrary/issues/new where you reach the developers. – tbeu May 25 '20 at 21:24
  • 2
    Thanks for the hint, I did as you've suggested: https://github.com/modelica/ModelicaStandardLibrary/issues/3569 – Karin May 28 '20 at 21:16
  • According to the documentation of the Modelica.Fluid, `The momentum balance and the energy balance are only fulfilled exactly if two ports of equal diameter are connected`, you might need to use a `Modelica.Fluid.Fittings.AbruptAdaptor` component. Here is the reference link:https://doc.modelica.org/Modelica%203.2.3/Resources/helpDymola/Modelica_Fluid_UsersGuide.html#Modelica.Fluid.UsersGuide.Overview – Jack May 31 '20 at 15:22
  • I've added the AbruptAdaptor to the system model, where the diameter is increased from the pipe diameter to a diameter = "pipe diameter x 100". There is a very small pressure recovery in the abruptor model. The characteristics of the pressure distribution in the pipe remains basically unchanged (unfortunately). – Karin Jun 02 '20 at 20:53

0 Answers0