Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery.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/Buildings 11.0.1-master/package.mo", uses=false) Using package Buildings with version 11.0.1 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 11.0.1-master/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(Buildings.Electrical.DC.Storage.Examples.Battery,tolerance=1e-06,outputFormat="mat",numberOfIntervals=5000,variableFilter="time|bat.terminal.i.1.|loa.i.1.|bat.SOC|sou.S.1.|bat.P|loa.S.1.",fileNamePrefix="Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery") translateModel(Buildings.Electrical.DC.Storage.Examples.Battery,tolerance=1e-06,outputFormat="mat",numberOfIntervals=5000,variableFilter="time|bat.terminal.i.1.|loa.i.1.|bat.SOC|sou.S.1.|bat.P|loa.S.1.",fileNamePrefix="Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery") Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001486/0.001486, allocations: 113.5 kB / 16.42 MB, free: 6.453 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.001681/0.001681, allocations: 183.9 kB / 17.35 MB, free: 5.734 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.53/1.53, allocations: 222.9 MB / 241.1 MB, free: 15.15 MB / 206.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 11.0.1-master/package.mo): time 2.725/2.725, allocations: 469.4 MB / 0.7428 GB, free: 3.605 MB / 0.6075 GB Notification: Performance of FrontEnd - loaded program: time 0.001489/0.001489, allocations: 71.89 kB / 1.065 GB, free: 13.8 MB / 0.8419 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.9246/0.9261, allocations: 159.1 MB / 1.221 GB, free: 2.352 MB / 0.9356 GB Notification: Performance of NFInst.instantiate(Buildings.Electrical.DC.Storage.Examples.Battery): time 0.01025/0.9364, allocations: 4.219 MB / 1.225 GB, free: 14.11 MB / 0.9512 GB Notification: Performance of NFInst.instExpressions: time 0.005079/0.9415, allocations: 1.955 MB / 1.227 GB, free: 12.15 MB / 0.9512 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.0006713/0.9422, allocations: 15.94 kB / 1.227 GB, free: 12.13 MB / 0.9512 GB Notification: Performance of NFTyping.typeComponents: time 0.001754/0.944, allocations: 394 kB / 1.227 GB, free: 11.75 MB / 0.9512 GB Notification: Performance of NFTyping.typeBindings: time 0.001191/0.9452, allocations: 246.5 kB / 1.228 GB, free: 11.5 MB / 0.9512 GB Notification: Performance of NFTyping.typeClassSections: time 0.001587/0.9468, allocations: 439.2 kB / 1.228 GB, free: 11.07 MB / 0.9512 GB Notification: Performance of NFFlatten.flatten: time 0.001937/0.9488, allocations: 0.9363 MB / 1.229 GB, free: 10.13 MB / 0.9512 GB Notification: Performance of NFFlatten.resolveConnections: time 0.002359/0.9512, allocations: 1.026 MB / 1.23 GB, free: 9.098 MB / 0.9512 GB Notification: Performance of NFEvalConstants.evaluate: time 0.000849/0.952, allocations: 362.7 kB / 1.23 GB, free: 8.742 MB / 0.9512 GB Notification: Performance of NFSimplifyModel.simplify: time 0.0009431/0.953, allocations: 386.4 kB / 1.231 GB, free: 8.363 MB / 0.9512 GB Notification: Performance of NFPackage.collectConstants: time 0.0002343/0.9533, allocations: 76 kB / 1.231 GB, free: 8.289 MB / 0.9512 GB Notification: Performance of NFFlatten.collectFunctions: time 0.0006488/0.9539, allocations: 211.7 kB / 1.231 GB, free: 8.082 MB / 0.9512 GB Notification: Performance of NFScalarize.scalarize: time 0.0003725/0.9543, allocations: 223.4 kB / 1.231 GB, free: 7.863 MB / 0.9512 GB Notification: Performance of NFVerifyModel.verify: time 0.0007369/0.9551, allocations: 378.1 kB / 1.231 GB, free: 7.492 MB / 0.9512 GB Notification: Performance of NFConvertDAE.convert: time 0.001926/0.957, allocations: 0.9478 MB / 1.232 GB, free: 6.543 MB / 0.9512 GB Notification: Performance of FrontEnd - DAE generated: time 6.372e-06/0.957, allocations: 4 kB / 1.232 GB, free: 6.539 MB / 0.9512 GB Notification: Performance of FrontEnd: time 2.194e-06/0.957, allocations: 0 / 1.232 GB, free: 6.539 MB / 0.9512 GB Notification: Performance of Transformations before backend: time 4.237e-05/0.9571, allocations: 4 kB / 1.232 GB, free: 6.535 MB / 0.9512 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 191 * Number of variables: 191 Notification: Performance of Generate backend data structure: time 0.002757/0.9599, allocations: 0.9732 MB / 1.233 GB, free: 5.512 MB / 0.9512 GB Notification: Performance of prepare preOptimizeDAE: time 5.063e-05/0.9599, allocations: 11.97 kB / 1.233 GB, free: 5.5 MB / 0.9512 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0008866/0.9608, allocations: 120 kB / 1.233 GB, free: 5.383 MB / 0.9512 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.001045/0.9619, allocations: 448.8 kB / 1.234 GB, free: 4.902 MB / 0.9512 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 9.212e-05/0.962, allocations: 58.38 kB / 1.234 GB, free: 4.848 MB / 0.9512 GB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0001846/0.9622, allocations: 84.36 kB / 1.234 GB, free: 4.766 MB / 0.9512 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.00215/0.9643, allocations: 0.885 MB / 1.235 GB, free: 3.812 MB / 0.9512 GB Notification: Performance of preOpt findStateOrder (simulation): time 3.169e-05/0.9644, allocations: 7.938 kB / 1.235 GB, free: 3.805 MB / 0.9512 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 0.0001086/0.9645, allocations: 31.98 kB / 1.235 GB, free: 3.773 MB / 0.9512 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 9.786e-05/0.9646, allocations: 45.98 kB / 1.235 GB, free: 3.73 MB / 0.9512 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.001503/0.9661, allocations: 0.5698 MB / 1.236 GB, free: 3.16 MB / 0.9512 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.006447/0.9726, allocations: 3.708 MB / 1.239 GB, free: 15.23 MB / 0.9669 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0009791/0.9736, allocations: 386.8 kB / 1.239 GB, free: 14.81 MB / 0.9669 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0006541/0.9743, allocations: 233 kB / 1.24 GB, free: 14.57 MB / 0.9669 GB Notification: Performance of preOpt evalFunc (simulation): time 5.046e-05/0.9743, allocations: 12.36 kB / 1.24 GB, free: 14.55 MB / 0.9669 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0006485/0.975, allocations: 289 kB / 1.24 GB, free: 14.25 MB / 0.9669 GB Notification: Performance of pre-optimization done (n=51): time 4.558e-06/0.975, allocations: 0 / 1.24 GB, free: 14.25 MB / 0.9669 GB Notification: Performance of matching and sorting (n=51): time 0.001475/0.9765, allocations: 497.5 kB / 1.24 GB, free: 13.75 MB / 0.9669 GB Notification: Performance of inlineWhenForInitialization (initialization): time 0.0001342/0.9767, allocations: 196.5 kB / 1.241 GB, free: 13.52 MB / 0.9669 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.000691/0.9774, allocations: 429.1 kB / 1.241 GB, free: 13.1 MB / 0.9669 GB Notification: Performance of collectPreVariables (initialization): time 9.999e-05/0.9775, allocations: 45.7 kB / 1.241 GB, free: 13.05 MB / 0.9669 GB Notification: Performance of collectInitialEqns (initialization): time 0.0003412/0.9778, allocations: 331.7 kB / 1.241 GB, free: 12.71 MB / 0.9669 GB Notification: Performance of collectInitialBindings (initialization): time 0.0001957/0.978, allocations: 142.2 kB / 1.242 GB, free: 12.57 MB / 0.9669 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0003167/0.9784, allocations: 178.5 kB / 1.242 GB, free: 12.39 MB / 0.9669 GB Notification: Performance of setup shared object (initialization): time 0.0002463/0.9786, allocations: 358.8 kB / 1.242 GB, free: 12.03 MB / 0.9669 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.000541/0.9792, allocations: 168.8 kB / 1.242 GB, free: 11.86 MB / 0.9669 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0008399/0.98, allocations: 409 kB / 1.243 GB, free: 11.36 MB / 0.9669 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.001141/0.9812, allocations: 0.5118 MB / 1.243 GB, free: 10.75 MB / 0.9669 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 8.406e-06/0.9812, allocations: 0 / 1.243 GB, free: 10.75 MB / 0.9669 GB Notification: Performance of matching and sorting (n=96) (initialization): time 0.00156/0.9828, allocations: 0.6197 MB / 1.244 GB, free: 10.13 MB / 0.9669 GB Notification: Performance of prepare postOptimizeDAE: time 3.389e-05/0.9828, allocations: 11.94 kB / 1.244 GB, free: 10.12 MB / 0.9669 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.757e-05/0.9828, allocations: 7.984 kB / 1.244 GB, free: 10.11 MB / 0.9669 GB Notification: Performance of postOpt tearingSystem (initialization): time 4.156e-05/0.9829, allocations: 12 kB / 1.244 GB, free: 10.1 MB / 0.9669 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0005764/0.9835, allocations: 99.77 kB / 1.244 GB, free: 10 MB / 0.9669 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 3.767e-05/0.9835, allocations: 19.92 kB / 1.244 GB, free: 9.98 MB / 0.9669 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0006282/0.9842, allocations: 75.22 kB / 1.244 GB, free: 9.906 MB / 0.9669 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 8.922e-05/0.9843, allocations: 35.98 kB / 1.244 GB, free: 9.871 MB / 0.9669 GB Notification: Performance of preBalanceInitialSystem (initialization_lambda0): time 0.0007958/0.9851, allocations: 326 kB / 1.244 GB, free: 9.551 MB / 0.9669 GB Notification: Performance of partitionIndependentBlocks (initialization_lambda0): time 0.0007505/0.9858, allocations: 416.4 kB / 1.245 GB, free: 9.039 MB / 0.9669 GB Notification: Performance of analyzeInitialSystem (initialization_lambda0): time 0.001109/0.987, allocations: 0.5145 MB / 1.245 GB, free: 8.422 MB / 0.9669 GB Notification: Performance of solveInitialSystemEqSystem (initialization_lambda0): time 1.268e-05/0.987, allocations: 4 kB / 1.245 GB, free: 8.418 MB / 0.9669 GB Notification: Performance of matching and sorting (n=96) (initialization_lambda0): time 0.001767/0.9888, allocations: 0.6089 MB / 1.246 GB, free: 7.801 MB / 0.9669 GB Notification: Performance of prepare postOptimizeDAE: time 2.474e-05/0.9888, allocations: 14.12 kB / 1.246 GB, free: 7.789 MB / 0.9669 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.609e-05/0.9888, allocations: 8 kB / 1.246 GB, free: 7.781 MB / 0.9669 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.823e-05/0.9889, allocations: 15.94 kB / 1.246 GB, free: 7.766 MB / 0.9669 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0005336/0.9894, allocations: 111.7 kB / 1.246 GB, free: 7.656 MB / 0.9669 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 2.36e-05/0.9895, allocations: 11.94 kB / 1.246 GB, free: 7.645 MB / 0.9669 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.00071/0.9902, allocations: 67.42 kB / 1.246 GB, free: 7.578 MB / 0.9669 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 8.517e-05/0.9903, allocations: 31.98 kB / 1.246 GB, free: 7.547 MB / 0.9669 GB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 32 * Number of states: 0 () * Number of discrete variables: 56 ($PRE.toOn.enableFire,$PRE.toHold.enableFire,$PRE.toDischarge.enableFire,$PRE.toOff.enableFire,stateGraphRoot.activeSteps,toOff.enableFire,toOff.localCondition,discharge.active,discharge.oldActive,$PRE.discharge.oldActive,discharge.newActive,$PRE.discharge.newActive,discharge.localActive,$PRE.discharge.localActive,toDischarge.enableFire,toDischarge.localCondition,hold.oldActive,$PRE.hold.oldActive,hold.newActive,$PRE.hold.newActive,hold.localActive,$PRE.hold.localActive,hold.active,toHold.enableFire,toHold.localCondition,charge.active,charge.oldActive,$PRE.charge.oldActive,charge.newActive,$PRE.charge.newActive,charge.localActive,$PRE.charge.localActive,toOn.enableFire,toOn.localCondition,off.oldActive,$PRE.off.oldActive,off.newActive,$PRE.off.newActive,off.localActive,$PRE.off.localActive,off.active,bat.cha.overCharged,$PRE.bat.cha.overCharged,bat.cha.underCharged,$PRE.bat.cha.underCharged,$whenCondition1,toOn.t_start,$PRE.toOn.t_start,toHold.t_start,$PRE.toHold.t_start,toDischarge.t_start,$PRE.toDischarge.t_start,toOff.t_start,$PRE.toOff.t_start,stateGraphRoot.resume,stateGraphRoot.suspend) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (96): * Single equations (assignments): 96 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of prepare postOptimizeDAE: time 0.0004035/0.9907, allocations: 253.9 kB / 1.246 GB, free: 7.293 MB / 0.9669 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0001707/0.9909, allocations: 51.38 kB / 1.246 GB, free: 7.242 MB / 0.9669 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001208/0.9921, allocations: 401.1 kB / 1.247 GB, free: 6.84 MB / 0.9669 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 1.181e-05/0.9921, allocations: 0 / 1.247 GB, free: 6.84 MB / 0.9669 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 1.005e-05/0.9921, allocations: 7.984 kB / 1.247 GB, free: 6.832 MB / 0.9669 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0002973/0.9924, allocations: 152.4 kB / 1.247 GB, free: 6.664 MB / 0.9669 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0001356/0.9926, allocations: 16 kB / 1.247 GB, free: 6.648 MB / 0.9669 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0002927/0.9929, allocations: 19.98 kB / 1.247 GB, free: 6.629 MB / 0.9669 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001984/0.9931, allocations: 48.31 kB / 1.247 GB, free: 6.582 MB / 0.9669 GB Notification: Performance of postOpt createDAEmodeBDAE (simulation): time 0.001513/0.9946, allocations: 0.8593 MB / 1.248 GB, free: 5.715 MB / 0.9669 GB Notification: Performance of postOpt symbolicJacobianDAE (simulation): time 0.001835/0.9965, allocations: 1.097 MB / 1.249 GB, free: 4.594 MB / 0.9669 GB Notification: Performance of postOpt setEvaluationStage (simulation): time 0.000435/0.9969, allocations: 183.4 kB / 1.249 GB, free: 4.414 MB / 0.9669 GB Notification: Performance of sorting global known variables: time 0.0004261/0.9974, allocations: 263.1 kB / 1.249 GB, free: 4.16 MB / 0.9669 GB Notification: Performance of Backend: time 7.72e-07/0.9974, allocations: 0 / 1.249 GB, free: 4.16 MB / 0.9669 GB Notification: Performance of simCode: created initialization part: time 0.003261/1.001, allocations: 0.7926 MB / 1.25 GB, free: 3.371 MB / 0.9669 GB Notification: Performance of SimCode: time 0.003023/1.004, allocations: 1.433 MB / 1.251 GB, free: 1.895 MB / 0.9669 GB Notification: Performance of Templates: time 0.02513/1.029, allocations: 8.363 MB / 1.26 GB, free: 9.586 MB / 0.9825 GB make -j1 -f Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery.makefile (rm -f Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery.pipe ; mkfifo Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery.pipe ; head -c 1048576 < Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery.pipe >> ../files/Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery.sim & ./Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery -abortSlowSimulation -alarm=480 -emit_protected -lv LOG_STATS > Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery.pipe 2>&1) diffSimulationResults("Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery_res.mat","/mnt/ReferenceFiles/Buildings/csv/master/Buildings_Electrical_DC_Storage_Examples_Battery.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/OpenModelicaLibraryTesting/files/Buildings_latest_Buildings.Electrical.DC.Storage.Examples.Battery.diff",relTol=0.003,relTolDiffMinMax=0.003,rangeDelta=0.001) Reference file matches