ACL Version 1.25
- AirConditioning Library 1.25 is part of Modelon's 2023.1 release. New versions of Modelon's libraries are sold and distributed directly from Modelon, as well as approved resellers.
Version 1.25 contains the changes described below.
Build 2
Enhancements
- Robustness improvement when using pressure, density & specific enthalpy (p, d, h) as dynamic states in refrigerant control volumes.
Especially in the low pressure liquid region, it has been observed that due to the density function, the state change from volume mass & internal energy to pressure and specific enthalpy is numerically sensitive and can result in mass loss or increase during simulation. The option to introduce density as additional state mitigated this by integrating the density as a independant state, ensuring that solver error control is applied to it. However, using this option has shown other issues in this region, such as inaccurate pressure fluctuations & negative density appearing in results. The root caue of this has been identified as inconsistency appearing between the independent states, p, d & h.
With this release, a consistency check is implemented in all control volumes (both in pipes & heat exchanger channels, as well as other components like junctions, valves, receivers, etc) using p, d & h as states, so that if an inconsistent state occur, the pressure is corrected so that when computing density from p, h, the result is consistent with the density state. Multiple tests has shown that this mitigate inaccurate pressure behavior and precense of negative density values.
The feature is controlled via the "System_ACL" component parameters and affect all volumes in the model. On the "Refrigeration side" tab, pdh states is enabled by setting the parameter stateChoice. When pdh is selected, the parameter d_tol_rel on the same tab determine the maximum allowed relative error between the density state and the density from pressure and enthalpy states in each volume. Tolerances in the range of 1e-3 to 1e-4 has appeared giveing good trade-off between accuracy and simulation speed. - A method has been implemented to automatically compute the total refrigerant volume & mass in a system. Include the component "AirConditioning.AggregateTwoPhase" at the top level of a system model, and its internal variables M & V will be the total mass & volume of all refrigerant volumes in that system.
Build 1 (2023-02-03)
New features
- Frost model: Added user selectable frost layer air model for use in heat exchangers (EvaporatorFrost Example - see Advanced>AirModel). This model captures both frosting and thawing and, when used in a heat exchanger, includes channel specific feedback on flow distributions due to frost layer thickness by restricting the flow channel when the option "Advanced>enableFrostFlowImpact" = true (= false only thermal resistance due to frost layer thickness is included). Under non-frosting conditions, this model behaves similar to the default air model.
Enhancements
- All coolant-air heat exchangers in the Heating package now have the capability to pass the inhomogeneous outlet air distribution through the outlet air connector. They can now be used together with HXAirHandling components to model heat exchanger stacks. To enable the feature, set the parameter homogeneousAirOutlet = false on the heat exchanger. The deafult behavior is unchanged, namely that mixed outlet air passed through a single outlet connector. Connections in case of mixed air must now be made to air_out[1, 1] instead of previously air_out. The included conversion script will automatically convert connections in existing models.
- Robustness of the moist air calculations in heat exchangers has been improved by adjusting the specific enthalpy reference point for the dry air part. The new reference ensures that enthlpy is a monotonous function of temperature, which improves convergence of non-linear systems involving these variables. Results are expected to change only for the specific enthalpy variable due to this. Temperaure and heat transfer results are not affected. If the previous enthalpy reference is needed for some reason, it can be achieved by inheriting the current moist air model and apply the modifier dhAir = 0.
- Steady-state initialization robustness of heat exchangers LayeredVertical & LayeredHorizontal has been improved by propagating the air mass flow rate initial guess value to the internal air re-sampling component.
- The PressureSensor component now provide the pressure output signal in Pa by default. This is to avoid unit error mistakes when feeding the signal to a component with a pressure input, which are considered as Pa by default. To output the pressure in bar, set the parameter useBar = true.
- The summary records of PlateRefRefHX & ChevronPlateRefRefHX now have the total mass and volume from both sides included in the variables M_ref & V_ref, to avoid easily missing that since all other heat exchangers include all refrigerant in those variables. The variables M_ref_sec & V_ref_sec have been removed from the summary. If the total mass or volume per side is needed, they can be accessed from the internal sub-components M/V_ref & M/V_ref_sec instead.
- The initial wall temperature in PlateRefRefHX & ChevronPlateRefRefHX is now assigned differently by default. The temperature of each wall segment is now taken as a weighted average of the initial fluid temperatures on both sides of the wall. The weighting can be adjusted to be closer to one fluid or the other using the parameter HX_Init.wt_wall. The previous parameter for relating the initial wall temperature to the fluid temperature "HX_Init.dT_ref_sec" has been removed. To set a different initial temperature, the parameter T0_wall can be used.
- Several functions of refrigerant media based on Helmholtz equations of state now have analytical derivative functions defined. This removes the need for numerical Jacobians for solving commonly occurring non-linear systems of equation, improving the simulation performance & robustness with these media. Few functions of Helmholtz based media do not yet have analytical derivatives though, and analytical ODE Jacobian is not available. SBTL media must be used for that.
- Improved robustess when exactly 0 degree C occur as inlet or outlet air temperature in heat exchangers. At this temperature the moist air model return very high heat capacity, and the abrupt change made the solving difficult. The updated air channel model uses the actual enthalpy difference between inlet and outlet temperature instead. Minimal result deviations can occur due to this change, being largest in when condensation occur. Typical observed result deviations have been < 1% for the air heat capacity and < 0.1% for the total transferred heat. Affected components are heat exchangers where AirModel options \"Analytic solution air flow model (moist)\" or \"Analytic solution air flow model (dry)\" are used.
- Improved robustness and improved readability of simulation logs by introducing asserts to certain media functions when they are called out of range (for example during iterative solving or variable step solver attempting a too long step).
- Modelica compliance improvements to remove several non-meaningful warnings from compilation logs.
- Multiple functions in AirConditioning.ThermoFluidPro.CommonFunctions have been moved to Modelon Base Library or replaced with the equivalent functions that existed there. The conversion script should be able to handle the changes. The function AirConditioning.ThermoFluidPro.CommonFunctions.invertVector has been replaced with Modelon.Math.RealVectors.rdivide1 and will require manual changes to the input, with a = 1.0 and b = vec.
- In the phase separator components, the summary variable for outlet vapor quality "x_out" was presenting the value of an intermediate variable only valid when both phases are present in the separator. This was corrected so the summary variable shows the correct quality also for full and empty separator.
- In the correlation AirConditioning.ThermoFluidPro.PressureLoss.FrictionTotalD, the switch from_dp can now be used to remove an unnecessary system of equations.
- Medium packages for carbon dioxide have been modified to use an IIR reference state in which the enthalpy and entropy of the saturated liquid at T=273.15K are 200kJ/kg and 1kJ/(kg.K) respectively.
- A feed forward block was added inside LimPI and can be conditionally enabled with enableFeedForward. It is propagated to SimpleTXV and can be enabled there. It is disabled by default. This was to enable branch shutoff in cycle systems. For the example models SingleTXV and TwoTXV, the experiment settings, tube sizes, and compressor behavior during reverse flow were changed.
Bug fixes
- Corrected issues with ph-visualizers. The visualizer for r1234yf with log pressure scale had an error that would show pressure levels incorrectly. Further many examples in ACL had instances with non-default aspect ratio of the ph-visualizer. That cause mis-alignment between the ph diagram bitmap and the plotted simulation results. To allow easier detection of any error, the visualizer component will render a rectangle overlaying the bitmap grid axes. If they do not align, the plotted results will also be incorrectly plotted. The solution is to resize the visualizer on the diagram to correct aspect ratio. Tools should only allow correct aspect ratio due to annotations in the visualizer components.
- Fixed an error in the AirTemperature sensor that was using air moisture from the incorrect flow direction when allowFlowReversal was set to true and analyticInverseTfromh was set to false.
- Corrected errors in the derivative functions of moist air specific heat capacity and specific enthalpy. These improvements mainly improve the robustness for heat exchangers involving moist air, as the functions are called to get Jacobians for solving non-linear equation systems there.
- Fixed that when using the flow resistance correlation AirConditioning.ThermoFluidPro.PressureLoss.FrictionTotalD, the pressure loss calibration factor would adjust the pressure drop by 1/CF. For all other flow correlations pressure loss is proportional to the calibration factor, and that is now the case for FrictionTotalD as well. Note: In existing models using this correlation together with calibration factor different from 1, the resulting pressure drop will change. The user needs to manually invert the calibration factor to achive the same result as with earlier library versions.