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.004674/0.004674, allocations: 103.9 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.001161/0.001161, allocations: 194.4 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.262/1.262, allocations: 222.9 MB / 240.4 MB, free: 4.312 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.002357/0.002357, allocations: 282.3 kB / 290.8 MB, free: 1.91 MB / 238.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/package.mo): time 0.9172/0.9172, allocations: 169.2 MB / 0.4983 GB, free: 13.8 MB / 382.1 MB Notification: Performance of FrontEnd - loaded program: time 0.001771/0.001771, allocations: 99.86 kB / 0.6809 GB, free: 0 / 478.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1646/0.1663, allocations: 86.98 MB / 0.7659 GB, free: 8.945 MB / 0.5606 GB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex): time 0.003678/0.1701, allocations: 2.639 MB / 0.7684 GB, free: 6.289 MB / 0.5606 GB Notification: Performance of NFInst.instExpressions: time 0.001858/0.1719, allocations: 1.076 MB / 0.7695 GB, free: 5.203 MB / 0.5606 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.0002145/0.1722, allocations: 11.88 kB / 0.7695 GB, free: 5.191 MB / 0.5606 GB Notification: Performance of NFTyping.typeComponents: time 0.0002751/0.1725, allocations: 71.64 kB / 0.7696 GB, free: 5.121 MB / 0.5606 GB Notification: Performance of NFTyping.typeBindings: time 0.0002947/0.1728, allocations: 130.9 kB / 0.7697 GB, free: 4.992 MB / 0.5606 GB Notification: Performance of NFTyping.typeClassSections: time 0.0004626/0.1733, allocations: 175.6 kB / 0.7699 GB, free: 4.82 MB / 0.5606 GB Notification: Performance of NFFlatten.flatten: time 0.000534/0.1738, allocations: 0.5099 MB / 0.7704 GB, free: 4.309 MB / 0.5606 GB Notification: Performance of NFFlatten.resolveConnections: time 0.0001301/0.1739, allocations: 52.7 kB / 0.7704 GB, free: 4.258 MB / 0.5606 GB Notification: Performance of NFEvalConstants.evaluate: time 0.0003574/0.1743, allocations: 235.1 kB / 0.7706 GB, free: 4.027 MB / 0.5606 GB Notification: Performance of NFSimplifyModel.simplify: time 0.0003518/0.1747, allocations: 231 kB / 0.7709 GB, free: 3.801 MB / 0.5606 GB Notification: Performance of NFPackage.collectConstants: time 7.085e-05/0.1747, allocations: 28 kB / 0.7709 GB, free: 3.773 MB / 0.5606 GB Notification: Performance of NFFlatten.collectFunctions: time 0.0001842/0.1749, allocations: 79.91 kB / 0.771 GB, free: 3.695 MB / 0.5606 GB Notification: Performance of NFScalarize.scalarize: time 8.241e-05/0.175, allocations: 75.72 kB / 0.771 GB, free: 3.621 MB / 0.5606 GB Notification: Performance of NFVerifyModel.verify: time 0.0002001/0.1752, allocations: 195 kB / 0.7712 GB, free: 3.43 MB / 0.5606 GB Notification: Performance of NFConvertDAE.convert: time 0.0004758/0.1757, allocations: 418.6 kB / 0.7716 GB, free: 3.02 MB / 0.5606 GB Notification: Performance of FrontEnd - DAE generated: time 4.148e-06/0.1757, allocations: 0 / 0.7716 GB, free: 3.02 MB / 0.5606 GB Notification: Performance of FrontEnd: time 2.094e-06/0.1757, allocations: 0 / 0.7716 GB, free: 3.02 MB / 0.5606 GB Notification: Performance of Transformations before backend: time 1.157e-05/0.1758, allocations: 0 / 0.7716 GB, free: 3.02 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.001973/0.1777, allocations: 0.8132 MB / 0.7724 GB, free: 2.141 MB / 0.5606 GB Notification: Performance of prepare preOptimizeDAE: time 5.874e-05/0.1778, allocations: 8.031 kB / 0.7724 GB, free: 2.133 MB / 0.5606 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 7.516e-05/0.1779, allocations: 54.73 kB / 0.7725 GB, free: 2.07 MB / 0.5606 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0001117/0.178, allocations: 44.45 kB / 0.7725 GB, free: 2.027 MB / 0.5606 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0004698/0.1785, allocations: 335.9 kB / 0.7728 GB, free: 1.656 MB / 0.5606 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 2.313e-05/0.1785, allocations: 16.81 kB / 0.7729 GB, free: 1.641 MB / 0.5606 GB Notification: Performance of preOpt expandDerOperator (simulation): time 6.726e-05/0.1786, allocations: 28.31 kB / 0.7729 GB, free: 1.613 MB / 0.5606 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.000765/0.1794, allocations: 324.9 kB / 0.7732 GB, free: 1.285 MB / 0.5606 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.98e-05/0.1794, allocations: 4 kB / 0.7732 GB, free: 1.281 MB / 0.5606 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 3.803e-05/0.1794, allocations: 7.984 kB / 0.7732 GB, free: 1.273 MB / 0.5606 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 1.043e-05/0.1794, allocations: 4 kB / 0.7732 GB, free: 1.27 MB / 0.5606 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.000832/0.1803, allocations: 299.7 kB / 0.7735 GB, free: 0.9766 MB / 0.5606 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001235/0.1815, allocations: 0.7734 MB / 0.7742 GB, free: 152 kB / 0.5606 GB Notification: Performance of preOpt comSubExp (simulation): time 0.3624/0.544, allocations: 382 kB / 0.7746 GB, free: 14.51 MB / 0.5606 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0005568/0.5446, allocations: 205.2 kB / 0.7748 GB, free: 14.5 MB / 0.5606 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0006082/0.5452, allocations: 455 kB / 0.7752 GB, free: 14.03 MB / 0.5606 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0008026/0.546, allocations: 323.2 kB / 0.7756 GB, free: 13.96 MB / 0.5606 GB Notification: Performance of pre-optimization done (n=42): time 2.275e-06/0.546, allocations: 1.812 kB / 0.7756 GB, free: 13.96 MB / 0.5606 GB Notification: Performance of matching and sorting (n=42): time 0.00159/0.5476, allocations: 0.6107 MB / 0.7761 GB, free: 13.93 MB / 0.5606 GB Notification: Performance of inlineWhenForInitialization (initialization): time 4.029e-05/0.5477, allocations: 86.78 kB / 0.7762 GB, free: 13.83 MB / 0.5606 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0003182/0.548, allocations: 306.9 kB / 0.7765 GB, free: 13.73 MB / 0.5606 GB Notification: Performance of collectPreVariables (initialization): time 4.114e-05/0.548, allocations: 38.06 kB / 0.7766 GB, free: 13.7 MB / 0.5606 GB Notification: Performance of collectInitialEqns (initialization): time 8.424e-05/0.5481, allocations: 162.3 kB / 0.7767 GB, free: 13.61 MB / 0.5606 GB Notification: Performance of collectInitialBindings (initialization): time 9.879e-05/0.5482, allocations: 147.9 kB / 0.7769 GB, free: 13.55 MB / 0.5606 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.000158/0.5484, allocations: 96.33 kB / 0.7769 GB, free: 13.53 MB / 0.5606 GB Notification: Performance of setup shared object (initialization): time 7.742e-05/0.5485, allocations: 348.8 kB / 0.7773 GB, free: 13.22 MB / 0.5606 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0005101/0.549, allocations: 204.1 kB / 0.7775 GB, free: 13.21 MB / 0.5606 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0004972/0.5495, allocations: 247.5 kB / 0.7777 GB, free: 13.16 MB / 0.5606 GB Notification: Performance of analyzeInitialSystem (initialization): time 5.609/6.159, allocations: 0.866 GB / 1.644 GB, free: 103.3 MB / 0.8419 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 6.722e-06/6.159, allocations: 4 kB / 1.644 GB, free: 103.3 MB / 0.8419 GB Notification: Performance of matching and sorting (n=61) (initialization): time 0.001157/6.16, allocations: 0.6419 MB / 1.644 GB, free: 102.8 MB / 0.8419 GB Notification: Performance of prepare postOptimizeDAE: time 3.855e-05/6.16, allocations: 89.09 kB / 1.644 GB, free: 102.7 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 6.953e-06/6.16, allocations: 0 / 1.644 GB, free: 102.7 MB / 0.8419 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.76e-05/6.16, allocations: 4 kB / 1.644 GB, free: 102.7 MB / 0.8419 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0004996/6.16, allocations: 115.3 kB / 1.645 GB, free: 102.6 MB / 0.8419 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 9.197e-06/6.16, allocations: 8 kB / 1.645 GB, free: 102.6 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0004342/6.161, allocations: 73.17 kB / 1.645 GB, free: 102.6 MB / 0.8419 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 3.78e-05/6.161, allocations: 19.73 kB / 1.645 GB, free: 102.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.0002608/6.161, allocations: 199 kB / 1.645 GB, free: 102.4 MB / 0.8419 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 6.046e-05/6.161, allocations: 40.78 kB / 1.645 GB, free: 102.4 MB / 0.8419 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001281/6.162, allocations: 0.6353 MB / 1.646 GB, free: 101.9 MB / 0.8419 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 5.41e-06/6.162, allocations: 4 kB / 1.646 GB, free: 101.9 MB / 0.8419 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 7.044e-06/6.162, allocations: 6.062 kB / 1.646 GB, free: 101.9 MB / 0.8419 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 7.244e-06/6.163, allocations: 7.984 kB / 1.646 GB, free: 101.9 MB / 0.8419 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0003199/6.163, allocations: 436.2 kB / 1.646 GB, free: 101.5 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.124e-06/6.163, allocations: 0 / 1.646 GB, free: 101.5 MB / 0.8419 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0005328/6.163, allocations: 110.6 kB / 1.646 GB, free: 101.4 MB / 0.8419 GB Notification: Performance of postOpt tearingSystem (simulation): time 4.689e-06/6.163, allocations: 4 kB / 1.646 GB, free: 101.4 MB / 0.8419 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 3.482e-05/6.163, allocations: 14.17 kB / 1.646 GB, free: 101.4 MB / 0.8419 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 4.348e-06/6.163, allocations: 4 kB / 1.646 GB, free: 101.4 MB / 0.8419 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.504e-06/6.163, allocations: 9.375 kB / 1.646 GB, free: 101.4 MB / 0.8419 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001352/6.165, allocations: 0.7811 MB / 1.647 GB, free: 100.8 MB / 0.8419 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001368/6.165, allocations: 162.6 kB / 1.647 GB, free: 100.6 MB / 0.8419 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 6.644e-05/6.165, allocations: 12.88 kB / 1.647 GB, free: 100.6 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0003849/6.165, allocations: 39.2 kB / 1.647 GB, free: 100.6 MB / 0.8419 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001148/6.166, allocations: 62.86 kB / 1.647 GB, free: 100.6 MB / 0.8419 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.8e-05/6.166, allocations: 15.81 kB / 1.647 GB, free: 100.5 MB / 0.8419 GB Notification: Performance of sorting global known variables: time 0.0001403/6.166, allocations: 216.6 kB / 1.647 GB, free: 100.4 MB / 0.8419 GB Notification: Performance of sort global known variables: time 1.4e-07/6.166, allocations: 0 / 1.647 GB, free: 100.4 MB / 0.8419 GB Notification: Performance of remove unused functions: time 0.0003324/6.166, allocations: 110 kB / 1.647 GB, free: 100.2 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.001566/6.168, allocations: 1.366 MB / 1.649 GB, free: 98.86 MB / 0.8419 GB Notification: Performance of simCode: created initialization part: time 0.001015/6.169, allocations: 0.6375 MB / 1.649 GB, free: 98.19 MB / 0.8419 GB Notification: Performance of simCode: created event and clocks part: time 2.204e-06/6.169, allocations: 0 / 1.649 GB, free: 98.19 MB / 0.8419 GB Notification: Performance of simCode: created simulation system equations: time 0.000471/6.169, allocations: 268.5 kB / 1.65 GB, free: 97.93 MB / 0.8419 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0004101/6.17, allocations: 74.72 kB / 1.65 GB, free: 97.87 MB / 0.8419 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.004819/6.174, allocations: 4.25 MB / 1.654 GB, free: 93.54 MB / 0.8419 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001724/6.175, allocations: 0.8012 MB / 1.655 GB, free: 92.7 MB / 0.8419 GB Notification: Performance of simCode: alias equations: time 0.0002891/6.175, allocations: 83.56 kB / 1.655 GB, free: 92.62 MB / 0.8419 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0002102/6.175, allocations: 143.4 kB / 1.655 GB, free: 92.48 MB / 0.8419 GB Notification: Performance of SimCode: time 3.91e-07/6.175, allocations: 0 / 1.655 GB, free: 92.48 MB / 0.8419 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.02724/6.202, allocations: 10.21 MB / 1.665 GB, free: 82.52 MB / 0.8419 GB Notification: Performance of buildModelFMU: Generate platform static: time 7.702/13.9, allocations: 9.938 kB / 1.665 GB, free: 82.51 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)