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.8989/0.8989, allocations: 141.8 MB / 149.3 MB, free: 9.191 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.001006/0.001006, allocations: 172.8 kB / 182.2 MB, free: 9.438 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.378/1.378, allocations: 221.5 MB / 436.4 MB, free: 13.26 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.0009374/0.0009375, allocations: 88.16 kB / 0.5074 GB, free: 10.09 MB / 410.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.001814/0.001814, allocations: 282 kB / 0.5889 GB, free: 54.62 MB / 410.7 MB Notification: Performance of FrontEnd - loaded program: time 1.389e-05/1.391e-05, allocations: 4 kB / 0.6765 GB, free: 12.8 MB / 458.7 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.3884/0.3884, allocations: 82.77 MB / 0.7574 GB, free: 31.98 MB / 458.7 MB Notification: Performance of FrontEnd - scodeFlatten: time 0.1385/0.527, allocations: 110.7 MB / 0.8654 GB, free: 1.188 MB / 0.5261 GB Notification: Performance of FrontEnd - mkProgramGraph: time 0.000234/0.5273, allocations: 83.77 kB / 0.8655 GB, free: 1.109 MB / 0.5261 GB Notification: Performance of FrontEnd - DAE generated: time 0.01219/0.5395, allocations: 4.053 MB / 0.8695 GB, free: 13 MB / 0.5417 GB Notification: Performance of FrontEnd: time 1.162e-06/0.5395, allocations: 0 / 0.8695 GB, free: 13 MB / 0.5417 GB Notification: Performance of Transformations before backend: time 8.065e-06/0.5395, allocations: 4 kB / 0.8695 GB, free: 13 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.0007115/0.5403, allocations: 475.8 kB / 0.8699 GB, free: 12.48 MB / 0.5417 GB Notification: Performance of prepare preOptimizeDAE: time 3.716e-05/0.5403, allocations: 12.22 kB / 0.8699 GB, free: 12.47 MB / 0.5417 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 5.76e-05/0.5404, allocations: 15.81 kB / 0.8699 GB, free: 12.45 MB / 0.5417 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0001722/0.5406, allocations: 202.8 kB / 0.8701 GB, free: 12.21 MB / 0.5417 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.416e-05/0.5406, allocations: 7.891 kB / 0.8701 GB, free: 12.21 MB / 0.5417 GB Notification: Performance of preOpt expandDerOperator (simulation): time 3.711e-05/0.5406, allocations: 8 kB / 0.8701 GB, free: 12.2 MB / 0.5417 GB Notification: Performance of preOpt removeEqualFunctionCalls (simulation): time 0.0001735/0.5408, allocations: 67.98 kB / 0.8702 GB, free: 12.13 MB / 0.5417 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0001796/0.541, allocations: 101.6 kB / 0.8703 GB, free: 12.03 MB / 0.5417 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.347e-05/0.541, allocations: 4 kB / 0.8703 GB, free: 12.02 MB / 0.5417 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.656e-05/0.541, allocations: 0 / 0.8703 GB, free: 12.02 MB / 0.5417 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 4.779e-06/0.541, allocations: 7.938 kB / 0.8703 GB, free: 12.02 MB / 0.5417 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0006886/0.5417, allocations: 409 kB / 0.8707 GB, free: 11.58 MB / 0.5417 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0001676/0.5419, allocations: 106.5 kB / 0.8708 GB, free: 11.46 MB / 0.5417 GB Notification: Performance of preOpt resolveLoops (simulation): time 8.859e-05/0.542, allocations: 56.84 kB / 0.8709 GB, free: 11.41 MB / 0.5417 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0005991/0.5426, allocations: 445.5 kB / 0.8713 GB, free: 10.88 MB / 0.5417 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.000208/0.5428, allocations: 121.2 kB / 0.8714 GB, free: 10.75 MB / 0.5417 GB Notification: Performance of pre-optimization done (n=16): time 1.533e-06/0.5429, allocations: 8 kB / 0.8714 GB, free: 10.74 MB / 0.5417 GB Notification: Performance of matching and sorting (n=16): time 0.01119/0.5541, allocations: 1.235 MB / 0.8726 GB, free: 9.5 MB / 0.5417 GB Notification: Performance of inlineWhenForInitialization (initialization): time 3.742e-05/0.5541, allocations: 59.34 kB / 0.8727 GB, free: 9.43 MB / 0.5417 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0001673/0.5543, allocations: 154.7 kB / 0.8728 GB, free: 9.266 MB / 0.5417 GB Notification: Performance of collectPreVariables (initialization): time 2.504e-05/0.5543, allocations: 29.7 kB / 0.8729 GB, free: 9.23 MB / 0.5417 GB Notification: Performance of collectInitialEqns (initialization): time 7.397e-05/0.5544, allocations: 108 kB / 0.873 GB, free: 9.121 MB / 0.5417 GB Notification: Performance of collectInitialBindings (initialization): time 5.455e-05/0.5545, allocations: 63.19 kB / 0.873 GB, free: 9.059 MB / 0.5417 GB Notification: Performance of simplifyInitialFunctions (initialization): time 1.367e-05/0.5545, allocations: 0 / 0.873 GB, free: 9.059 MB / 0.5417 GB Notification: Performance of setup shared object (initialization): time 0.0001055/0.5546, allocations: 326.8 kB / 0.8733 GB, free: 8.73 MB / 0.5417 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0001041/0.5547, allocations: 56.84 kB / 0.8734 GB, free: 8.672 MB / 0.5417 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0001077/0.5548, allocations: 71.52 kB / 0.8735 GB, free: 8.594 MB / 0.5417 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.01102/0.5658, allocations: 1.152 MB / 0.8746 GB, free: 7.438 MB / 0.5417 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 4.138e-06/0.5659, allocations: 0 / 0.8746 GB, free: 7.438 MB / 0.5417 GB Notification: Performance of matching and sorting (n=23) (initialization): time 0.01097/0.5769, allocations: 1.281 MB / 0.8758 GB, free: 6.152 MB / 0.5417 GB Notification: Performance of prepare postOptimizeDAE: time 4.201e-05/0.5769, allocations: 33.69 kB / 0.8759 GB, free: 6.113 MB / 0.5417 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.139e-05/0.5769, allocations: 8.062 kB / 0.8759 GB, free: 6.105 MB / 0.5417 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.461e-05/0.577, allocations: 3.938 kB / 0.8759 GB, free: 6.102 MB / 0.5417 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0002647/0.5772, allocations: 43.97 kB / 0.8759 GB, free: 6.059 MB / 0.5417 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 7.184e-06/0.5773, allocations: 4 kB / 0.8759 GB, free: 6.055 MB / 0.5417 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0002296/0.5775, allocations: 15.89 kB / 0.8759 GB, free: 6.039 MB / 0.5417 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 2.345e-05/0.5775, allocations: 8 kB / 0.8759 GB, free: 6.031 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.0001834/0.5777, allocations: 131.3 kB / 0.8761 GB, free: 5.895 MB / 0.5417 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 4.307e-05/0.5778, allocations: 15.81 kB / 0.8761 GB, free: 5.879 MB / 0.5417 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.01041/0.5882, allocations: 1.735 MB / 0.8778 GB, free: 4.137 MB / 0.5417 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 7.634e-06/0.5882, allocations: 3.938 kB / 0.8778 GB, free: 4.133 MB / 0.5417 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.751e-06/0.5882, allocations: 0 / 0.8778 GB, free: 4.133 MB / 0.5417 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 6.271e-06/0.5883, allocations: 3.938 kB / 0.8778 GB, free: 4.129 MB / 0.5417 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0002731/0.5885, allocations: 234 kB / 0.878 GB, free: 3.863 MB / 0.5417 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.675e-06/0.5885, allocations: 4 kB / 0.878 GB, free: 3.859 MB / 0.5417 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0003009/0.5889, allocations: 43.98 kB / 0.8781 GB, free: 3.816 MB / 0.5417 GB Notification: Performance of postOpt tearingSystem (simulation): time 5.661e-06/0.5889, allocations: 0 / 0.8781 GB, free: 3.816 MB / 0.5417 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.204e-05/0.5889, allocations: 3.984 kB / 0.8781 GB, free: 3.812 MB / 0.5417 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 8.836e-06/0.5889, allocations: 7.953 kB / 0.8781 GB, free: 3.805 MB / 0.5417 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.825e-06/0.5889, allocations: 0 / 0.8781 GB, free: 3.805 MB / 0.5417 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.01048/0.5994, allocations: 1.795 MB / 0.8798 GB, free: 1.992 MB / 0.5417 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001863/0.5996, allocations: 116.9 kB / 0.8799 GB, free: 1.859 MB / 0.5417 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 4.316e-05/0.5997, allocations: 4 kB / 0.8799 GB, free: 1.855 MB / 0.5417 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001891/0.5999, allocations: 11.98 kB / 0.8799 GB, free: 1.844 MB / 0.5417 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001191/0.6, allocations: 23.92 kB / 0.88 GB, free: 1.82 MB / 0.5417 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 1.816e-05/0.6, allocations: 4 kB / 0.88 GB, free: 1.816 MB / 0.5417 GB Notification: Performance of sorting global known variables: time 0.0001203/0.6002, allocations: 133.2 kB / 0.8801 GB, free: 1.688 MB / 0.5417 GB Notification: Performance of sort global known variables: time 1.3e-07/0.6002, allocations: 0 / 0.8801 GB, free: 1.688 MB / 0.5417 GB Notification: Performance of remove unused functions: time 0.000337/0.6005, allocations: 63.92 kB / 0.8802 GB, free: 1.625 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.0002337/0.6008, allocations: 139.1 kB / 0.8803 GB, free: 1.477 MB / 0.5417 GB Notification: Performance of simCode: created initialization part: time 0.0003152/0.6011, allocations: 188.8 kB / 0.8805 GB, free: 1.281 MB / 0.5417 GB Notification: Performance of simCode: created event and clocks part: time 1.914e-06/0.6011, allocations: 4 kB / 0.8805 GB, free: 1.277 MB / 0.5417 GB Notification: Performance of simCode: created simulation system equations: time 0.0001181/0.6012, allocations: 71.92 kB / 0.8805 GB, free: 1.207 MB / 0.5417 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002483/0.6015, allocations: 22.89 kB / 0.8806 GB, free: 1.188 MB / 0.5417 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.0009144/0.6024, allocations: 457.7 kB / 0.881 GB, free: 0.7227 MB / 0.5417 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0003373/0.6028, allocations: 0.728 MB / 0.8817 GB, free: 15.97 MB / 0.5573 GB Notification: Performance of simCode: alias equations: time 0.0001745/0.6029, allocations: 24.61 kB / 0.8817 GB, free: 15.95 MB / 0.5573 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 9.591e-05/0.603, allocations: 23.42 kB / 0.8818 GB, free: 15.93 MB / 0.5573 GB Notification: Performance of SimCode: time 4.2e-07/0.6031, allocations: 0 / 0.8818 GB, free: 15.93 MB / 0.5573 GB Notification: Performance of Templates: time 0.007262/0.6103, allocations: 2.299 MB / 0.884 GB, free: 13.65 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)