Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling.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 3.2.3+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ElectricalEnergyStorage 3.2.2-master/package.mo", uses=false) Using package ElectricalEnergyStorage with version 3.2.2 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ElectricalEnergyStorage 3.2.2-master/package.mo) Using package Modelica with version 3.2.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+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(ElectricalEnergyStorage.Examples.AdvancedStackCycling,tolerance=1e-06,outputFormat="empty",numberOfIntervals=40000,variableFilter="",fileNamePrefix="ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling") translateModel(ElectricalEnergyStorage.Examples.AdvancedStackCycling,tolerance=1e-06,outputFormat="empty",numberOfIntervals=40000,variableFilter="",fileNamePrefix="ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling") Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001438/0.001438, allocations: 115.2 kB / 16.42 MB, free: 6.508 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.001616/0.001616, allocations: 188.2 kB / 17.35 MB, free: 5.758 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo): time 1.268/1.268, allocations: 205.1 MB / 223.2 MB, free: 12.24 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ElectricalEnergyStorage 3.2.2-master/package.mo): time 0.04433/0.04433, allocations: 7.045 MB / 277.6 MB, free: 4.961 MB / 222.1 MB Notification: Modelica requested package Complex of version 3.2.3. Complex 4.0.0 is used instead which states that it is fully compatible without conversion script needed. Notification: Modelica requested package ModelicaServices of version 3.2.3. ModelicaServices 4.0.0 is used instead which states that it is fully compatible without conversion script needed. Notification: ElectricalEnergyStorage requested package Modelica of version 3.2.2. Modelica 3.2.3 is used instead which states that it is fully compatible without conversion script needed. Notification: Performance of FrontEnd - loaded program: time 0.001434/0.001434, allocations: 71.89 kB / 386 MB, free: 48.12 MB / 318.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.06558/0.06702, allocations: 48.1 MB / 434.1 MB, free: 9.434 MB / 318.1 MB [/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/Blocks/Math.mo:543:5-544:48:writable] Warning: Parameter cycler.vOut.gain.k has no value, and is fixed during initialization (fixed=true), using available start value (start=1) as default value. [/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/Blocks/Math.mo:543:5-544:48:writable] Warning: Parameter cycler.iOut.gain.k has no value, and is fixed during initialization (fixed=true), using available start value (start=1) as default value. [/home/hudson/saved_omc/libraries/.openmodelica/libraries/ElectricalEnergyStorage 3.2.2-master/package.mo:595:11-595:138:writable] Warning: Parameter batteryStack.SOCini has no value, and is fixed during initialization (fixed=true), using available start value (start=fill(0.5, ns, np)) as default value. Notification: Performance of NFInst.instantiate(ElectricalEnergyStorage.Examples.AdvancedStackCycling): time 0.009397/0.07645, allocations: 10.65 MB / 444.7 MB, free: 14.73 MB / 334.1 MB Notification: Performance of NFInst.instExpressions: time 0.007821/0.08429, allocations: 5.791 MB / 450.5 MB, free: 8.914 MB / 334.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.001056/0.08536, allocations: 59.81 kB / 450.6 MB, free: 8.855 MB / 334.1 MB Notification: Performance of NFTyping.typeComponents: time 0.002623/0.088, allocations: 1.473 MB / 452 MB, free: 7.375 MB / 334.1 MB [/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/Utilities/Strings.mo:139:3-175:14:writable] Warning: Pure function 'Modelica.Utilities.Strings.isEmpty' contains a call to impure function 'Modelica.Utilities.Strings.Advanced.skipWhiteSpace'. Notification: Performance of NFTyping.typeBindings: time 0.001191/0.0892, allocations: 0.6357 MB / 452.7 MB, free: 6.734 MB / 334.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.00163/0.09084, allocations: 1.21 MB / 453.9 MB, free: 5.523 MB / 334.1 MB Notification: Performance of NFFlatten.flatten: time 0.008417/0.09927, allocations: 10.66 MB / 464.5 MB, free: 10.84 MB / 350.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.007542/0.1068, allocations: 7.482 MB / 472 MB, free: 3.258 MB / 350.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.003456/0.1103, allocations: 3.732 MB / 475.8 MB, free: 15.52 MB / 366.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.003344/0.1137, allocations: 3.674 MB / 479.4 MB, free: 11.83 MB / 366.1 MB Notification: Performance of NFPackage.collectConstants: time 0.001503/0.1152, allocations: 1.281 MB / 480.7 MB, free: 10.55 MB / 366.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.00164/0.1168, allocations: 1.324 MB / 482 MB, free: 9.223 MB / 366.1 MB Notification: Performance of NFScalarize.scalarize: time 0.00195/0.1188, allocations: 2.529 MB / 484.6 MB, free: 6.688 MB / 366.1 MB Notification: Performance of NFVerifyModel.verify: time 0.004507/0.1233, allocations: 4.677 MB / 489.2 MB, free: 1.992 MB / 366.1 MB Notification: Performance of NFConvertDAE.convert: time 0.01339/0.1367, allocations: 17.52 MB / 0.4949 GB, free: 444 kB / 382.1 MB Notification: Performance of FrontEnd - DAE generated: time 5.831e-06/0.1367, allocations: 0 / 0.4949 GB, free: 444 kB / 382.1 MB Notification: Performance of FrontEnd: time 2.234e-06/0.1367, allocations: 4 kB / 0.4949 GB, free: 440 kB / 382.1 MB Notification: Performance of Transformations before backend: time 0.0002709/0.137, allocations: 0 / 0.4949 GB, free: 440 kB / 382.1 MB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 1082 * Number of variables: 1082 Notification: Performance of Generate backend data structure: time 0.01702/0.154, allocations: 9.209 MB / 0.5039 GB, free: 7.129 MB / 398.1 MB Notification: Performance of prepare preOptimizeDAE: time 4.102e-05/0.1541, allocations: 8.031 kB / 0.5039 GB, free: 7.121 MB / 398.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.001282/0.1554, allocations: 0.734 MB / 0.5046 GB, free: 6.379 MB / 398.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.01341/0.1688, allocations: 8.484 MB / 0.5129 GB, free: 13.82 MB / 414.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0002602/0.1691, allocations: 360.7 kB / 0.5132 GB, free: 13.46 MB / 414.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0007302/0.1698, allocations: 439.9 kB / 0.5137 GB, free: 13.04 MB / 414.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.01174/0.1816, allocations: 7.582 MB / 0.5211 GB, free: 5.234 MB / 414.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 7.393e-05/0.1816, allocations: 7.938 kB / 0.5211 GB, free: 5.227 MB / 414.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 0.0005145/0.1822, allocations: 176 kB / 0.5212 GB, free: 5.055 MB / 414.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 0.0001209/0.1823, allocations: 152.1 kB / 0.5214 GB, free: 4.902 MB / 414.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.1775/0.3598, allocations: 6.509 MB / 0.5277 GB, free: 79.88 MB / 414.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.03857/0.3984, allocations: 31.12 MB / 0.5581 GB, free: 60.43 MB / 414.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.005531/0.404, allocations: 8.373 MB / 0.5663 GB, free: 52.71 MB / 414.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.003059/0.4071, allocations: 2.48 MB / 0.5687 GB, free: 50.23 MB / 414.1 MB Notification: Performance of preOpt evalFunc (simulation): time 9.58e-05/0.4072, allocations: 33.83 kB / 0.5688 GB, free: 50.2 MB / 414.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.002468/0.4097, allocations: 2.164 MB / 0.5709 GB, free: 48 MB / 414.1 MB Notification: Performance of pre-optimization done (n=203): time 3.707e-06/0.4097, allocations: 4 kB / 0.5709 GB, free: 48 MB / 414.1 MB Notification: Performance of matching and sorting (n=203): time 0.0102/0.4199, allocations: 6.516 MB / 0.5772 GB, free: 41.45 MB / 414.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 7.147e-05/0.42, allocations: 389.8 kB / 0.5776 GB, free: 40.99 MB / 414.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.01139/0.4314, allocations: 10.83 MB / 0.5882 GB, free: 30.13 MB / 414.1 MB Notification: Performance of collectPreVariables (initialization): time 0.0002578/0.4317, allocations: 73.7 kB / 0.5883 GB, free: 30.05 MB / 414.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.002531/0.4342, allocations: 3.052 MB / 0.5912 GB, free: 27 MB / 414.1 MB Notification: Performance of collectInitialBindings (initialization): time 0.000509/0.4347, allocations: 0.6996 MB / 0.5919 GB, free: 26.31 MB / 414.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0008375/0.4356, allocations: 0.5631 MB / 0.5925 GB, free: 25.74 MB / 414.1 MB Notification: Performance of setup shared object (initialization): time 3.212e-05/0.4356, allocations: 305.1 kB / 0.5928 GB, free: 25.44 MB / 414.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.002385/0.438, allocations: 1.981 MB / 0.5947 GB, free: 23.46 MB / 414.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.002657/0.4407, allocations: 2.773 MB / 0.5974 GB, free: 20.39 MB / 414.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.01579/0.4564, allocations: 9.417 MB / 0.6066 GB, free: 10.73 MB / 414.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 1.005e-05/0.4565, allocations: 8 kB / 0.6066 GB, free: 10.73 MB / 414.1 MB Notification: Performance of matching and sorting (n=331) (initialization): time 0.007364/0.4638, allocations: 5.525 MB / 0.612 GB, free: 5.184 MB / 414.1 MB Notification: Performance of prepare postOptimizeDAE: time 2.288e-05/0.4639, allocations: 20 kB / 0.612 GB, free: 5.164 MB / 414.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.713e-05/0.4639, allocations: 19.5 kB / 0.612 GB, free: 5.148 MB / 414.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 0.001019/0.4649, allocations: 464.5 kB / 0.6125 GB, free: 4.691 MB / 414.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.002264/0.4672, allocations: 0.66 MB / 0.6131 GB, free: 4.031 MB / 414.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.005198/0.4724, allocations: 4.876 MB / 0.6179 GB, free: 15.01 MB / 430.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.002499/0.4749, allocations: 472.7 kB / 0.6183 GB, free: 14.54 MB / 430.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.0002246/0.4752, allocations: 108 kB / 0.6184 GB, free: 14.44 MB / 430.1 MB Warning: Assuming fixed start value for the following 3 variables: batteryStack.cell[3,1].linearDynamicImpedance.cellImpedance.rcseriesLinear.rclinear[1].capacitor.variableCapacitor.Q:VARIABLE(unit = "C" fixed = true ) type: Real [3,1,1] batteryStack.cell[2,1].linearDynamicImpedance.cellImpedance.rcseriesLinear.rclinear[1].capacitor.variableCapacitor.Q:VARIABLE(unit = "C" fixed = true ) type: Real [3,1,1] batteryStack.cell[1,1].linearDynamicImpedance.cellImpedance.rcseriesLinear.rclinear[1].capacitor.variableCapacitor.Q:VARIABLE(unit = "C" fixed = true ) type: Real [3,1,1] Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 82 * Number of states: 0 () * Number of discrete variables: 52 ($PRE.cycler.chargingFinished.fallingEdge.not_u,$PRE.cycler.cycling.edge1.u,$PRE.cycler.cycling.BeforeChargingDelay.timer.entryTime,$PRE.cycler.cycling.BeforeChargingDelay.rSFlipFlop.pre.u,$PRE.cycler.cycling.AfterChargingDelay.timer.entryTime,$PRE.cycler.cycling.AfterChargingDelay.rSFlipFlop.pre.u,$PRE.cycler.cycling.rSFlipFlop.pre.u,cycler.chargingFinished.fallingEdge.not_u,cycler.chargingFinished.fallingEdge.y,cycler.chargingFinished.GraterEqualVmax.y,cycler.cycling.or1.y,cycler.cycling.greaterThreshold.y,cycler.cycling.edge1.y,cycler.cycling.edge1.u,cycler.cycling.BeforeChargingDelay.greaterThreshold.y,cycler.cycling.BeforeChargingDelay.timer.entryTime,cycler.cycling.BeforeChargingDelay.rSFlipFlop.pre.u,cycler.cycling.BeforeChargingDelay.rSFlipFlop.QI,cycler.cycling.BeforeChargingDelay.u,cycler.cycling.AfterChargingDelay.greaterThreshold.y,cycler.cycling.AfterChargingDelay.timer.entryTime,cycler.cycling.AfterChargingDelay.rSFlipFlop.pre.u,cycler.cycling.AfterChargingDelay.rSFlipFlop.QI,cycler.cycling.AfterChargingDelay.u,cycler.cycling.lessVinMin.y,cycler.cycling.rSFlipFlop.pre.u,cycler.Charging,cycler.Discharging,$whenCondition1,$whenCondition2,batteryStack.cell[3,1].linearDynamicImpedance.selfDischarge.qabs.absInt.local_reset,batteryStack.cell[3,1].linearDynamicImpedance.cellImpedance.rs.impedanceValue.qabs.absInt.local_reset,batteryStack.cell[3,1].linearDynamicImpedance.cellImpedance.rcseriesLinear.rclinear[1].resistor.impedanceValue.qabs.absInt.local_reset,batteryStack.cell[3,1].linearDynamicImpedance.cellImpedance.rcseriesLinear.rclinear[1].capacitor.impedanceValue.qabs.absInt.local_reset,batteryStack.cell[3,1].linearDynamicImpedance.calculator.EquivalentCycles.integrator.local_reset,batteryStack.cell[3,1].linearDynamicImpedance.calculator.q.absInt.local_reset,batteryStack.cell[3,1].linearDynamicImpedance.calculator.sOC.integrator.local_reset,batteryStack.cell[2,1].linearDynamicImpedance.selfDischarge.qabs.absInt.local_reset,batteryStack.cell[2,1].linearDynamicImpedance.cellImpedance.rs.impedanceValue.qabs.absInt.local_reset,batteryStack.cell[2,1].linearDynamicImpedance.cellImpedance.rcseriesLinear.rclinear[1].resistor.impedanceValue.qabs.absInt.local_reset,batteryStack.cell[2,1].linearDynamicImpedance.cellImpedance.rcseriesLinear.rclinear[1].capacitor.impedanceValue.qabs.absInt.local_reset,batteryStack.cell[2,1].linearDynamicImpedance.calculator.EquivalentCycles.integrator.local_reset,batteryStack.cell[2,1].linearDynamicImpedance.calculator.q.absInt.local_reset,batteryStack.cell[2,1].linearDynamicImpedance.calculator.sOC.integrator.local_reset,batteryStack.cell[1,1].linearDynamicImpedance.selfDischarge.qabs.absInt.local_reset,batteryStack.cell[1,1].linearDynamicImpedance.cellImpedance.rs.impedanceValue.qabs.absInt.local_reset,batteryStack.cell[1,1].linearDynamicImpedance.cellImpedance.rcseriesLinear.rclinear[1].resistor.impedanceValue.qabs.absInt.local_reset,batteryStack.cell[1,1].linearDynamicImpedance.cellImpedance.rcseriesLinear.rclinear[1].capacitor.impedanceValue.qabs.absInt.local_reset,batteryStack.cell[1,1].linearDynamicImpedance.calculator.EquivalentCycles.integrator.local_reset,batteryStack.cell[1,1].linearDynamicImpedance.calculator.q.absInt.local_reset,batteryStack.cell[1,1].linearDynamicImpedance.calculator.sOC.integrator.local_reset,charger.controlledCurrent.limitedController.limIntegrator.local_reset) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (302): * Single equations (assignments): 301 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 1 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems (#iteration vars, #inner vars, density): 0 systems * Non-linear torn systems (#iteration vars, #inner vars): 1 system {(3,27)} Notification: Performance of prepare postOptimizeDAE: time 0.004972/0.4801, allocations: 3.932 MB / 0.6223 GB, free: 10.5 MB / 430.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0008216/0.481, allocations: 0.5052 MB / 0.6228 GB, free: 9.984 MB / 430.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.007492/0.4885, allocations: 4.641 MB / 0.6273 GB, free: 5.328 MB / 430.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 2.118e-05/0.4885, allocations: 11.95 kB / 0.6273 GB, free: 5.316 MB / 430.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 4.258e-06/0.4885, allocations: 0 / 0.6273 GB, free: 5.316 MB / 430.1 MB Notification: Performance of postOpt removeConstants (simulation): time 0.004006/0.4925, allocations: 1.791 MB / 0.6291 GB, free: 3.5 MB / 430.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0007846/0.4933, allocations: 75.98 kB / 0.6291 GB, free: 3.426 MB / 430.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.001768/0.4951, allocations: 255.6 kB / 0.6294 GB, free: 3.176 MB / 430.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0003807/0.4955, allocations: 137.8 kB / 0.6295 GB, free: 3.043 MB / 430.1 MB Notification: Performance of postOpt createDAEmodeBDAE (simulation): time 0.008755/0.5043, allocations: 5.028 MB / 0.6344 GB, free: 14.04 MB / 446.1 MB Notification: Performance of postOpt symbolicJacobianDAE (simulation): time 0.009377/0.5136, allocations: 7.155 MB / 0.6414 GB, free: 6.863 MB / 446.1 MB Notification: Performance of postOpt setEvaluationStage (simulation): time 0.002558/0.5162, allocations: 2.014 MB / 0.6434 GB, free: 4.848 MB / 446.1 MB Notification: Performance of sorting global known variables: time 0.01065/0.5269, allocations: 7.65 MB / 0.6509 GB, free: 13.2 MB / 462.1 MB Notification: Performance of Backend: time 4.91e-07/0.5269, allocations: 4 kB / 0.6509 GB, free: 13.19 MB / 462.1 MB Notification: Performance of simCode: created initialization part: time 0.006894/0.5338, allocations: 3.436 MB / 0.6542 GB, free: 9.77 MB / 462.1 MB Notification: Performance of SimCode: time 0.02317/0.557, allocations: 16.19 MB / 0.67 GB, free: 9.535 MB / 478.1 MB Notification: Performance of Templates: time 0.2864/0.8434, allocations: 90.97 MB / 0.7589 GB, free: 167 MB / 0.5137 GB make -j1 -f ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling.makefile (rm -f ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling.pipe ; mkfifo ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling.pipe ; head -c 1048576 < ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling.pipe >> ../files/ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling.sim & ./ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling -abortSlowSimulation -alarm=480 -lv LOG_STATS > ElectricalEnergyStorage_ElectricalEnergyStorage.Examples.AdvancedStackCycling.pipe 2>&1)