Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.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/NcDataReader2 2.5.1-master/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/package.mo", uses=false) Using package BuildingSystems with version 2.0.0-beta (/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/package.mo) Using package NcDataReader2 with version 2.5.1 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.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(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple") translateModel(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple") Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.00586/0.00586, allocations: 99.31 kB / 15.73 MB, free: 6.047 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.001346/0.001346, allocations: 187.7 kB / 16.67 MB, free: 5.977 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.29/1.29, allocations: 222.9 MB / 240.4 MB, free: 4.312 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.002107/0.002107, allocations: 283.1 kB / 290.8 MB, free: 1.922 MB / 238.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/package.mo): time 0.9396/0.9396, allocations: 169.3 MB / 0.4983 GB, free: 13.81 MB / 382.1 MB Notification: Performance of FrontEnd - loaded program: time 0.00193/0.00193, allocations: 95.86 kB / 0.6814 GB, free: 15.5 MB / 494.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1601/0.1621, allocations: 86.96 MB / 0.7663 GB, free: 8.457 MB / 0.5606 GB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple): time 0.002834/0.165, allocations: 1.953 MB / 0.7682 GB, free: 6.488 MB / 0.5606 GB Notification: Performance of NFInst.instExpressions: time 0.001287/0.1663, allocations: 0.8625 MB / 0.7691 GB, free: 5.617 MB / 0.5606 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.0001134/0.1664, allocations: 7.938 kB / 0.7691 GB, free: 5.609 MB / 0.5606 GB Notification: Performance of NFTyping.typeComponents: time 0.0002087/0.1666, allocations: 47.69 kB / 0.7691 GB, free: 5.562 MB / 0.5606 GB Notification: Performance of NFTyping.typeBindings: time 0.0001177/0.1668, allocations: 47.56 kB / 0.7692 GB, free: 5.516 MB / 0.5606 GB Notification: Performance of NFTyping.typeClassSections: time 0.0002989/0.1671, allocations: 99.7 kB / 0.7693 GB, free: 5.418 MB / 0.5606 GB Notification: Performance of NFFlatten.flatten: time 0.0002117/0.1673, allocations: 191.3 kB / 0.7695 GB, free: 5.23 MB / 0.5606 GB Notification: Performance of NFFlatten.resolveConnections: time 9.366e-05/0.1674, allocations: 25.48 kB / 0.7695 GB, free: 5.207 MB / 0.5606 GB Notification: Performance of NFEvalConstants.evaluate: time 0.0001451/0.1675, allocations: 91.61 kB / 0.7696 GB, free: 5.117 MB / 0.5606 GB Notification: Performance of NFSimplifyModel.simplify: time 0.0001328/0.1677, allocations: 83.62 kB / 0.7697 GB, free: 5.035 MB / 0.5606 GB Notification: Performance of NFPackage.collectConstants: time 2.484e-05/0.1677, allocations: 8 kB / 0.7697 GB, free: 5.027 MB / 0.5606 GB Notification: Performance of NFFlatten.collectFunctions: time 0.0001238/0.1678, allocations: 63.94 kB / 0.7697 GB, free: 4.965 MB / 0.5606 GB Notification: Performance of NFScalarize.scalarize: time 3.534e-05/0.1679, allocations: 23.91 kB / 0.7698 GB, free: 4.941 MB / 0.5606 GB Notification: Performance of NFVerifyModel.verify: time 7.872e-05/0.168, allocations: 75.53 kB / 0.7698 GB, free: 4.867 MB / 0.5606 GB Notification: Performance of NFConvertDAE.convert: time 0.0002404/0.1682, allocations: 187.4 kB / 0.77 GB, free: 4.684 MB / 0.5606 GB Notification: Performance of FrontEnd - DAE generated: time 9.738e-06/0.1682, allocations: 0 / 0.77 GB, free: 4.684 MB / 0.5606 GB Notification: Performance of FrontEnd: time 1.633e-06/0.1683, allocations: 3.938 kB / 0.77 GB, free: 4.68 MB / 0.5606 GB Notification: Performance of Transformations before backend: time 6.552e-06/0.1683, allocations: 0 / 0.77 GB, free: 4.68 MB / 0.5606 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 19 * Number of variables: 19 Notification: Performance of Generate backend data structure: time 0.0008771/0.1691, allocations: 0.5119 MB / 0.7705 GB, free: 4.113 MB / 0.5606 GB Notification: Performance of prepare preOptimizeDAE: time 3.354e-05/0.1692, allocations: 8.031 kB / 0.7705 GB, free: 4.105 MB / 0.5606 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 5.67e-05/0.1692, allocations: 16.75 kB / 0.7705 GB, free: 4.09 MB / 0.5606 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0002265/0.1695, allocations: 232 kB / 0.7707 GB, free: 3.824 MB / 0.5606 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.395e-05/0.1695, allocations: 8.375 kB / 0.7708 GB, free: 3.816 MB / 0.5606 GB Notification: Performance of preOpt expandDerOperator (simulation): time 3.504e-05/0.1695, allocations: 8.375 kB / 0.7708 GB, free: 3.809 MB / 0.5606 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0002825/0.1698, allocations: 136 kB / 0.7709 GB, free: 3.672 MB / 0.5606 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.1e-05/0.1699, allocations: 0 / 0.7709 GB, free: 3.672 MB / 0.5606 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.631e-05/0.1699, allocations: 4 kB / 0.7709 GB, free: 3.668 MB / 0.5606 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 4.098e-06/0.1699, allocations: 0 / 0.7709 GB, free: 3.668 MB / 0.5606 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.000283/0.1702, allocations: 99.92 kB / 0.771 GB, free: 3.57 MB / 0.5606 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0005907/0.1708, allocations: 416.5 kB / 0.7714 GB, free: 3.113 MB / 0.5606 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0003101/0.1711, allocations: 134.4 kB / 0.7715 GB, free: 2.973 MB / 0.5606 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0001605/0.1713, allocations: 76.81 kB / 0.7716 GB, free: 2.895 MB / 0.5606 GB Notification: Performance of preOpt evalFunc (simulation): time 0.000576/0.1718, allocations: 441.5 kB / 0.772 GB, free: 2.371 MB / 0.5606 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0002862/0.1721, allocations: 135.5 kB / 0.7721 GB, free: 2.227 MB / 0.5606 GB Notification: Performance of pre-optimization done (n=16): time 1.553e-06/0.1722, allocations: 0 / 0.7721 GB, free: 2.227 MB / 0.5606 GB Notification: Performance of matching and sorting (n=16): time 0.0006132/0.1728, allocations: 234.6 kB / 0.7724 GB, free: 1.992 MB / 0.5606 GB Notification: Performance of inlineWhenForInitialization (initialization): time 3.578e-05/0.1728, allocations: 59.41 kB / 0.7724 GB, free: 1.922 MB / 0.5606 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0001471/0.173, allocations: 184.1 kB / 0.7726 GB, free: 1.734 MB / 0.5606 GB Notification: Performance of collectPreVariables (initialization): time 2.013e-05/0.173, allocations: 25.7 kB / 0.7726 GB, free: 1.703 MB / 0.5606 GB Notification: Performance of collectInitialEqns (initialization): time 6.414e-05/0.1731, allocations: 116.1 kB / 0.7727 GB, free: 1.586 MB / 0.5606 GB Notification: Performance of collectInitialBindings (initialization): time 4.753e-05/0.1731, allocations: 51.27 kB / 0.7728 GB, free: 1.535 MB / 0.5606 GB Notification: Performance of simplifyInitialFunctions (initialization): time 6.638e-05/0.1732, allocations: 37.69 kB / 0.7728 GB, free: 1.492 MB / 0.5606 GB Notification: Performance of setup shared object (initialization): time 9.658e-05/0.1733, allocations: 330.8 kB / 0.7731 GB, free: 1.16 MB / 0.5606 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.000189/0.1735, allocations: 72.72 kB / 0.7732 GB, free: 1.086 MB / 0.5606 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0001785/0.1737, allocations: 104.5 kB / 0.7733 GB, free: 0.9766 MB / 0.5606 GB Notification: Performance of analyzeInitialSystem (initialization): time 2.552/2.726, allocations: 378.8 MB / 1.143 GB, free: 284.6 MB / 0.8419 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 6.382e-06/2.726, allocations: 0.75 kB / 1.143 GB, free: 284.6 MB / 0.8419 GB Notification: Performance of matching and sorting (n=23) (initialization): time 0.0006606/2.727, allocations: 252.9 kB / 1.143 GB, free: 284.4 MB / 0.8419 GB Notification: Performance of prepare postOptimizeDAE: time 4.754e-05/2.727, allocations: 29.7 kB / 1.143 GB, free: 284.3 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 9.929e-06/2.727, allocations: 0 / 1.143 GB, free: 284.3 MB / 0.8419 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.968e-05/2.727, allocations: 8.922 kB / 1.143 GB, free: 284.3 MB / 0.8419 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0003112/2.727, allocations: 43.06 kB / 1.144 GB, free: 284.3 MB / 0.8419 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 8.957e-06/2.727, allocations: 0 / 1.144 GB, free: 284.3 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0002577/2.728, allocations: 19.7 kB / 1.144 GB, free: 284.3 MB / 0.8419 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 2.862e-05/2.728, allocations: 10.69 kB / 1.144 GB, free: 284.3 MB / 0.8419 GB Warning: Assuming fixed start value for the following 4 variables: battery.E_charged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy charged to the battery" type: Real battery.E_discharged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy taken from the battery" type: Real battery.EAva:VARIABLE(start = 0.315 * battery.SOC_start * battery.E_nominal unit = "J" fixed = true ) "Available charge of the battery" type: Real battery.EBou:VARIABLE(start = 0.685 * battery.SOC_start * battery.E_nominal unit = "J" fixed = true ) "Bound charge of the battery" type: Real Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 3 * Number of states: 0 () * Number of discrete variables: 5 ($PRE.gain.count,$PRE.gain.T_start,gain.count,gain.T_start,$whenCondition1) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (22): * Single equations (assignments): 21 * Array equations: 0 * Algorithm blocks: 1 * 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.0002272/2.728, allocations: 162.2 kB / 1.144 GB, free: 284.1 MB / 0.8419 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 3.868e-05/2.728, allocations: 15.19 kB / 1.144 GB, free: 284.1 MB / 0.8419 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0007486/2.729, allocations: 236.5 kB / 1.144 GB, free: 283.9 MB / 0.8419 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 4.779e-06/2.729, allocations: 0 / 1.144 GB, free: 283.9 MB / 0.8419 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.45e-06/2.729, allocations: 0.5156 kB / 1.144 GB, free: 283.9 MB / 0.8419 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 6.362e-06/2.729, allocations: 3.984 kB / 1.144 GB, free: 283.9 MB / 0.8419 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0002418/2.729, allocations: 268 kB / 1.144 GB, free: 283.7 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.034e-06/2.729, allocations: 0 / 1.144 GB, free: 283.7 MB / 0.8419 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0003221/2.729, allocations: 38.92 kB / 1.144 GB, free: 283.6 MB / 0.8419 GB Notification: Performance of postOpt tearingSystem (simulation): time 4.348e-06/2.729, allocations: 4 kB / 1.144 GB, free: 283.6 MB / 0.8419 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.446e-05/2.729, allocations: 3.984 kB / 1.144 GB, free: 283.6 MB / 0.8419 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 3.346e-06/2.729, allocations: 1.438 kB / 1.144 GB, free: 283.6 MB / 0.8419 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.623e-06/2.729, allocations: 0 / 1.144 GB, free: 283.6 MB / 0.8419 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0008323/2.73, allocations: 319 kB / 1.145 GB, free: 283.4 MB / 0.8419 GB Notification: Performance of postOpt removeConstants (simulation): time 9.384e-05/2.73, allocations: 102.3 kB / 1.145 GB, free: 283.3 MB / 0.8419 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 4.616e-05/2.73, allocations: 11.17 kB / 1.145 GB, free: 283.3 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0002181/2.731, allocations: 6.812 kB / 1.145 GB, free: 283.3 MB / 0.8419 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 9.216e-05/2.731, allocations: 27.22 kB / 1.145 GB, free: 283.2 MB / 0.8419 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.13e-05/2.731, allocations: 7.5 kB / 1.145 GB, free: 283.2 MB / 0.8419 GB Notification: Performance of sorting global known variables: time 0.0001139/2.731, allocations: 131.3 kB / 1.145 GB, free: 283.1 MB / 0.8419 GB Notification: Performance of sort global known variables: time 9.12e-07/2.731, allocations: 0 / 1.145 GB, free: 283.1 MB / 0.8419 GB Notification: Performance of remove unused functions: time 0.0004421/2.731, allocations: 56.89 kB / 1.145 GB, free: 283.1 MB / 0.8419 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 1 * Number of states: 4 (battery.EAva,battery.EBou,battery.E_charged,battery.E_discharged) * Number of discrete variables: 3 ($whenCondition1,gain.T_start,gain.count) * Number of discrete states: 1 (gain.count) * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (20): * Single equations (assignments): 18 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 2 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of Backend phase and start with SimCode phase: time 0.0001828/2.732, allocations: 128.8 kB / 1.145 GB, free: 283 MB / 0.8419 GB Notification: Performance of simCode: created initialization part: time 0.0006012/2.732, allocations: 221.9 kB / 1.145 GB, free: 282.8 MB / 0.8419 GB Notification: Performance of simCode: created event and clocks part: time 2.725e-06/2.732, allocations: 0 / 1.145 GB, free: 282.8 MB / 0.8419 GB Notification: Performance of simCode: created simulation system equations: time 0.0002831/2.732, allocations: 93.59 kB / 1.145 GB, free: 282.7 MB / 0.8419 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0003896/2.733, allocations: 32.47 kB / 1.145 GB, free: 282.7 MB / 0.8419 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.001125/2.734, allocations: 0.5323 MB / 1.146 GB, free: 282.2 MB / 0.8419 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001548/2.734, allocations: 0.7242 MB / 1.147 GB, free: 281.5 MB / 0.8419 GB Notification: Performance of simCode: alias equations: time 0.0001752/2.734, allocations: 32.8 kB / 1.147 GB, free: 281.4 MB / 0.8419 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 9.337e-05/2.734, allocations: 23.42 kB / 1.147 GB, free: 281.4 MB / 0.8419 GB Notification: Performance of SimCode: time 3.6e-07/2.734, allocations: 0 / 1.147 GB, free: 281.4 MB / 0.8419 GB Notification: Performance of Templates: time 0.007176/2.742, allocations: 2.625 MB / 1.149 GB, free: 278.9 MB / 0.8419 GB make -j1 -f BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.makefile (rm -f BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe ; mkfifo BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe ; head -c 1048576 < BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe >> ../files/BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.sim & ./BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple -abortSlowSimulation -alarm=480 -lv LOG_STATS > BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe 2>&1)