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/BuildingSystems 2.0.0-master/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) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo", uses=false) Using package NcDataReader2 with version 2.5.1 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/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) 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 BuildingSystems with version 2.0.0-beta (/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/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/BuildingSystems 2.0.0-master/package.mo): time 0.7936/0.7936, allocations: 143.4 MB / 159.2 MB, free: 4.891 MB / 122.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001163/0.001163, allocations: 184.5 kB / 191.9 MB, free: 5.734 MB / 154.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 1.507/1.507, allocations: 222.9 MB / 447.3 MB, free: 5.863 MB / 330.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001018/0.001019, allocations: 95.75 kB / 0.5169 GB, free: 3.73 MB / 410.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.001982/0.001982, allocations: 292.5 kB / 0.5973 GB, free: 49.35 MB / 410.7 MB Notification: Performance of FrontEnd - loaded program: time 0.001592/0.001592, allocations: 83.88 kB / 0.6885 GB, free: 3.832 MB / 458.7 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.3579/0.3595, allocations: 81.29 MB / 0.7679 GB, free: 27.64 MB / 458.7 MB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple): time 0.002573/0.3621, allocations: 2.003 MB / 0.7699 GB, free: 25.64 MB / 458.7 MB Notification: Performance of NFInst.instExpressions: time 0.001007/0.3632, allocations: 0.8652 MB / 0.7707 GB, free: 24.77 MB / 458.7 MB Notification: Performance of NFInst.updateImplicitVariability: time 7.183e-05/0.3632, allocations: 7.938 kB / 0.7707 GB, free: 24.76 MB / 458.7 MB Notification: Performance of NFTyping.typeComponents: time 0.0001924/0.3634, allocations: 42.42 kB / 0.7707 GB, free: 24.72 MB / 458.7 MB Notification: Performance of NFTyping.typeBindings: time 9.112e-05/0.3635, allocations: 43.62 kB / 0.7708 GB, free: 24.68 MB / 458.7 MB Notification: Performance of NFTyping.typeClassSections: time 0.0001988/0.3637, allocations: 75.86 kB / 0.7709 GB, free: 24.6 MB / 458.7 MB Notification: Performance of NFFlatten.flatten: time 0.000123/0.3639, allocations: 179.4 kB / 0.771 GB, free: 24.43 MB / 458.7 MB Notification: Performance of NFFlatten.resolveConnections: time 7.524e-05/0.364, allocations: 17.53 kB / 0.771 GB, free: 24.41 MB / 458.7 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0001055/0.3641, allocations: 83.53 kB / 0.7711 GB, free: 24.33 MB / 458.7 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0001008/0.3642, allocations: 79.66 kB / 0.7712 GB, free: 24.25 MB / 458.7 MB Notification: Performance of NFPackage.collectConstants: time 2.406e-05/0.3642, allocations: 8 kB / 0.7712 GB, free: 24.24 MB / 458.7 MB Notification: Performance of NFFlatten.collectFunctions: time 9.737e-05/0.3643, allocations: 55.95 kB / 0.7713 GB, free: 24.19 MB / 458.7 MB Notification: Performance of NFScalarize.scalarize: time 2.951e-05/0.3644, allocations: 19.91 kB / 0.7713 GB, free: 24.17 MB / 458.7 MB Notification: Performance of NFVerifyModel.verify: time 7.035e-05/0.3644, allocations: 71.58 kB / 0.7714 GB, free: 24.1 MB / 458.7 MB Notification: Performance of NFConvertDAE.convert: time 0.0001746/0.3646, allocations: 183.4 kB / 0.7715 GB, free: 23.92 MB / 458.7 MB Notification: Performance of FrontEnd - DAE generated: time 4.478e-06/0.3646, allocations: 0 / 0.7715 GB, free: 23.92 MB / 458.7 MB Notification: Performance of FrontEnd: time 1.133e-06/0.3646, allocations: 0 / 0.7715 GB, free: 23.92 MB / 458.7 MB Notification: Performance of Transformations before backend: time 3.526e-06/0.3646, allocations: 0 / 0.7715 GB, free: 23.92 MB / 458.7 MB 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.0008263/0.3655, allocations: 0.4964 MB / 0.772 GB, free: 23.37 MB / 458.7 MB Notification: Performance of prepare preOptimizeDAE: time 3.512e-05/0.3655, allocations: 11.97 kB / 0.772 GB, free: 23.36 MB / 458.7 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 4.795e-05/0.3656, allocations: 16.75 kB / 0.772 GB, free: 23.34 MB / 458.7 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0002043/0.3658, allocations: 248.8 kB / 0.7723 GB, free: 23.06 MB / 458.7 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.123e-05/0.3658, allocations: 4.375 kB / 0.7723 GB, free: 23.05 MB / 458.7 MB Notification: Performance of preOpt expandDerOperator (simulation): time 3.21e-05/0.3658, allocations: 16.27 kB / 0.7723 GB, free: 23.04 MB / 458.7 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0002577/0.3661, allocations: 128.4 kB / 0.7724 GB, free: 22.91 MB / 458.7 MB Notification: Performance of preOpt findStateOrder (simulation): time 1.173e-05/0.3661, allocations: 4 kB / 0.7724 GB, free: 22.91 MB / 458.7 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.451e-05/0.3661, allocations: 4 kB / 0.7724 GB, free: 22.9 MB / 458.7 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 4.849e-06/0.3661, allocations: 3.938 kB / 0.7724 GB, free: 22.9 MB / 458.7 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0002803/0.3664, allocations: 103.9 kB / 0.7725 GB, free: 22.8 MB / 458.7 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0005356/0.367, allocations: 408.5 kB / 0.7729 GB, free: 22.35 MB / 458.7 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0002945/0.3673, allocations: 146.4 kB / 0.7731 GB, free: 22.2 MB / 458.7 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0001549/0.3674, allocations: 76.77 kB / 0.7731 GB, free: 22.12 MB / 458.7 MB Notification: Performance of preOpt evalFunc (simulation): time 0.0005022/0.368, allocations: 445.5 kB / 0.7736 GB, free: 21.59 MB / 458.7 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0002794/0.3682, allocations: 127.3 kB / 0.7737 GB, free: 21.45 MB / 458.7 MB Notification: Performance of pre-optimization done (n=16): time 1.572e-06/0.3683, allocations: 0 / 0.7737 GB, free: 21.45 MB / 458.7 MB Notification: Performance of matching and sorting (n=16): time 0.0005543/0.3688, allocations: 230.5 kB / 0.7739 GB, free: 21.22 MB / 458.7 MB Notification: Performance of inlineWhenForInitialization (initialization): time 3.096e-05/0.3689, allocations: 59.34 kB / 0.774 GB, free: 21.15 MB / 458.7 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0001397/0.369, allocations: 187.9 kB / 0.7741 GB, free: 20.96 MB / 458.7 MB Notification: Performance of collectPreVariables (initialization): time 1.415e-05/0.369, allocations: 25.7 kB / 0.7742 GB, free: 20.93 MB / 458.7 MB Notification: Performance of collectInitialEqns (initialization): time 4.934e-05/0.3691, allocations: 116 kB / 0.7743 GB, free: 20.81 MB / 458.7 MB Notification: Performance of collectInitialBindings (initialization): time 3.318e-05/0.3691, allocations: 55.2 kB / 0.7743 GB, free: 20.76 MB / 458.7 MB Notification: Performance of simplifyInitialFunctions (initialization): time 5.852e-05/0.3692, allocations: 37.7 kB / 0.7744 GB, free: 20.71 MB / 458.7 MB Notification: Performance of setup shared object (initialization): time 5.193e-05/0.3692, allocations: 330.8 kB / 0.7747 GB, free: 20.38 MB / 458.7 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0001728/0.3694, allocations: 68.81 kB / 0.7747 GB, free: 20.31 MB / 458.7 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0001692/0.3696, allocations: 95.55 kB / 0.7748 GB, free: 20.21 MB / 458.7 MB Notification: Performance of analyzeInitialSystem (initialization): time 2.769/3.139, allocations: 378.8 MB / 1.145 GB, free: 11.04 MB / 0.6667 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 4.037e-06/3.139, allocations: 0 / 1.145 GB, free: 11.04 MB / 0.6667 GB Notification: Performance of matching and sorting (n=23) (initialization): time 0.0005395/3.139, allocations: 254.7 kB / 1.145 GB, free: 10.84 MB / 0.6667 GB Notification: Performance of prepare postOptimizeDAE: time 4.244e-05/3.139, allocations: 35.98 kB / 1.145 GB, free: 10.8 MB / 0.6667 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 7.965e-06/3.139, allocations: 0 / 1.145 GB, free: 10.8 MB / 0.6667 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.681e-05/3.139, allocations: 0 / 1.145 GB, free: 10.8 MB / 0.6667 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0002446/3.14, allocations: 47.5 kB / 1.145 GB, free: 10.76 MB / 0.6667 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 7.163e-06/3.14, allocations: 0 / 1.145 GB, free: 10.76 MB / 0.6667 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0001879/3.14, allocations: 22.84 kB / 1.145 GB, free: 10.74 MB / 0.6667 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 2.608e-05/3.14, allocations: 11.61 kB / 1.145 GB, free: 10.73 MB / 0.6667 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.6850000000000001 * 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.0002241/3.14, allocations: 159.4 kB / 1.145 GB, free: 10.59 MB / 0.6667 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 3.251e-05/3.14, allocations: 17.53 kB / 1.145 GB, free: 10.59 MB / 0.6667 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0006175/3.141, allocations: 238 kB / 1.145 GB, free: 10.36 MB / 0.6667 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 8.877e-06/3.141, allocations: 4.75 kB / 1.145 GB, free: 10.35 MB / 0.6667 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 4.819e-06/3.141, allocations: 0 / 1.145 GB, free: 10.35 MB / 0.6667 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 5.47e-06/3.141, allocations: 1.078 kB / 1.145 GB, free: 10.35 MB / 0.6667 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0002715/3.141, allocations: 258.1 kB / 1.146 GB, free: 10.06 MB / 0.6667 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 1.793e-06/3.141, allocations: 0 / 1.146 GB, free: 10.06 MB / 0.6667 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0002379/3.141, allocations: 46.16 kB / 1.146 GB, free: 10.02 MB / 0.6667 GB Notification: Performance of postOpt tearingSystem (simulation): time 3.467e-06/3.141, allocations: 0 / 1.146 GB, free: 10.02 MB / 0.6667 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.084e-05/3.141, allocations: 4 kB / 1.146 GB, free: 10.02 MB / 0.6667 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 3.416e-06/3.141, allocations: 8 kB / 1.146 GB, free: 10.01 MB / 0.6667 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.653e-06/3.141, allocations: 0 / 1.146 GB, free: 10.01 MB / 0.6667 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.4866/3.628, allocations: 34.54 MB / 1.18 GB, free: 232.6 MB / 0.6667 GB Notification: Performance of postOpt removeConstants (simulation): time 7.004e-05/3.628, allocations: 113.2 kB / 1.18 GB, free: 232.5 MB / 0.6667 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 2.558e-05/3.628, allocations: 4.75 kB / 1.18 GB, free: 232.5 MB / 0.6667 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001512/3.628, allocations: 15.98 kB / 1.18 GB, free: 232.5 MB / 0.6667 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 7.966e-05/3.628, allocations: 22.2 kB / 1.18 GB, free: 232.4 MB / 0.6667 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 1.593e-05/3.629, allocations: 6.953 kB / 1.18 GB, free: 232.4 MB / 0.6667 GB Notification: Performance of sorting global known variables: time 8.581e-05/3.629, allocations: 140.2 kB / 1.18 GB, free: 232.3 MB / 0.6667 GB Notification: Performance of sort global known variables: time 1.3e-07/3.629, allocations: 4 kB / 1.18 GB, free: 232.3 MB / 0.6667 GB Notification: Performance of remove unused functions: time 0.0005368/3.629, allocations: 120.8 kB / 1.18 GB, free: 232.2 MB / 0.6667 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.0001558/3.629, allocations: 128.8 kB / 1.18 GB, free: 232.1 MB / 0.6667 GB Notification: Performance of simCode: created initialization part: time 0.0004206/3.63, allocations: 218.5 kB / 1.18 GB, free: 231.8 MB / 0.6667 GB Notification: Performance of simCode: created event and clocks part: time 2.364e-06/3.63, allocations: 1.594 kB / 1.18 GB, free: 231.8 MB / 0.6667 GB Notification: Performance of simCode: created simulation system equations: time 0.0001873/3.63, allocations: 90.3 kB / 1.18 GB, free: 231.8 MB / 0.6667 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002749/3.63, allocations: 31.73 kB / 1.18 GB, free: 231.7 MB / 0.6667 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.001105/3.631, allocations: 0.7902 MB / 1.181 GB, free: 230.9 MB / 0.6667 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001147/3.631, allocations: 0.7248 MB / 1.182 GB, free: 230.1 MB / 0.6667 GB Notification: Performance of simCode: alias equations: time 0.001025/3.633, allocations: 125.5 kB / 1.182 GB, free: 230 MB / 0.6667 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.000461/3.633, allocations: 51.36 kB / 1.182 GB, free: 230 MB / 0.6667 GB Notification: Performance of SimCode: time 3.81e-07/3.633, allocations: 0 / 1.182 GB, free: 230 MB / 0.6667 GB Notification: Performance of Templates: time 0.01728/3.65, allocations: 12.65 MB / 1.194 GB, free: 217.3 MB / 0.6667 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)