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.9712/0.9712, allocations: 141.7 MB / 154.3 MB, free: 15.5 MB / 138.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001105/0.001105, allocations: 182 kB / 187.3 MB, free: 11.9 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.55/1.55, allocations: 221.3 MB / 441.4 MB, free: 4.676 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.001039/0.001039, allocations: 92.27 kB / 0.5124 GB, free: 24.13 MB / 394.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.001837/0.001837, allocations: 274.2 kB / 0.5939 GB, free: 7.992 MB / 442.7 MB Notification: Performance of FrontEnd - loaded program: time 3.461e-05/3.464e-05, allocations: 4 kB / 0.6834 GB, free: 12.28 MB / 0.5261 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.4936/0.4936, allocations: 82.76 MB / 0.7643 GB, free: 108.7 MB / 0.5261 GB Notification: Performance of FrontEnd - scodeFlatten: time 0.1688/0.6624, allocations: 111.3 MB / 0.873 GB, free: 13.25 MB / 0.5417 GB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0002763/0.6628, allocations: 80.73 kB / 0.873 GB, free: 13.18 MB / 0.5417 GB Notification: Performance of FrontEnd - DAE generated: time 0.01748/0.6803, allocations: 4.101 MB / 0.877 GB, free: 9.039 MB / 0.5417 GB Notification: Performance of FrontEnd: time 1.833e-06/0.6803, allocations: 448 / 0.8771 GB, free: 9.039 MB / 0.5417 GB Notification: Performance of Transformations before backend: time 8.536e-06/0.6803, allocations: 0 / 0.8771 GB, free: 9.039 MB / 0.5417 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.00101/0.6814, allocations: 479.7 kB / 0.8775 GB, free: 8.52 MB / 0.5417 GB Notification: Performance of prepare preOptimizeDAE: time 5.737e-05/0.6814, allocations: 8.031 kB / 0.8775 GB, free: 8.512 MB / 0.5417 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 7.636e-05/0.6815, allocations: 15.81 kB / 0.8775 GB, free: 8.496 MB / 0.5417 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0002525/0.6818, allocations: 206.8 kB / 0.8777 GB, free: 8.254 MB / 0.5417 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 2.323e-05/0.6818, allocations: 7.953 kB / 0.8777 GB, free: 8.246 MB / 0.5417 GB Notification: Performance of preOpt expandDerOperator (simulation): time 4.822e-05/0.6819, allocations: 12 kB / 0.8777 GB, free: 8.234 MB / 0.5417 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.000341/0.6822, allocations: 109.6 kB / 0.8779 GB, free: 8.121 MB / 0.5417 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.486e-05/0.6822, allocations: 0 / 0.8779 GB, free: 8.121 MB / 0.5417 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 2.741e-05/0.6823, allocations: 8 kB / 0.8779 GB, free: 8.113 MB / 0.5417 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 1.044e-05/0.6823, allocations: 4 kB / 0.8779 GB, free: 8.109 MB / 0.5417 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0002502/0.6826, allocations: 75.94 kB / 0.8779 GB, free: 8.035 MB / 0.5417 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001006/0.6836, allocations: 452.5 kB / 0.8784 GB, free: 7.543 MB / 0.5417 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0003009/0.6839, allocations: 102.6 kB / 0.8785 GB, free: 7.434 MB / 0.5417 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.000171/0.6841, allocations: 60.86 kB / 0.8785 GB, free: 7.371 MB / 0.5417 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0009031/0.685, allocations: 445.5 kB / 0.8789 GB, free: 6.844 MB / 0.5417 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0003884/0.6854, allocations: 115.3 kB / 0.8791 GB, free: 6.719 MB / 0.5417 GB Notification: Performance of pre-optimization done (n=16): time 3.346e-06/0.6854, allocations: 0 / 0.8791 GB, free: 6.719 MB / 0.5417 GB Notification: Performance of matching and sorting (n=16): time 0.0005761/0.686, allocations: 159.7 kB / 0.8792 GB, free: 6.559 MB / 0.5417 GB Notification: Performance of inlineWhenForInitialization (initialization): time 8.039e-05/0.6861, allocations: 55.39 kB / 0.8793 GB, free: 6.492 MB / 0.5417 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0002651/0.6864, allocations: 177.4 kB / 0.8794 GB, free: 6.312 MB / 0.5417 GB Notification: Performance of collectPreVariables (initialization): time 5.585e-05/0.6865, allocations: 37.62 kB / 0.8795 GB, free: 6.27 MB / 0.5417 GB Notification: Performance of collectInitialEqns (initialization): time 0.0001032/0.6866, allocations: 104 kB / 0.8796 GB, free: 6.164 MB / 0.5417 GB Notification: Performance of collectInitialBindings (initialization): time 7.716e-05/0.6867, allocations: 59.19 kB / 0.8796 GB, free: 6.105 MB / 0.5417 GB Notification: Performance of simplifyInitialFunctions (initialization): time 1.65e-05/0.6867, allocations: 8 kB / 0.8796 GB, free: 6.098 MB / 0.5417 GB Notification: Performance of setup shared object (initialization): time 0.0001853/0.6869, allocations: 326.8 kB / 0.8799 GB, free: 5.77 MB / 0.5417 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0001703/0.6871, allocations: 60.84 kB / 0.88 GB, free: 5.707 MB / 0.5417 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0001954/0.6873, allocations: 78.38 kB / 0.8801 GB, free: 5.625 MB / 0.5417 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.0002225/0.6875, allocations: 87.25 kB / 0.8802 GB, free: 5.531 MB / 0.5417 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 2.996e-06/0.6875, allocations: 0 / 0.8802 GB, free: 5.531 MB / 0.5417 GB Notification: Performance of matching and sorting (n=23) (initialization): time 0.0005618/0.6881, allocations: 223.6 kB / 0.8804 GB, free: 5.305 MB / 0.5417 GB Notification: Performance of prepare postOptimizeDAE: time 5.368e-05/0.6882, allocations: 37.7 kB / 0.8804 GB, free: 5.262 MB / 0.5417 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 6.352e-06/0.6882, allocations: 0 / 0.8804 GB, free: 5.262 MB / 0.5417 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.715e-05/0.6882, allocations: 0 / 0.8804 GB, free: 5.262 MB / 0.5417 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0004001/0.6886, allocations: 47.95 kB / 0.8805 GB, free: 5.215 MB / 0.5417 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.116e-05/0.6886, allocations: 0 / 0.8805 GB, free: 5.215 MB / 0.5417 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0002945/0.6889, allocations: 23.86 kB / 0.8805 GB, free: 5.191 MB / 0.5417 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 4.075e-05/0.689, allocations: 16.05 kB / 0.8805 GB, free: 5.176 MB / 0.5417 GB Warning: Assuming fixed start value for the following 4 variables: battery.E_discharged:VARIABLE(start = 0.0 unit = "J" ) "Total energy taken from the battery" type: Real battery.E_charged:VARIABLE(start = 0.0 unit = "J" ) "Total energy charged to the battery" type: Real battery.EBou:VARIABLE(start = (1.0 - battery.c) * battery.SOC_start * battery.E_nominal unit = "J" ) "Bound charge of the battery" type: Real battery.EAva:VARIABLE(start = battery.c * battery.SOC_start * battery.E_nominal unit = "J" ) "Available 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 ($whenCondition1,$PRE.gain.T_start,gain.T_start,$PRE.gain.count,gain.count) * Number of discrete 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 (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of prepare postOptimizeDAE: time 0.0002444/0.6892, allocations: 126.2 kB / 0.8806 GB, free: 5.047 MB / 0.5417 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 4.851e-05/0.6893, allocations: 19.8 kB / 0.8806 GB, free: 5.027 MB / 0.5417 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0006803/0.69, allocations: 220 kB / 0.8808 GB, free: 4.816 MB / 0.5417 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 7.243e-06/0.69, allocations: 4 kB / 0.8808 GB, free: 4.812 MB / 0.5417 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 1.209e-05/0.6901, allocations: 7.984 kB / 0.8809 GB, free: 4.805 MB / 0.5417 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 6.883e-06/0.6901, allocations: 0 / 0.8809 GB, free: 4.805 MB / 0.5417 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0003558/0.6905, allocations: 269.4 kB / 0.8811 GB, free: 4.492 MB / 0.5417 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 3.126e-06/0.6905, allocations: 0 / 0.8811 GB, free: 4.492 MB / 0.5417 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0003779/0.6909, allocations: 35.98 kB / 0.8811 GB, free: 4.457 MB / 0.5417 GB Notification: Performance of postOpt tearingSystem (simulation): time 8.696e-06/0.6909, allocations: 3.984 kB / 0.8811 GB, free: 4.453 MB / 0.5417 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.991e-05/0.6909, allocations: 8 kB / 0.8812 GB, free: 4.445 MB / 0.5417 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 6.071e-06/0.6909, allocations: 3.938 kB / 0.8812 GB, free: 4.441 MB / 0.5417 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.954e-06/0.691, allocations: 3.938 kB / 0.8812 GB, free: 4.438 MB / 0.5417 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0007169/0.6917, allocations: 282.1 kB / 0.8814 GB, free: 4.145 MB / 0.5417 GB Notification: Performance of postOpt removeConstants (simulation): time 0.000158/0.6919, allocations: 112.9 kB / 0.8815 GB, free: 4.016 MB / 0.5417 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 5.555e-05/0.6919, allocations: 15.98 kB / 0.8816 GB, free: 4 MB / 0.5417 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0002609/0.6922, allocations: 11.98 kB / 0.8816 GB, free: 3.988 MB / 0.5417 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 9.874e-05/0.6923, allocations: 19.97 kB / 0.8816 GB, free: 3.969 MB / 0.5417 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.408e-05/0.6923, allocations: 4 kB / 0.8816 GB, free: 3.965 MB / 0.5417 GB Notification: Performance of sorting global known variables: time 0.0001928/0.6925, allocations: 144.3 kB / 0.8817 GB, free: 3.824 MB / 0.5417 GB Notification: Performance of sort global known variables: time 2.81e-07/0.6926, allocations: 0 / 0.8817 GB, free: 3.824 MB / 0.5417 GB Notification: Performance of remove unused functions: time 0.0005254/0.6931, allocations: 75.92 kB / 0.8818 GB, free: 3.75 MB / 0.5417 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) * 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 (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.0003241/0.6934, allocations: 145.7 kB / 0.8819 GB, free: 3.598 MB / 0.5417 GB Notification: Performance of simCode: created initialization part: time 0.0005014/0.6939, allocations: 192.8 kB / 0.8821 GB, free: 3.398 MB / 0.5417 GB Notification: Performance of simCode: created event and clocks part: time 2.665e-06/0.694, allocations: 4.125 kB / 0.8821 GB, free: 3.395 MB / 0.5417 GB Notification: Performance of simCode: created simulation system equations: time 0.0002332/0.6942, allocations: 83.91 kB / 0.8822 GB, free: 3.312 MB / 0.5417 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0003241/0.6945, allocations: 28.11 kB / 0.8822 GB, free: 3.285 MB / 0.5417 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.001201/0.6958, allocations: 458.4 kB / 0.8827 GB, free: 2.812 MB / 0.5417 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0004001/0.6962, allocations: 0.7283 MB / 0.8834 GB, free: 2.059 MB / 0.5417 GB Notification: Performance of simCode: alias equations: time 0.0001862/0.6964, allocations: 17.33 kB / 0.8834 GB, free: 2.043 MB / 0.5417 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001095/0.6965, allocations: 23.42 kB / 0.8834 GB, free: 2.02 MB / 0.5417 GB Notification: Performance of SimCode: time 4.61e-07/0.6965, allocations: 0 / 0.8834 GB, free: 2.02 MB / 0.5417 GB Notification: Performance of Templates: time 0.008599/0.7051, allocations: 2.656 MB / 0.886 GB, free: 15.39 MB / 0.5573 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)