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: translateModel(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex") translateModel(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex") Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001556/0.001556, allocations: 112.7 kB / 16.42 MB, free: 6.512 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.001654/0.001655, allocations: 190.7 kB / 17.35 MB, free: 5.738 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.313/1.313, allocations: 222.9 MB / 241.1 MB, free: 15.12 MB / 206.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.002076/0.002076, allocations: 292.1 kB / 291.5 MB, free: 14.44 MB / 238.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/package.mo): time 0.9146/0.9146, allocations: 169.2 MB / 0.499 GB, free: 4.426 MB / 382.1 MB Notification: Performance of FrontEnd - loaded program: time 0.001793/0.001793, allocations: 95.84 kB / 0.6821 GB, free: 7 MB / 494.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.3802/0.382, allocations: 86.98 MB / 0.767 GB, free: 3.945 MB / 0.5294 GB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex): time 0.003205/0.3852, allocations: 2.649 MB / 0.7696 GB, free: 1.281 MB / 0.5294 GB Notification: Performance of NFInst.instExpressions: time 0.001465/0.3867, allocations: 1.08 MB / 0.7707 GB, free: 196 kB / 0.5294 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.0001131/0.3868, allocations: 11.94 kB / 0.7707 GB, free: 184 kB / 0.5294 GB Notification: Performance of NFTyping.typeComponents: time 0.000205/0.3871, allocations: 79 kB / 0.7708 GB, free: 108 kB / 0.5294 GB Notification: Performance of NFTyping.typeBindings: time 0.0002067/0.3873, allocations: 115.1 kB / 0.7709 GB, free: 15.99 MB / 0.545 GB Notification: Performance of NFTyping.typeClassSections: time 0.0003608/0.3876, allocations: 171.5 kB / 0.771 GB, free: 15.82 MB / 0.545 GB Notification: Performance of NFFlatten.flatten: time 0.0004326/0.3881, allocations: 0.5177 MB / 0.7715 GB, free: 15.3 MB / 0.545 GB Notification: Performance of NFFlatten.resolveConnections: time 0.0001103/0.3882, allocations: 44.7 kB / 0.7716 GB, free: 15.26 MB / 0.545 GB Notification: Performance of NFEvalConstants.evaluate: time 0.0002722/0.3885, allocations: 239.1 kB / 0.7718 GB, free: 15.03 MB / 0.545 GB Notification: Performance of NFSimplifyModel.simplify: time 0.0002926/0.3888, allocations: 219.1 kB / 0.772 GB, free: 14.81 MB / 0.545 GB Notification: Performance of NFPackage.collectConstants: time 6.912e-05/0.3889, allocations: 28 kB / 0.772 GB, free: 14.79 MB / 0.545 GB Notification: Performance of NFFlatten.collectFunctions: time 0.000163/0.389, allocations: 87.83 kB / 0.7721 GB, free: 14.7 MB / 0.545 GB Notification: Performance of NFScalarize.scalarize: time 6.962e-05/0.3891, allocations: 75.72 kB / 0.7722 GB, free: 14.62 MB / 0.545 GB Notification: Performance of NFVerifyModel.verify: time 0.0001526/0.3893, allocations: 183 kB / 0.7724 GB, free: 14.45 MB / 0.545 GB Notification: Performance of NFConvertDAE.convert: time 0.0003826/0.3896, allocations: 433 kB / 0.7728 GB, free: 14.02 MB / 0.545 GB Notification: Performance of FrontEnd - DAE generated: time 2.745e-06/0.3897, allocations: 0 / 0.7728 GB, free: 14.02 MB / 0.545 GB Notification: Performance of FrontEnd: time 1.192e-06/0.3897, allocations: 3.938 kB / 0.7728 GB, free: 14.02 MB / 0.545 GB Notification: Performance of Transformations before backend: time 5.701e-06/0.3897, allocations: 0 / 0.7728 GB, free: 14.02 MB / 0.545 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.001737/0.3914, allocations: 0.8016 MB / 0.7736 GB, free: 13.15 MB / 0.545 GB Notification: Performance of prepare preOptimizeDAE: time 3.407e-05/0.3915, allocations: 12.03 kB / 0.7736 GB, free: 13.14 MB / 0.545 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 8.956e-05/0.3916, allocations: 36.47 kB / 0.7736 GB, free: 13.11 MB / 0.545 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.000368/0.3919, allocations: 343.8 kB / 0.7739 GB, free: 12.73 MB / 0.545 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 2.083e-05/0.392, allocations: 20.81 kB / 0.774 GB, free: 12.71 MB / 0.545 GB Notification: Performance of preOpt expandDerOperator (simulation): time 6.316e-05/0.392, allocations: 32.27 kB / 0.774 GB, free: 12.68 MB / 0.545 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.000714/0.3927, allocations: 329.1 kB / 0.7743 GB, free: 12.34 MB / 0.545 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.45e-05/0.3928, allocations: 0 / 0.7743 GB, free: 12.34 MB / 0.545 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 3.611e-05/0.3928, allocations: 11.94 kB / 0.7743 GB, free: 12.33 MB / 0.545 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 6.652e-06/0.3928, allocations: 4 kB / 0.7743 GB, free: 12.33 MB / 0.545 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0008446/0.3937, allocations: 298.2 kB / 0.7746 GB, free: 12.04 MB / 0.545 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0009916/0.3947, allocations: 0.7734 MB / 0.7754 GB, free: 11.21 MB / 0.545 GB Notification: Performance of preOpt comSubExp (simulation): time 0.001038/0.3957, allocations: 381.6 kB / 0.7757 GB, free: 10.82 MB / 0.545 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.000479/0.3962, allocations: 205.6 kB / 0.7759 GB, free: 10.61 MB / 0.545 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0006143/0.3968, allocations: 457.4 kB / 0.7764 GB, free: 10.07 MB / 0.545 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0006819/0.3975, allocations: 329.2 kB / 0.7767 GB, free: 9.734 MB / 0.545 GB Notification: Performance of pre-optimization done (n=42): time 1.874e-06/0.3975, allocations: 0 / 0.7767 GB, free: 9.734 MB / 0.545 GB Notification: Performance of matching and sorting (n=42): time 0.001574/0.3991, allocations: 0.609 MB / 0.7773 GB, free: 9.121 MB / 0.545 GB Notification: Performance of inlineWhenForInitialization (initialization): time 3.947e-05/0.3992, allocations: 89.09 kB / 0.7774 GB, free: 9.016 MB / 0.545 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.000268/0.3995, allocations: 304.5 kB / 0.7776 GB, free: 8.711 MB / 0.545 GB Notification: Performance of collectPreVariables (initialization): time 4.537e-05/0.3995, allocations: 33.7 kB / 0.7777 GB, free: 8.672 MB / 0.545 GB Notification: Performance of collectInitialEqns (initialization): time 0.0001056/0.3996, allocations: 168.8 kB / 0.7778 GB, free: 8.5 MB / 0.545 GB Notification: Performance of collectInitialBindings (initialization): time 0.0001091/0.3997, allocations: 142 kB / 0.778 GB, free: 8.359 MB / 0.545 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0001414/0.3999, allocations: 94 kB / 0.7781 GB, free: 8.262 MB / 0.545 GB Notification: Performance of setup shared object (initialization): time 0.0001127/0.4, allocations: 350.8 kB / 0.7784 GB, free: 7.91 MB / 0.545 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0005111/0.4005, allocations: 198.7 kB / 0.7786 GB, free: 7.711 MB / 0.545 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0005263/0.4011, allocations: 254.3 kB / 0.7788 GB, free: 7.449 MB / 0.545 GB Notification: Performance of analyzeInitialSystem (initialization): time 6.504/6.905, allocations: 0.866 GB / 1.645 GB, free: 276 MB / 0.8419 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 6.071e-06/6.905, allocations: 0 / 1.645 GB, free: 276 MB / 0.8419 GB Notification: Performance of matching and sorting (n=61) (initialization): time 0.0012/6.907, allocations: 0.6418 MB / 1.645 GB, free: 275.5 MB / 0.8419 GB Notification: Performance of prepare postOptimizeDAE: time 3.603e-05/6.907, allocations: 88.67 kB / 1.646 GB, free: 275.4 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 7.905e-06/6.907, allocations: 4 kB / 1.646 GB, free: 275.4 MB / 0.8419 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.959e-05/6.907, allocations: 5.969 kB / 1.646 GB, free: 275.4 MB / 0.8419 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.000532/6.907, allocations: 115.6 kB / 1.646 GB, free: 275.3 MB / 0.8419 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 8.917e-06/6.907, allocations: 8.125 kB / 1.646 GB, free: 275.3 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0004791/6.908, allocations: 59.28 kB / 1.646 GB, free: 275.3 MB / 0.8419 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 3.939e-05/6.908, allocations: 25.83 kB / 1.646 GB, free: 275.3 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.0002399/6.908, allocations: 193.2 kB / 1.646 GB, free: 275.1 MB / 0.8419 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 5.861e-05/6.908, allocations: 41.5 kB / 1.646 GB, free: 275.1 MB / 0.8419 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001366/6.91, allocations: 0.6343 MB / 1.647 GB, free: 274.4 MB / 0.8419 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 8.195e-06/6.91, allocations: 3.984 kB / 1.647 GB, free: 274.4 MB / 0.8419 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.474e-06/6.91, allocations: 4 kB / 1.647 GB, free: 274.4 MB / 0.8419 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001312/6.91, allocations: 163.3 kB / 1.647 GB, free: 274.3 MB / 0.8419 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 6.805e-05/6.91, allocations: 16 kB / 1.647 GB, free: 274.3 MB / 0.8419 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0004211/6.91, allocations: 35.89 kB / 1.647 GB, free: 274.2 MB / 0.8419 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001198/6.91, allocations: 59.92 kB / 1.647 GB, free: 274.2 MB / 0.8419 GB Notification: Performance of postOpt createDAEmodeBDAE (simulation): time 0.001715/6.912, allocations: 0.7595 MB / 1.648 GB, free: 273.4 MB / 0.8419 GB Notification: Performance of postOpt symbolicJacobianDAE (simulation): time 0.001517/6.914, allocations: 1.025 MB / 1.649 GB, free: 272.4 MB / 0.8419 GB Notification: Performance of postOpt setEvaluationStage (simulation): time 0.0004741/6.914, allocations: 260.6 kB / 1.649 GB, free: 272.1 MB / 0.8419 GB Notification: Performance of sorting global known variables: time 0.0001404/6.914, allocations: 211.1 kB / 1.649 GB, free: 271.9 MB / 0.8419 GB Notification: Performance of Backend: time 4.91e-07/6.914, allocations: 3.281 kB / 1.649 GB, free: 271.9 MB / 0.8419 GB Notification: Performance of simCode: created initialization part: time 0.001065/6.915, allocations: 0.5568 MB / 1.65 GB, free: 271.3 MB / 0.8419 GB Notification: Performance of SimCode: time 0.001243/6.917, allocations: 1.474 MB / 1.651 GB, free: 269.9 MB / 0.8419 GB Notification: Performance of Templates: time 0.009147/6.926, allocations: 7.165 MB / 1.658 GB, free: 262.8 MB / 0.8419 GB make -j1 -f BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.makefile (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 & ./BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex -abortSlowSimulation -alarm=480 -lv LOG_STATS > BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex.pipe 2>&1)