Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries/ --ompython_omhome=/usr Buildings_9_Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 9.1.1-maint.9.1.x/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/ModelicaServices 4.0.0+maint.om/package.mo", uses=false) Using package ModelicaServices with version 4.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/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 Buildings with version 9.1.1 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 9.1.1-maint.9.1.x/package.mo) Running command: "" <> buildModelFMU(Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl,fileNamePrefix="Buildings_9_Buildings_Examples_ChillerPlant_BaseClasses_Controls_Examples_BatteryControl",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl,fileNamePrefix="Buildings_9_Buildings_Examples_ChillerPlant_BaseClasses_Controls_Examples_BatteryControl",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 9.1.1-maint.9.1.x/package.mo): time 2.25/2.25, allocations: 387.4 MB / 394.9 MB, free: 13.29 MB / 314.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001038/0.001038, allocations: 184.8 kB / 487.4 MB, free: 5.004 MB / 394.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 1.454/1.454, allocations: 221.5 MB / 0.7824 GB, free: 1.004 MB / 0.5417 GB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.0009024/0.0009024, allocations: 95.89 kB / 0.9219 GB, free: 2.238 MB / 0.6823 GB Notification: Performance of FrontEnd - loaded program: time 1.893e-05/1.894e-05, allocations: 3.984 kB / 1.067 GB, free: 185.6 MB / 0.7605 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.2567/0.2567, allocations: 142.4 MB / 1.206 GB, free: 43.86 MB / 0.7605 GB Notification: Performance of FrontEnd - scodeFlatten: time 0.8431/1.1, allocations: 152.7 MB / 1.355 GB, free: 18.01 MB / 0.823 GB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0002143/1.1, allocations: 89.61 kB / 1.355 GB, free: 18.01 MB / 0.823 GB Notification: Performance of FrontEnd - DAE generated: time 0.01938/1.12, allocations: 8.231 MB / 1.363 GB, free: 33.17 MB / 0.8386 GB Notification: Performance of FrontEnd: time 1.312e-06/1.12, allocations: 0 / 1.363 GB, free: 33.17 MB / 0.8386 GB Notification: Performance of Transformations before backend: time 3.076e-05/1.12, allocations: 15.52 kB / 1.363 GB, free: 33.17 MB / 0.8386 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 128 * Number of variables: 128 Notification: Performance of Generate backend data structure: time 0.0008605/1.121, allocations: 0.6248 MB / 1.364 GB, free: 32.72 MB / 0.8386 GB Notification: Performance of prepare preOptimizeDAE: time 4.261e-05/1.121, allocations: 8.219 kB / 1.364 GB, free: 32.72 MB / 0.8386 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 9.502e-05/1.121, allocations: 57.06 kB / 1.364 GB, free: 32.69 MB / 0.8386 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0003619/1.121, allocations: 325.6 kB / 1.364 GB, free: 32.47 MB / 0.8386 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 3.875e-05/1.121, allocations: 23.53 kB / 1.364 GB, free: 32.46 MB / 0.8386 GB Notification: Performance of preOpt expandDerOperator (simulation): time 6.127e-05/1.121, allocations: 44.92 kB / 1.364 GB, free: 32.46 MB / 0.8386 GB Notification: Performance of preOpt removeEqualFunctionCalls (simulation): time 0.0006284/1.122, allocations: 357.5 kB / 1.365 GB, free: 32.46 MB / 0.8386 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0006753/1.122, allocations: 0.4913 MB / 1.365 GB, free: 32.34 MB / 0.8386 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.598e-05/1.122, allocations: 0 / 1.365 GB, free: 32.34 MB / 0.8386 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 4.106e-05/1.123, allocations: 6.859 kB / 1.365 GB, free: 32.34 MB / 0.8386 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 3.204e-05/1.123, allocations: 24.5 kB / 1.365 GB, free: 32.34 MB / 0.8386 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001896/1.124, allocations: 1.814 MB / 1.367 GB, free: 31.42 MB / 0.8386 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0004298/1.125, allocations: 362 kB / 1.367 GB, free: 31.34 MB / 0.8386 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0001948/1.125, allocations: 174.4 kB / 1.367 GB, free: 31.31 MB / 0.8386 GB Notification: Performance of preOpt evalFunc (simulation): time 5.534e-05/1.125, allocations: 18.12 kB / 1.368 GB, free: 31.31 MB / 0.8386 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0003072/1.126, allocations: 245.2 kB / 1.368 GB, free: 31.23 MB / 0.8386 GB Notification: Performance of pre-optimization done (n=48): time 1.994e-06/1.126, allocations: 0 / 1.368 GB, free: 31.23 MB / 0.8386 GB Notification: Performance of matching and sorting (n=48): time 0.0005736/1.126, allocations: 325.3 kB / 1.368 GB, free: 31.17 MB / 0.8386 GB Notification: Performance of inlineWhenForInitialization (initialization): time 4.961e-05/1.126, allocations: 120.7 kB / 1.368 GB, free: 31.04 MB / 0.8386 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0001926/1.126, allocations: 210.8 kB / 1.368 GB, free: 30.92 MB / 0.8386 GB Notification: Performance of collectPreVariables (initialization): time 4.829e-05/1.126, allocations: 43.16 kB / 1.368 GB, free: 30.89 MB / 0.8386 GB Notification: Performance of collectInitialEqns (initialization): time 0.0001288/1.127, allocations: 213.2 kB / 1.369 GB, free: 30.75 MB / 0.8386 GB Notification: Performance of collectInitialBindings (initialization): time 8.064e-05/1.127, allocations: 100.2 kB / 1.369 GB, free: 30.69 MB / 0.8386 GB Notification: Performance of simplifyInitialFunctions (initialization): time 1.99e-05/1.127, allocations: 0 / 1.369 GB, free: 30.69 MB / 0.8386 GB Notification: Performance of setup shared object (initialization): time 0.0001459/1.127, allocations: 347.1 kB / 1.369 GB, free: 30.38 MB / 0.8386 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0002046/1.127, allocations: 141.9 kB / 1.369 GB, free: 30.38 MB / 0.8386 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0002472/1.127, allocations: 274.5 kB / 1.369 GB, free: 30.23 MB / 0.8386 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.0002615/1.128, allocations: 145.9 kB / 1.37 GB, free: 30.22 MB / 0.8386 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 3.176e-06/1.128, allocations: 3.938 kB / 1.37 GB, free: 30.21 MB / 0.8386 GB Notification: Performance of matching and sorting (n=76) (initialization): time 0.0006141/1.128, allocations: 454.5 kB / 1.37 GB, free: 30.13 MB / 0.8386 GB Notification: Performance of prepare postOptimizeDAE: time 1.957e-05/1.128, allocations: 7.75 kB / 1.37 GB, free: 30.13 MB / 0.8386 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 9.157e-06/1.128, allocations: 3.844 kB / 1.37 GB, free: 30.13 MB / 0.8386 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.095e-05/1.128, allocations: 7.719 kB / 1.37 GB, free: 30.13 MB / 0.8386 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0002598/1.129, allocations: 65.12 kB / 1.37 GB, free: 30.12 MB / 0.8386 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 8.687e-06/1.129, allocations: 11.84 kB / 1.37 GB, free: 30.12 MB / 0.8386 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0002156/1.129, allocations: 32.2 kB / 1.37 GB, free: 30.11 MB / 0.8386 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 6.443e-05/1.129, allocations: 25.34 kB / 1.37 GB, free: 30.11 MB / 0.8386 GB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 16 * Number of states: 0 () * Number of discrete variables: 59 ($PRE.con.multiSwitch1.u[1],$PRE.con.multiSwitch1.u[2],$PRE.con.t1.enableFire,$PRE.con.t2.enableFire,$PRE.con.t3.enableFire,$PRE.con.t4.enableFire,$PRE.con.t3.t_start,con.t3.t_start,$PRE.con.t4.t_start,con.t4.t_start,con.stateGraphRoot.resume,con.stateGraphRoot.suspend,$whenCondition2,$whenCondition1,con.greaterEqualThreshold.y,con.and1.u1,con.and1.u2,con.and1.y,con.and2.u2,con.and2.y,con.lessEqualThreshold.y,con.multiSwitch1.u[1],con.multiSwitch1.u[2],con.multiSwitch1.firstActiveIndex,$PRE.con.off.localActive,con.off.localActive,con.off.inPort[1].set,con.off.outPort[1].reset,$PRE.con.off.newActive,con.off.newActive,$PRE.con.off.oldActive,con.off.oldActive,con.off.active,con.stateGraphRoot.activeSteps,con.alternative.split[2].available,con.t1.enableFire,con.t1.fire,$PRE.con.t1.t_start,con.t1.t_start,con.t2.enableFire,con.t2.fire,$PRE.con.t2.t_start,con.t2.t_start,$PRE.con.charge.localActive,con.charge.localActive,$PRE.con.charge.newActive,con.charge.newActive,$PRE.con.charge.oldActive,con.charge.oldActive,con.charge.active,$PRE.con.discharge.localActive,con.discharge.localActive,$PRE.con.discharge.newActive,con.discharge.newActive,$PRE.con.discharge.oldActive,con.discharge.oldActive,con.discharge.active,con.t3.enableFire,con.t4.enableFire) * Number of discrete states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (76): * Single equations (assignments): 76 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of prepare postOptimizeDAE: time 0.0001751/1.129, allocations: 165.6 kB / 1.37 GB, free: 29.97 MB / 0.8386 GB Notification: Performance of postOpt createAliasVarsForOutputStates (simulation): time 0.0004676/1.129, allocations: 313 kB / 1.371 GB, free: 29.92 MB / 0.8386 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 4.052e-05/1.13, allocations: 31.16 kB / 1.371 GB, free: 29.9 MB / 0.8386 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0006908/1.13, allocations: 376.2 kB / 1.371 GB, free: 29.85 MB / 0.8386 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 6.022e-06/1.13, allocations: 3.844 kB / 1.371 GB, free: 29.85 MB / 0.8386 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 7.073e-06/1.13, allocations: 0 / 1.371 GB, free: 29.85 MB / 0.8386 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 1.039e-05/1.13, allocations: 10.56 kB / 1.371 GB, free: 29.84 MB / 0.8386 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.00135/1.132, allocations: 0.9569 MB / 1.372 GB, free: 29.54 MB / 0.8386 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 5.29e-06/1.132, allocations: 3.844 kB / 1.372 GB, free: 29.54 MB / 0.8386 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0001554/1.132, allocations: 36.14 kB / 1.372 GB, free: 29.53 MB / 0.8386 GB Notification: Performance of postOpt tearingSystem (simulation): time 6.322e-06/1.132, allocations: 6.812 kB / 1.372 GB, free: 29.53 MB / 0.8386 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.89e-05/1.132, allocations: 11.33 kB / 1.372 GB, free: 29.52 MB / 0.8386 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 5.12e-06/1.132, allocations: 6.422 kB / 1.372 GB, free: 29.52 MB / 0.8386 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 3.516e-06/1.132, allocations: 0 / 1.372 GB, free: 29.52 MB / 0.8386 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0006096/1.133, allocations: 0.4912 MB / 1.372 GB, free: 29.31 MB / 0.8386 GB Notification: Performance of postOpt removeConstants (simulation): time 3.926e-05/1.133, allocations: 100.5 kB / 1.373 GB, free: 29.2 MB / 0.8386 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 4.997e-05/1.133, allocations: 14.19 kB / 1.373 GB, free: 29.2 MB / 0.8386 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001769/1.133, allocations: 21.92 kB / 1.373 GB, free: 29.2 MB / 0.8386 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001519/1.133, allocations: 62.84 kB / 1.373 GB, free: 29.2 MB / 0.8386 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 3.342e-05/1.133, allocations: 22.39 kB / 1.373 GB, free: 29.2 MB / 0.8386 GB Notification: Performance of sorting global known variables: time 9.629e-05/1.133, allocations: 133.5 kB / 1.373 GB, free: 29.11 MB / 0.8386 GB Notification: Performance of sort global known variables: time 1.7e-07/1.133, allocations: 0 / 1.373 GB, free: 29.11 MB / 0.8386 GB Notification: Performance of remove unused functions: time 0.0004292/1.134, allocations: 69.16 kB / 1.373 GB, free: 29.11 MB / 0.8386 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 3 * Number of states: 0 () * Number of discrete variables: 44 (con.t4.t_start,con.t3.t_start,con.t2.enableFire,con.t1.enableFire,con.discharge.active,con.discharge.localActive,con.charge.active,con.charge.localActive,con.off.localActive,$cse1,$cse2,$cse3,$cse4,$cse5,$cse6,$whenCondition2,$whenCondition1,con.greaterEqualThreshold.y,con.and1.u1,con.and1.u2,con.and1.y,con.and2.u2,con.and2.y,con.lessEqualThreshold.y,con.multiSwitch1.u[1],con.multiSwitch1.u[2],con.multiSwitch1.firstActiveIndex,con.off.inPort[1].set,con.off.outPort[1].reset,con.off.newActive,con.off.oldActive,con.off.active,con.stateGraphRoot.activeSteps,con.alternative.split[2].available,con.t1.fire,con.t1.t_start,con.t2.fire,con.t2.t_start,con.charge.newActive,con.charge.oldActive,con.discharge.newActive,con.discharge.oldActive,con.t3.enableFire,con.t4.enableFire) * Number of discrete states: 5 (con.off.newActive,con.charge.newActive,con.discharge.newActive,con.t3.t_start,con.t4.t_start) * Top-level inputs: 0 Notification: Strong component statistics for simulation (54): * Single equations (assignments): 47 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 7 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of Backend phase and start with SimCode phase: time 0.001057/1.135, allocations: 1.219 MB / 1.374 GB, free: 28.22 MB / 0.8386 GB Notification: Performance of simCode: created initialization part: time 0.0005222/1.135, allocations: 396.9 kB / 1.374 GB, free: 28.2 MB / 0.8386 GB Notification: Performance of simCode: created event and clocks part: time 2.104e-06/1.135, allocations: 0 / 1.374 GB, free: 28.2 MB / 0.8386 GB Notification: Performance of simCode: created simulation system equations: time 0.0002684/1.135, allocations: 209.4 kB / 1.375 GB, free: 28.19 MB / 0.8386 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0003079/1.136, allocations: 33.48 kB / 1.375 GB, free: 28.18 MB / 0.8386 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.001244/1.137, allocations: 0.6061 MB / 1.375 GB, free: 27.95 MB / 0.8386 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0004182/1.137, allocations: 0.8318 MB / 1.376 GB, free: 27.25 MB / 0.8386 GB Notification: Performance of simCode: alias equations: time 0.000212/1.138, allocations: 72.73 kB / 1.376 GB, free: 27.23 MB / 0.8386 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0002411/1.138, allocations: 142.4 kB / 1.376 GB, free: 27.23 MB / 0.8386 GB Notification: Performance of SimCode: time 3.41e-07/1.138, allocations: 0 / 1.376 GB, free: 27.23 MB / 0.8386 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.02474/1.163, allocations: 6.854 MB / 1.383 GB, free: 25.76 MB / 0.8386 GB Notification: Performance of buildModelFMU: configured platform static using cached values: time 0.0001563/1.163, allocations: 170.4 kB / 1.383 GB, free: 25.57 MB / 0.8386 GB Notification: Performance of buildModelFMU: Generate platform static: time 2.044/3.207, allocations: 3.625 kB / 1.383 GB, free: 25.57 MB / 0.8386 GB (rm -f Buildings_9_Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl.pipe ; mkfifo Buildings_9_Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl.pipe ; head -c 1048576 < Buildings_9_Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl.pipe >> ../files/Buildings_9_Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl.sim & /home/hudson/saved_omc/OMSimulator/install/linux/bin/OMSimulator -r=Buildings_9_Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl_res.mat --tempDir=temp_Buildings_9_Buildings_Examples_ChillerPlant_BaseClasses_Controls_Examples_BatteryControl_fmu --startTime=0 --stopTime=604800 --timeout=50 --tolerance=1e-06 Buildings_9_Buildings_Examples_ChillerPlant_BaseClasses_Controls_Examples_BatteryControl.fmu > Buildings_9_Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl.pipe 2>&1) TODO: How the !@#!# did the simulation report success but simulation result Buildings_9_Buildings.Examples.ChillerPlant.BaseClasses.Controls.Examples.BatteryControl_res.mat does not exist to compare? outputFormat=mat