Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.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 4.0.0+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ThermofluidStream 1.1.0-main/package.mo", uses=false) Using package ThermofluidStream with version 1.1.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ThermofluidStream 1.1.0-main/package.mo) Using package Modelica with version 4.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+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(ThermofluidStream.FlowControl.Tests.Switch,tolerance=1e-06,outputFormat="mat",numberOfIntervals=2000,variableFilter="Time|fourWaySwitch.switch.tanValve.outlet.m_flow|fourWaySwitch.switch1.tanValve.outlet.m_flow|pulse.T_start|pulse.count|pulse1.T_start|pulse1.count|source.outlet.m_flow|source1.outlet.m_flow|source2.outlet.m_flow|switch.tanValve.outlet.m_flow",fileNamePrefix="ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch") translateModel(ThermofluidStream.FlowControl.Tests.Switch,tolerance=1e-06,outputFormat="mat",numberOfIntervals=2000,variableFilter="Time|fourWaySwitch.switch.tanValve.outlet.m_flow|fourWaySwitch.switch1.tanValve.outlet.m_flow|pulse.T_start|pulse.count|pulse1.T_start|pulse1.count|source.outlet.m_flow|source1.outlet.m_flow|source2.outlet.m_flow|switch.tanValve.outlet.m_flow",fileNamePrefix="ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch") Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.00703/0.00703, allocations: 100.7 kB / 15.73 MB, free: 6.062 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.001401/0.001401, allocations: 194.3 kB / 16.67 MB, free: 5.973 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 1.469/1.469, allocations: 222.9 MB / 240.4 MB, free: 15.16 MB / 206.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ThermofluidStream 1.1.0-main/package.mo): time 0.7295/0.7295, allocations: 91.19 MB / 381.7 MB, free: 7.531 MB / 302.1 MB Notification: Performance of FrontEnd - loaded program: time 0.001406/0.001406, allocations: 75.88 kB / 0.5168 GB, free: 4.125 MB / 446.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.4092/0.4106, allocations: 67.69 MB / 0.5829 GB, free: 13.9 MB / 446.1 MB Notification: Performance of NFInst.instantiate(ThermofluidStream.FlowControl.Tests.Switch): time 0.5798/0.9904, allocations: 225.1 MB / 0.8027 GB, free: 388 kB / 0.5762 GB Notification: Performance of NFInst.instExpressions: time 0.0265/1.017, allocations: 25.01 MB / 0.8272 GB, free: 13.37 MB / 0.5919 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.003488/1.02, allocations: 78.09 kB / 0.8272 GB, free: 13.37 MB / 0.5919 GB Notification: Performance of NFTyping.typeComponents: time 0.004891/1.025, allocations: 1.671 MB / 0.8289 GB, free: 13.15 MB / 0.5919 GB Notification: Performance of NFTyping.typeBindings: time 0.007801/1.033, allocations: 2.599 MB / 0.8314 GB, free: 12.23 MB / 0.5919 GB Notification: Performance of NFTyping.typeClassSections: time 0.005451/1.039, allocations: 1.917 MB / 0.8333 GB, free: 11.2 MB / 0.5919 GB Notification: Performance of NFFlatten.flatten: time 0.005369/1.044, allocations: 4.008 MB / 0.8372 GB, free: 9.766 MB / 0.5919 GB Notification: Performance of NFFlatten.resolveConnections: time 0.001813/1.046, allocations: 1.13 MB / 0.8383 GB, free: 9.176 MB / 0.5919 GB Notification: Performance of NFEvalConstants.evaluate: time 0.003114/1.049, allocations: 1.618 MB / 0.8399 GB, free: 8.27 MB / 0.5919 GB Notification: Performance of NFSimplifyModel.simplify: time 0.003743/1.053, allocations: 2.108 MB / 0.8419 GB, free: 6.32 MB / 0.5919 GB Notification: Performance of NFPackage.collectConstants: time 0.0008085/1.054, allocations: 316 kB / 0.8422 GB, free: 6.012 MB / 0.5919 GB Notification: Performance of NFFlatten.collectFunctions: time 0.007881/1.062, allocations: 3.37 MB / 0.8455 GB, free: 3.156 MB / 0.5919 GB Notification: Performance of NFScalarize.scalarize: time 0.0008841/1.062, allocations: 0.65 MB / 0.8462 GB, free: 2.535 MB / 0.5919 GB Notification: Performance of NFVerifyModel.verify: time 0.002866/1.065, allocations: 1.502 MB / 0.8476 GB, free: 1.055 MB / 0.5919 GB Notification: Performance of NFConvertDAE.convert: time 0.009521/1.075, allocations: 4.828 MB / 0.8523 GB, free: 12.46 MB / 0.6075 GB Notification: Performance of FrontEnd - DAE generated: time 4.328e-06/1.075, allocations: 0 / 0.8523 GB, free: 12.46 MB / 0.6075 GB Notification: Performance of FrontEnd: time 1.292e-06/1.075, allocations: 0 / 0.8523 GB, free: 12.46 MB / 0.6075 GB Notification: Performance of Transformations before backend: time 0.0001248/1.075, allocations: 0 / 0.8523 GB, free: 12.46 MB / 0.6075 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 496 * Number of variables: 496 Notification: Performance of Generate backend data structure: time 0.008645/1.084, allocations: 3.437 MB / 0.8557 GB, free: 9 MB / 0.6075 GB Notification: Performance of prepare preOptimizeDAE: time 3.443e-05/1.084, allocations: 8.031 kB / 0.8557 GB, free: 8.992 MB / 0.6075 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0006898/1.084, allocations: 306.1 kB / 0.856 GB, free: 8.691 MB / 0.6075 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.003344/1.088, allocations: 1.775 MB / 0.8577 GB, free: 6.957 MB / 0.6075 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 9.699e-05/1.088, allocations: 150.3 kB / 0.8579 GB, free: 6.812 MB / 0.6075 GB Notification: Performance of preOpt expandDerOperator (simulation): time 0.000306/1.088, allocations: 196 kB / 0.8581 GB, free: 6.621 MB / 0.6075 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.004069/1.092, allocations: 2.342 MB / 0.8603 GB, free: 4.258 MB / 0.6075 GB Notification: Performance of preOpt findStateOrder (simulation): time 4.665e-05/1.092, allocations: 0 / 0.8603 GB, free: 4.258 MB / 0.6075 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 0.0001664/1.092, allocations: 78.19 kB / 0.8604 GB, free: 4.184 MB / 0.6075 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 7.46e-05/1.093, allocations: 74.69 kB / 0.8605 GB, free: 4.109 MB / 0.6075 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.003859/1.096, allocations: 2.238 MB / 0.8627 GB, free: 1.871 MB / 0.6075 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.01223/1.109, allocations: 10.25 MB / 0.8727 GB, free: 6.852 MB / 0.6231 GB Notification: Performance of preOpt comSubExp (simulation): time 0.003193/1.112, allocations: 1.912 MB / 0.8745 GB, free: 4.93 MB / 0.6231 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.001765/1.114, allocations: 1.066 MB / 0.8756 GB, free: 3.863 MB / 0.6231 GB Notification: Performance of preOpt evalFunc (simulation): time 0.007554/1.121, allocations: 6.606 MB / 0.882 GB, free: 12.49 MB / 0.6387 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.001896/1.123, allocations: 1.063 MB / 0.8831 GB, free: 11.41 MB / 0.6387 GB Notification: Performance of pre-optimization done (n=193): time 3.707e-06/1.123, allocations: 0 / 0.8831 GB, free: 11.41 MB / 0.6387 GB Notification: Performance of matching and sorting (n=198): time 0.01274/1.136, allocations: 6.568 MB / 0.8895 GB, free: 4.68 MB / 0.6387 GB Notification: Performance of inlineWhenForInitialization (initialization): time 6.748e-05/1.136, allocations: 101.6 kB / 0.8896 GB, free: 4.562 MB / 0.6387 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.001993/1.138, allocations: 1.392 MB / 0.8909 GB, free: 3.168 MB / 0.6387 GB Notification: Performance of collectPreVariables (initialization): time 0.0001475/1.138, allocations: 61.7 kB / 0.891 GB, free: 3.102 MB / 0.6387 GB Notification: Performance of collectInitialEqns (initialization): time 0.0007946/1.139, allocations: 0.9413 MB / 0.8919 GB, free: 2.152 MB / 0.6387 GB Notification: Performance of collectInitialBindings (initialization): time 0.0005997/1.14, allocations: 0.6888 MB / 0.8926 GB, free: 1.473 MB / 0.6387 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0005448/1.14, allocations: 299.5 kB / 0.8929 GB, free: 1.176 MB / 0.6387 GB Notification: Performance of setup shared object (initialization): time 0.0001101/1.14, allocations: 305.1 kB / 0.8932 GB, free: 0.875 MB / 0.6387 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.00133/1.142, allocations: 0.6911 MB / 0.8939 GB, free: 188 kB / 0.6387 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.001505/1.143, allocations: 0.8499 MB / 0.8947 GB, free: 15.31 MB / 0.6544 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.007107/1.15, allocations: 2.563 MB / 0.8972 GB, free: 12.7 MB / 0.6544 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 6.522e-06/1.15, allocations: 0 / 0.8972 GB, free: 12.7 MB / 0.6544 GB Notification: Performance of matching and sorting (n=217) (initialization): time 0.005164/1.155, allocations: 2.456 MB / 0.8996 GB, free: 10.25 MB / 0.6544 GB Notification: Performance of prepare postOptimizeDAE: time 6.489e-05/1.156, allocations: 65.94 kB / 0.8996 GB, free: 10.18 MB / 0.6544 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.32e-05/1.156, allocations: 0 / 0.8996 GB, free: 10.18 MB / 0.6544 GB Notification: Performance of postOpt tearingSystem (initialization): time 0.0015/1.157, allocations: 469.3 kB / 0.9001 GB, free: 9.715 MB / 0.6544 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.00128/1.158, allocations: 329.4 kB / 0.9004 GB, free: 9.41 MB / 0.6544 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.008205/1.167, allocations: 6.455 MB / 0.9067 GB, free: 2.703 MB / 0.6544 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.001338/1.168, allocations: 59.95 kB / 0.9068 GB, free: 2.645 MB / 0.6544 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.0002519/1.168, allocations: 71.97 kB / 0.9068 GB, free: 2.574 MB / 0.6544 GB Warning: Assuming fixed start value for the following 1 variables: flowResistance2.inlet.m_flow:VARIABLE(flow=true unit = "kg/s" fixed = true ) "Mass flow rate" type: Real Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 9 * Number of states: 0 () * Number of discrete variables: 10 ($PRE.pulse.count,$PRE.pulse.T_start,pulse.count,pulse.T_start,$whenCondition1,pulse1.count,$PRE.pulse1.count,pulse1.T_start,$PRE.pulse1.T_start,$whenCondition2) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (173): * Single equations (assignments): 169 * Array equations: 0 * Algorithm blocks: 2 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 2 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems (#iteration vars, #inner vars, density): 2 systems {(2,10,100.0%), (4,28,93.8%)} * Non-linear torn systems (#iteration vars, #inner vars): 0 systems Notification: Performance of prepare postOptimizeDAE: time 0.00103/1.169, allocations: 485.5 kB / 0.9073 GB, free: 2.113 MB / 0.6544 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0005498/1.17, allocations: 214.6 kB / 0.9075 GB, free: 1.902 MB / 0.6544 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.006128/1.176, allocations: 3.117 MB / 0.9105 GB, free: 14.77 MB / 0.67 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 1.906e-05/1.176, allocations: 23.94 kB / 0.9106 GB, free: 14.75 MB / 0.67 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 2.199e-05/1.176, allocations: 11.94 kB / 0.9106 GB, free: 14.74 MB / 0.67 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 2.335e-05/1.176, allocations: 11.95 kB / 0.9106 GB, free: 14.73 MB / 0.67 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.009175/1.185, allocations: 5.241 MB / 0.9157 GB, free: 9.484 MB / 0.67 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 1.073e-05/1.185, allocations: 4.219 kB / 0.9157 GB, free: 9.48 MB / 0.67 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.001224/1.187, allocations: 313.6 kB / 0.916 GB, free: 9.191 MB / 0.67 GB Notification: Performance of postOpt tearingSystem (simulation): time 0.001435/1.188, allocations: 485.1 kB / 0.9165 GB, free: 8.711 MB / 0.67 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 0.0001818/1.188, allocations: 67.95 kB / 0.9165 GB, free: 8.645 MB / 0.67 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.007903/1.196, allocations: 6.469 MB / 0.9229 GB, free: 1.918 MB / 0.67 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 3.416e-06/1.196, allocations: 6.656 kB / 0.9229 GB, free: 1.914 MB / 0.67 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.00682/1.203, allocations: 3.686 MB / 0.9265 GB, free: 14.22 MB / 0.6856 GB Notification: Performance of postOpt removeConstants (simulation): time 0.00103/1.204, allocations: 0.4994 MB / 0.927 GB, free: 13.7 MB / 0.6856 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0004303/1.204, allocations: 55.88 kB / 0.927 GB, free: 13.64 MB / 0.6856 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.001184/1.206, allocations: 55.95 kB / 0.9271 GB, free: 13.59 MB / 0.6856 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.00037/1.206, allocations: 176.1 kB / 0.9272 GB, free: 13.42 MB / 0.6856 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 0.0001606/1.206, allocations: 71.95 kB / 0.9273 GB, free: 13.35 MB / 0.6856 GB Notification: Performance of sorting global known variables: time 0.001602/1.208, allocations: 0.9928 MB / 0.9283 GB, free: 12.37 MB / 0.6856 GB Notification: Performance of sort global known variables: time 1.6e-07/1.208, allocations: 0 / 0.9283 GB, free: 12.37 MB / 0.6856 GB Notification: Performance of remove unused functions: time 0.002529/1.21, allocations: 0.901 MB / 0.9291 GB, free: 11.46 MB / 0.6856 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 9 * Number of states: 6 (switch.tanValve.outlet.m_flow,flowResistance2.inlet.m_flow,fourWaySwitch.switch.tanValve.outlet.m_flow,fourWaySwitch.switch1.tanValve.outlet.m_flow,flowResistance3.inlet.m_flow,flowResistance6.inlet.m_flow) * Number of discrete variables: 6 ($whenCondition1,pulse.T_start,pulse.count,$whenCondition2,pulse1.T_start,pulse1.count) * Number of discrete states: 2 (pulse1.count,pulse.count) * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (170): * Single equations (assignments): 164 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 4 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 2 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems (#iteration vars, #inner vars, density): 2 systems {(2,10,100.0%), (4,28,93.8%)} * Non-linear torn systems (#iteration vars, #inner vars): 0 systems Notification: Performance of Backend phase and start with SimCode phase: time 0.001692/1.212, allocations: 0.9425 MB / 0.9301 GB, free: 10.58 MB / 0.6856 GB Notification: Performance of simCode: created initialization part: time 0.004517/1.217, allocations: 2.433 MB / 0.9324 GB, free: 8.117 MB / 0.6856 GB Notification: Performance of simCode: created event and clocks part: time 3.596e-06/1.217, allocations: 0 / 0.9324 GB, free: 8.117 MB / 0.6856 GB Notification: Performance of simCode: created simulation system equations: time 0.002823/1.219, allocations: 1.535 MB / 0.9339 GB, free: 6.594 MB / 0.6856 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.003451/1.223, allocations: 0.6631 MB / 0.9346 GB, free: 5.945 MB / 0.6856 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.008208/1.231, allocations: 4.351 MB / 0.9388 GB, free: 1.547 MB / 0.6856 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.001454/1.233, allocations: 1.576 MB / 0.9404 GB, free: 15.93 MB / 0.7012 GB Notification: Performance of simCode: alias equations: time 0.001576/1.234, allocations: 432.5 kB / 0.9408 GB, free: 15.53 MB / 0.7012 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0006085/1.235, allocations: 187.4 kB / 0.941 GB, free: 15.35 MB / 0.7012 GB Notification: Performance of SimCode: time 1.022e-06/1.235, allocations: 4 kB / 0.941 GB, free: 15.34 MB / 0.7012 GB Notification: Performance of Templates: time 0.07111/1.306, allocations: 45.79 MB / 0.9857 GB, free: 2.031 MB / 0.7325 GB make -j1 -f ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.makefile (rm -f ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.pipe ; mkfifo ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.pipe ; head -c 1048576 < ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.pipe >> ../files/ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.sim & ./ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch -abortSlowSimulation -alarm=1200 -emit_protected -lv LOG_STATS > ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.pipe 2>&1) diffSimulationResults("ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch_res.mat","/mnt/ReferenceFiles/ThermofluidStream-main-regression/ReferenceData/ThermofluidStream.FlowControl.Tests.Switch_ref.mat","/var/lib/jenkins/ws/OpenModelicaLibraryTestingWork/OpenModelicaLibraryTesting/files/ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.diff",relTol=0.003,relTolDiffMinMax=0.003,rangeDelta=0.001) Reference file matches