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: "" <> buildModelFMU(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex,fileNamePrefix="BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatteryComplex",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex,fileNamePrefix="BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatteryComplex",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.004304/0.004305, allocations: 102.5 kB / 15.73 MB, free: 6.035 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.001029/0.001029, allocations: 196.8 kB / 16.67 MB, free: 5.969 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.269/1.269, allocations: 222.9 MB / 240.4 MB, free: 4.32 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.002106/0.002106, allocations: 275.1 kB / 290.8 MB, free: 1.922 MB / 238.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/package.mo): time 0.9378/0.9378, allocations: 169.3 MB / 0.4983 GB, free: 13.8 MB / 382.1 MB Notification: Performance of FrontEnd - loaded program: time 0.001832/0.001832, allocations: 91.84 kB / 0.6809 GB, free: 8 kB / 478.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1637/0.1655, allocations: 86.98 MB / 0.7659 GB, free: 8.953 MB / 0.5606 GB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex): time 0.003919/0.1695, allocations: 2.645 MB / 0.7685 GB, free: 6.293 MB / 0.5606 GB Notification: Performance of NFInst.instExpressions: time 0.002081/0.1716, allocations: 1.068 MB / 0.7695 GB, free: 5.215 MB / 0.5606 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.000278/0.1719, allocations: 11.94 kB / 0.7695 GB, free: 5.203 MB / 0.5606 GB Notification: Performance of NFTyping.typeComponents: time 0.0003029/0.1723, allocations: 67.64 kB / 0.7696 GB, free: 5.137 MB / 0.5606 GB Notification: Performance of NFTyping.typeBindings: time 0.000346/0.1726, allocations: 138.9 kB / 0.7697 GB, free: 5 MB / 0.5606 GB Notification: Performance of NFTyping.typeClassSections: time 0.0005175/0.1732, allocations: 175.6 kB / 0.7699 GB, free: 4.828 MB / 0.5606 GB Notification: Performance of NFFlatten.flatten: time 0.0006653/0.1738, allocations: 0.5138 MB / 0.7704 GB, free: 4.312 MB / 0.5606 GB Notification: Performance of NFFlatten.resolveConnections: time 0.0001601/0.174, allocations: 52.7 kB / 0.7704 GB, free: 4.262 MB / 0.5606 GB Notification: Performance of NFEvalConstants.evaluate: time 0.0004526/0.1745, allocations: 235.1 kB / 0.7706 GB, free: 4.031 MB / 0.5606 GB Notification: Performance of NFSimplifyModel.simplify: time 0.0004316/0.1749, allocations: 219.1 kB / 0.7709 GB, free: 3.816 MB / 0.5606 GB Notification: Performance of NFPackage.collectConstants: time 9.849e-05/0.175, allocations: 28 kB / 0.7709 GB, free: 3.789 MB / 0.5606 GB Notification: Performance of NFFlatten.collectFunctions: time 0.0002404/0.1753, allocations: 75.95 kB / 0.771 GB, free: 3.715 MB / 0.5606 GB Notification: Performance of NFScalarize.scalarize: time 0.0001081/0.1754, allocations: 79.66 kB / 0.771 GB, free: 3.637 MB / 0.5606 GB Notification: Performance of NFVerifyModel.verify: time 0.000236/0.1756, allocations: 191 kB / 0.7712 GB, free: 3.449 MB / 0.5606 GB Notification: Performance of NFConvertDAE.convert: time 0.0005172/0.1762, allocations: 418.6 kB / 0.7716 GB, free: 3.039 MB / 0.5606 GB Notification: Performance of FrontEnd - DAE generated: time 5.089e-06/0.1762, allocations: 0 / 0.7716 GB, free: 3.039 MB / 0.5606 GB Notification: Performance of FrontEnd: time 2.786e-06/0.1762, allocations: 0 / 0.7716 GB, free: 3.039 MB / 0.5606 GB Notification: Performance of Transformations before backend: time 1.526e-05/0.1762, allocations: 3.938 kB / 0.7716 GB, free: 3.035 MB / 0.5606 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.00199/0.1782, allocations: 0.8132 MB / 0.7724 GB, free: 2.156 MB / 0.5606 GB Notification: Performance of prepare preOptimizeDAE: time 4.26e-05/0.1782, allocations: 8.031 kB / 0.7724 GB, free: 2.148 MB / 0.5606 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 7.279e-05/0.1783, allocations: 58.73 kB / 0.7725 GB, free: 2.082 MB / 0.5606 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0001042/0.1784, allocations: 40.47 kB / 0.7725 GB, free: 2.043 MB / 0.5606 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0004688/0.1789, allocations: 343.9 kB / 0.7728 GB, free: 1.664 MB / 0.5606 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 2.066e-05/0.1789, allocations: 16.81 kB / 0.7729 GB, free: 1.648 MB / 0.5606 GB Notification: Performance of preOpt expandDerOperator (simulation): time 6.94e-05/0.179, allocations: 20.38 kB / 0.7729 GB, free: 1.629 MB / 0.5606 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0007166/0.1797, allocations: 324.9 kB / 0.7732 GB, free: 1.301 MB / 0.5606 GB Notification: Performance of preOpt findStateOrder (simulation): time 2.644e-05/0.1798, allocations: 8 kB / 0.7732 GB, free: 1.293 MB / 0.5606 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 3.38e-05/0.1798, allocations: 7.938 kB / 0.7732 GB, free: 1.285 MB / 0.5606 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 9.808e-06/0.1798, allocations: 4 kB / 0.7732 GB, free: 1.281 MB / 0.5606 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.000816/0.1806, allocations: 299.7 kB / 0.7735 GB, free: 0.9883 MB / 0.5606 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.00122/0.1819, allocations: 0.7734 MB / 0.7742 GB, free: 164 kB / 0.5606 GB Notification: Performance of preOpt comSubExp (simulation): time 0.3726/0.5545, allocations: 374.4 kB / 0.7746 GB, free: 14.96 MB / 0.5606 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0005991/0.5551, allocations: 208.8 kB / 0.7748 GB, free: 14.95 MB / 0.5606 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0005918/0.5557, allocations: 456.6 kB / 0.7752 GB, free: 14.48 MB / 0.5606 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0008216/0.5565, allocations: 325.1 kB / 0.7755 GB, free: 14.41 MB / 0.5606 GB Notification: Performance of pre-optimization done (n=42): time 3.667e-06/0.5566, allocations: 0.8438 kB / 0.7755 GB, free: 14.41 MB / 0.5606 GB Notification: Performance of matching and sorting (n=42): time 0.001718/0.5583, allocations: 0.612 MB / 0.7761 GB, free: 14.38 MB / 0.5606 GB Notification: Performance of inlineWhenForInitialization (initialization): time 4.034e-05/0.5583, allocations: 84.59 kB / 0.7762 GB, free: 14.28 MB / 0.5606 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0003194/0.5587, allocations: 310.5 kB / 0.7765 GB, free: 14.18 MB / 0.5606 GB Notification: Performance of collectPreVariables (initialization): time 3.915e-05/0.5587, allocations: 37.77 kB / 0.7766 GB, free: 14.14 MB / 0.5606 GB Notification: Performance of collectInitialEqns (initialization): time 9.039e-05/0.5588, allocations: 161.2 kB / 0.7767 GB, free: 14.06 MB / 0.5606 GB Notification: Performance of collectInitialBindings (initialization): time 0.0001212/0.5589, allocations: 144.5 kB / 0.7769 GB, free: 14 MB / 0.5606 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0001565/0.5591, allocations: 96.12 kB / 0.7769 GB, free: 13.98 MB / 0.5606 GB Notification: Performance of setup shared object (initialization): time 8.04e-05/0.5592, allocations: 348.3 kB / 0.7773 GB, free: 13.67 MB / 0.5606 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.000535/0.5597, allocations: 208.8 kB / 0.7775 GB, free: 13.66 MB / 0.5606 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0005393/0.5603, allocations: 240.8 kB / 0.7777 GB, free: 13.54 MB / 0.5606 GB Notification: Performance of analyzeInitialSystem (initialization): time 6.172/6.732, allocations: 0.866 GB / 1.644 GB, free: 104.3 MB / 0.8419 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 6.262e-06/6.732, allocations: 0 / 1.644 GB, free: 104.3 MB / 0.8419 GB Notification: Performance of matching and sorting (n=61) (initialization): time 0.001172/6.734, allocations: 0.6349 MB / 1.644 GB, free: 103.8 MB / 0.8419 GB Notification: Performance of prepare postOptimizeDAE: time 3.944e-05/6.734, allocations: 96.16 kB / 1.644 GB, free: 103.7 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 6.402e-06/6.734, allocations: 1.125 kB / 1.644 GB, free: 103.7 MB / 0.8419 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.077e-05/6.734, allocations: 4 kB / 1.644 GB, free: 103.7 MB / 0.8419 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0004976/6.734, allocations: 114.6 kB / 1.645 GB, free: 103.6 MB / 0.8419 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 8.526e-06/6.734, allocations: 4 kB / 1.645 GB, free: 103.5 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0004474/6.735, allocations: 68.77 kB / 1.645 GB, free: 103.5 MB / 0.8419 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 3.848e-05/6.735, allocations: 24.78 kB / 1.645 GB, free: 103.5 MB / 0.8419 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.685 * 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.685 * 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.0002635/6.735, allocations: 199.6 kB / 1.645 GB, free: 103.3 MB / 0.8419 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 5.676e-05/6.735, allocations: 40.78 kB / 1.645 GB, free: 103.3 MB / 0.8419 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001322/6.736, allocations: 0.6313 MB / 1.646 GB, free: 102.8 MB / 0.8419 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 5.26e-06/6.736, allocations: 4 kB / 1.646 GB, free: 102.8 MB / 0.8419 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.11e-06/6.736, allocations: 3.938 kB / 1.646 GB, free: 102.8 MB / 0.8419 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 8.165e-06/6.736, allocations: 13.2 kB / 1.646 GB, free: 102.8 MB / 0.8419 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0003295/6.737, allocations: 437.2 kB / 1.646 GB, free: 102.5 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.225e-06/6.737, allocations: 0 / 1.646 GB, free: 102.5 MB / 0.8419 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0005173/6.737, allocations: 107.8 kB / 1.646 GB, free: 102.4 MB / 0.8419 GB Notification: Performance of postOpt tearingSystem (simulation): time 4.148e-06/6.737, allocations: 4 kB / 1.646 GB, free: 102.4 MB / 0.8419 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 3.405e-05/6.737, allocations: 15.48 kB / 1.646 GB, free: 102.3 MB / 0.8419 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 3.257e-06/6.737, allocations: 4 kB / 1.646 GB, free: 102.3 MB / 0.8419 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.573e-06/6.737, allocations: 3.938 kB / 1.646 GB, free: 102.3 MB / 0.8419 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001397/6.739, allocations: 0.7887 MB / 1.647 GB, free: 101.6 MB / 0.8419 GB Notification: Performance of postOpt removeConstants (simulation): time 0.00015/6.739, allocations: 164.2 kB / 1.647 GB, free: 101.4 MB / 0.8419 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 6.356e-05/6.739, allocations: 12 kB / 1.647 GB, free: 101.4 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0003917/6.739, allocations: 35.89 kB / 1.647 GB, free: 101.3 MB / 0.8419 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001152/6.74, allocations: 55.92 kB / 1.647 GB, free: 101.3 MB / 0.8419 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.889e-05/6.74, allocations: 20 kB / 1.647 GB, free: 101.3 MB / 0.8419 GB Notification: Performance of sorting global known variables: time 0.0001394/6.74, allocations: 215 kB / 1.647 GB, free: 101.1 MB / 0.8419 GB Notification: Performance of sort global known variables: time 1.2e-07/6.74, allocations: 0 / 1.647 GB, free: 101.1 MB / 0.8419 GB Notification: Performance of remove unused functions: time 0.0003437/6.74, allocations: 114 kB / 1.647 GB, free: 100.9 MB / 0.8419 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.00166/6.742, allocations: 1.365 MB / 1.649 GB, free: 99.56 MB / 0.8419 GB Notification: Performance of simCode: created initialization part: time 0.001041/6.743, allocations: 0.6378 MB / 1.649 GB, free: 98.89 MB / 0.8419 GB Notification: Performance of simCode: created event and clocks part: time 2.916e-06/6.743, allocations: 0 / 1.649 GB, free: 98.89 MB / 0.8419 GB Notification: Performance of simCode: created simulation system equations: time 0.0004943/6.743, allocations: 269.7 kB / 1.65 GB, free: 98.63 MB / 0.8419 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0004136/6.744, allocations: 75.95 kB / 1.65 GB, free: 98.57 MB / 0.8419 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.004946/6.749, allocations: 4.247 MB / 1.654 GB, free: 94.24 MB / 0.8419 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001585/6.749, allocations: 0.8012 MB / 1.655 GB, free: 93.41 MB / 0.8419 GB Notification: Performance of simCode: alias equations: time 0.0003093/6.749, allocations: 83.52 kB / 1.655 GB, free: 93.32 MB / 0.8419 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0002121/6.749, allocations: 143.4 kB / 1.655 GB, free: 93.18 MB / 0.8419 GB Notification: Performance of SimCode: time 6.11e-07/6.749, allocations: 0 / 1.655 GB, free: 93.18 MB / 0.8419 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.02473/6.774, allocations: 9.843 MB / 1.664 GB, free: 83.58 MB / 0.8419 GB Notification: Performance of buildModelFMU: Generate platform static: time 7.799/14.57, allocations: 8 kB / 1.664 GB, free: 83.57 MB / 0.8419 GB (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 & /home/hudson/saved_omc/OMSimulator/install/bin/OMSimulator --tempDir=temp_BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatteryComplex_fmu --startTime=0 --stopTime=3.1536e+07 --timeout=50 --tolerance=1e-06 BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatteryComplex.fmu > BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.pipe 2>&1)