Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.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.BatteryComplex,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex") translateModel(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex") Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001311/0.001311, allocations: 111.3 kB / 15.23 MB, free: 0.6602 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.001313/0.001313, allocations: 193.7 kB / 16.14 MB, free: 6.645 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.465/1.465, allocations: 222.9 MB / 239.8 MB, free: 4.613 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.002722/0.002722, allocations: 294.7 kB / 290.2 MB, free: 2.203 MB / 238.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/package.mo): time 1.079/1.079, allocations: 178.6 MB / 0.5068 GB, free: 4.797 MB / 382.1 MB Notification: Performance of FrontEnd - loaded program: time 0.002817/0.002817, allocations: 94.17 kB / 0.6057 GB, free: 25.29 MB / 430.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1761/0.179, allocations: 89.14 MB / 0.6928 GB, free: 4.867 MB / 494.1 MB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex): time 0.003987/0.183, allocations: 2.69 MB / 0.6954 GB, free: 2.168 MB / 494.1 MB Notification: Performance of NFInst.instExpressions: time 0.001876/0.1849, allocations: 1.093 MB / 0.6965 GB, free: 1.074 MB / 494.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0001413/0.1851, allocations: 15.88 kB / 0.6965 GB, free: 1.059 MB / 494.1 MB Notification: Performance of NFTyping.typeComponents: time 0.0002629/0.1854, allocations: 67.53 kB / 0.6965 GB, free: 0.9922 MB / 494.1 MB Notification: Performance of NFTyping.typeBindings: time 0.0002256/0.1856, allocations: 103.2 kB / 0.6966 GB, free: 0.8906 MB / 494.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.0003499/0.1859, allocations: 143.8 kB / 0.6968 GB, free: 0.75 MB / 494.1 MB Notification: Performance of NFFlatten.flatten: time 0.0004683/0.1864, allocations: 494.2 kB / 0.6973 GB, free: 272 kB / 494.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0001344/0.1866, allocations: 44.95 kB / 0.6973 GB, free: 228 kB / 494.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0002985/0.1869, allocations: 215 kB / 0.6975 GB, free: 12 kB / 494.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0003119/0.1872, allocations: 219 kB / 0.6977 GB, free: 15.8 MB / 0.4981 GB Notification: Performance of NFPackage.collectConstants: time 5.932e-05/0.1873, allocations: 16 kB / 0.6977 GB, free: 15.78 MB / 0.4981 GB Notification: Performance of NFFlatten.collectFunctions: time 0.0001705/0.1874, allocations: 59.97 kB / 0.6978 GB, free: 15.72 MB / 0.4981 GB Notification: Performance of NFScalarize.scalarize: time 7.907e-05/0.1875, allocations: 63.72 kB / 0.6978 GB, free: 15.66 MB / 0.4981 GB Notification: Performance of NFVerifyModel.verify: time 0.0001905/0.1877, allocations: 171 kB / 0.698 GB, free: 15.49 MB / 0.4981 GB Notification: Performance of NFConvertDAE.convert: time 0.0004738/0.1882, allocations: 406.6 kB / 0.6984 GB, free: 15.09 MB / 0.4981 GB Notification: Performance of FrontEnd - DAE generated: time 4.999e-06/0.1882, allocations: 0 / 0.6984 GB, free: 15.09 MB / 0.4981 GB Notification: Performance of FrontEnd: time 1.272e-06/0.1882, allocations: 0 / 0.6984 GB, free: 15.09 MB / 0.4981 GB Notification: Performance of Transformations before backend: time 5.561e-06/0.1882, allocations: 0 / 0.6984 GB, free: 15.09 MB / 0.4981 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 49 * Number of variables: 49 Notification: Performance of Generate backend data structure: time 0.001999/0.1902, allocations: 0.8093 MB / 0.6992 GB, free: 14.22 MB / 0.4981 GB Notification: Performance of prepare preOptimizeDAE: time 3.665e-05/0.1903, allocations: 12.03 kB / 0.6992 GB, free: 14.21 MB / 0.4981 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0001153/0.1904, allocations: 40.47 kB / 0.6992 GB, free: 14.17 MB / 0.4981 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0004447/0.1909, allocations: 335.9 kB / 0.6996 GB, free: 13.8 MB / 0.4981 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 2.487e-05/0.1909, allocations: 12.81 kB / 0.6996 GB, free: 13.79 MB / 0.4981 GB Notification: Performance of preOpt expandDerOperator (simulation): time 6.967e-05/0.191, allocations: 32.27 kB / 0.6996 GB, free: 13.75 MB / 0.4981 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.000784/0.1918, allocations: 329.1 kB / 0.6999 GB, free: 13.43 MB / 0.4981 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.519e-05/0.1918, allocations: 4 kB / 0.6999 GB, free: 13.42 MB / 0.4981 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 3.848e-05/0.1918, allocations: 8 kB / 0.6999 GB, free: 13.41 MB / 0.4981 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 1.127e-05/0.1919, allocations: 4 kB / 0.6999 GB, free: 13.41 MB / 0.4981 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0008993/0.1928, allocations: 295.7 kB / 0.7002 GB, free: 13.12 MB / 0.4981 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001206/0.194, allocations: 0.7772 MB / 0.701 GB, free: 12.29 MB / 0.4981 GB Notification: Performance of preOpt comSubExp (simulation): time 0.001168/0.1952, allocations: 392.8 kB / 0.7013 GB, free: 11.89 MB / 0.4981 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0005162/0.1957, allocations: 209.6 kB / 0.7015 GB, free: 11.68 MB / 0.4981 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0007353/0.1964, allocations: 449.5 kB / 0.702 GB, free: 11.15 MB / 0.4981 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0008437/0.1973, allocations: 328.6 kB / 0.7023 GB, free: 10.81 MB / 0.4981 GB Notification: Performance of pre-optimization done (n=42): time 1.964e-06/0.1973, allocations: 0 / 0.7023 GB, free: 10.81 MB / 0.4981 GB Notification: Performance of matching and sorting (n=42): time 0.001758/0.1991, allocations: 0.6132 MB / 0.7029 GB, free: 10.19 MB / 0.4981 GB Notification: Performance of inlineWhenForInitialization (initialization): time 6.863e-05/0.1992, allocations: 81.11 kB / 0.703 GB, free: 10.09 MB / 0.4981 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.000366/0.1995, allocations: 308.5 kB / 0.7033 GB, free: 9.781 MB / 0.4981 GB Notification: Performance of collectPreVariables (initialization): time 5.346e-05/0.1996, allocations: 37.69 kB / 0.7033 GB, free: 9.738 MB / 0.4981 GB Notification: Performance of collectInitialEqns (initialization): time 0.0001405/0.1997, allocations: 160.9 kB / 0.7034 GB, free: 9.578 MB / 0.4981 GB Notification: Performance of collectInitialBindings (initialization): time 0.000159/0.1999, allocations: 142 kB / 0.7036 GB, free: 9.438 MB / 0.4981 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0001847/0.2001, allocations: 98 kB / 0.7037 GB, free: 9.336 MB / 0.4981 GB Notification: Performance of setup shared object (initialization): time 0.0001944/0.2003, allocations: 350.8 kB / 0.704 GB, free: 8.984 MB / 0.4981 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0005451/0.2008, allocations: 199.5 kB / 0.7042 GB, free: 8.781 MB / 0.4981 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0005577/0.2014, allocations: 254.3 kB / 0.7044 GB, free: 8.52 MB / 0.4981 GB Notification: Performance of analyzeInitialSystem (initialization): time 6.227/6.428, allocations: 0.866 GB / 1.57 GB, free: 23.5 MB / 0.7325 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 7.875e-06/6.429, allocations: 4 kB / 1.57 GB, free: 23.5 MB / 0.7325 GB Notification: Performance of matching and sorting (n=61) (initialization): time 0.001265/6.43, allocations: 0.6322 MB / 1.571 GB, free: 23.01 MB / 0.7325 GB Notification: Performance of prepare postOptimizeDAE: time 4.907e-05/6.43, allocations: 92.03 kB / 1.571 GB, free: 22.91 MB / 0.7325 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 8.246e-06/6.43, allocations: 0 / 1.571 GB, free: 22.91 MB / 0.7325 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.027e-05/6.43, allocations: 4 kB / 1.571 GB, free: 22.9 MB / 0.7325 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0005417/6.43, allocations: 113.2 kB / 1.571 GB, free: 22.8 MB / 0.7325 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 9.497e-06/6.43, allocations: 7.828 kB / 1.571 GB, free: 22.8 MB / 0.7325 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0004673/6.431, allocations: 64.56 kB / 1.571 GB, free: 22.76 MB / 0.7325 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 4.449e-05/6.431, allocations: 26.3 kB / 1.571 GB, free: 22.74 MB / 0.7325 GB Warning: Assuming fixed start value for the following 8 variables: battery_C20.E_charged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy charged to the battery" type: Real battery_C20.E_discharged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy taken from the battery" type: Real battery_1C.E_charged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy charged to the battery" type: Real battery_1C.E_discharged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy taken from the battery" type: Real battery_1C.EAva:VARIABLE(start = 0.315 * battery_1C.SOC_start * battery_1C.E_nominal unit = "J" fixed = true ) "Available charge of the battery" type: Real battery_1C.EBou:VARIABLE(start = 0.6850000000000001 * battery_1C.SOC_start * battery_1C.E_nominal unit = "J" fixed = true ) "Bound charge of the battery" type: Real battery_C20.EAva:VARIABLE(start = 0.315 * battery_C20.SOC_start * battery_C20.E_nominal unit = "J" fixed = true ) "Available charge of the battery" type: Real battery_C20.EBou:VARIABLE(start = 0.6850000000000001 * battery_C20.SOC_start * battery_C20.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: 6 * Number of states: 0 () * Number of discrete variables: 15 ($PRE.load_1C.count,$PRE.load_1C.T_start,$PRE.gain.count,$PRE.gain.T_start,load_1C.count,load_1C.T_start,gain.count,gain.T_start,$whenCondition2,$whenCondition3,$PRE.load_C20.count,$PRE.load_C20.T_start,load_C20.count,load_C20.T_start,$whenCondition1) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (58): * Single equations (assignments): 55 * Array equations: 0 * Algorithm blocks: 3 * 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.0002982/6.431, allocations: 201.8 kB / 1.572 GB, free: 22.57 MB / 0.7325 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 6.024e-05/6.431, allocations: 40.62 kB / 1.572 GB, free: 22.55 MB / 0.7325 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001472/6.433, allocations: 0.6315 MB / 1.572 GB, free: 22.09 MB / 0.7325 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 5.961e-06/6.433, allocations: 7.844 kB / 1.572 GB, free: 22.08 MB / 0.7325 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 6.402e-06/6.433, allocations: 3.938 kB / 1.572 GB, free: 22.08 MB / 0.7325 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 6.842e-06/6.433, allocations: 7.984 kB / 1.572 GB, free: 22.07 MB / 0.7325 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0003635/6.433, allocations: 435.4 kB / 1.573 GB, free: 21.71 MB / 0.7325 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.174e-06/6.433, allocations: 0 / 1.573 GB, free: 21.71 MB / 0.7325 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0005493/6.434, allocations: 106.5 kB / 1.573 GB, free: 21.61 MB / 0.7325 GB Notification: Performance of postOpt tearingSystem (simulation): time 4.178e-06/6.434, allocations: 8 kB / 1.573 GB, free: 21.6 MB / 0.7325 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 3.927e-05/6.434, allocations: 17.98 kB / 1.573 GB, free: 21.59 MB / 0.7325 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 4.037e-06/6.434, allocations: 4 kB / 1.573 GB, free: 21.59 MB / 0.7325 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.254e-06/6.434, allocations: 3.938 kB / 1.573 GB, free: 21.58 MB / 0.7325 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001514/6.435, allocations: 0.7888 MB / 1.574 GB, free: 20.86 MB / 0.7325 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001532/6.436, allocations: 162.2 kB / 1.574 GB, free: 20.7 MB / 0.7325 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 6.937e-05/6.436, allocations: 8 kB / 1.574 GB, free: 20.7 MB / 0.7325 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0004177/6.436, allocations: 39.89 kB / 1.574 GB, free: 20.66 MB / 0.7325 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001478/6.436, allocations: 63.92 kB / 1.574 GB, free: 20.59 MB / 0.7325 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 3.661e-05/6.436, allocations: 19.98 kB / 1.574 GB, free: 20.57 MB / 0.7325 GB Notification: Performance of sorting global known variables: time 0.0001581/6.436, allocations: 215.1 kB / 1.574 GB, free: 20.36 MB / 0.7325 GB Notification: Performance of sort global known variables: time 1.31e-07/6.436, allocations: 0 / 1.574 GB, free: 20.36 MB / 0.7325 GB Notification: Performance of remove unused functions: time 0.0003823/6.437, allocations: 114.5 kB / 1.574 GB, free: 20.25 MB / 0.7325 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 2 * Number of states: 8 (battery_1C.EAva,battery_1C.EBou,battery_1C.E_charged,battery_1C.E_discharged,battery_C20.EAva,battery_C20.EBou,battery_C20.E_charged,battery_C20.E_discharged) * Number of discrete variables: 9 ($whenCondition3,$whenCondition2,gain.T_start,gain.count,load_1C.T_start,load_1C.count,$whenCondition1,load_C20.T_start,load_C20.count) * Number of discrete states: 3 (load_C20.count,gain.count,load_1C.count) * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (54): * Single equations (assignments): 48 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 6 * 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.0001898/6.437, allocations: 138.4 kB / 1.574 GB, free: 20.12 MB / 0.7325 GB Notification: Performance of simCode: created initialization part: time 0.00107/6.438, allocations: 0.6339 MB / 1.575 GB, free: 19.45 MB / 0.7325 GB Notification: Performance of simCode: created event and clocks part: time 2.395e-06/6.438, allocations: 0 / 1.575 GB, free: 19.45 MB / 0.7325 GB Notification: Performance of simCode: created simulation system equations: time 0.0005173/6.439, allocations: 263.7 kB / 1.575 GB, free: 19.2 MB / 0.7325 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0004412/6.439, allocations: 66.72 kB / 1.575 GB, free: 19.13 MB / 0.7325 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.001576/6.441, allocations: 1.222 MB / 1.576 GB, free: 17.93 MB / 0.7325 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001729/6.441, allocations: 0.8065 MB / 1.577 GB, free: 17.1 MB / 0.7325 GB Notification: Performance of simCode: alias equations: time 0.0003909/6.441, allocations: 84.53 kB / 1.577 GB, free: 17.02 MB / 0.7325 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001625/6.441, allocations: 51.41 kB / 1.577 GB, free: 16.97 MB / 0.7325 GB Notification: Performance of SimCode: time 2.9e-07/6.441, allocations: 0 / 1.577 GB, free: 16.97 MB / 0.7325 GB Notification: Performance of Templates: time 0.009078/6.451, allocations: 5.58 MB / 1.583 GB, free: 11.5 MB / 0.7325 GB make -j1 -f BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.makefile (rm -f BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.pipe ; mkfifo BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.pipe ; head -c 1048576 < BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.pipe >> ../files/BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.sim & ./BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex -abortSlowSimulation -alarm=480 -lv LOG_STATS > BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.pipe 2>&1)