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: "" <> buildModelFMU(ThermofluidStream.FlowControl.Tests.Switch,fileNamePrefix="ThermofluidStream_ThermofluidStream_FlowControl_Tests_Switch",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(ThermofluidStream.FlowControl.Tests.Switch,fileNamePrefix="ThermofluidStream_ThermofluidStream_FlowControl_Tests_Switch",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.006132/0.006132, allocations: 98.39 kB / 15.73 MB, free: 5.98 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.001237/0.001237, allocations: 194.4 kB / 16.67 MB, free: 5.91 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.47/1.47, allocations: 222.9 MB / 240.4 MB, free: 15.08 MB / 206.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ThermofluidStream 1.1.0-main/package.mo): time 0.7744/0.7744, allocations: 91.19 MB / 381.7 MB, free: 7.531 MB / 302.1 MB Notification: Performance of FrontEnd - loaded program: time 0.003202/0.003202, allocations: 75.89 kB / 0.5164 GB, free: 4.637 MB / 446.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.4145/0.4177, allocations: 67.69 MB / 0.5825 GB, free: 13.64 MB / 446.1 MB Notification: Performance of NFInst.instantiate(ThermofluidStream.FlowControl.Tests.Switch): time 0.6205/1.038, allocations: 225.1 MB / 0.8022 GB, free: 424 kB / 0.5762 GB Notification: Performance of NFInst.instExpressions: time 0.02772/1.066, allocations: 25.01 MB / 0.8267 GB, free: 13.43 MB / 0.5919 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.003602/1.07, allocations: 78.59 kB / 0.8267 GB, free: 13.43 MB / 0.5919 GB Notification: Performance of NFTyping.typeComponents: time 0.006277/1.076, allocations: 1.669 MB / 0.8284 GB, free: 13.22 MB / 0.5919 GB Notification: Performance of NFTyping.typeBindings: time 0.009431/1.085, allocations: 2.66 MB / 0.831 GB, free: 12.26 MB / 0.5919 GB Notification: Performance of NFTyping.typeClassSections: time 0.006454/1.092, allocations: 1.915 MB / 0.8328 GB, free: 11.23 MB / 0.5919 GB Notification: Performance of NFFlatten.flatten: time 0.006767/1.099, allocations: 4.021 MB / 0.8368 GB, free: 9.789 MB / 0.5919 GB Notification: Performance of NFFlatten.resolveConnections: time 0.001967/1.101, allocations: 1.134 MB / 0.8379 GB, free: 9.199 MB / 0.5919 GB Notification: Performance of NFEvalConstants.evaluate: time 0.004396/1.105, allocations: 1.657 MB / 0.8395 GB, free: 8.203 MB / 0.5919 GB Notification: Performance of NFSimplifyModel.simplify: time 0.003168/1.108, allocations: 2.109 MB / 0.8415 GB, free: 6.254 MB / 0.5919 GB Notification: Performance of NFPackage.collectConstants: time 0.0006527/1.109, allocations: 316 kB / 0.8418 GB, free: 5.945 MB / 0.5919 GB Notification: Performance of NFFlatten.collectFunctions: time 0.009337/1.118, allocations: 3.372 MB / 0.8451 GB, free: 3.09 MB / 0.5919 GB Notification: Performance of NFScalarize.scalarize: time 0.0006642/1.119, allocations: 0.6537 MB / 0.8458 GB, free: 2.465 MB / 0.5919 GB Notification: Performance of NFVerifyModel.verify: time 0.002522/1.122, allocations: 1.505 MB / 0.8473 GB, free: 0.9844 MB / 0.5919 GB Notification: Performance of NFConvertDAE.convert: time 0.00913/1.131, allocations: 4.821 MB / 0.852 GB, free: 12.4 MB / 0.6075 GB Notification: Performance of FrontEnd - DAE generated: time 4.488e-06/1.131, allocations: 0 / 0.852 GB, free: 12.4 MB / 0.6075 GB Notification: Performance of FrontEnd: time 1.422e-06/1.131, allocations: 0 / 0.852 GB, free: 12.4 MB / 0.6075 GB Notification: Performance of Transformations before backend: time 4.544e-05/1.131, allocations: 0 / 0.852 GB, free: 12.4 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.00705/1.138, allocations: 3.436 MB / 0.8553 GB, free: 8.938 MB / 0.6075 GB Notification: Performance of prepare preOptimizeDAE: time 3.828e-05/1.138, allocations: 8.031 kB / 0.8553 GB, free: 8.93 MB / 0.6075 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.0004693/1.138, allocations: 274.6 kB / 0.8556 GB, free: 8.652 MB / 0.6075 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0004987/1.139, allocations: 306.1 kB / 0.8559 GB, free: 8.352 MB / 0.6075 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.002813/1.142, allocations: 1.77 MB / 0.8576 GB, free: 6.625 MB / 0.6075 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0002152/1.142, allocations: 151.8 kB / 0.8577 GB, free: 6.477 MB / 0.6075 GB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0003033/1.142, allocations: 203.5 kB / 0.8579 GB, free: 6.281 MB / 0.6075 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.004019/1.146, allocations: 2.341 MB / 0.8602 GB, free: 3.918 MB / 0.6075 GB Notification: Performance of preOpt findStateOrder (simulation): time 3.811e-05/1.146, allocations: 0 / 0.8602 GB, free: 3.918 MB / 0.6075 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 0.0001702/1.147, allocations: 76 kB / 0.8603 GB, free: 3.844 MB / 0.6075 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 7.6e-05/1.147, allocations: 70.69 kB / 0.8604 GB, free: 3.773 MB / 0.6075 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.00399/1.151, allocations: 2.234 MB / 0.8626 GB, free: 1.539 MB / 0.6075 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.01327/1.164, allocations: 10.26 MB / 0.8726 GB, free: 6.512 MB / 0.6231 GB Notification: Performance of preOpt comSubExp (simulation): time 0.003368/1.167, allocations: 1.905 MB / 0.8744 GB, free: 4.598 MB / 0.6231 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.00199/1.169, allocations: 1.068 MB / 0.8755 GB, free: 3.527 MB / 0.6231 GB Notification: Performance of preOpt evalFunc (simulation): time 0.007977/1.177, allocations: 6.608 MB / 0.8819 GB, free: 12.16 MB / 0.6387 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.002138/1.18, allocations: 1.068 MB / 0.883 GB, free: 11.07 MB / 0.6387 GB Notification: Performance of pre-optimization done (n=193): time 4.238e-06/1.18, allocations: 2.438 kB / 0.883 GB, free: 11.07 MB / 0.6387 GB Notification: Performance of matching and sorting (n=198): time 0.01486/1.194, allocations: 6.571 MB / 0.8894 GB, free: 4.332 MB / 0.6387 GB Notification: Performance of inlineWhenForInitialization (initialization): time 8.231e-05/1.195, allocations: 110.5 kB / 0.8895 GB, free: 4.207 MB / 0.6387 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.00244/1.197, allocations: 1.392 MB / 0.8908 GB, free: 2.812 MB / 0.6387 GB Notification: Performance of collectPreVariables (initialization): time 0.000134/1.197, allocations: 57.7 kB / 0.8909 GB, free: 2.75 MB / 0.6387 GB Notification: Performance of collectInitialEqns (initialization): time 0.0008791/1.198, allocations: 0.9392 MB / 0.8918 GB, free: 1.801 MB / 0.6387 GB Notification: Performance of collectInitialBindings (initialization): time 0.0005359/1.199, allocations: 0.6889 MB / 0.8925 GB, free: 1.121 MB / 0.6387 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0006356/1.199, allocations: 303.5 kB / 0.8928 GB, free: 0.8203 MB / 0.6387 GB Notification: Performance of setup shared object (initialization): time 8.275e-05/1.199, allocations: 301.1 kB / 0.8931 GB, free: 0.5234 MB / 0.6387 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.001311/1.201, allocations: 0.6911 MB / 0.8937 GB, free: 15.83 MB / 0.6544 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.001593/1.202, allocations: 0.8474 MB / 0.8946 GB, free: 14.96 MB / 0.6544 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.007506/1.21, allocations: 2.578 MB / 0.8971 GB, free: 12.34 MB / 0.6544 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 7.393e-06/1.21, allocations: 0 / 0.8971 GB, free: 12.34 MB / 0.6544 GB Notification: Performance of matching and sorting (n=217) (initialization): time 0.004918/1.215, allocations: 2.45 MB / 0.8995 GB, free: 9.895 MB / 0.6544 GB Notification: Performance of prepare postOptimizeDAE: time 6.568e-05/1.215, allocations: 59.39 kB / 0.8995 GB, free: 9.824 MB / 0.6544 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.133e-05/1.215, allocations: 4 kB / 0.8995 GB, free: 9.82 MB / 0.6544 GB Notification: Performance of postOpt tearingSystem (initialization): time 0.001443/1.216, allocations: 473.3 kB / 0.9 GB, free: 9.352 MB / 0.6544 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.001304/1.218, allocations: 317.6 kB / 0.9003 GB, free: 9.059 MB / 0.6544 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.008781/1.226, allocations: 6.449 MB / 0.9066 GB, free: 2.359 MB / 0.6544 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.001521/1.228, allocations: 63.98 kB / 0.9067 GB, free: 2.297 MB / 0.6544 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.0001949/1.228, allocations: 71.97 kB / 0.9067 GB, free: 2.227 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.00105/1.229, allocations: 485.6 kB / 0.9072 GB, free: 1.766 MB / 0.6544 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0004498/1.23, allocations: 206.6 kB / 0.9074 GB, free: 1.562 MB / 0.6544 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.006325/1.236, allocations: 3.142 MB / 0.9105 GB, free: 14.41 MB / 0.67 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 1.825e-05/1.236, allocations: 20 kB / 0.9105 GB, free: 14.39 MB / 0.67 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 2.023e-05/1.236, allocations: 11.94 kB / 0.9105 GB, free: 14.38 MB / 0.67 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 2.634e-05/1.236, allocations: 11.97 kB / 0.9105 GB, free: 14.37 MB / 0.67 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.009413/1.246, allocations: 5.23 MB / 0.9156 GB, free: 9.133 MB / 0.67 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 8.806e-06/1.246, allocations: 4 kB / 0.9156 GB, free: 9.129 MB / 0.67 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.001342/1.247, allocations: 313.3 kB / 0.9159 GB, free: 8.84 MB / 0.67 GB Notification: Performance of postOpt tearingSystem (simulation): time 0.001467/1.248, allocations: 489.9 kB / 0.9164 GB, free: 8.355 MB / 0.67 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 0.0001633/1.249, allocations: 63.95 kB / 0.9164 GB, free: 8.293 MB / 0.67 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.008195/1.257, allocations: 6.47 MB / 0.9228 GB, free: 1.57 MB / 0.67 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 5.831e-06/1.257, allocations: 4.141 kB / 0.9228 GB, free: 1.566 MB / 0.67 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.007411/1.264, allocations: 3.685 MB / 0.9264 GB, free: 13.87 MB / 0.6856 GB Notification: Performance of postOpt removeConstants (simulation): time 0.001271/1.266, allocations: 0.4955 MB / 0.9268 GB, free: 13.36 MB / 0.6856 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0004419/1.266, allocations: 55.86 kB / 0.9269 GB, free: 13.3 MB / 0.6856 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.001225/1.267, allocations: 59.97 kB / 0.9269 GB, free: 13.24 MB / 0.6856 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0004823/1.268, allocations: 168.6 kB / 0.9271 GB, free: 13.08 MB / 0.6856 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 0.0001685/1.268, allocations: 80.08 kB / 0.9272 GB, free: 13 MB / 0.6856 GB Notification: Performance of sorting global known variables: time 0.001705/1.27, allocations: 0.9967 MB / 0.9282 GB, free: 12.02 MB / 0.6856 GB Notification: Performance of sort global known variables: time 3.3e-07/1.27, allocations: 0 / 0.9282 GB, free: 12.02 MB / 0.6856 GB Notification: Performance of remove unused functions: time 0.002958/1.273, allocations: 0.901 MB / 0.929 GB, free: 11.11 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.008743/1.281, allocations: 5.076 MB / 0.934 GB, free: 6.074 MB / 0.6856 GB Notification: Performance of simCode: created initialization part: time 0.004668/1.286, allocations: 2.431 MB / 0.9364 GB, free: 3.609 MB / 0.6856 GB Notification: Performance of simCode: created event and clocks part: time 6.792e-06/1.286, allocations: 0 / 0.9364 GB, free: 3.609 MB / 0.6856 GB Notification: Performance of simCode: created simulation system equations: time 0.002869/1.289, allocations: 1.541 MB / 0.9379 GB, free: 2.078 MB / 0.6856 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.003593/1.293, allocations: 0.6534 MB / 0.9385 GB, free: 1.441 MB / 0.6856 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.03258/1.325, allocations: 16.68 MB / 0.9548 GB, free: 0.5703 MB / 0.7012 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.001471/1.327, allocations: 1.577 MB / 0.9563 GB, free: 14.96 MB / 0.7169 GB Notification: Performance of simCode: alias equations: time 0.001632/1.328, allocations: 428.8 kB / 0.9567 GB, free: 14.56 MB / 0.7169 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.001491/1.33, allocations: 0.9835 MB / 0.9577 GB, free: 13.58 MB / 0.7169 GB Notification: Performance of SimCode: time 1.002e-06/1.33, allocations: 0 / 0.9577 GB, free: 13.58 MB / 0.7169 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.1226/1.452, allocations: 66.64 MB / 1.023 GB, free: 11.38 MB / 0.7794 GB Notification: Performance of buildModelFMU: Generate platform static: time 14.22/15.68, allocations: 15.8 kB / 1.023 GB, free: 11.36 MB / 0.7794 GB (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 & python3 -m fmpy simulate --output-file ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch_res.csv --start-time 0 --stop-time 10 --timeout 1200 --relative-tolerance 1e-06 --interface-type ModelExchange --solver CVode --output-interval 0.01 ThermofluidStream_ThermofluidStream_FlowControl_Tests_Switch.fmu > ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.pipe 2>&1) diffSimulationResults("ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch_res.csv","/mnt/ReferenceFiles/ThermofluidStream-main-regression/ReferenceData/ThermofluidStream.FlowControl.Tests.Switch_ref.mat","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/OpenModelicaLibraryTesting/files/ThermofluidStream_ThermofluidStream.FlowControl.Tests.Switch.diff",relTol=0.003,relTolDiffMinMax=0.003,rangeDelta=0.001) Reference file matches