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: "" <> buildModelFMU(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple,fileNamePrefix="BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatterySimple",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple,fileNamePrefix="BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatterySimple",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/package.mo): time 0.7789/0.7789, allocations: 141.7 MB / 154.3 MB, free: 15.48 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.001137/0.001138, allocations: 184.8 kB / 187.3 MB, free: 11.88 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.552/1.552, allocations: 221.3 MB / 441.4 MB, free: 4.578 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.000851/0.0008512, allocations: 95.95 kB / 0.5124 GB, free: 24.27 MB / 394.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.001789/0.001789, allocations: 270.4 kB / 0.5939 GB, free: 7.949 MB / 442.7 MB Notification: Performance of FrontEnd - loaded program: time 4.281e-05/4.298e-05, allocations: 4 kB / 0.6835 GB, free: 12.14 MB / 0.5261 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.483/0.4831, allocations: 82.77 MB / 0.7644 GB, free: 108.7 MB / 0.5261 GB Notification: Performance of FrontEnd - scodeFlatten: time 0.1315/0.6147, allocations: 111.3 MB / 0.8731 GB, free: 13.2 MB / 0.5417 GB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0002879/0.615, allocations: 72.88 kB / 0.8731 GB, free: 13.12 MB / 0.5417 GB Notification: Performance of FrontEnd - DAE generated: time 0.0121/0.6271, allocations: 4.108 MB / 0.8771 GB, free: 8.977 MB / 0.5417 GB Notification: Performance of FrontEnd: time 1.884e-06/0.6272, allocations: 448 / 0.8771 GB, free: 8.977 MB / 0.5417 GB Notification: Performance of Transformations before backend: time 8.716e-06/0.6272, allocations: 0 / 0.8771 GB, free: 8.977 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.000759/0.628, allocations: 479.7 kB / 0.8776 GB, free: 8.457 MB / 0.5417 GB Notification: Performance of prepare preOptimizeDAE: time 5.092e-05/0.628, allocations: 11.97 kB / 0.8776 GB, free: 8.445 MB / 0.5417 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 5.436e-05/0.6281, allocations: 42.55 kB / 0.8777 GB, free: 8.395 MB / 0.5417 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 5.013e-05/0.6281, allocations: 15.81 kB / 0.8777 GB, free: 8.379 MB / 0.5417 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0001987/0.6283, allocations: 210.7 kB / 0.8779 GB, free: 8.133 MB / 0.5417 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.561e-05/0.6284, allocations: 4 kB / 0.8779 GB, free: 8.129 MB / 0.5417 GB Notification: Performance of preOpt expandDerOperator (simulation): time 3.93e-05/0.6284, allocations: 12 kB / 0.8779 GB, free: 8.117 MB / 0.5417 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0002257/0.6286, allocations: 109.6 kB / 0.878 GB, free: 8.004 MB / 0.5417 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.319e-05/0.6287, allocations: 0 / 0.878 GB, free: 8.004 MB / 0.5417 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.86e-05/0.6287, allocations: 4 kB / 0.878 GB, free: 8 MB / 0.5417 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 9.809e-06/0.6287, allocations: 0 / 0.878 GB, free: 8 MB / 0.5417 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0001583/0.6289, allocations: 81.14 kB / 0.8781 GB, free: 7.922 MB / 0.5417 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0007422/0.6296, allocations: 456.5 kB / 0.8785 GB, free: 7.426 MB / 0.5417 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0001991/0.6298, allocations: 102.6 kB / 0.8786 GB, free: 7.316 MB / 0.5417 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.000108/0.63, allocations: 64.84 kB / 0.8787 GB, free: 7.25 MB / 0.5417 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0006777/0.6306, allocations: 441.5 kB / 0.8791 GB, free: 6.727 MB / 0.5417 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0002357/0.6309, allocations: 119.3 kB / 0.8792 GB, free: 6.598 MB / 0.5417 GB Notification: Performance of pre-optimization done (n=16): time 3.968e-06/0.6309, allocations: 3.984 kB / 0.8792 GB, free: 6.594 MB / 0.5417 GB Notification: Performance of matching and sorting (n=16): time 0.0003596/0.6313, allocations: 155.8 kB / 0.8794 GB, free: 6.438 MB / 0.5417 GB Notification: Performance of inlineWhenForInitialization (initialization): time 4.173e-05/0.6313, allocations: 51.41 kB / 0.8794 GB, free: 6.375 MB / 0.5417 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0001699/0.6315, allocations: 177.3 kB / 0.8796 GB, free: 6.195 MB / 0.5417 GB Notification: Performance of collectPreVariables (initialization): time 2.275e-05/0.6315, allocations: 33.7 kB / 0.8796 GB, free: 6.156 MB / 0.5417 GB Notification: Performance of collectInitialEqns (initialization): time 7.337e-05/0.6316, allocations: 112 kB / 0.8797 GB, free: 6.043 MB / 0.5417 GB Notification: Performance of collectInitialBindings (initialization): time 5.75e-05/0.6317, allocations: 63.19 kB / 0.8798 GB, free: 5.98 MB / 0.5417 GB Notification: Performance of simplifyInitialFunctions (initialization): time 9.748e-06/0.6317, allocations: 0 / 0.8798 GB, free: 5.98 MB / 0.5417 GB Notification: Performance of setup shared object (initialization): time 0.0001291/0.6318, allocations: 326.8 kB / 0.8801 GB, free: 5.652 MB / 0.5417 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0001065/0.6319, allocations: 60.84 kB / 0.8801 GB, free: 5.59 MB / 0.5417 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0001234/0.6321, allocations: 83.47 kB / 0.8802 GB, free: 5.5 MB / 0.5417 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.0001254/0.6322, allocations: 80.67 kB / 0.8803 GB, free: 5.414 MB / 0.5417 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 1.864e-06/0.6322, allocations: 4 kB / 0.8803 GB, free: 5.41 MB / 0.5417 GB Notification: Performance of matching and sorting (n=23) (initialization): time 0.0003478/0.6326, allocations: 221.5 kB / 0.8805 GB, free: 5.184 MB / 0.5417 GB Notification: Performance of prepare postOptimizeDAE: time 4.556e-05/0.6326, allocations: 33.7 kB / 0.8805 GB, free: 5.145 MB / 0.5417 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.154e-05/0.6326, allocations: 6.406 kB / 0.8805 GB, free: 5.141 MB / 0.5417 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.685e-05/0.6327, allocations: 0 / 0.8805 GB, free: 5.141 MB / 0.5417 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0002531/0.6329, allocations: 43.97 kB / 0.8806 GB, free: 5.098 MB / 0.5417 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.659e-05/0.6329, allocations: 7.891 kB / 0.8806 GB, free: 5.09 MB / 0.5417 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0001896/0.6331, allocations: 27.95 kB / 0.8806 GB, free: 5.062 MB / 0.5417 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 2.268e-05/0.6332, allocations: 8 kB / 0.8806 GB, free: 5.055 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.0001693/0.6333, allocations: 133.5 kB / 0.8808 GB, free: 4.922 MB / 0.5417 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 2.907e-05/0.6334, allocations: 15.81 kB / 0.8808 GB, free: 4.906 MB / 0.5417 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0004631/0.6338, allocations: 222.9 kB / 0.881 GB, free: 4.691 MB / 0.5417 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 5.691e-06/0.6339, allocations: 8 kB / 0.881 GB, free: 4.684 MB / 0.5417 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 4.198e-06/0.6339, allocations: 0 / 0.881 GB, free: 4.684 MB / 0.5417 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 5.079e-06/0.6339, allocations: 0 / 0.881 GB, free: 4.684 MB / 0.5417 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0002529/0.6341, allocations: 265.5 kB / 0.8812 GB, free: 4.375 MB / 0.5417 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 1.593e-06/0.6342, allocations: 0 / 0.8812 GB, free: 4.375 MB / 0.5417 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0002562/0.6344, allocations: 39.97 kB / 0.8813 GB, free: 4.336 MB / 0.5417 GB Notification: Performance of postOpt tearingSystem (simulation): time 3.196e-06/0.6344, allocations: 0 / 0.8813 GB, free: 4.336 MB / 0.5417 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.398e-05/0.6345, allocations: 8 kB / 0.8813 GB, free: 4.328 MB / 0.5417 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 1.723e-06/0.6345, allocations: 3.938 kB / 0.8813 GB, free: 4.324 MB / 0.5417 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 7.62e-07/0.6345, allocations: 0 / 0.8813 GB, free: 4.324 MB / 0.5417 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0004559/0.6349, allocations: 286.7 kB / 0.8816 GB, free: 4.027 MB / 0.5417 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001004/0.635, allocations: 112.9 kB / 0.8817 GB, free: 3.898 MB / 0.5417 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 3.165e-05/0.6351, allocations: 4 kB / 0.8817 GB, free: 3.895 MB / 0.5417 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001623/0.6353, allocations: 19.98 kB / 0.8817 GB, free: 3.875 MB / 0.5417 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 8.249e-05/0.6353, allocations: 15.97 kB / 0.8817 GB, free: 3.859 MB / 0.5417 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 1.527e-05/0.6354, allocations: 8 kB / 0.8817 GB, free: 3.852 MB / 0.5417 GB Notification: Performance of sorting global known variables: time 0.0001183/0.6355, allocations: 144.3 kB / 0.8819 GB, free: 3.711 MB / 0.5417 GB Notification: Performance of sort global known variables: time 1.3e-07/0.6355, allocations: 0 / 0.8819 GB, free: 3.711 MB / 0.5417 GB Notification: Performance of remove unused functions: time 0.000302/0.6358, allocations: 71.92 kB / 0.8819 GB, free: 3.641 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.0008261/0.6366, allocations: 0.8594 MB / 0.8828 GB, free: 2.75 MB / 0.5417 GB Notification: Performance of simCode: created initialization part: time 0.0003315/0.637, allocations: 192.5 kB / 0.883 GB, free: 2.551 MB / 0.5417 GB Notification: Performance of simCode: created event and clocks part: time 2.505e-06/0.637, allocations: 0 / 0.883 GB, free: 2.551 MB / 0.5417 GB Notification: Performance of simCode: created simulation system equations: time 0.0001346/0.6371, allocations: 79.88 kB / 0.883 GB, free: 2.473 MB / 0.5417 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002427/0.6374, allocations: 30.3 kB / 0.8831 GB, free: 2.445 MB / 0.5417 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.0009839/0.6384, allocations: 0.5236 MB / 0.8836 GB, free: 1.883 MB / 0.5417 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0002879/0.6387, allocations: 0.7244 MB / 0.8843 GB, free: 1.133 MB / 0.5417 GB Notification: Performance of simCode: alias equations: time 0.0001168/0.6388, allocations: 22.67 kB / 0.8843 GB, free: 1.113 MB / 0.5417 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001143/0.6389, allocations: 63.41 kB / 0.8844 GB, free: 1.051 MB / 0.5417 GB Notification: Performance of SimCode: time 5.51e-07/0.6389, allocations: 0 / 0.8844 GB, free: 1.051 MB / 0.5417 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.01802/0.657, allocations: 4.52 MB / 0.8888 GB, free: 12.73 MB / 0.5573 GB Notification: Performance of buildModelFMU: configured platform static using cached values: time 0.0002383/0.6573, allocations: 190 kB / 0.889 GB, free: 12.5 MB / 0.5573 GB Notification: Performance of buildModelFMU: Generate platform static: time 1.749/2.406, allocations: 4 kB / 0.889 GB, free: 12.49 MB / 0.5573 GB (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 & /home/hudson/saved_omc/OMSimulator/install/linux/bin/OMSimulator --tempDir=temp_BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatterySimple_fmu --startTime=0 --stopTime=3.1536e+07 --timeout=50 --tolerance=1e-06 BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatterySimple.fmu > BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe 2>&1)