Closed mwetter closed 8 years ago
The case Annex60.Fluid.HeatExchangers.Examples.AirHeater_u
still has an error in OpenModelica. The other three test cases with T
as input signal, and with water instead of air, are working in OpenModelica.
The error message is
[...modelica-annex60/Annex60/Fluid/Interfaces/ConservationEquation.mo:141:7-141:25:writable] Error: Initialization problem is structurally singular, error found sorting equations
13: hea.vol.dynBal.medium.p = 101325.0;
111: hea.vol.dynBal.medium.p = vol.dynBal.medium.p;
4: vol.dynBal.medium.p = 101325.0;
for variables
vol.dynBal.ports_H_flow[1](128), hea.vol.dynBal.ports_H_flow[2](44), vol.dynBal.medium.Xi[1](122), vol.m_flow_small(5)
Error: No system for the symbolic initialization was generated.
However, medium.p
is 101325 Pa. It looks like OpenModelica fails to properly eliminate alias variables.
The problem was because the mixing volume was directly connected to the pressure source. This lead in AirHeater_u
to a high index DAE which OpenModelica could not handle. Adding a pressure drop element between these two components avoid this high index DAE, and now all four test cases simulate in OpenModelica.
I also changed a few parameters to get more reasonable transient response.
The commit https://github.com/iea-annex60/modelica-annex60/commit/25376251ea98705b3b12fb4ba2e9d875c802e2a8 causes
Annex60.Fluid.HeatExchangers.Examples.Heater_T
to fail with