modelBranchingDynamicPipes

Multi-way connections of pipes with dynamic momentum balance, pressure wave and flow reversal

Extends from TRANSFORM.Icons.Example (Icon for runnable examples).

Information

This model demonstrates the use of distributed pipe models with dynamic energy, mass and momentum balances. At time=2s the pressure of boundary4 jumps, which causes a pressure wave and flow reversal.

Change system.momentumDynamics on the Assumptions tab of the system object from SteadyStateInitial to SteadyState, in order to assume a steady-state momentum balance. This is the default for all models of the library.

Note the static head caused by the elevation of the pipes.

Note the appropriate use of the Model Structure of the DynamicPipe models (Advanced tab). The default Model Structure is av_vb, i.e. volumes with a pressure state are exposed at both ports. In many cases this gives good numerical performance, avoiding algebraic loops in connections, e.g. if a pipe is connected to a valve or to a vessel with portsData configured. The price to pay is a high-index DAE if two pipes are connected or if a pipe is connected to a boundary with prescribed pressure. In such cases one might consider changing the Model Structure.

In the BranchingDynamicPipes example, {pipe1,pipe3,pipe4}.Model Structure are configured to a_v_b, while pipe2.Model Structure remains av_vb. This avoids a high-index DAE and overdetermined initial conditions.

Components

TypeNameDefaultDescription
Modelica.Fluid.Systemsystem
TRANSFORM.Fluid.BoundaryConditions.Boundary_pTboundary1
Pipes.GenericPipe_MultiTransferSurfacepipe1
Pipes.GenericPipe_MultiTransferSurfacepipe2
Pipes.GenericPipe_MultiTransferSurfacepipe3
Pipes.GenericPipe_MultiTransferSurfacepipe4
TRANSFORM.Fluid.BoundaryConditions.Boundary_pTboundary4
Modelica.Blocks.Sources.Rampramp1
Utilities.ErrorAnalysis.UnitTestsunitTests
Modelica.Blocks.Sources.CombiTimeTabletimeTable_pipe2_T
HeatAndMassTransfer.BoundaryConditions.Heat.HeatFlow[pipe2.nV]heat2
Modelica.Blocks.Sources.RealExpression[pipe2.nV]realExpression
Modelica.Blocks.Sources.CombiTimeTabletimeTable_pipe2_p

Contents

NameDescription
Medium