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.8227/0.8227, allocations: 143.4 MB / 158.3 MB, free: 5.793 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.001111/0.001112, allocations: 181 kB / 191.5 MB, free: 5.781 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.685/1.685, allocations: 223.2 MB / 447.7 MB, free: 6.578 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.001475/0.001475, allocations: 100.2 kB / 0.5188 GB, free: 2.926 MB / 410.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.001756/0.001756, allocations: 280.9 kB / 0.6005 GB, free: 49 MB / 410.7 MB Notification: Performance of FrontEnd - loaded program: time 0.0004629/0.000463, allocations: 12 kB / 0.6929 GB, free: 2.348 MB / 458.7 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.479/0.4795, allocations: 82.78 MB / 0.7737 GB, free: 26.24 MB / 458.7 MB Notification: Performance of FrontEnd - scodeFlatten: time 0.168/0.6475, allocations: 112.1 MB / 0.8832 GB, free: 9.996 MB / 0.5417 GB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0002274/0.6478, allocations: 79.84 kB / 0.8833 GB, free: 9.922 MB / 0.5417 GB Notification: Performance of FrontEnd - DAE generated: time 0.02424/0.6721, allocations: 7.834 MB / 0.8909 GB, free: 2 MB / 0.5417 GB Notification: Performance of FrontEnd: time 2.064e-06/0.6721, allocations: 0 / 0.8909 GB, free: 2 MB / 0.5417 GB Notification: Performance of Transformations before backend: time 1.227e-05/0.6721, allocations: 4 kB / 0.8909 GB, free: 1.996 MB / 0.5417 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.001728/0.6739, allocations: 0.7743 MB / 0.8917 GB, free: 1.156 MB / 0.5417 GB Notification: Performance of prepare preOptimizeDAE: time 5.052e-05/0.6739, allocations: 12.77 kB / 0.8917 GB, free: 1.145 MB / 0.5417 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0001054/0.674, allocations: 39.53 kB / 0.8917 GB, free: 1.105 MB / 0.5417 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0002946/0.6744, allocations: 255.2 kB / 0.892 GB, free: 0.8164 MB / 0.5417 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 3.869e-05/0.6744, allocations: 28.38 kB / 0.892 GB, free: 0.7891 MB / 0.5417 GB Notification: Performance of preOpt expandDerOperator (simulation): time 6.207e-05/0.6745, allocations: 31.94 kB / 0.892 GB, free: 0.7578 MB / 0.5417 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0007712/0.6752, allocations: 340.8 kB / 0.8923 GB, free: 424 kB / 0.5417 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.753e-05/0.6753, allocations: 7.938 kB / 0.8923 GB, free: 416 kB / 0.5417 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 3.995e-05/0.6753, allocations: 8 kB / 0.8924 GB, free: 408 kB / 0.5417 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 7.364e-06/0.6753, allocations: 4 kB / 0.8924 GB, free: 404 kB / 0.5417 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0008498/0.6762, allocations: 344.3 kB / 0.8927 GB, free: 60 kB / 0.5417 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001577/0.6778, allocations: 0.8984 MB / 0.8936 GB, free: 15.1 MB / 0.5573 GB Notification: Performance of preOpt comSubExp (simulation): time 0.001062/0.6789, allocations: 426.1 kB / 0.894 GB, free: 14.67 MB / 0.5573 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0007078/0.6796, allocations: 453.6 kB / 0.8944 GB, free: 14.13 MB / 0.5573 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0006943/0.6803, allocations: 348.7 kB / 0.8947 GB, free: 13.77 MB / 0.5573 GB Notification: Performance of pre-optimization done (n=42): time 2.615e-06/0.6803, allocations: 0 / 0.8947 GB, free: 13.77 MB / 0.5573 GB Notification: Performance of matching and sorting (n=42): time 0.001635/0.6819, allocations: 0.6774 MB / 0.8954 GB, free: 13.09 MB / 0.5573 GB Notification: Performance of inlineWhenForInitialization (initialization): time 6.233e-05/0.682, allocations: 85.11 kB / 0.8955 GB, free: 12.99 MB / 0.5573 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.000352/0.6824, allocations: 295.7 kB / 0.8958 GB, free: 12.7 MB / 0.5573 GB Notification: Performance of collectPreVariables (initialization): time 4.586e-05/0.6824, allocations: 41.69 kB / 0.8958 GB, free: 12.65 MB / 0.5573 GB Notification: Performance of collectInitialEqns (initialization): time 0.0001234/0.6826, allocations: 160.8 kB / 0.896 GB, free: 12.49 MB / 0.5573 GB Notification: Performance of collectInitialBindings (initialization): time 0.00013/0.6827, allocations: 149.9 kB / 0.8961 GB, free: 12.34 MB / 0.5573 GB Notification: Performance of simplifyInitialFunctions (initialization): time 2.732e-05/0.6827, allocations: 8 kB / 0.8961 GB, free: 12.33 MB / 0.5573 GB Notification: Performance of setup shared object (initialization): time 0.0001529/0.6829, allocations: 346.8 kB / 0.8964 GB, free: 11.98 MB / 0.5573 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0005101/0.6834, allocations: 233.6 kB / 0.8967 GB, free: 11.75 MB / 0.5573 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.000508/0.6839, allocations: 262.6 kB / 0.8969 GB, free: 11.47 MB / 0.5573 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.0005563/0.6845, allocations: 307.9 kB / 0.8972 GB, free: 11.16 MB / 0.5573 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 2.986e-06/0.6845, allocations: 0 / 0.8972 GB, free: 11.16 MB / 0.5573 GB Notification: Performance of matching and sorting (n=61) (initialization): time 0.001348/0.6859, allocations: 0.67 MB / 0.8979 GB, free: 10.46 MB / 0.5573 GB Notification: Performance of prepare postOptimizeDAE: time 7.872e-05/0.686, allocations: 93.09 kB / 0.8979 GB, free: 10.35 MB / 0.5573 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 9.739e-06/0.686, allocations: 4 kB / 0.898 GB, free: 10.35 MB / 0.5573 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.936e-05/0.686, allocations: 4 kB / 0.898 GB, free: 10.34 MB / 0.5573 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0006404/0.6866, allocations: 123.8 kB / 0.8981 GB, free: 10.22 MB / 0.5573 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.604e-05/0.6867, allocations: 11.94 kB / 0.8981 GB, free: 10.21 MB / 0.5573 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0006027/0.6873, allocations: 75.67 kB / 0.8982 GB, free: 10.14 MB / 0.5573 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 5.662e-05/0.6873, allocations: 19.98 kB / 0.8982 GB, free: 10.12 MB / 0.5573 GB Warning: Assuming fixed start value for the following 8 variables: battery_1C.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_C20.E_discharged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy taken from the battery" type: Real battery_C20.E_charged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy charged to the battery" type: Real battery_1C.EBou:VARIABLE(start = (1.0 - battery_1C.c) * battery_1C.SOC_start * battery_1C.E_nominal unit = "J" fixed = true ) "Bound charge of the battery" type: Real battery_1C.EAva:VARIABLE(start = battery_1C.c * battery_1C.SOC_start * battery_1C.E_nominal unit = "J" fixed = true ) "Available charge of the battery" type: Real battery_C20.EBou:VARIABLE(start = (1.0 - battery_C20.c) * battery_C20.SOC_start * battery_C20.E_nominal unit = "J" fixed = true ) "Bound charge of the battery" type: Real battery_C20.EAva:VARIABLE(start = battery_C20.c * battery_C20.SOC_start * battery_C20.E_nominal unit = "J" fixed = true ) "Available 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 ($whenCondition3,$whenCondition2,$PRE.gain.T_start,gain.T_start,$PRE.gain.count,gain.count,$PRE.load_1C.T_start,load_1C.T_start,$PRE.load_1C.count,load_1C.count,$whenCondition1,$PRE.load_C20.T_start,load_C20.T_start,$PRE.load_C20.count,load_C20.count) * 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 (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of prepare postOptimizeDAE: time 0.000359/0.6877, allocations: 203.5 kB / 0.8984 GB, free: 9.91 MB / 0.5573 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 7.226e-05/0.6878, allocations: 39.52 kB / 0.8984 GB, free: 9.871 MB / 0.5573 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001673/0.6895, allocations: 0.6813 MB / 0.8991 GB, free: 9.176 MB / 0.5573 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 8.656e-06/0.6895, allocations: 8 kB / 0.8991 GB, free: 9.168 MB / 0.5573 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 8.897e-06/0.6895, allocations: 7.984 kB / 0.8991 GB, free: 9.16 MB / 0.5573 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 1.052e-05/0.6895, allocations: 3.953 kB / 0.8991 GB, free: 9.156 MB / 0.5573 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0005608/0.6901, allocations: 476.9 kB / 0.8995 GB, free: 8.641 MB / 0.5573 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 6.903e-06/0.6901, allocations: 4 kB / 0.8995 GB, free: 8.637 MB / 0.5573 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0006532/0.6908, allocations: 115.9 kB / 0.8997 GB, free: 8.523 MB / 0.5573 GB Notification: Performance of postOpt tearingSystem (simulation): time 8.677e-06/0.6908, allocations: 4 kB / 0.8997 GB, free: 8.52 MB / 0.5573 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 4.535e-05/0.6908, allocations: 19.98 kB / 0.8997 GB, free: 8.5 MB / 0.5573 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 5.19e-06/0.6908, allocations: 4 kB / 0.8997 GB, free: 8.496 MB / 0.5573 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.893e-06/0.6909, allocations: 0 / 0.8997 GB, free: 8.496 MB / 0.5573 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001801/0.6927, allocations: 0.8761 MB / 0.9005 GB, free: 7.602 MB / 0.5573 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0002314/0.6929, allocations: 168.3 kB / 0.9007 GB, free: 7.418 MB / 0.5573 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 6.935e-05/0.693, allocations: 16 kB / 0.9007 GB, free: 7.402 MB / 0.5573 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0004657/0.6935, allocations: 43.95 kB / 0.9008 GB, free: 7.359 MB / 0.5573 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001592/0.6936, allocations: 63.86 kB / 0.9008 GB, free: 7.297 MB / 0.5573 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 4.26e-05/0.6937, allocations: 19.98 kB / 0.9008 GB, free: 7.277 MB / 0.5573 GB Notification: Performance of sorting global known variables: time 0.0002604/0.6939, allocations: 231.1 kB / 0.9011 GB, free: 7.051 MB / 0.5573 GB Notification: Performance of sort global known variables: time 2.1e-07/0.6939, allocations: 0 / 0.9011 GB, free: 7.051 MB / 0.5573 GB Notification: Performance of remove unused functions: time 0.000494/0.6944, allocations: 139.9 kB / 0.9012 GB, free: 6.914 MB / 0.5573 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 (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of Backend phase and start with SimCode phase: time 0.000297/0.6947, allocations: 162.2 kB / 0.9013 GB, free: 6.75 MB / 0.5573 GB Notification: Performance of simCode: created initialization part: time 0.001394/0.6962, allocations: 0.6791 MB / 0.902 GB, free: 6.039 MB / 0.5573 GB Notification: Performance of simCode: created event and clocks part: time 2.915e-06/0.6962, allocations: 0 / 0.902 GB, free: 6.039 MB / 0.5573 GB Notification: Performance of simCode: created simulation system equations: time 0.0006074/0.6968, allocations: 287.7 kB / 0.9023 GB, free: 5.758 MB / 0.5573 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0003878/0.6972, allocations: 55.3 kB / 0.9023 GB, free: 5.703 MB / 0.5573 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.002067/0.6993, allocations: 1.31 MB / 0.9036 GB, free: 4.363 MB / 0.5573 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0003647/0.6996, allocations: 0.8093 MB / 0.9044 GB, free: 3.523 MB / 0.5573 GB Notification: Performance of simCode: alias equations: time 0.0003739/0.7, allocations: 71.41 kB / 0.9045 GB, free: 3.453 MB / 0.5573 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001811/0.7002, allocations: 43.42 kB / 0.9045 GB, free: 3.414 MB / 0.5573 GB Notification: Performance of SimCode: time 2.074e-06/0.7002, allocations: 0 / 0.9045 GB, free: 3.414 MB / 0.5573 GB Notification: Performance of Templates: time 0.4106/1.111, allocations: 5.873 MB / 0.9103 GB, free: 126.8 MB / 0.5573 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)