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/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: 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/BuildingSystems 2.0.0-master/package.mo): time 0.8526/0.8526, allocations: 143.4 MB / 159.2 MB, free: 4.902 MB / 122.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001206/0.001206, allocations: 184.5 kB / 191.9 MB, free: 5.723 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.361/1.361, allocations: 222.9 MB / 447.3 MB, free: 5.879 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.00109/0.00109, allocations: 95.78 kB / 0.517 GB, free: 3.746 MB / 410.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.001869/0.001869, allocations: 282 kB / 0.5973 GB, free: 49.38 MB / 410.7 MB Notification: Performance of FrontEnd - loaded program: time 0.001558/0.001558, allocations: 75.89 kB / 0.6885 GB, free: 3.859 MB / 458.7 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.3701/0.3717, allocations: 81.3 MB / 0.7679 GB, free: 27.67 MB / 458.7 MB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatteryComplex): time 0.00331/0.375, allocations: 2.681 MB / 0.7705 GB, free: 24.97 MB / 458.7 MB Notification: Performance of NFInst.instExpressions: time 0.001561/0.3766, allocations: 1.091 MB / 0.7716 GB, free: 23.88 MB / 458.7 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0001226/0.3768, allocations: 15.94 kB / 0.7716 GB, free: 23.86 MB / 458.7 MB Notification: Performance of NFTyping.typeComponents: time 0.0002346/0.377, allocations: 66.2 kB / 0.7717 GB, free: 23.8 MB / 458.7 MB Notification: Performance of NFTyping.typeBindings: time 0.0001918/0.3772, allocations: 99.23 kB / 0.7718 GB, free: 23.7 MB / 458.7 MB Notification: Performance of NFTyping.typeClassSections: time 0.0003289/0.3775, allocations: 155.8 kB / 0.7719 GB, free: 23.55 MB / 458.7 MB Notification: Performance of NFFlatten.flatten: time 0.0003051/0.3779, allocations: 490.2 kB / 0.7724 GB, free: 23.07 MB / 458.7 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0001175/0.378, allocations: 40.73 kB / 0.7724 GB, free: 23.03 MB / 458.7 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0002249/0.3782, allocations: 222.9 kB / 0.7726 GB, free: 22.81 MB / 458.7 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0002335/0.3785, allocations: 207.1 kB / 0.7728 GB, free: 22.61 MB / 458.7 MB Notification: Performance of NFPackage.collectConstants: time 4.944e-05/0.3785, allocations: 16 kB / 0.7728 GB, free: 22.59 MB / 458.7 MB Notification: Performance of NFFlatten.collectFunctions: time 0.000143/0.3787, allocations: 71.94 kB / 0.7729 GB, free: 22.52 MB / 458.7 MB Notification: Performance of NFScalarize.scalarize: time 6.556e-05/0.3787, allocations: 71.66 kB / 0.773 GB, free: 22.45 MB / 458.7 MB Notification: Performance of NFVerifyModel.verify: time 0.0001508/0.3789, allocations: 167 kB / 0.7731 GB, free: 22.29 MB / 458.7 MB Notification: Performance of NFConvertDAE.convert: time 0.0003083/0.3792, allocations: 398.5 kB / 0.7735 GB, free: 21.89 MB / 458.7 MB Notification: Performance of FrontEnd - DAE generated: time 5.029e-06/0.3792, allocations: 0 / 0.7735 GB, free: 21.89 MB / 458.7 MB Notification: Performance of FrontEnd: time 1.232e-06/0.3792, allocations: 0 / 0.7735 GB, free: 21.89 MB / 458.7 MB Notification: Performance of Transformations before backend: time 7.064e-06/0.3793, allocations: 0 / 0.7735 GB, free: 21.89 MB / 458.7 MB 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.001569/0.3808, allocations: 0.8095 MB / 0.7743 GB, free: 21.02 MB / 458.7 MB Notification: Performance of prepare preOptimizeDAE: time 3.833e-05/0.3809, allocations: 8.031 kB / 0.7743 GB, free: 21.01 MB / 458.7 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 8.968e-05/0.381, allocations: 40.47 kB / 0.7744 GB, free: 20.97 MB / 458.7 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0003777/0.3814, allocations: 347.8 kB / 0.7747 GB, free: 20.59 MB / 458.7 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 2.096e-05/0.3814, allocations: 20.8 kB / 0.7747 GB, free: 20.57 MB / 458.7 MB Notification: Performance of preOpt expandDerOperator (simulation): time 6.197e-05/0.3815, allocations: 24.38 kB / 0.7747 GB, free: 20.55 MB / 458.7 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0006243/0.3821, allocations: 329 kB / 0.775 GB, free: 20.22 MB / 458.7 MB Notification: Performance of preOpt findStateOrder (simulation): time 1.841e-05/0.3821, allocations: 3.906 kB / 0.7751 GB, free: 20.21 MB / 458.7 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 3.17e-05/0.3822, allocations: 12 kB / 0.7751 GB, free: 20.2 MB / 458.7 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 6.352e-06/0.3822, allocations: 8 kB / 0.7751 GB, free: 20.2 MB / 458.7 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0007895/0.383, allocations: 291.7 kB / 0.7753 GB, free: 19.91 MB / 458.7 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.000932/0.3839, allocations: 0.7773 MB / 0.7761 GB, free: 19.08 MB / 458.7 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0009312/0.3848, allocations: 389.5 kB / 0.7765 GB, free: 18.68 MB / 458.7 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0004103/0.3853, allocations: 209.6 kB / 0.7767 GB, free: 18.47 MB / 458.7 MB Notification: Performance of preOpt evalFunc (simulation): time 0.0005152/0.3858, allocations: 457.4 kB / 0.7771 GB, free: 17.93 MB / 458.7 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0006453/0.3864, allocations: 328.5 kB / 0.7774 GB, free: 17.59 MB / 458.7 MB Notification: Performance of pre-optimization done (n=42): time 1.864e-06/0.3865, allocations: 0 / 0.7774 GB, free: 17.59 MB / 458.7 MB Notification: Performance of matching and sorting (n=42): time 0.001438/0.3879, allocations: 0.6078 MB / 0.778 GB, free: 16.98 MB / 458.7 MB Notification: Performance of inlineWhenForInitialization (initialization): time 3.734e-05/0.388, allocations: 85.11 kB / 0.7781 GB, free: 16.88 MB / 458.7 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0002325/0.3882, allocations: 308.5 kB / 0.7784 GB, free: 16.57 MB / 458.7 MB Notification: Performance of collectPreVariables (initialization): time 3.12e-05/0.3882, allocations: 37.7 kB / 0.7784 GB, free: 16.52 MB / 458.7 MB Notification: Performance of collectInitialEqns (initialization): time 7.708e-05/0.3883, allocations: 152.9 kB / 0.7786 GB, free: 16.37 MB / 458.7 MB Notification: Performance of collectInitialBindings (initialization): time 8.606e-05/0.3884, allocations: 145.9 kB / 0.7787 GB, free: 16.23 MB / 458.7 MB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0001319/0.3885, allocations: 98 kB / 0.7788 GB, free: 16.12 MB / 458.7 MB Notification: Performance of setup shared object (initialization): time 6.48e-05/0.3886, allocations: 350.8 kB / 0.7791 GB, free: 15.77 MB / 458.7 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0004446/0.3891, allocations: 207.5 kB / 0.7793 GB, free: 15.57 MB / 458.7 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0004507/0.3895, allocations: 238.4 kB / 0.7796 GB, free: 15.32 MB / 458.7 MB Notification: Performance of analyzeInitialSystem (initialization): time 6.517/6.906, allocations: 0.866 GB / 1.646 GB, free: 9.125 MB / 0.6667 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 8.526e-06/6.907, allocations: 3.719 kB / 1.646 GB, free: 9.125 MB / 0.6667 GB Notification: Performance of matching and sorting (n=61) (initialization): time 0.001323/6.908, allocations: 0.6382 MB / 1.646 GB, free: 8.605 MB / 0.6667 GB Notification: Performance of prepare postOptimizeDAE: time 5.2e-05/6.908, allocations: 90.81 kB / 1.646 GB, free: 8.5 MB / 0.6667 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 9.438e-06/6.908, allocations: 0 / 1.646 GB, free: 8.5 MB / 0.6667 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.217e-05/6.908, allocations: 4 kB / 1.646 GB, free: 8.496 MB / 0.6667 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.000507/6.908, allocations: 115.8 kB / 1.646 GB, free: 8.383 MB / 0.6667 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.212e-05/6.908, allocations: 4 kB / 1.646 GB, free: 8.379 MB / 0.6667 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0004555/6.909, allocations: 65.47 kB / 1.647 GB, free: 8.336 MB / 0.6667 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 4.503e-05/6.909, allocations: 27.03 kB / 1.647 GB, free: 8.312 MB / 0.6667 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.6850000000000001 * 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.6850000000000001 * 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.0003108/6.909, allocations: 209.2 kB / 1.647 GB, free: 8.117 MB / 0.6667 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 6.296e-05/6.909, allocations: 34.12 kB / 1.647 GB, free: 8.102 MB / 0.6667 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001453/6.911, allocations: 0.6326 MB / 1.647 GB, free: 7.473 MB / 0.6667 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 7.143e-06/6.911, allocations: 8 kB / 1.647 GB, free: 7.465 MB / 0.6667 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 6.192e-06/6.911, allocations: 3.938 kB / 1.647 GB, free: 7.461 MB / 0.6667 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 7.824e-06/6.911, allocations: 3.984 kB / 1.647 GB, free: 7.457 MB / 0.6667 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0003554/6.911, allocations: 438 kB / 1.648 GB, free: 7.008 MB / 0.6667 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.395e-06/6.911, allocations: 1.594 kB / 1.648 GB, free: 7.008 MB / 0.6667 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0005184/6.912, allocations: 108.7 kB / 1.648 GB, free: 6.902 MB / 0.6667 GB Notification: Performance of postOpt tearingSystem (simulation): time 4.018e-06/6.912, allocations: 4 kB / 1.648 GB, free: 6.898 MB / 0.6667 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 3.76e-05/6.912, allocations: 19.98 kB / 1.648 GB, free: 6.879 MB / 0.6667 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 3.366e-06/6.912, allocations: 4 kB / 1.648 GB, free: 6.875 MB / 0.6667 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.384e-06/6.912, allocations: 3.938 kB / 1.648 GB, free: 6.871 MB / 0.6667 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 1.337/8.249, allocations: 169.7 MB / 1.814 GB, free: 93.79 MB / 0.6667 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001576/8.249, allocations: 163.8 kB / 1.814 GB, free: 93.61 MB / 0.6667 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 5.448e-05/8.249, allocations: 16 kB / 1.814 GB, free: 93.6 MB / 0.6667 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0003832/8.249, allocations: 35.95 kB / 1.814 GB, free: 93.56 MB / 0.6667 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001422/8.25, allocations: 55.92 kB / 1.814 GB, free: 93.51 MB / 0.6667 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 3.576e-05/8.25, allocations: 19.98 kB / 1.814 GB, free: 93.49 MB / 0.6667 GB Notification: Performance of sorting global known variables: time 0.0001639/8.25, allocations: 211.1 kB / 1.814 GB, free: 93.28 MB / 0.6667 GB Notification: Performance of sort global known variables: time 1.4e-07/8.25, allocations: 0 / 1.814 GB, free: 93.28 MB / 0.6667 GB Notification: Performance of remove unused functions: time 0.001215/8.251, allocations: 427.9 kB / 1.815 GB, free: 92.87 MB / 0.6667 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.0001825/8.251, allocations: 133.7 kB / 1.815 GB, free: 92.73 MB / 0.6667 GB Notification: Performance of simCode: created initialization part: time 0.00106/8.252, allocations: 0.6449 MB / 1.815 GB, free: 92.06 MB / 0.6667 GB Notification: Performance of simCode: created event and clocks part: time 1.854e-06/8.252, allocations: 1.031 kB / 1.815 GB, free: 92.06 MB / 0.6667 GB Notification: Performance of simCode: created simulation system equations: time 0.0004917/8.253, allocations: 263.9 kB / 1.816 GB, free: 91.8 MB / 0.6667 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0004081/8.253, allocations: 80.05 kB / 1.816 GB, free: 91.73 MB / 0.6667 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.002864/8.256, allocations: 1.627 MB / 1.817 GB, free: 90.06 MB / 0.6667 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0002391/8.256, allocations: 0.8132 MB / 1.818 GB, free: 89.22 MB / 0.6667 GB Notification: Performance of simCode: alias equations: time 0.004246/8.261, allocations: 0.5094 MB / 1.819 GB, free: 88.72 MB / 0.6667 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.002036/8.263, allocations: 139.2 kB / 1.819 GB, free: 88.58 MB / 0.6667 GB Notification: Performance of SimCode: time 3.2e-07/8.263, allocations: 0 / 1.819 GB, free: 88.58 MB / 0.6667 GB Notification: Performance of Templates: time 0.07227/8.335, allocations: 64.37 MB / 1.882 GB, free: 23.98 MB / 0.6667 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)