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.005328/0.005328, allocations: 96.52 kB / 15.73 MB, free: 6.039 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.001349/0.001349, allocations: 200.8 kB / 16.68 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.469/1.469, allocations: 222.9 MB / 240.4 MB, free: 4.332 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.002505/0.002505, allocations: 294.7 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 1.052/1.052, allocations: 169.3 MB / 0.4983 GB, free: 13.8 MB / 382.1 MB Notification: Performance of FrontEnd - loaded program: time 0.002693/0.002694, allocations: 91.84 kB / 0.6809 GB, free: 52 kB / 478.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1783/0.181, allocations: 86.98 MB / 0.7659 GB, free: 8.996 MB / 0.5606 GB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex): time 0.004024/0.1851, allocations: 2.646 MB / 0.7685 GB, free: 6.332 MB / 0.5606 GB Notification: Performance of NFInst.instExpressions: time 0.001938/0.187, allocations: 1.072 MB / 0.7695 GB, free: 5.25 MB / 0.5606 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.0001503/0.1872, allocations: 15.88 kB / 0.7695 GB, free: 5.234 MB / 0.5606 GB Notification: Performance of NFTyping.typeComponents: time 0.0002588/0.1875, allocations: 71.62 kB / 0.7696 GB, free: 5.164 MB / 0.5606 GB Notification: Performance of NFTyping.typeBindings: time 0.0002403/0.1877, allocations: 127 kB / 0.7697 GB, free: 5.039 MB / 0.5606 GB Notification: Performance of NFTyping.typeClassSections: time 0.0004274/0.1882, allocations: 175.6 kB / 0.7699 GB, free: 4.867 MB / 0.5606 GB Notification: Performance of NFFlatten.flatten: time 0.0005425/0.1887, allocations: 0.5061 MB / 0.7704 GB, free: 4.359 MB / 0.5606 GB Notification: Performance of NFFlatten.resolveConnections: time 0.0001423/0.1889, allocations: 56.58 kB / 0.7704 GB, free: 4.305 MB / 0.5606 GB Notification: Performance of NFEvalConstants.evaluate: time 0.0003113/0.1892, allocations: 227.2 kB / 0.7706 GB, free: 4.082 MB / 0.5606 GB Notification: Performance of NFSimplifyModel.simplify: time 0.0003307/0.1895, allocations: 230.9 kB / 0.7709 GB, free: 3.855 MB / 0.5606 GB Notification: Performance of NFPackage.collectConstants: time 5.92e-05/0.1896, allocations: 32 kB / 0.7709 GB, free: 3.824 MB / 0.5606 GB Notification: Performance of NFFlatten.collectFunctions: time 0.000171/0.1898, allocations: 79.95 kB / 0.771 GB, free: 3.746 MB / 0.5606 GB Notification: Performance of NFScalarize.scalarize: time 8.36e-05/0.1899, allocations: 71.73 kB / 0.771 GB, free: 3.676 MB / 0.5606 GB Notification: Performance of NFVerifyModel.verify: time 0.0002037/0.1901, allocations: 187 kB / 0.7712 GB, free: 3.492 MB / 0.5606 GB Notification: Performance of NFConvertDAE.convert: time 0.0004959/0.1906, allocations: 422.2 kB / 0.7716 GB, free: 3.078 MB / 0.5606 GB Notification: Performance of FrontEnd - DAE generated: time 4.138e-06/0.1906, allocations: 0 / 0.7716 GB, free: 3.078 MB / 0.5606 GB Notification: Performance of FrontEnd: time 1.383e-06/0.1906, allocations: 0 / 0.7716 GB, free: 3.078 MB / 0.5606 GB Notification: Performance of Transformations before backend: time 6.392e-06/0.1906, allocations: 0 / 0.7716 GB, free: 3.078 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.001947/0.1926, allocations: 0.8246 MB / 0.7724 GB, free: 2.188 MB / 0.5606 GB Notification: Performance of prepare preOptimizeDAE: time 4.09e-05/0.1926, allocations: 8.031 kB / 0.7724 GB, free: 2.18 MB / 0.5606 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 7.75e-05/0.1927, allocations: 58.72 kB / 0.7725 GB, free: 2.113 MB / 0.5606 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 9.918e-05/0.1928, allocations: 40.7 kB / 0.7725 GB, free: 2.074 MB / 0.5606 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0004491/0.1933, allocations: 340.1 kB / 0.7728 GB, free: 1.699 MB / 0.5606 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 2.096e-05/0.1933, allocations: 16.81 kB / 0.7729 GB, free: 1.684 MB / 0.5606 GB Notification: Performance of preOpt expandDerOperator (simulation): time 7.361e-05/0.1934, allocations: 24.33 kB / 0.7729 GB, free: 1.66 MB / 0.5606 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0007693/0.1941, allocations: 332.8 kB / 0.7732 GB, free: 1.324 MB / 0.5606 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.656e-05/0.1942, allocations: 0 / 0.7732 GB, free: 1.324 MB / 0.5606 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 3.924e-05/0.1942, allocations: 11.98 kB / 0.7732 GB, free: 1.312 MB / 0.5606 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 1.087e-05/0.1942, allocations: 15.94 kB / 0.7732 GB, free: 1.297 MB / 0.5606 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0008474/0.1951, allocations: 283.8 kB / 0.7735 GB, free: 1.02 MB / 0.5606 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001211/0.1963, allocations: 0.7891 MB / 0.7743 GB, free: 180 kB / 0.5606 GB Notification: Performance of preOpt comSubExp (simulation): time 0.3327/0.529, allocations: 375.6 kB / 0.7746 GB, free: 14.97 MB / 0.5606 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0005616/0.5296, allocations: 205.1 kB / 0.7748 GB, free: 14.95 MB / 0.5606 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0005876/0.5302, allocations: 455.1 kB / 0.7753 GB, free: 14.48 MB / 0.5606 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0007677/0.531, allocations: 327.5 kB / 0.7756 GB, free: 14.42 MB / 0.5606 GB Notification: Performance of pre-optimization done (n=42): time 2.325e-06/0.531, allocations: 0.75 kB / 0.7756 GB, free: 14.42 MB / 0.5606 GB Notification: Performance of matching and sorting (n=42): time 0.001623/0.5326, allocations: 0.6107 MB / 0.7762 GB, free: 14.39 MB / 0.5606 GB Notification: Performance of inlineWhenForInitialization (initialization): time 4.052e-05/0.5327, allocations: 87.61 kB / 0.7763 GB, free: 14.29 MB / 0.5606 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0002994/0.533, allocations: 304.9 kB / 0.7765 GB, free: 14.19 MB / 0.5606 GB Notification: Performance of collectPreVariables (initialization): time 4.191e-05/0.533, allocations: 37.73 kB / 0.7766 GB, free: 14.16 MB / 0.5606 GB Notification: Performance of collectInitialEqns (initialization): time 9.078e-05/0.5331, allocations: 161 kB / 0.7767 GB, free: 14.07 MB / 0.5606 GB Notification: Performance of collectInitialBindings (initialization): time 0.0001055/0.5332, allocations: 153.8 kB / 0.7769 GB, free: 14 MB / 0.5606 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0001543/0.5334, allocations: 92.48 kB / 0.777 GB, free: 13.98 MB / 0.5606 GB Notification: Performance of setup shared object (initialization): time 7.475e-05/0.5335, allocations: 351.5 kB / 0.7773 GB, free: 13.67 MB / 0.5606 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0005266/0.534, allocations: 209.4 kB / 0.7775 GB, free: 13.64 MB / 0.5606 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.000527/0.5346, allocations: 243.9 kB / 0.7777 GB, free: 13.52 MB / 0.5606 GB Notification: Performance of analyzeInitialSystem (initialization): time 5.524/6.058, allocations: 0.866 GB / 1.644 GB, free: 104.2 MB / 0.8419 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 6.322e-06/6.059, allocations: 0 / 1.644 GB, free: 104.2 MB / 0.8419 GB Notification: Performance of matching and sorting (n=61) (initialization): time 0.001083/6.06, allocations: 0.64 MB / 1.644 GB, free: 103.7 MB / 0.8419 GB Notification: Performance of prepare postOptimizeDAE: time 3.572e-05/6.06, allocations: 92.22 kB / 1.644 GB, free: 103.6 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 6.001e-06/6.06, allocations: 0 / 1.644 GB, free: 103.6 MB / 0.8419 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.978e-05/6.06, allocations: 5.078 kB / 1.644 GB, free: 103.6 MB / 0.8419 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0004917/6.06, allocations: 117.1 kB / 1.645 GB, free: 103.5 MB / 0.8419 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 7.745e-06/6.06, allocations: 9.656 kB / 1.645 GB, free: 103.5 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0004196/6.061, allocations: 68.88 kB / 1.645 GB, free: 103.4 MB / 0.8419 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 3.636e-05/6.061, allocations: 23.61 kB / 1.645 GB, free: 103.4 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.0002352/6.061, allocations: 202.8 kB / 1.645 GB, free: 103.2 MB / 0.8419 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 5.399e-05/6.061, allocations: 40.11 kB / 1.645 GB, free: 103.2 MB / 0.8419 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001244/6.062, allocations: 0.6321 MB / 1.646 GB, free: 102.8 MB / 0.8419 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 5.401e-06/6.062, allocations: 5.078 kB / 1.646 GB, free: 102.8 MB / 0.8419 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 4.839e-06/6.062, allocations: 7.938 kB / 1.646 GB, free: 102.7 MB / 0.8419 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 6.312e-06/6.062, allocations: 3.984 kB / 1.646 GB, free: 102.7 MB / 0.8419 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0003201/6.063, allocations: 436.4 kB / 1.646 GB, free: 102.4 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 1.794e-06/6.063, allocations: 4 kB / 1.646 GB, free: 102.4 MB / 0.8419 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0005087/6.063, allocations: 107.3 kB / 1.646 GB, free: 102.3 MB / 0.8419 GB Notification: Performance of postOpt tearingSystem (simulation): time 2.755e-06/6.063, allocations: 4 kB / 1.646 GB, free: 102.3 MB / 0.8419 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 3.259e-05/6.063, allocations: 19.36 kB / 1.646 GB, free: 102.3 MB / 0.8419 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 2.164e-06/6.063, allocations: 0 / 1.646 GB, free: 102.3 MB / 0.8419 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.563e-06/6.063, allocations: 3.938 kB / 1.646 GB, free: 102.3 MB / 0.8419 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001273/6.064, allocations: 0.787 MB / 1.647 GB, free: 101.5 MB / 0.8419 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001246/6.065, allocations: 164.9 kB / 1.647 GB, free: 101.3 MB / 0.8419 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 5.584e-05/6.065, allocations: 12 kB / 1.647 GB, free: 101.3 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0003869/6.065, allocations: 44.77 kB / 1.647 GB, free: 101.3 MB / 0.8419 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001129/6.065, allocations: 55.92 kB / 1.647 GB, free: 101.2 MB / 0.8419 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.822e-05/6.065, allocations: 19.14 kB / 1.647 GB, free: 101.2 MB / 0.8419 GB Notification: Performance of sorting global known variables: time 0.0001319/6.065, allocations: 215 kB / 1.647 GB, free: 101 MB / 0.8419 GB Notification: Performance of sort global known variables: time 1.2e-07/6.065, allocations: 0 / 1.647 GB, free: 101 MB / 0.8419 GB Notification: Performance of remove unused functions: time 0.0003996/6.066, allocations: 118.1 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.001511/6.067, allocations: 1.37 MB / 1.649 GB, free: 99.47 MB / 0.8419 GB Notification: Performance of simCode: created initialization part: time 0.0009078/6.068, allocations: 0.6297 MB / 1.649 GB, free: 98.8 MB / 0.8419 GB Notification: Performance of simCode: created event and clocks part: time 2.895e-06/6.068, allocations: 4 kB / 1.649 GB, free: 98.8 MB / 0.8419 GB Notification: Performance of simCode: created simulation system equations: time 0.0004487/6.069, allocations: 263.8 kB / 1.65 GB, free: 98.55 MB / 0.8419 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0004058/6.069, allocations: 78.8 kB / 1.65 GB, free: 98.48 MB / 0.8419 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.004541/6.074, allocations: 4.253 MB / 1.654 GB, free: 94.15 MB / 0.8419 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001318/6.074, allocations: 0.8051 MB / 1.655 GB, free: 93.31 MB / 0.8419 GB Notification: Performance of simCode: alias equations: time 0.0002703/6.074, allocations: 80.33 kB / 1.655 GB, free: 93.23 MB / 0.8419 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001962/6.074, allocations: 143.4 kB / 1.655 GB, free: 93.09 MB / 0.8419 GB Notification: Performance of SimCode: time 2.81e-07/6.074, allocations: 0 / 1.655 GB, free: 93.09 MB / 0.8419 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.5895/6.664, allocations: 9.965 MB / 1.665 GB, free: 83.37 MB / 0.8419 GB Notification: Performance of buildModelFMU: Generate platform static: time 10.11/16.78, allocations: 12.91 kB / 1.665 GB, free: 83.36 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)