Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.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.BatterySimple,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple") translateModel(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple,tolerance=1e-06,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple") Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001321/0.001321, allocations: 107.4 kB / 16.41 MB, free: 5.977 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.001268/0.001268, allocations: 188.3 kB / 17.34 MB, free: 5.586 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.255/1.255, allocations: 222.9 MB / 241 MB, free: 15.09 MB / 206.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.001995/0.001995, allocations: 291 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.8942/0.8942, allocations: 169.2 MB / 0.499 GB, free: 4.438 MB / 382.1 MB Notification: Performance of FrontEnd - loaded program: time 0.001697/0.001697, allocations: 95.84 kB / 0.6821 GB, free: 6.988 MB / 494.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.4412/0.4429, allocations: 86.98 MB / 0.767 GB, free: 3.777 MB / 0.5294 GB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple): time 0.002623/0.4455, allocations: 1.95 MB / 0.7689 GB, free: 1.812 MB / 0.5294 GB Notification: Performance of NFInst.instExpressions: time 0.00119/0.4467, allocations: 0.8621 MB / 0.7698 GB, free: 0.9414 MB / 0.5294 GB Notification: Performance of NFInst.updateImplicitVariability: time 7.404e-05/0.4468, allocations: 0 / 0.7698 GB, free: 0.9414 MB / 0.5294 GB Notification: Performance of NFTyping.typeComponents: time 0.0002022/0.447, allocations: 55.61 kB / 0.7698 GB, free: 0.8867 MB / 0.5294 GB Notification: Performance of NFTyping.typeBindings: time 8.76e-05/0.4471, allocations: 47.56 kB / 0.7699 GB, free: 0.8398 MB / 0.5294 GB Notification: Performance of NFTyping.typeClassSections: time 0.000249/0.4474, allocations: 91.77 kB / 0.7699 GB, free: 0.75 MB / 0.5294 GB Notification: Performance of NFFlatten.flatten: time 0.000189/0.4476, allocations: 195.2 kB / 0.7701 GB, free: 0.5586 MB / 0.5294 GB Notification: Performance of NFFlatten.resolveConnections: time 8.693e-05/0.4477, allocations: 25.2 kB / 0.7701 GB, free: 0.5391 MB / 0.5294 GB Notification: Performance of NFEvalConstants.evaluate: time 0.0001327/0.4478, allocations: 83.64 kB / 0.7702 GB, free: 468 kB / 0.5294 GB Notification: Performance of NFSimplifyModel.simplify: time 0.0001194/0.448, allocations: 91.59 kB / 0.7703 GB, free: 376 kB / 0.5294 GB Notification: Performance of NFPackage.collectConstants: time 2.519e-05/0.448, allocations: 12 kB / 0.7703 GB, free: 364 kB / 0.5294 GB Notification: Performance of NFFlatten.collectFunctions: time 0.0001071/0.4481, allocations: 55.95 kB / 0.7704 GB, free: 308 kB / 0.5294 GB Notification: Performance of NFScalarize.scalarize: time 3.583e-05/0.4481, allocations: 31.84 kB / 0.7704 GB, free: 276 kB / 0.5294 GB Notification: Performance of NFVerifyModel.verify: time 7.742e-05/0.4482, allocations: 67.66 kB / 0.7705 GB, free: 208 kB / 0.5294 GB Notification: Performance of NFConvertDAE.convert: time 0.0002185/0.4484, allocations: 189.9 kB / 0.7707 GB, free: 20 kB / 0.5294 GB Notification: Performance of FrontEnd - DAE generated: time 3.978e-06/0.4485, allocations: 0 / 0.7707 GB, free: 20 kB / 0.5294 GB Notification: Performance of FrontEnd: time 1.392e-06/0.4485, allocations: 0 / 0.7707 GB, free: 20 kB / 0.5294 GB Notification: Performance of Transformations before backend: time 5.54e-06/0.4485, allocations: 0 / 0.7707 GB, free: 20 kB / 0.5294 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 19 * Number of variables: 19 Notification: Performance of Generate backend data structure: time 0.0008714/0.4493, allocations: 0.4964 MB / 0.7711 GB, free: 15.47 MB / 0.545 GB Notification: Performance of prepare preOptimizeDAE: time 3.256e-05/0.4494, allocations: 12.03 kB / 0.7712 GB, free: 15.46 MB / 0.545 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 5.165e-05/0.4494, allocations: 16.75 kB / 0.7712 GB, free: 15.44 MB / 0.545 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0002386/0.4497, allocations: 247.8 kB / 0.7714 GB, free: 15.16 MB / 0.545 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.382e-05/0.4497, allocations: 4.375 kB / 0.7714 GB, free: 15.16 MB / 0.545 GB Notification: Performance of preOpt expandDerOperator (simulation): time 3.33e-05/0.4497, allocations: 16.31 kB / 0.7714 GB, free: 15.14 MB / 0.545 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.000279/0.45, allocations: 129.9 kB / 0.7715 GB, free: 15.01 MB / 0.545 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.139e-05/0.4501, allocations: 0 / 0.7715 GB, free: 15.01 MB / 0.545 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.617e-05/0.4501, allocations: 0 / 0.7715 GB, free: 15.01 MB / 0.545 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 6.011e-06/0.4501, allocations: 4 kB / 0.7716 GB, free: 15 MB / 0.545 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0002856/0.4504, allocations: 103.8 kB / 0.7717 GB, free: 14.9 MB / 0.545 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0005949/0.451, allocations: 416.5 kB / 0.772 GB, free: 14.45 MB / 0.545 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0003054/0.4513, allocations: 134.4 kB / 0.7722 GB, free: 14.3 MB / 0.545 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0001626/0.4515, allocations: 76.81 kB / 0.7723 GB, free: 14.23 MB / 0.545 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0005774/0.4521, allocations: 449.5 kB / 0.7727 GB, free: 13.7 MB / 0.545 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0003002/0.4524, allocations: 130.3 kB / 0.7728 GB, free: 13.56 MB / 0.545 GB Notification: Performance of pre-optimization done (n=16): time 1.523e-06/0.4524, allocations: 0 / 0.7728 GB, free: 13.56 MB / 0.545 GB Notification: Performance of matching and sorting (n=16): time 0.0005786/0.453, allocations: 229.6 kB / 0.773 GB, free: 13.33 MB / 0.545 GB Notification: Performance of inlineWhenForInitialization (initialization): time 3.744e-05/0.453, allocations: 55.41 kB / 0.7731 GB, free: 13.26 MB / 0.545 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0001429/0.4532, allocations: 178.5 kB / 0.7732 GB, free: 13.08 MB / 0.545 GB Notification: Performance of collectPreVariables (initialization): time 2.502e-05/0.4532, allocations: 29.7 kB / 0.7733 GB, free: 13.04 MB / 0.545 GB Notification: Performance of collectInitialEqns (initialization): time 7.108e-05/0.4533, allocations: 116 kB / 0.7734 GB, free: 12.93 MB / 0.545 GB Notification: Performance of collectInitialBindings (initialization): time 4.801e-05/0.4533, allocations: 59.19 kB / 0.7734 GB, free: 12.87 MB / 0.545 GB Notification: Performance of simplifyInitialFunctions (initialization): time 6.663e-05/0.4534, allocations: 41.69 kB / 0.7735 GB, free: 12.82 MB / 0.545 GB Notification: Performance of setup shared object (initialization): time 0.0001113/0.4535, allocations: 330.8 kB / 0.7738 GB, free: 12.49 MB / 0.545 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0001766/0.4537, allocations: 72.8 kB / 0.7739 GB, free: 12.41 MB / 0.545 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.000177/0.4539, allocations: 90.53 kB / 0.774 GB, free: 12.32 MB / 0.545 GB Notification: Performance of analyzeInitialSystem (initialization): time 2.243/2.697, allocations: 378.8 MB / 1.144 GB, free: 9.184 MB / 0.7169 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 3.377e-06/2.697, allocations: 0 / 1.144 GB, free: 9.184 MB / 0.7169 GB Notification: Performance of matching and sorting (n=23) (initialization): time 0.0004297/2.698, allocations: 256.7 kB / 1.144 GB, free: 8.992 MB / 0.7169 GB Notification: Performance of prepare postOptimizeDAE: time 2.547e-05/2.698, allocations: 37.27 kB / 1.144 GB, free: 8.953 MB / 0.7169 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 5.51e-06/2.698, allocations: 0 / 1.144 GB, free: 8.953 MB / 0.7169 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.452e-05/2.698, allocations: 4 kB / 1.144 GB, free: 8.949 MB / 0.7169 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0002103/2.698, allocations: 39.66 kB / 1.144 GB, free: 8.914 MB / 0.7169 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 6.622e-06/2.698, allocations: 9.75 kB / 1.144 GB, free: 8.91 MB / 0.7169 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0001622/2.698, allocations: 22.69 kB / 1.144 GB, free: 8.895 MB / 0.7169 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 1.68e-05/2.698, allocations: 7.562 kB / 1.144 GB, free: 8.891 MB / 0.7169 GB Warning: Assuming fixed start value for the following 4 variables: battery.E_charged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy charged to the battery" type: Real battery.E_discharged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy taken from the battery" type: Real battery.EAva:VARIABLE(start = 0.315 * battery.SOC_start * battery.E_nominal unit = "J" fixed = true ) "Available charge of the battery" type: Real battery.EBou:VARIABLE(start = 0.685 * battery.SOC_start * battery.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: 3 * Number of states: 0 () * Number of discrete variables: 5 ($PRE.gain.count,$PRE.gain.T_start,gain.count,gain.T_start,$whenCondition1) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (22): * Single equations (assignments): 21 * Array equations: 0 * Algorithm blocks: 1 * 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.0001532/2.698, allocations: 145.5 kB / 1.144 GB, free: 8.754 MB / 0.7169 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 2.722e-05/2.698, allocations: 18.88 kB / 1.144 GB, free: 8.742 MB / 0.7169 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0004763/2.699, allocations: 236.9 kB / 1.145 GB, free: 8.566 MB / 0.7169 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 3.417e-06/2.699, allocations: 4 kB / 1.145 GB, free: 8.562 MB / 0.7169 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 3.707e-06/2.699, allocations: 3.844 kB / 1.145 GB, free: 8.562 MB / 0.7169 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 3.446e-06/2.699, allocations: 0 / 1.145 GB, free: 8.562 MB / 0.7169 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0001499/2.699, allocations: 260.3 kB / 1.145 GB, free: 8.301 MB / 0.7169 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 1.272e-06/2.699, allocations: 0 / 1.145 GB, free: 8.301 MB / 0.7169 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0002178/2.699, allocations: 48.41 kB / 1.145 GB, free: 8.258 MB / 0.7169 GB Notification: Performance of postOpt tearingSystem (simulation): time 2.224e-06/2.699, allocations: 0 / 1.145 GB, free: 8.258 MB / 0.7169 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 1.79e-05/2.699, allocations: 7.062 kB / 1.145 GB, free: 8.254 MB / 0.7169 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 1.633e-06/2.699, allocations: 0 / 1.145 GB, free: 8.254 MB / 0.7169 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.382e-06/2.699, allocations: 0 / 1.145 GB, free: 8.254 MB / 0.7169 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0005141/2.7, allocations: 314.4 kB / 1.145 GB, free: 7.953 MB / 0.7169 GB Notification: Performance of postOpt removeConstants (simulation): time 6.39e-05/2.7, allocations: 111.1 kB / 1.145 GB, free: 7.832 MB / 0.7169 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 2.899e-05/2.7, allocations: 8 kB / 1.145 GB, free: 7.824 MB / 0.7169 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001469/2.7, allocations: 7.984 kB / 1.145 GB, free: 7.816 MB / 0.7169 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 6.045e-05/2.7, allocations: 15.98 kB / 1.145 GB, free: 7.801 MB / 0.7169 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 1.331e-05/2.7, allocations: 8.859 kB / 1.145 GB, free: 7.793 MB / 0.7169 GB Notification: Performance of sorting global known variables: time 6.879e-05/2.7, allocations: 134.2 kB / 1.145 GB, free: 7.664 MB / 0.7169 GB Notification: Performance of sort global known variables: time 1.082e-06/2.7, allocations: 2.906 kB / 1.145 GB, free: 7.664 MB / 0.7169 GB Notification: Performance of remove unused functions: time 0.0002482/2.7, allocations: 67.28 kB / 1.146 GB, free: 7.605 MB / 0.7169 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 1 * Number of states: 4 (battery.EAva,battery.EBou,battery.E_charged,battery.E_discharged) * Number of discrete variables: 3 ($whenCondition1,gain.T_start,gain.count) * Number of discrete states: 1 (gain.count) * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (20): * Single equations (assignments): 18 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 2 * 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.0001238/2.701, allocations: 125.2 kB / 1.146 GB, free: 7.48 MB / 0.7169 GB Notification: Performance of simCode: created initialization part: time 0.0003851/2.701, allocations: 225.8 kB / 1.146 GB, free: 7.25 MB / 0.7169 GB Notification: Performance of simCode: created event and clocks part: time 1.953e-06/2.701, allocations: 0 / 1.146 GB, free: 7.25 MB / 0.7169 GB Notification: Performance of simCode: created simulation system equations: time 0.0001582/2.701, allocations: 87.89 kB / 1.146 GB, free: 7.164 MB / 0.7169 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002434/2.701, allocations: 38.31 kB / 1.146 GB, free: 7.133 MB / 0.7169 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.0007008/2.702, allocations: 0.554 MB / 1.147 GB, free: 6.566 MB / 0.7169 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001077/2.702, allocations: 0.7242 MB / 1.147 GB, free: 5.816 MB / 0.7169 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 6.633e-05/2.702, allocations: 27.42 kB / 1.147 GB, free: 5.789 MB / 0.7169 GB Notification: Performance of SimCode: time 2.1e-07/2.702, allocations: 4 kB / 1.147 GB, free: 5.785 MB / 0.7169 GB Notification: Performance of Templates: time 0.003489/2.706, allocations: 2.679 MB / 1.15 GB, free: 3.129 MB / 0.7169 GB make -j1 -f BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.makefile (rm -f BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe ; mkfifo BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe ; head -c 1048576 < BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe >> ../files/BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.sim & ./BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple -abortSlowSimulation -alarm=480 -lv LOG_STATS > BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe 2>&1)