The model PrescribedOutlet does not break algebraic loops for computing enthalpy when not energyDynamics==SteadState. This is a missed opportunity compared to pumps and valves where the dynamics state does break algebraic loops. The reason is that the implementation has
such that a direct dependency between the inflow and outflow enthalpy remains. The current implementation thus only filters the control input but does actually add fluid dynamics.
This could be revised such that port_b.h_outflow depends directly on the state T. To conserve energy, dhAct should then be computed from (port_b.h_outflow - inStream(port_a.h_outflow))*port_a.m_flow, to which the capacity limitations can be applied, if needed. The corresponding heat flow rate is added to the computation of der(T).
The model
PrescribedOutlet
does not break algebraic loops for computing enthalpy whennot energyDynamics==SteadState
. This is a missed opportunity compared to pumps and valves where the dynamics state does break algebraic loops. The reason is that the implementation hassuch that a direct dependency between the inflow and outflow enthalpy remains. The current implementation thus only filters the control input but does actually add fluid dynamics.
This could be revised such that
port_b.h_outflow
depends directly on the stateT
. To conserve energy,dhAct
should then be computed from(port_b.h_outflow - inStream(port_a.h_outflow))*port_a.m_flow
, to which the capacity limitations can be applied, if needed. The corresponding heat flow rate is added to the computation ofder(T)
.Can we revise the implementation in this way?