Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr Buildings_maint.7.0.x_Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 7.0.3-maint.7.0.x/package.mo", uses=false) Using package Buildings with version 7.0.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 7.0.3-maint.7.0.x/package.mo) Using package Modelica with version 3.2.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo) Using package Complex with version 4.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo) Using package ModelicaServices with version 4.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo) Running command: translateModel(Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="Buildings_maint.7.0.x_Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater") translateModel(Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="Buildings_maint.7.0.x_Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater") Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.00113/0.00113, allocations: 106.5 kB / 16.42 MB, free: 6.465 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001084/0.001084, allocations: 189.5 kB / 17.36 MB, free: 5.707 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo): time 1.151/1.151, allocations: 205.1 MB / 223.2 MB, free: 12.22 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 7.0.3-maint.7.0.x/package.mo): time 1.201/1.201, allocations: 251.7 MB / 0.51 GB, free: 420 kB / 430.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 1.513e-05/1.513e-05, allocations: 6.219 kB / 0.7264 GB, free: 4.695 MB / 0.5606 GB Notification: Performance of NFInst.instantiate(Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater): time 0.3793/0.3794, allocations: 126.1 MB / 0.8496 GB, free: 11.53 MB / 0.6387 GB Notification: Performance of NFInst.instExpressions: time 0.01904/0.3984, allocations: 15.53 MB / 0.8647 GB, free: 14.88 MB / 0.6544 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.00235/0.4008, allocations: 72.47 kB / 0.8648 GB, free: 14.86 MB / 0.6544 GB Notification: Performance of NFTyping.typeComponents: time 0.002072/0.4029, allocations: 0.9664 MB / 0.8657 GB, free: 14.04 MB / 0.6544 GB [/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/Utilities/Strings.mo:139:3-175:14:writable] Warning: Pure function 'Modelica.Utilities.Strings.isEmpty' contains a call to impure function 'Modelica.Utilities.Strings.Advanced.skipWhiteSpace'. Notification: Performance of NFTyping.typeBindings: time 0.00585/0.4088, allocations: 2.576 MB / 0.8682 GB, free: 11.97 MB / 0.6544 GB Notification: Performance of NFTyping.typeClassSections: time 0.004345/0.4131, allocations: 2.13 MB / 0.8703 GB, free: 10.32 MB / 0.6544 GB Notification: Performance of NFFlatten.flatten: time 0.005804/0.4189, allocations: 5.298 MB / 0.8755 GB, free: 5.016 MB / 0.6544 GB Notification: Performance of NFFlatten.resolveConnections: time 0.002163/0.4211, allocations: 1.8 MB / 0.8773 GB, free: 3.191 MB / 0.6544 GB Notification: Performance of NFEvalConstants.evaluate: time 0.003341/0.4245, allocations: 1.962 MB / 0.8792 GB, free: 1.23 MB / 0.6544 GB Notification: Performance of NFSimplifyModel.simplify: time 0.001745/0.4262, allocations: 1.389 MB / 0.8805 GB, free: 15.84 MB / 0.67 GB Notification: Performance of NFPackage.collectConstants: time 0.0002297/0.4265, allocations: 199.9 kB / 0.8807 GB, free: 15.64 MB / 0.67 GB Notification: Performance of NFFlatten.collectFunctions: time 0.003864/0.4303, allocations: 2.172 MB / 0.8828 GB, free: 13.46 MB / 0.67 GB Notification: Performance of combineBinaries: time 0.002316/0.4327, allocations: 3.356 MB / 0.8861 GB, free: 10.07 MB / 0.67 GB Notification: Performance of replaceArrayConstructors: time 0.001248/0.4339, allocations: 2.127 MB / 0.8882 GB, free: 7.922 MB / 0.67 GB Notification: Performance of NFVerifyModel.verify: time 0.000451/0.4344, allocations: 378.9 kB / 0.8886 GB, free: 7.551 MB / 0.67 GB Notification: Performance of FrontEnd: time 0.0003778/0.4348, allocations: 71.69 kB / 0.8886 GB, free: 7.48 MB / 0.67 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 312 (277) * Number of variables: 312 (292) Notification: Performance of Bindings: time 0.007693/0.4425, allocations: 9.759 MB / 0.8982 GB, free: 13.42 MB / 0.6856 GB Notification: Performance of FunctionAlias: time 0.0007695/0.4432, allocations: 0.9043 MB / 0.899 GB, free: 12.5 MB / 0.6856 GB Notification: Performance of Early Inline: time 0.004566/0.4478, allocations: 5.199 MB / 0.9041 GB, free: 7.246 MB / 0.6856 GB Notification: Performance of simplify1: time 0.0003016/0.4481, allocations: 307.6 kB / 0.9044 GB, free: 6.945 MB / 0.6856 GB Notification: Performance of Alias: time 0.007879/0.456, allocations: 8.035 MB / 0.9123 GB, free: 14.33 MB / 0.7012 GB Notification: Performance of simplify2: time 0.0002933/0.4563, allocations: 219.7 kB / 0.9125 GB, free: 14.12 MB / 0.7012 GB Notification: Performance of Events: time 0.0009757/0.4573, allocations: 0.9258 MB / 0.9134 GB, free: 13.19 MB / 0.7012 GB Notification: Performance of Detect States: time 0.0008784/0.4582, allocations: 1.005 MB / 0.9143 GB, free: 12.16 MB / 0.7012 GB Notification: Performance of Partitioning: time 0.001368/0.4596, allocations: 1.459 MB / 0.9158 GB, free: 10.5 MB / 0.7012 GB Error: Internal error NBSlice.fillDependencyArray failed because number of flattened indices 1 for dependency splDat.u[1] could not be divided by the body size 4 without rest. Error: Internal error NBAdjacency.Matrix.createPseudo failed for: [ARRY] (4) {{splDat.u[1]}, {splDat.u[2]}, {splDat.u[3]}, {splDat.u[4]}} = {{splDat.y1[1]}, {splDat.y2[1]}, {splDat.y3[1]}, {splDat.y4[1]}} ($RES_SIM_164) Error: Internal error NBAdjacency.Matrix.create failed to create adjacency matrix for system: System Variables (171/191) **************************** (1) [ALGB] (1) stream Real[1] sin1.ports.h_outflow (min = {-1e10 for $i1 in 1:1}, max = {1e10 for $i1 in 1:1}, nominal = {1e6 for $i1 in 1:1}) (2) [ALGB] (1) final Real heaPum.con.vol.p = heaPum.con.vol.ports[1].p (3) [ALGB] (2) protected flow Real[2] heaPum.eva.vol.dynBal.ports.m_flow (min = {-1e5 for $i1 in 1:2}, max = {1e5 for $i1 in 1:2}) (4) [ALGB] (1) Real heaPum.com.pSuc (start = 1e5, min = 0.0, nominal = 1e5) (5) [DISC] (1) Boolean $SEV_29 (6) [ALGB] (1) Real heaPum.com.vSuc (start = 1e-4, min = 0.0) (7) [ALGB] (1) Real heaPum.sta_a1.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (8) [DISC] (1) Boolean $SEV_28 (9) [ALGB] (2) stream Real[2] heaPum.con.vol.ports.h_outflow (min = {-1e10 for $i1 in 1:2}, max = {1e10 for $i1 in 1:2}, nominal = {1e6 for $i1 in 1:2}) (10) [ALGB] (1) Real heaPum.com.port_a.T (start = 288.15, min = 0.0, nominal = 300.0) (11) [DISC] (1) Boolean $SEV_26 (12) [ALGB] (1) protected final Real heaPum.eva.vol.dynBal.medium.state.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (13) [DISC] (1) Boolean $SEV_23 (14) [ALGB] (1) Real heaPum.con.NTU = heaPum.con.UA / (heaPum.con.cp_default * Buildings.Utilities.Math.Functions.smoothMax(abs(heaPum.m1_flow), heaPum.con.m_flow_small, heaPum.con.m_flow_small)) (min = 0.0) (15) [ALGB] (1) Real heaPum.con.port_b.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (16) [ALGB] (1) protected Real heaPum.state_a1_inflow.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (17) [DISC] (1) Boolean $SEV_20 (18) [ALGB] (1) Real[1] Sou.ports.p (start = {3e5}, min = {0.0 for $i1 in 1:1}, max = {1e8 for $i1 in 1:1}, nominal = {1e5 for $i1 in 1:1}) (19) [ALGB] (1) Real heaPum.com.pDis (start = 1e6, min = 0.0, nominal = 1e5) (20) [ALGB] (1) Real heaPum.sta_b2.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (21) [ALGB] (2) protected final Real[2] heaPum.con.vol.dynBal.ports_H_flow (min = {-1e8 for $i1 in 1:2}, max = {1e8 for $i1 in 1:2}, nominal = {1000.0 for $i1 in 1:2}) (22) [DISC] (1) Boolean $TEV_1 (23) [DISC] (1) Boolean heaPum.com.isOn (fixed = false) (24) [ALGB] (1) Real heaPum.com.PThe (25) [DISC] (1) Boolean $TEV_0 (26) [ALGB] (1) Real heaPum.com.mLea_flow (27) [ALGB] (1) Real loa.medium.T_degC = Modelica.SIunits.Conversions.to_degC(-((-273.15) - loa.medium.T_degC)) (28) [ALGB] (1) Real heaPum.sta_a1.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (29) [ALGB] (1) protected final Real heaPum.eva.vol.dynBal.medium.state.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (30) [ALGB] (1) Real heaPum.m1_flow = heaPum.m1_flow (min = -1e5, max = 1e5) (31) [ALGB] (1) stream Real heaPum.eva.preDro.port_b.h_outflow (start = 83680.0, min = -1e10, max = 1e10, nominal = 83680.0) (32) [ALGB] (1) Real heaPum.eva.eps = Buildings.Utilities.Math.Functions.smoothMin(Buildings.Fluid.HeatExchangers.BaseClasses.epsilon_ntuZ(heaPum.eva.NTU, 0.0, 6), 0.999, 1e-4) (min = 0.0) (33) [ALGB] (1) final Real heaPum.eva.vol.p = heaPum.eva.vol.ports[1].p (34) [DISC] (1) Boolean $SEV_15 (35) [DISC] (1) Boolean $SEV_14 (36) [ALGB] (2) stream Real[2] heaPum.eva.vol.ports.h_outflow (min = {-1e10 for $i1 in 1:2}, max = {1e10 for $i1 in 1:2}, nominal = {1e6 for $i1 in 1:2}) (37) [DISC] (1) Boolean $SEV_13 (38) [ALGB] (1) protected final Real heaPum.eva.vol.dynBal.medium.T_degC = Modelica.SIunits.Conversions.to_degC(-((-273.15) - heaPum.eva.vol.dynBal.medium.T_degC)) (39) [DISC] (1) Boolean $SEV_12 (40) [DISC] (1) Boolean $SEV_11 (41) [ALGB] (2) protected final Real[2] heaPum.eva.vol.dynBal.ports_H_flow (min = {-1e8 for $i1 in 1:2}, max = {1e8 for $i1 in 1:2}, nominal = {1000.0 for $i1 in 1:2}) (42) [DISC] (1) Boolean $SEV_10 (43) [ALGB] (1) Real heaPum.sta_b1.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (44) [ALGB] (1) Real heaPum.com.hCon (45) [ALGB] (1) Real heaPum.port_a2.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (46) [ALGB] (1) protected Real heaPum.lim.y (47) [ALGB] (1) Real heaPum.com.pEva (start = 1e5, min = 0.0, nominal = 1e5) (48) [ALGB] (2) protected stream Real[2] heaPum.con.vol.dynBal.ports.h_outflow (min = {-1e10 for $i1 in 1:2}, max = {1e10 for $i1 in 1:2}, nominal = {1e6 for $i1 in 1:2}) (49) [ALGB] (1) stream Real[1] sin2.ports.h_outflow (min = {-1e10 for $i1 in 1:1}, max = {1e10 for $i1 in 1:1}, nominal = {1e6 for $i1 in 1:1}) (50) [ALGB] (2) protected flow Real[2] heaPum.con.vol.dynBal.ports.m_flow (min = {-1e5 for $i1 in 1:2}, max = {1e5 for $i1 in 1:2}) (51) [ALGB] (1) Real heaPum.eva.preDro.port_b.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (52) [DISS] (1) protected discrete Real calDat.nextTimeEvent (fixed = true, start = 0.0) (53) [ALGB] (1) flow Real[1] Sou.ports.m_flow (min = {-1e60}, max = {1e60}) (54) [ALGB] (1) protected Real heaPum.com.PR (start = 2.0, min = 0.0) (55) [ALGB] (1) flow Real heaPum.port_b2.m_flow (min = -1e5, max = 1e60) (56) [ALGB] (1) Real heaPum.con.preDro.port_b.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (57) [ALGB] (1) stream Real[1] Sou.ports.h_outflow (min = {-1e10 for $i1 in 1:1}, max = {1e10 for $i1 in 1:1}, nominal = {1e6 for $i1 in 1:1}) (58) [ALGB] (1) Real heaPum.sta_b1.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (59) [ALGB] (1) Real heaPum.eva.UAeff.y = Buildings.Utilities.Math.Functions.smoothMax(heaPum.eva.UA, (heaPum.eva.cp_default * heaPum.eva.eps * abs(heaPum.m2_flow)) / (1.0 - heaPum.eva.eps), heaPum.eva.UA_small) (60) [ALGB] (1) stream Real heaPum.port_a1.h_outflow (start = 83680.0, min = -1e10, max = 1e10, nominal = 83680.0) (61) [ALGB] (1) Real heaPum.eva.NTU = heaPum.eva.UA / (heaPum.eva.cp_default * Buildings.Utilities.Math.Functions.smoothMax(abs(heaPum.m2_flow), heaPum.eva.m_flow_small, heaPum.eva.m_flow_small)) (min = 0.0) (62) [ALGB] (1) protected Real heaPum.con.con.Q_flow (63) [ALGB] (1) Real heaPum.con.UAeff.y = Buildings.Utilities.Math.Functions.smoothMax(heaPum.con.UA, (heaPum.con.cp_default * heaPum.con.eps * abs(heaPum.m1_flow)) / (1.0 - heaPum.con.eps), heaPum.con.UA_small) (64) [ALGB] (1) Real heaPum.com.TSuc (start = 288.15, min = 0.0, nominal = 300.0) (65) [ALGB] (1) Real $FUN_8 (66) [ALGB] (1) Real $FUN_7 (67) [ALGB] (1) stream Real[1] loa.ports.h_outflow (min = {-1e10 for $i1 in 1:1}, max = {1e10 for $i1 in 1:1}, nominal = {1e6 for $i1 in 1:1}) (68) [ALGB] (1) Real heaPum.m2_flow = heaPum.m2_flow (min = -1e5, max = 1e5) (69) [ALGB] (1) Real $FUN_4 (70) [DISS] (1) protected discrete Real calDat.nextTimeEventScaled (fixed = true, start = 0.0) (71) [ALGB] (1) Real $FUN_3 (72) [ALGB] (2) flow Real[2] heaPum.con.vol.ports.m_flow (min = {-1e5 for $i1 in 1:2}, max = {1e5 for $i1 in 1:2}) (73) [ALGB] (1) Real $FUN_20 (74) [ALGB] (1) stream Real heaPum.port_a2.h_outflow (start = 83680.0, min = -1e10, max = 1e10, nominal = 83680.0) (75) [ALGB] (1) Real heaPum.com.m_flow (76) [ALGB] (1) Real heaPum.eva.port_b.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (77) [ALGB] (1) protected Real heaPum.com.PRInt (start = 2.0) (78) [ALGB] (1) protected final Real heaPum.eva.vol.dynBal.m (start = heaPum.eva.vol.V * heaPum.eva.vol.rho_start, min = 0.0, StateSelect = default) (79) [ALGB] (1) protected final Real heaPum.eva.vol.dynBal.medium.p_bar = Modelica.SIunits.Conversions.to_bar(99999.99999999999 * heaPum.eva.vol.dynBal.medium.p_bar) (80) [ALGB] (4) Real[4] calDat.y (81) [ALGB] (1) Real $FUN_19 (82) [ALGB] (1) Real loa.medium.state.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (83) [ALGB] (1) Real $FUN_18 (84) [ALGB] (1) Real Sou.medium.state.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (85) [ALGB] (2) protected Real[2] heaPum.con.vol.dynBal.ports.p (start = {3e5 for $ports1 in 1:2}, min = {0.0 for $i1 in 1:2}, max = {1e8 for $i1 in 1:2}, nominal = {1e5 for $i1 in 1:2}) (86) [ALGB] (1) Real $FUN_17 (87) [ALGB] (1) Real[1] sin2.ports.p (start = {3e5}, min = {0.0 for $i1 in 1:1}, max = {1e8 for $i1 in 1:1}, nominal = {1e5 for $i1 in 1:1}) (88) [ALGB] (1) flow Real[1] loa.ports.m_flow (min = {-1e60}, max = {1e60}) (89) [ALGB] (1) protected Real heaPum.state_b2_inflow.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (90) [ALGB] (1) protected final Real heaPum.eva.vol.dynBal.U (start = Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.eva.vol.dynBal.Medium.specificInternalEnergy(Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.eva.vol.dynBal.Medium.setState_pTX(heaPum.eva.vol.dynBal.p_start, heaPum.eva.vol.dynBal.T_start, {})) * heaPum.eva.vol.dynBal.fluidVolume * heaPum.eva.vol.dynBal.rho_start + heaPum.eva.vol.dynBal.CSen * (heaPum.eva.vol.dynBal.T_start - 273.15), nominal = 1e5) (91) [ALGB] (1) protected Real heaPum.com.v_norm (92) [DISC] (1) Boolean $SEV_8 (93) [DISC] (1) Boolean $SEV_7 (94) [ALGB] (1) Real heaPum.com.pCon (start = 1e6, min = 0.0, nominal = 1e5) (95) [ALGB] (1) flow Real heaPum.con.vol.heatPort.Q_flow (96) [DISC] (1) Boolean $SEV_0 (97) [ALGB] (1) protected Real heaPum.state_a2_inflow.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (98) [ALGB] (1) protected final Real heaPum.con.vol.dynBal.m (start = heaPum.con.vol.V * heaPum.con.vol.rho_start, min = 0.0, StateSelect = default) (99) [ALGB] (1) Real loa.medium.state.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (100) [ALGB] (1) Real Sou.medium.state.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (101) [ALGB] (1) Real Sou.medium.T_degC = Modelica.SIunits.Conversions.to_degC(-((-273.15) - Sou.medium.T_degC)) (102) [ALGB] (1) protected Real heaPum.state_b2_inflow.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (103) [ALGB] (2) Real[2] heaPum.con.vol.ports.p (start = {3e5 for $ports1 in 1:2}, min = {0.0 for $i1 in 1:2}, max = {1e8 for $i1 in 1:2}, nominal = {1e5 for $i1 in 1:2}) (104) [ALGB] (1) stream Real heaPum.con.preDro.port_b.h_outflow (start = 83680.0, min = -1e10, max = 1e10, nominal = 83680.0) (105) [ALGB] (1) Real[1] sin1.ports.p (start = {3e5}, min = {0.0 for $i1 in 1:1}, max = {1e8 for $i1 in 1:1}, nominal = {1e5 for $i1 in 1:1}) (106) [ALGB] (1) Real Sou.m_flow_in (107) [ALGB] (1) Real heaPum.eva.dp = heaPum.port_a2.p - heaPum.eva.port_b.p (start = heaPum.eva._dp_start) (108) [ALGB] (1) Real[1] splDat.y4 (109) [ALGB] (1) flow Real heaPum.eva.vol.heatPort.Q_flow (110) [ALGB] (1) Real[1] splDat.y3 (111) [ALGB] (1) Real[1] splDat.y2 (112) [ALGB] (1) Real[1] splDat.y1 (113) [ALGB] (1) protected final Real heaPum.con.vol.dynBal.medium.T_degC = Modelica.SIunits.Conversions.to_degC(-((-273.15) - heaPum.con.vol.dynBal.medium.T_degC)) (114) [ALGB] (1) protected final Real heaPum.con.vol.dynBal.U (start = Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.con.vol.dynBal.Medium.specificInternalEnergy(Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.con.vol.dynBal.Medium.setState_pTX(heaPum.con.vol.dynBal.p_start, heaPum.con.vol.dynBal.T_start, {})) * heaPum.con.vol.dynBal.fluidVolume * heaPum.con.vol.dynBal.rho_start + heaPum.con.vol.dynBal.CSen * (heaPum.con.vol.dynBal.T_start - 273.15), nominal = 1e5) (115) [ALGB] (1) protected Real heaPum.state_a2_inflow.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (116) [ALGB] (1) Real Sou.medium.p_bar = Modelica.SIunits.Conversions.to_bar(99999.99999999999 * Sou.medium.p_bar) (117) [ALGB] (1) flow Real heaPum.port_b1.m_flow (min = -1e5, max = 1e60) (118) [ALGB] (1) stream Real heaPum.eva.port_b.h_outflow (start = heaPum.eva.h_outflow_start, min = -1e10, max = 1e10, nominal = 83680.0) (119) [ALGB] (1) Real heaPum.com.P (120) [ALGB] (1) Real heaPum.con.dp = heaPum.port_a1.p - heaPum.con.port_b.p (start = heaPum.con._dp_start) (121) [DISC] (1) Boolean $SEV_47 (122) [DISC] (1) Boolean $SEV_46 (123) [ALGB] (2) protected stream Real[2] heaPum.eva.vol.dynBal.ports.h_outflow (min = {-1e10 for $i1 in 1:2}, max = {1e10 for $i1 in 1:2}, nominal = {1e6 for $i1 in 1:2}) (124) [DISC] (1) Boolean $SEV_45 (125) [DISC] (1) Boolean $SEV_44 (126) [ALGB] (1) Real heaPum.sta_a2.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (127) [DISC] (1) Boolean $SEV_43 (128) [DISC] (1) Boolean $SEV_42 (129) [ALGB] (1) Real heaPum.com.port_b.T (start = 288.15, min = 0.0, nominal = 300.0) (130) [DISC] (1) Boolean $SEV_41 (131) [ALGB] (1) Real heaPum.com.COP (start = 5.0, min = 0.0) (132) [DISC] (1) Boolean $SEV_40 (133) [ALGB] (1) Real heaPum.dp2 = heaPum.port_a2.p - heaPum.eva.port_b.p (134) [ALGB] (1) Real heaPum.dp1 = heaPum.port_a1.p - heaPum.con.port_b.p (135) [ALGB] (1) protected Real heaPum.eva.con.Q_flow (136) [ALGB] (1) Real heaPum.eva.preDro.dp = heaPum.port_a2.p - heaPum.eva.preDro.port_b.p (start = heaPum.eva.preDro._dp_start, nominal = 1000.0) (137) [ALGB] (1) protected final Real heaPum.con.vol.dynBal.medium.p_bar = Modelica.SIunits.Conversions.to_bar(99999.99999999999 * heaPum.con.vol.dynBal.medium.p_bar) (138) [ALGB] (1) flow Real[1] sin2.ports.m_flow (min = {-1e60}, max = {1e60}) (139) [ALGB] (1) flow Real[1] sin1.ports.m_flow (min = {-1e60}, max = {1e60}) (140) [ALGB] (4) Real[4] splDat.u (141) [ALGB] (1) protected Real heaPum.com.k (start = 1.2) (142) [ALGB] (1) protected Real heaPum.con.con.dT (143) [ALGB] (1) protected Real heaPum.state_b1_inflow.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (144) [ALGB] (1) Real heaPum.con.eps = Buildings.Utilities.Math.Functions.smoothMin(Buildings.Fluid.HeatExchangers.BaseClasses.epsilon_ntuZ(heaPum.con.NTU, 0.0, 6), 0.999, 1e-4) (min = 0.0) (145) [ALGB] (1) Real heaPum.com.hEva (146) [DISC] (1) Boolean $SEV_39 (147) [ALGB] (1) Real heaPum.sta_a2.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (148) [DISC] (1) Boolean $SEV_38 (149) [ALGB] (1) protected final Real heaPum.con.vol.dynBal.medium.state.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (150) [DISC] (1) Boolean $SEV_37 (151) [DISC] (1) Boolean $SEV_36 (152) [ALGB] (1) Real loa.medium.p_bar = Modelica.SIunits.Conversions.to_bar(99999.99999999999 * loa.medium.p_bar) (153) [DISC] (1) Boolean $SEV_35 (154) [DISC] (1) Boolean $SEV_34 (155) [DISC] (1) Boolean $SEV_33 (156) [DISC] (1) Boolean $SEV_32 (157) [DISC] (1) Boolean $SEV_31 (158) [DISC] (1) Boolean $SEV_30 (159) [ALGB] (1) protected Real heaPum.state_a1_inflow.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) (160) [ALGB] (1) stream Real heaPum.con.port_b.h_outflow (start = heaPum.con.h_outflow_start, min = -1e10, max = 1e10, nominal = 83680.0) (161) [ALGB] (2) Real[2] heaPum.eva.vol.ports.p (start = {3e5 for $ports1 in 1:2}, min = {0.0 for $i1 in 1:2}, max = {1e8 for $i1 in 1:2}, nominal = {1e5 for $i1 in 1:2}) (162) [ALGB] (1) Real[1] loa.ports.p (start = {3e5}, min = {0.0 for $i1 in 1:1}, max = {1e8 for $i1 in 1:1}, nominal = {1e5 for $i1 in 1:1}) (163) [ALGB] (1) Real heaPum.sta_b2.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (164) [ALGB] (1) Real heaPum.port_a1.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (165) [ALGB] (1) Real loa.m_flow_in (166) [ALGB] (1) protected Real heaPum.eva.con.dT (167) [ALGB] (1) protected Real heaPum.state_b1_inflow.p (start = 3e5, min = 0.0, max = 1e8, nominal = 1e5) (168) [ALGB] (2) flow Real[2] heaPum.eva.vol.ports.m_flow (min = {-1e5 for $i1 in 1:2}, max = {1e5 for $i1 in 1:2}) (169) [ALGB] (2) protected Real[2] heaPum.eva.vol.dynBal.ports.p (start = {3e5 for $ports1 in 1:2}, min = {0.0 for $i1 in 1:2}, max = {1e8 for $i1 in 1:2}, nominal = {1e5 for $i1 in 1:2}) (170) [ALGB] (1) Real heaPum.con.preDro.dp = heaPum.port_a1.p - heaPum.con.preDro.port_b.p (start = heaPum.con.preDro._dp_start, nominal = 1000.0) (171) [ALGB] (1) protected final Real heaPum.con.vol.dynBal.medium.state.T (start = 293.15, min = 1.0, max = 1e4, nominal = 300.0) System Equations (164/191) **************************** (1) [SCAL] (1) heaPum.sta_b2.T = 273.15 + 2.390057361376673e-4 * noEvent(if $SEV_47 then sin2.ports[1].h_outflow else heaPum.eva.port_b.h_outflow) ($RES_SIM_362) (2) [SCAL] (1) heaPum.sta_a2.p = heaPum.port_a2.p ($RES_SIM_363) (3) [SCAL] (1) heaPum.eva.vol.dynBal.U = heaPum.eva.vol.dynBal.m * (4184.0 * ((-273.15) - ((-273.15) - heaPum.eva.vol.dynBal.medium.T_degC))) ($RES_SIM_80) (4) [SCAL] (1) heaPum.con.vol.dynBal.m = heaPum.con.vol.dynBal.fluidVolume * heaPum.con.vol.dynBal.rho_start ($RES_SIM_120) (5) [SCAL] (1) heaPum.sta_a2.T = 273.15 + 2.390057361376673e-4 * noEvent(if $SEV_46 then Sou.ports[1].h_outflow else heaPum.port_a2.h_outflow) ($RES_SIM_364) (6) [SCAL] (1) heaPum.eva.vol.dynBal.m = heaPum.eva.vol.dynBal.fluidVolume * heaPum.eva.vol.dynBal.rho_start ($RES_SIM_81) (7) [SCAL] (1) heaPum.sta_b1.p = heaPum.con.port_b.p ($RES_SIM_365) (8) [SCAL] (1) heaPum.con.vol.dynBal.medium.state.p = 99999.99999999999 * heaPum.con.vol.dynBal.medium.p_bar ($RES_SIM_122) (9) [SCAL] (1) heaPum.sta_b1.T = 273.15 + 2.390057361376673e-4 * noEvent(if $SEV_45 then sin1.ports[1].h_outflow else heaPum.con.port_b.h_outflow) ($RES_SIM_366) (10) [SCAL] (1) heaPum.eva.vol.dynBal.medium.state.p = 99999.99999999999 * heaPum.eva.vol.dynBal.medium.p_bar ($RES_SIM_83) (11) [SCAL] (1) heaPum.con.vol.dynBal.medium.state.T = -((-273.15) - heaPum.con.vol.dynBal.medium.T_degC) ($RES_SIM_123) (12) [SCAL] (1) heaPum.eva.vol.dynBal.medium.state.T = -((-273.15) - heaPum.eva.vol.dynBal.medium.T_degC) ($RES_SIM_84) (13) [SCAL] (1) heaPum.sta_a1.p = heaPum.port_a1.p ($RES_SIM_367) (14) [SCAL] (1) heaPum.sta_a1.T = 273.15 + 2.390057361376673e-4 * noEvent(if $SEV_44 then loa.ports[1].h_outflow else heaPum.port_a1.h_outflow) ($RES_SIM_368) (15) [SCAL] (1) loa.ports[1].p = 99999.99999999999 * loa.medium.p_bar ($RES_SIM_128) (16) [SCAL] (1) loa.ports[1].h_outflow = 4184.0 * ((-273.15) - ((-273.15) - loa.medium.T_degC)) ($RES_SIM_129) (17) [SCAL] (1) $SEV_29 = heaPum.eva.UA - (heaPum.eva.cp_default * heaPum.eva.eps * $FUN_17) / (1.0 - heaPum.eva.eps) < (-heaPum.eva.UA_small) ($RES_EVT_450) (18) [SCAL] (1) $SEV_30 = heaPum.eva.UA_small > 0.0 ($RES_EVT_451) (19) [SCAL] (1) $SEV_31 = 0.999 - $FUN_18 > 1e-4 ($RES_EVT_452) (20) [SCAL] (1) $SEV_32 = 0.999 - $FUN_18 < (-1e-4) ($RES_EVT_453) (21) [SCAL] (1) $SEV_33 = $FUN_17 - heaPum.eva.m_flow_small > heaPum.eva.m_flow_small ($RES_EVT_454) (22) [SCAL] (1) $SEV_34 = $FUN_17 - heaPum.eva.m_flow_small < (-heaPum.eva.m_flow_small) ($RES_EVT_455) (23) [SCAL] (1) $SEV_35 = heaPum.eva.m_flow_small > 0.0 ($RES_EVT_456) (24) [SCAL] (1) $SEV_36 = heaPum.con.UA - (heaPum.con.cp_default * heaPum.con.eps * $FUN_19) / (1.0 - heaPum.con.eps) > heaPum.con.UA_small ($RES_EVT_457) (25) [SCAL] (1) $SEV_37 = heaPum.con.UA - (heaPum.con.cp_default * heaPum.con.eps * $FUN_19) / (1.0 - heaPum.con.eps) < (-heaPum.con.UA_small) ($RES_EVT_458) (26) [SCAL] (1) $SEV_38 = heaPum.con.UA_small > 0.0 ($RES_EVT_459) (27) [SCAL] (1) heaPum.lim.y = homotopy(smooth(0, if $SEV_7 then heaPum.lim.uMax else if $SEV_8 then heaPum.lim.uMin else isOn.k), isOn.k) ($RES_SIM_12) (28) [SCAL] (1) heaPum.con.con.Q_flow = heaPum.con.UAeff.y * heaPum.con.con.dT ($RES_SIM_91) (29) [SCAL] (1) heaPum.eva.preDro.port_b.p = heaPum.eva.vol.ports[1].p ($RES_SIM_219) (30) [SCAL] (1) heaPum.con.con.dT = heaPum.com.port_b.T - (273.15 + 2.390057361376673e-4 * (4184.0 * ((-273.15) - ((-273.15) - heaPum.con.vol.dynBal.medium.T_degC)))) ($RES_SIM_94) (31) [SCAL] (1) loa.medium.state.p = 99999.99999999999 * loa.medium.p_bar ($RES_SIM_135) (32) [SCAL] (1) loa.medium.state.T = -((-273.15) - loa.medium.T_degC) ($RES_SIM_136) (33) [SCAL] (1) heaPum.con.preDro.port_b.h_outflow = loa.ports[1].h_outflow ($RES_SIM_99) (34) [SCAL] (1) $SEV_39 = 0.999 - $FUN_20 > 1e-4 ($RES_EVT_460) (35) [SCAL] (1) $SEV_40 = 0.999 - $FUN_20 < (-1e-4) ($RES_EVT_461) (36) [SCAL] (1) $SEV_41 = $FUN_19 - heaPum.con.m_flow_small > heaPum.con.m_flow_small ($RES_EVT_462) (37) [SCAL] (1) -Sou.m_flow_in = sum(Sou.ports.m_flow) ($RES_$AUX_352) (38) [SCAL] (1) $SEV_42 = $FUN_19 - heaPum.con.m_flow_small < (-heaPum.con.m_flow_small) ($RES_EVT_463) (39) [SCAL] (1) -loa.m_flow_in = sum(loa.ports.m_flow) ($RES_$AUX_351) (40) [SCAL] (1) $SEV_43 = heaPum.con.m_flow_small > 0.0 ($RES_EVT_464) (41) [SCAL] (1) $FUN_3 = semiLinear(heaPum.con.vol.dynBal.ports[1].m_flow, heaPum.con.preDro.port_b.h_outflow, heaPum.con.vol.dynBal.ports[1].h_outflow) ($RES_$AUX_350) (42) [SCAL] (1) $SEV_44 = heaPum.m1_flow > 0.0 ($RES_EVT_465) (43) [SCAL] (1) $SEV_45 = heaPum.port_b1.m_flow > 0.0 ($RES_EVT_466) (44) [SCAL] (1) $SEV_46 = heaPum.m2_flow > 0.0 ($RES_EVT_467) (45) [SCAL] (1) $SEV_47 = heaPum.port_b2.m_flow > 0.0 ($RES_EVT_468) (46) [SCAL] (1) heaPum.com.PR = max(heaPum.com.pDis / heaPum.com.pSuc, 0.0) ($RES_SIM_23) (47) [SCAL] (1) heaPum.com.isOn = $SEV_12 ($RES_SIM_24) (48) [SCAL] (1) heaPum.eva.vol.ports[2].h_outflow = heaPum.eva.port_b.h_outflow ($RES_SIM_223) (49) [-IF-] (11)if heaPum.com.isOn then (49) [----] [SCAL] (1) -(-heaPum.con.con.Q_flow) = heaPum.com.P * heaPum.com.COP ($RES_SIM_26) (49) [----] [SCAL] (1) -heaPum.con.con.Q_flow = -((-heaPum.eva.con.Q_flow) + heaPum.com.P) ($RES_SIM_27) (49) [----] [SCAL] (1) -heaPum.eva.con.Q_flow = heaPum.com.m_flow * (heaPum.com.hEva - heaPum.com.hCon) ($RES_SIM_28) (49) [----] [SCAL] (1) heaPum.com.P = heaPum.com.PThe / heaPum.com.etaEle + heaPum.com.PLos ($RES_SIM_29) (49) [----] [SCAL] (1) heaPum.com.TSuc = heaPum.com.port_a.T + heaPum.com.dTSup ($RES_SIM_30) (49) [----] [SCAL] (1) heaPum.com.PThe = heaPum.com.V_flow_nominal * heaPum.com.pSuc * ((heaPum.com.k * heaPum.com.v_norm) / (heaPum.com.k - 1.0)) * (((1.0 / heaPum.com.k) * heaPum.com.PRInt ^ ((heaPum.com.k - 1.0) / heaPum.com.k) + (heaPum.com.PR * ((heaPum.com.k - 1.0) / heaPum.com.k)) / heaPum.com.volRat) - 1.0) ($RES_SIM_31) (49) [----] [SCAL] (1) heaPum.com.k = Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.com.ref.isentropicExponentVap_Tv(heaPum.com.TSuc, heaPum.com.vSuc) ($RES_SIM_32) (49) [----] [SCAL] (1) heaPum.com.m_flow = heaPum.com.v_norm * smooth(1, if $SEV_13 then heaPum.com.V_flow_nominal / heaPum.com.vSuc - heaPum.com.mLea_flow else if $SEV_14 then (1e-5 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc else if $SEV_15 then 0.25 * ((heaPum.com.mLea_flow + (1e-5 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc) - heaPum.com.V_flow_nominal / heaPum.com.vSuc) * ((-3.0) + ((heaPum.com.V_flow_nominal / heaPum.com.vSuc - ((1e-5 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc + heaPum.com.mLea_flow)) / ((1e-6 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc)) ^ 2.0) * ((1e6 * heaPum.com.vSuc * (heaPum.com.V_flow_nominal / heaPum.com.vSuc - (heaPum.com.mLea_flow + (1e-5 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc))) / heaPum.com.V_flow_nominal) + 0.5 * ((heaPum.com.V_flow_nominal / heaPum.com.vSuc + (1e-5 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc) - heaPum.com.mLea_flow) else 0.5 * ((heaPum.com.V_flow_nominal / heaPum.com.vSuc + (1e-5 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc) - heaPum.com.mLea_flow)) ($RES_SIM_33) (49) [----] [SCAL] (1) heaPum.com.mLea_flow = heaPum.com.leaCoe * heaPum.com.PR ($RES_SIM_34) (49) [----] [SCAL] (1) heaPum.com.pDis = heaPum.com.pCon ($RES_SIM_35) (49) [----] [SCAL] (1) heaPum.com.pSuc = heaPum.com.pEva ($RES_SIM_36) (49) [----] else (49) [----] [SCAL] (1) heaPum.com.COP = 1.0 ($RES_SIM_37) (49) [----] [SCAL] (1) -heaPum.con.con.Q_flow = 0.0 ($RES_SIM_38) (49) [----] [SCAL] (1) -heaPum.eva.con.Q_flow = 0.0 ($RES_SIM_39) (49) [----] [SCAL] (1) heaPum.com.TSuc = heaPum.com.port_a.T ($RES_SIM_40) (49) [----] [SCAL] (1) heaPum.com.P = 0.0 ($RES_SIM_41) (49) [----] [SCAL] (1) heaPum.com.PThe = 0.0 ($RES_SIM_42) (49) [----] [SCAL] (1) heaPum.com.m_flow = 0.0 ($RES_SIM_43) (49) [----] [SCAL] (1) heaPum.com.mLea_flow = 0.0 ($RES_SIM_44) (49) [----] [SCAL] (1) heaPum.com.pDis = heaPum.com.pCon ($RES_SIM_45) (49) [----] [SCAL] (1) heaPum.com.pSuc = heaPum.com.pEva ($RES_SIM_46) (49) [----] [SCAL] (1) heaPum.com.k = 1.0 ($RES_SIM_47) (49) [----] end if; (50) [SCAL] (1) heaPum.eva.vol.ports[2].p = heaPum.eva.port_b.p ($RES_SIM_224) (51) [SCAL] (1) sin1.ports[1].h_outflow = 4184.0 * ((-273.15) + sin1.T) ($RES_SIM_142) (52) [SCAL] (1) sin1.ports[1].p = sin1.p ($RES_SIM_144) (53) [SCAL] (1) Sou.ports[1].p = 99999.99999999999 * Sou.medium.p_bar ($RES_SIM_146) (54) [SCAL] (1) $FUN_4 = semiLinear(heaPum.con.vol.dynBal.ports[2].m_flow, sin1.ports[1].h_outflow, heaPum.con.vol.dynBal.ports[2].h_outflow) ($RES_$AUX_349) (55) [SCAL] (1) Sou.ports[1].h_outflow = 4184.0 * ((-273.15) - ((-273.15) - Sou.medium.T_degC)) ($RES_SIM_147) (56) [SCAL] (1) 0.0 = sum(heaPum.con.vol.dynBal.ports.m_flow) ($RES_$AUX_348) (57) [SCAL] (1) -heaPum.con.vol.heatPort.Q_flow = sum(heaPum.con.vol.dynBal.ports_H_flow) ($RES_$AUX_347) (58) [SCAL] (1) $FUN_7 = semiLinear(heaPum.eva.vol.dynBal.ports[1].m_flow, heaPum.eva.preDro.port_b.h_outflow, heaPum.eva.vol.dynBal.ports[1].h_outflow) ($RES_$AUX_346) (59) [SCAL] (1) $FUN_8 = semiLinear(heaPum.eva.vol.dynBal.ports[2].m_flow, sin2.ports[1].h_outflow, heaPum.eva.vol.dynBal.ports[2].h_outflow) ($RES_$AUX_345) (60) [SCAL] (1) 0.0 = sum(heaPum.eva.vol.dynBal.ports.m_flow) ($RES_$AUX_344) (61) [SCAL] (1) -heaPum.eva.vol.heatPort.Q_flow = sum(heaPum.eva.vol.dynBal.ports_H_flow) ($RES_$AUX_343) (62) [SCAL] (1) heaPum.com.v_norm = Buildings.Utilities.Math.Functions.smoothLimit(heaPum.lim.y, 0.0, 1.0, 0.001) ($RES_$AUX_342) (63) [SCAL] (1) heaPum.com.vSuc = Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.com.ref.specificVolumeVap_pT(heaPum.com.pSuc, heaPum.com.TSuc) ($RES_$AUX_341) (64) [SCAL] (1) heaPum.com.pCon = Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.com.ref.pressureSatVap_T(heaPum.com.port_b.T) ($RES_$AUX_340) (65) [SCAL] (1) Sou.medium.state.p = 99999.99999999999 * Sou.medium.p_bar ($RES_SIM_153) (66) [SCAL] (1) heaPum.eva.vol.dynBal.ports[2].h_outflow = heaPum.eva.vol.ports[2].h_outflow ($RES_SIM_239) (67) [SCAL] (1) Sou.medium.state.T = -((-273.15) - Sou.medium.T_degC) ($RES_SIM_154) (68) [SCAL] (1) heaPum.com.hCon = Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.com.ref.enthalpySatLiq_T(heaPum.com.port_b.T) ($RES_$AUX_339) (69) [SCAL] (1) heaPum.com.pEva = Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.com.ref.pressureSatVap_T(heaPum.com.port_a.T) ($RES_$AUX_338) (70) [SCAL] (1) heaPum.com.hEva = Buildings.Fluid.HeatPumps.Calibration.ScrollWaterToWater.heaPum.com.ref.enthalpySatVap_T(heaPum.com.port_a.T) ($RES_$AUX_337) (71) [SCAL] (1) $FUN_17 = abs(heaPum.m2_flow) ($RES_$AUX_336) (72) [SCAL] (1) $FUN_18 = Buildings.Fluid.HeatExchangers.BaseClasses.epsilon_ntuZ(heaPum.eva.NTU, 0.0, 6) ($RES_$AUX_335) (73) [SCAL] (1) $FUN_19 = abs(heaPum.m1_flow) ($RES_$AUX_334) (74) [SCAL] (1) $FUN_20 = Buildings.Fluid.HeatExchangers.BaseClasses.epsilon_ntuZ(heaPum.con.NTU, 0.0, 6) ($RES_$AUX_333) (75) [SCAL] (1) heaPum.dp1 = heaPum.port_a1.p - heaPum.con.port_b.p ($RES_BND_290) (76) [SCAL] (1) heaPum.eva.vol.dynBal.ports[1].h_outflow = heaPum.eva.vol.ports[1].h_outflow ($RES_SIM_240) (77) [SCAL] (1) heaPum.dp2 = heaPum.port_a2.p - heaPum.eva.port_b.p ($RES_BND_292) (78) [FOR-] (2) ($RES_SIM_241) (78) [----] for $i1 in 1:2 loop (78) [----] [SCAL] (1) heaPum.eva.vol.dynBal.ports[$i1].m_flow - heaPum.eva.vol.ports[$i1].m_flow = 0.0 ($RES_SIM_242) (78) [----] end for; (79) [SCAL] (1) heaPum.con.dp = heaPum.port_a1.p - heaPum.con.port_b.p ($RES_BND_294) (80) [ARRY] (2) heaPum.eva.vol.dynBal.ports.p = heaPum.eva.vol.ports.p ($RES_SIM_243) (81) [SCAL] (1) heaPum.con.vol.p = heaPum.con.vol.ports[1].p ($RES_BND_296) (82) [SCAL] (1) heaPum.con.preDro.port_b.p = heaPum.con.vol.ports[1].p ($RES_SIM_245) (83) [SCAL] (1) sin2.ports[1].h_outflow = 4184.0 * ((-273.15) + sin2.T) ($RES_SIM_160) (84) [SCAL] (1) heaPum.com.PRInt = heaPum.com.volRat ^ heaPum.com.k ($RES_SIM_49) (85) [SCAL] (1) sin2.ports[1].p = sin2.p ($RES_SIM_162) (86) [SCAL] (1) heaPum.con.vol.ports[2].h_outflow = heaPum.con.port_b.h_outflow ($RES_SIM_249) (87) [ARRY] (4) {{splDat.u[1]}, {splDat.u[2]}, {splDat.u[3]}, {splDat.u[4]}} = {{splDat.y1[1]}, {splDat.y2[1]}, {splDat.y3[1]}, {splDat.y4[1]}} ($RES_SIM_164) (88) [FOR-] (4) ($RES_SIM_165) (88) [----] for $i1 in 1:4 loop (88) [----] [SCAL] (1) calDat.y[$i1] = calDat.p_offset[$i1] + Modelica.Blocks.Tables.Internal.getTimeTableValue(calDat.tableID, $i1, time, calDat.nextTimeEventScaled, $TEV_1) ($RES_SIM_166) (88) [----] end for; (89) [WHEN] (1)when {$SEV_26, initial()} then (89) [----] calDat.nextTimeEvent := if calDat.nextTimeEventScaled < 1e60 then calDat.nextTimeEventScaled else 1e60 (89) [----] end when; (90) [WHEN] (1)when {$SEV_26, initial()} then (90) [----] calDat.nextTimeEventScaled := Modelica.Blocks.Tables.Internal.getNextTimeEvent(calDat.tableID, time) (90) [----] end when; (91) [SCAL] (1) $TEV_0 = $PRE.heaPum.com.isOn ($RES_EVT_419) (92) [SCAL] (1) heaPum.con.preDro.dp = heaPum.port_a1.p - heaPum.con.preDro.port_b.p ($RES_BND_305) (93) [SCAL] (1) heaPum.con.NTU = heaPum.con.UA / (heaPum.con.cp_default * smooth(1, if $SEV_41 then $FUN_19 else if $SEV_42 then heaPum.con.m_flow_small else if $SEV_43 then 0.25 * (heaPum.con.m_flow_small - $FUN_19) * ((-3.0) + (($FUN_19 - heaPum.con.m_flow_small) / heaPum.con.m_flow_small) ^ 2.0) * (($FUN_19 - heaPum.con.m_flow_small) / heaPum.con.m_flow_small) + 0.5 * ($FUN_19 + heaPum.con.m_flow_small) else 0.5 * ($FUN_19 + heaPum.con.m_flow_small))) ($RES_BND_306) (94) [SCAL] (1) heaPum.con.eps = smooth(1, if $SEV_39 then $FUN_20 else if $SEV_40 then 0.999 else 0.25 * (0.999 - $FUN_20) * ((-3.0) + ((0.999 - $FUN_20) / 1e-4) ^ 2.0) * (1e4 * (0.999 - $FUN_20)) + 0.5 * (0.999 + $FUN_20)) ($RES_BND_307) (95) [SCAL] (1) heaPum.con.UAeff.y = smooth(1, if $SEV_36 then heaPum.con.UA else if $SEV_37 then (heaPum.con.cp_default * heaPum.con.eps * $FUN_19) / (1.0 - heaPum.con.eps) else if $SEV_38 then 0.25 * ((heaPum.con.cp_default * heaPum.con.eps * $FUN_19) / (1.0 - heaPum.con.eps) - heaPum.con.UA) * ((-3.0) + ((heaPum.con.UA - ($FUN_19 * heaPum.con.eps * heaPum.con.cp_default) / (1.0 - heaPum.con.eps)) / heaPum.con.UA_small) ^ 2.0) * ((heaPum.con.UA - (heaPum.con.cp_default * heaPum.con.eps * $FUN_19) / (1.0 - heaPum.con.eps)) / heaPum.con.UA_small) + 0.5 * (heaPum.con.UA + (heaPum.con.cp_default * heaPum.con.eps * $FUN_19) / (1.0 - heaPum.con.eps)) else 0.5 * (heaPum.con.UA + (heaPum.con.cp_default * heaPum.con.eps * $FUN_19) / (1.0 - heaPum.con.eps))) ($RES_BND_308) (96) [SCAL] (1) heaPum.con.vol.ports[2].p = heaPum.con.port_b.p ($RES_SIM_250) (97) [SCAL] (1) heaPum.eva.con.Q_flow = heaPum.eva.UAeff.y * heaPum.eva.con.dT ($RES_SIM_52) (98) [SCAL] (1) heaPum.eva.con.dT = heaPum.com.port_a.T - (273.15 + 2.390057361376673e-4 * (4184.0 * ((-273.15) - ((-273.15) - heaPum.eva.vol.dynBal.medium.T_degC)))) ($RES_SIM_55) (99) [SCAL] (1) heaPum.eva.vol.heatPort.Q_flow - heaPum.eva.con.Q_flow = 0.0 ($RES_SIM_174) (100) [SCAL] (1) $TEV_1 = $PRE.calDat.nextTimeEventScaled ($RES_EVT_420) (101) [SCAL] (1) heaPum.eva.vol.ports[1].m_flow - heaPum.m2_flow = 0.0 ($RES_SIM_175) (102) [SCAL] (1) $SEV_0 = heaPum.lim.y > 0.01 ($RES_EVT_421) (103) [SCAL] (1) heaPum.eva.vol.ports[2].m_flow - heaPum.port_b2.m_flow = 0.0 ($RES_SIM_178) (104) [SCAL] (1) $SEV_7 = isOn.k > heaPum.lim.uMax ($RES_EVT_428) (105) [SCAL] (1) $SEV_8 = isOn.k < heaPum.lim.uMin ($RES_EVT_429) (106) [SCAL] (1) heaPum.eva.dp = heaPum.port_a2.p - heaPum.eva.port_b.p ($RES_BND_310) (107) [SCAL] (1) heaPum.eva.vol.p = heaPum.eva.vol.ports[1].p ($RES_BND_312) (108) [SCAL] (1) heaPum.eva.preDro.port_b.h_outflow = Sou.ports[1].h_outflow ($RES_SIM_60) (109) [SCAL] (1) heaPum.port_a1.h_outflow = heaPum.con.vol.ports[1].h_outflow ($RES_SIM_100) (110) [SCAL] (1) heaPum.port_a2.h_outflow = heaPum.eva.vol.ports[1].h_outflow ($RES_SIM_61) (111) [SCAL] (1) heaPum.con.preDro.dp = homotopy(Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_m_flow(heaPum.m1_flow, heaPum.con.preDro.k, heaPum.con.preDro.m_flow_turbulent), (1000.0 * heaPum.m1_flow) / heaPum.con.preDro.m_flow_nominal_pos) ($RES_SIM_101) (112) [SCAL] (1) heaPum.eva.preDro.dp = homotopy(Buildings.Fluid.BaseClasses.FlowModels.basicFlowFunction_m_flow(heaPum.m2_flow, heaPum.eva.preDro.k, heaPum.eva.preDro.m_flow_turbulent), (1000.0 * heaPum.m2_flow) / heaPum.eva.preDro.m_flow_nominal_pos) ($RES_SIM_62) (113) [SCAL] (1) heaPum.con.vol.dynBal.ports[2].h_outflow = heaPum.con.vol.ports[2].h_outflow ($RES_SIM_265) (114) [SCAL] (1) heaPum.con.vol.dynBal.ports[1].h_outflow = heaPum.con.vol.ports[1].h_outflow ($RES_SIM_266) (115) [FOR-] (2) ($RES_SIM_108) (115) [----] for $i1 in 1:2 loop (115) [----] [SCAL] (1) heaPum.con.vol.dynBal.ports[$i1].p = 99999.99999999999 * heaPum.con.vol.dynBal.medium.p_bar ($RES_SIM_109) (115) [----] end for; (116) [FOR-] (2) ($RES_SIM_267) (116) [----] for $i1 in 1:2 loop (116) [----] [SCAL] (1) heaPum.con.vol.dynBal.ports[$i1].m_flow - heaPum.con.vol.ports[$i1].m_flow = 0.0 ($RES_SIM_268) (116) [----] end for; (117) [FOR-] (2) ($RES_SIM_69) (117) [----] for $i1 in 1:2 loop (117) [----] [SCAL] (1) heaPum.eva.vol.dynBal.ports[$i1].p = 99999.99999999999 * heaPum.eva.vol.dynBal.medium.p_bar ($RES_SIM_70) (117) [----] end for; (118) [SCAL] (1) heaPum.con.vol.heatPort.Q_flow - heaPum.con.con.Q_flow = 0.0 ($RES_SIM_182) (119) [SCAL] (1) heaPum.con.vol.ports[1].m_flow - heaPum.m1_flow = 0.0 ($RES_SIM_183) (120) [ARRY] (2) heaPum.con.vol.dynBal.ports.p = heaPum.con.vol.ports.p ($RES_SIM_269) (121) [SCAL] (1) $SEV_10 = heaPum.com.port_a.T > 173.15 and heaPum.com.port_a.T < 345.25 ($RES_EVT_431) (122) [SCAL] (1) heaPum.con.vol.ports[2].m_flow - heaPum.port_b1.m_flow = 0.0 ($RES_SIM_186) (123) [SCAL] (1) $SEV_11 = heaPum.com.port_b.T > 173.15 and heaPum.com.port_b.T < 345.25 ($RES_EVT_432) (124) [SCAL] (1) $SEV_12 = not $PRE.heaPum.com.isOn and heaPum.lim.y > 0.01 or $PRE.heaPum.com.isOn and heaPum.lim.y >= 0.005 ($RES_EVT_433) (125) [SCAL] (1) $SEV_13 = heaPum.com.V_flow_nominal / heaPum.com.vSuc - (heaPum.com.mLea_flow + (1e-5 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc) > (1e-6 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc ($RES_EVT_434) (126) [SCAL] (1) splDat.y2[1] = -((-273.15) - loa.medium.T_degC) ($RES_SIM_189) (127) [SCAL] (1) $SEV_14 = heaPum.com.V_flow_nominal / heaPum.com.vSuc - (heaPum.com.mLea_flow + (1e-5 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc) < (-(1e-6 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc) ($RES_EVT_435) (128) [SCAL] (1) $SEV_15 = (1e-6 * heaPum.com.V_flow_nominal) / heaPum.com.vSuc > 0.0 ($RES_EVT_436) (129) [SCAL] (1) heaPum.eva.preDro.dp = heaPum.port_a2.p - heaPum.eva.preDro.port_b.p ($RES_BND_321) (130) [SCAL] (1) heaPum.eva.NTU = heaPum.eva.UA / (heaPum.eva.cp_default * smooth(1, if $SEV_33 then $FUN_17 else if $SEV_34 then heaPum.eva.m_flow_small else if $SEV_35 then 0.25 * (heaPum.eva.m_flow_small - $FUN_17) * ((-3.0) + (($FUN_17 - heaPum.eva.m_flow_small) / heaPum.eva.m_flow_small) ^ 2.0) * (($FUN_17 - heaPum.eva.m_flow_small) / heaPum.eva.m_flow_small) + 0.5 * ($FUN_17 + heaPum.eva.m_flow_small) else 0.5 * ($FUN_17 + heaPum.eva.m_flow_small))) ($RES_BND_322) (131) [SCAL] (1) heaPum.eva.eps = smooth(1, if $SEV_31 then $FUN_18 else if $SEV_32 then 0.999 else 0.25 * (0.999 - $FUN_18) * ((-3.0) + ((0.999 - $FUN_18) / 1e-4) ^ 2.0) * (1e4 * (0.999 - $FUN_18)) + 0.5 * (0.999 + $FUN_18)) ($RES_BND_323) (132) [SCAL] (1) heaPum.eva.UAeff.y = smooth(1, if $SEV_28 then heaPum.eva.UA else if $SEV_29 then (heaPum.eva.cp_default * heaPum.eva.eps * $FUN_17) / (1.0 - heaPum.eva.eps) else if $SEV_30 then 0.25 * ((heaPum.eva.cp_default * heaPum.eva.eps * $FUN_17) / (1.0 - heaPum.eva.eps) - heaPum.eva.UA) * ((-3.0) + ((heaPum.eva.UA - ($FUN_17 * heaPum.eva.eps * heaPum.eva.cp_default) / (1.0 - heaPum.eva.eps)) / heaPum.eva.UA_small) ^ 2.0) * ((heaPum.eva.UA - (heaPum.eva.cp_default * heaPum.eva.eps * $FUN_17) / (1.0 - heaPum.eva.eps)) / heaPum.eva.UA_small) + 0.5 * (heaPum.eva.UA + (heaPum.eva.cp_default * heaPum.eva.eps * $FUN_17) / (1.0 - heaPum.eva.eps)) else 0.5 * (heaPum.eva.UA + (heaPum.eva.cp_default * heaPum.eva.eps * $FUN_17) / (1.0 - heaPum.eva.eps))) ($RES_BND_324) (133) [SCAL] (1) heaPum.state_b2_inflow.p = heaPum.eva.port_b.p ($RES_SIM_353) (134) [FOR-] (2) ($RES_SIM_110) (134) [----] for $i1 in 1:2 loop (134) [----] [SCAL] (1) heaPum.con.vol.dynBal.ports[$i1].h_outflow = 4184.0 * ((-273.15) - ((-273.15) - heaPum.con.vol.dynBal.medium.T_degC)) ($RES_SIM_111) (134) [----] end for; (135) [SCAL] (1) heaPum.state_b2_inflow.T = 273.15 + 2.390057361376673e-4 * sin2.ports[1].h_outflow ($RES_SIM_354) (136) [FOR-] (2) ($RES_SIM_71) (136) [----] for $i1 in 1:2 loop (136) [----] [SCAL] (1) heaPum.eva.vol.dynBal.ports[$i1].h_outflow = 4184.0 * ((-273.15) - ((-273.15) - heaPum.eva.vol.dynBal.medium.T_degC)) ($RES_SIM_72) (136) [----] end for; (137) [SCAL] (1) heaPum.state_a2_inflow.p = heaPum.port_a2.p ($RES_SIM_355) (138) [SCAL] (1) heaPum.state_a2_inflow.T = 273.15 + 2.390057361376673e-4 * Sou.ports[1].h_outflow ($RES_SIM_356) (139) [SCAL] (1) heaPum.state_b1_inflow.p = heaPum.con.port_b.p ($RES_SIM_357) (140) [SCAL] (1) heaPum.state_b1_inflow.T = 273.15 + 2.390057361376673e-4 * sin1.ports[1].h_outflow ($RES_SIM_358) (141) [SCAL] (1) heaPum.state_a1_inflow.p = heaPum.port_a1.p ($RES_SIM_359) (142) [SCAL] (1) heaPum.con.vol.dynBal.ports_H_flow[2] = $FUN_4 ($RES_SIM_116) (143) [SCAL] (1) heaPum.eva.vol.dynBal.ports_H_flow[2] = $FUN_8 ($RES_SIM_77) (144) [SCAL] (1) heaPum.port_b1.m_flow + sin1.ports[1].m_flow = 0.0 ($RES_SIM_190) (145) [SCAL] (1) heaPum.con.vol.dynBal.ports_H_flow[1] = $FUN_3 ($RES_SIM_117) (146) [SCAL] (1) heaPum.eva.vol.dynBal.ports_H_flow[1] = $FUN_7 ($RES_SIM_78) (147) [SCAL] (1) sin1.ports[1].p = heaPum.con.port_b.p ($RES_SIM_191) (148) [SCAL] (1) heaPum.m2_flow + Sou.ports[1].m_flow = 0.0 ($RES_SIM_192) (149) [SCAL] (1) heaPum.con.vol.dynBal.U = heaPum.con.vol.dynBal.m * (4184.0 * ((-273.15) - ((-273.15) - heaPum.con.vol.dynBal.medium.T_degC))) ($RES_SIM_119) (150) [SCAL] (1) Sou.ports[1].p = heaPum.port_a2.p ($RES_SIM_193) (151) [SCAL] (1) heaPum.port_b2.m_flow + sin2.ports[1].m_flow = 0.0 ($RES_SIM_194) (152) [SCAL] (1) sin2.ports[1].p = heaPum.eva.port_b.p ($RES_SIM_195) (153) [SCAL] (1) $SEV_20 = abs(sum({abs(loa.ports[1].m_flow)}) - abs(loa.ports[1].m_flow)) <= 1e-60 ($RES_EVT_441) (154) [SCAL] (1) heaPum.m1_flow + loa.ports[1].m_flow = 0.0 ($RES_SIM_196) (155) [SCAL] (1) loa.ports[1].p = heaPum.port_a1.p ($RES_SIM_197) (156) [SCAL] (1) splDat.y4[1] = loa.m_flow_in ($RES_SIM_198) (157) [SCAL] (1) $SEV_23 = abs(sum({abs(Sou.ports[1].m_flow)}) - abs(Sou.ports[1].m_flow)) <= 1e-60 ($RES_EVT_444) (158) [SCAL] (1) splDat.y3[1] = Sou.m_flow_in ($RES_SIM_199) (159) [SCAL] (1) $SEV_26 = time >= $PRE.calDat.nextTimeEvent ($RES_EVT_447) (160) [SCAL] (1) $SEV_28 = heaPum.eva.UA - (heaPum.eva.cp_default * heaPum.eva.eps * $FUN_17) / (1.0 - heaPum.eva.eps) > heaPum.eva.UA_small ($RES_EVT_449) (161) [SCAL] (1) splDat.y1[1] = -((-273.15) - Sou.medium.T_degC) ($RES_SIM_200) (162) [ARRY] (4) calDat.y = splDat.u ($RES_SIM_201) (163) [SCAL] (1) heaPum.state_a1_inflow.T = 273.15 + 2.390057361376673e-4 * loa.ports[1].h_outflow ($RES_SIM_360) (164) [SCAL] (1) heaPum.sta_b2.p = heaPum.eva.port_b.p ($RES_SIM_361)