Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries/ --ompython_omhome=/usr Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 7.0.3-maint.7.0.x/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 3.2.3+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/ModelicaServices 3.2.3+maint.om/package.mo", uses=false) Using package ModelicaServices with version 3.2.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 3.2.3+maint.om/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 3.2.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 3.2.3+maint.om/package.mo) Using package Buildings with version 7.0.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 7.0.3-maint.7.0.x/package.mo) Running command: translateModel(Buildings.Electrical.DC.Storage.Examples.Battery,tolerance=1e-06,outputFormat="mat",numberOfIntervals=5000,variableFilter="time|bat.terminal.i.1.|loa.i.1.|bat.SOC|sou.S.1.|bat.P|loa.S.1.",fileNamePrefix="Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery") translateModel(Buildings.Electrical.DC.Storage.Examples.Battery,tolerance=1e-06,outputFormat="mat",numberOfIntervals=5000,variableFilter="time|bat.terminal.i.1.|loa.i.1.|bat.SOC|sou.S.1.|bat.P|loa.S.1.",fileNamePrefix="Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery") Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 7.0.3-maint.7.0.x/package.mo): time 1.458/1.458, allocations: 249.5 MB / 257 MB, free: 6.93 MB / 202.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 3.2.3+maint.om/package.mo): time 0.001017/0.001017, allocations: 183.4 kB / 316.3 MB, free: 3.23 MB / 250.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo): time 1.51/1.51, allocations: 205.3 MB / 0.5671 GB, free: 15.79 MB / 426.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 3.2.3+maint.om/package.mo): time 0.0008483/0.0008483, allocations: 92.23 kB / 0.6714 GB, free: 4.906 MB / 0.5105 GB Notification: Performance of FrontEnd - loaded program: time 1.426e-05/1.43e-05, allocations: 4 kB / 0.7814 GB, free: 102.7 MB / 0.5417 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.2276/0.2276, allocations: 106.3 MB / 0.8852 GB, free: 12.26 MB / 0.5573 GB Notification: Performance of FrontEnd - scodeFlatten: time 0.7897/1.017, allocations: 158.2 MB / 1.04 GB, free: 13.73 MB / 0.6667 GB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0002427/1.018, allocations: 87.38 kB / 1.04 GB, free: 13.68 MB / 0.6667 GB [/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 7.0.3-maint.7.0.x/Electrical/Interfaces/Source.mo:30:9-30:50:writable] Warning: Ignoring overconstrained operator applied to array components having size zero: Connections.potentialRoot(terminal.theta);. [/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 7.0.3-maint.7.0.x/Electrical/DC/Sensors/GeneralizedSensor.mo:39:3-39:57:writable] Warning: Ignoring overconstrained operator applied to array components having size zero: Connections.branch(terminal_p.theta, terminal_n.theta);. Notification: Performance of FrontEnd - DAE generated: time 0.04951/1.067, allocations: 20.9 MB / 1.06 GB, free: 12.63 MB / 0.6823 GB Notification: Performance of FrontEnd: time 1.503e-06/1.067, allocations: 0 / 1.06 GB, free: 12.63 MB / 0.6823 GB Notification: Performance of Transformations before backend: time 3.465e-05/1.067, allocations: 16 kB / 1.06 GB, free: 12.61 MB / 0.6823 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 191 * Number of variables: 191 Notification: Performance of Generate backend data structure: time 0.001307/1.069, allocations: 0.7884 MB / 1.061 GB, free: 11.82 MB / 0.6823 GB Notification: Performance of prepare preOptimizeDAE: time 4.831e-05/1.069, allocations: 8.031 kB / 1.061 GB, free: 11.81 MB / 0.6823 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0006455/1.069, allocations: 131 kB / 1.061 GB, free: 11.68 MB / 0.6823 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.000624/1.07, allocations: 409.8 kB / 1.061 GB, free: 11.3 MB / 0.6823 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 4.407e-05/1.07, allocations: 28 kB / 1.061 GB, free: 11.27 MB / 0.6823 GB Notification: Performance of preOpt expandDerOperator (simulation): time 9.944e-05/1.07, allocations: 47.95 kB / 1.062 GB, free: 11.22 MB / 0.6823 GB Notification: Performance of preOpt removeEqualFunctionCalls (simulation): time 0.0007864/1.071, allocations: 493.4 kB / 1.062 GB, free: 10.92 MB / 0.6823 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.001135/1.072, allocations: 0.7409 MB / 1.063 GB, free: 10.29 MB / 0.6823 GB Notification: Performance of preOpt findStateOrder (simulation): time 2.921e-05/1.072, allocations: 11.92 kB / 1.063 GB, free: 10.28 MB / 0.6823 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 5.749e-05/1.072, allocations: 7.625 kB / 1.063 GB, free: 10.27 MB / 0.6823 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 5.317e-05/1.072, allocations: 37.98 kB / 1.063 GB, free: 10.24 MB / 0.6823 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.003692/1.076, allocations: 3.55 MB / 1.066 GB, free: 6.926 MB / 0.6823 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0004685/1.076, allocations: 268.2 kB / 1.067 GB, free: 6.734 MB / 0.6823 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0002991/1.077, allocations: 179.1 kB / 1.067 GB, free: 6.613 MB / 0.6823 GB Notification: Performance of preOpt evalFunc (simulation): time 4.048e-05/1.077, allocations: 8.359 kB / 1.067 GB, free: 6.605 MB / 0.6823 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0003219/1.077, allocations: 194.4 kB / 1.067 GB, free: 6.453 MB / 0.6823 GB Notification: Performance of pre-optimization done (n=46): time 2.485e-06/1.077, allocations: 0 / 1.067 GB, free: 6.453 MB / 0.6823 GB Notification: Performance of matching and sorting (n=46): time 0.0005292/1.078, allocations: 293.4 kB / 1.067 GB, free: 6.219 MB / 0.6823 GB Notification: Performance of inlineWhenForInitialization (initialization): time 4.417e-05/1.078, allocations: 71.11 kB / 1.067 GB, free: 6.137 MB / 0.6823 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.000299/1.078, allocations: 310.9 kB / 1.068 GB, free: 5.895 MB / 0.6823 GB Notification: Performance of collectPreVariables (initialization): time 4.956e-05/1.078, allocations: 40.56 kB / 1.068 GB, free: 5.855 MB / 0.6823 GB Notification: Performance of collectInitialEqns (initialization): time 0.0002214/1.078, allocations: 350.3 kB / 1.068 GB, free: 5.559 MB / 0.6823 GB Notification: Performance of collectInitialBindings (initialization): time 9.993e-05/1.078, allocations: 120.9 kB / 1.068 GB, free: 5.457 MB / 0.6823 GB Notification: Performance of simplifyInitialFunctions (initialization): time 2.151e-05/1.078, allocations: 4 kB / 1.068 GB, free: 5.453 MB / 0.6823 GB Notification: Performance of setup shared object (initialization): time 0.0001658/1.079, allocations: 355.7 kB / 1.068 GB, free: 5.117 MB / 0.6823 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0002027/1.079, allocations: 129.2 kB / 1.068 GB, free: 5.039 MB / 0.6823 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0004236/1.079, allocations: 366.1 kB / 1.069 GB, free: 4.652 MB / 0.6823 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.0002563/1.08, allocations: 172.6 kB / 1.069 GB, free: 4.531 MB / 0.6823 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 4.759e-06/1.08, allocations: 0 / 1.069 GB, free: 4.531 MB / 0.6823 GB Notification: Performance of matching and sorting (n=93) (initialization): time 0.0007326/1.08, allocations: 0.5045 MB / 1.069 GB, free: 4.113 MB / 0.6823 GB Notification: Performance of prepare postOptimizeDAE: time 0.001097/1.081, allocations: 2.698 MB / 1.072 GB, free: 1.254 MB / 0.6823 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.027e-05/1.081, allocations: 8 kB / 1.072 GB, free: 1.246 MB / 0.6823 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.713e-05/1.081, allocations: 12 kB / 1.072 GB, free: 1.234 MB / 0.6823 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0003565/1.082, allocations: 106.9 kB / 1.072 GB, free: 1.137 MB / 0.6823 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 2.018e-05/1.082, allocations: 12 kB / 1.072 GB, free: 1.125 MB / 0.6823 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0003234/1.082, allocations: 47.52 kB / 1.072 GB, free: 1.078 MB / 0.6823 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 5.011e-05/1.082, allocations: 30.81 kB / 1.072 GB, free: 1.055 MB / 0.6823 GB Notification: Performance of prepare postOptimizeDAE: time 7.454e-06/1.082, allocations: 4 kB / 1.072 GB, free: 1.051 MB / 0.6823 GB Notification: Performance of postOpt replaceHomotopyWithSimplified (initialization): time 0.0006272/1.083, allocations: 430.6 kB / 1.073 GB, free: 0.7148 MB / 0.6823 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 8.296e-06/1.083, allocations: 8 kB / 1.073 GB, free: 0.707 MB / 0.6823 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.457e-05/1.083, allocations: 12.88 kB / 1.073 GB, free: 0.6953 MB / 0.6823 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0003499/1.083, allocations: 106.9 kB / 1.073 GB, free: 0.5977 MB / 0.6823 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.2e-05/1.083, allocations: 19.94 kB / 1.073 GB, free: 0.5781 MB / 0.6823 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0002488/1.084, allocations: 31.67 kB / 1.073 GB, free: 0.5469 MB / 0.6823 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 4.324e-05/1.084, allocations: 34.94 kB / 1.073 GB, free: 0.5195 MB / 0.6823 GB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 31 * Number of states: 0 () * Number of discrete variables: 48 ($PRE.toOn.enableFire,$PRE.toHold.enableFire,$PRE.toDischarge.enableFire,$PRE.toOff.enableFire,stateGraphRoot.resume,stateGraphRoot.suspend,$whenCondition1,$PRE.bat.cha.underCharged,bat.cha.underCharged,$PRE.bat.cha.overCharged,bat.cha.overCharged,startCharge.y,greaterEqualThreshold.y,startDischarge.y,lessEqualThreshold.y,$PRE.off.localActive,off.localActive,$PRE.off.newActive,off.newActive,$PRE.off.oldActive,off.oldActive,off.active,toOn.enableFire,$PRE.charge.localActive,charge.localActive,$PRE.charge.newActive,charge.newActive,$PRE.charge.oldActive,charge.oldActive,charge.active,toHold.enableFire,$PRE.hold.localActive,hold.localActive,$PRE.hold.newActive,hold.newActive,$PRE.hold.oldActive,hold.oldActive,hold.active,toDischarge.enableFire,$PRE.discharge.localActive,discharge.localActive,$PRE.discharge.newActive,discharge.newActive,$PRE.discharge.oldActive,discharge.oldActive,discharge.active,toOff.enableFire,stateGraphRoot.activeSteps) * Number of discrete states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (93): * Single equations (assignments): 93 * Array equations: 0 * Algorithm blocks: 0 * 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.0001609/1.084, allocations: 145.7 kB / 1.073 GB, free: 384 kB / 0.6823 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 6.485e-05/1.084, allocations: 43.52 kB / 1.073 GB, free: 340 kB / 0.6823 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0005991/1.084, allocations: 342.7 kB / 1.073 GB, free: 80 kB / 0.6823 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 6.302e-06/1.084, allocations: 4 kB / 1.073 GB, free: 76 kB / 0.6823 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 4.108e-06/1.084, allocations: 0 / 1.073 GB, free: 76 kB / 0.6823 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 7.575e-06/1.084, allocations: 3.984 kB / 1.073 GB, free: 72 kB / 0.6823 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.001561/1.086, allocations: 0.9694 MB / 1.074 GB, free: 15.23 MB / 0.698 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 4.408e-06/1.086, allocations: 0 / 1.074 GB, free: 15.23 MB / 0.698 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0002226/1.086, allocations: 51.28 kB / 1.074 GB, free: 15.19 MB / 0.698 GB Notification: Performance of postOpt tearingSystem (simulation): time 3.857e-06/1.086, allocations: 4 kB / 1.074 GB, free: 15.18 MB / 0.698 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.566e-05/1.086, allocations: 4 kB / 1.074 GB, free: 15.18 MB / 0.698 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 4.859e-06/1.086, allocations: 3.953 kB / 1.074 GB, free: 15.18 MB / 0.698 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 7.204e-06/1.086, allocations: 8 kB / 1.074 GB, free: 15.17 MB / 0.698 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0008905/1.087, allocations: 0.5893 MB / 1.075 GB, free: 14.68 MB / 0.698 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001831/1.087, allocations: 149.7 kB / 1.075 GB, free: 14.53 MB / 0.698 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 5.592e-05/1.088, allocations: 4 kB / 1.075 GB, free: 14.53 MB / 0.698 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001684/1.088, allocations: 15.36 kB / 1.075 GB, free: 14.52 MB / 0.698 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001387/1.088, allocations: 47.44 kB / 1.075 GB, free: 14.47 MB / 0.698 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 3.673e-05/1.088, allocations: 19.73 kB / 1.075 GB, free: 14.46 MB / 0.698 GB Notification: Performance of sorting global known variables: time 0.0002136/1.088, allocations: 197.3 kB / 1.075 GB, free: 14.3 MB / 0.698 GB Notification: Performance of sort global known variables: time 3.01e-07/1.088, allocations: 0 / 1.075 GB, free: 14.3 MB / 0.698 GB Notification: Performance of remove unused functions: time 0.0008828/1.089, allocations: 207.4 kB / 1.076 GB, free: 14.1 MB / 0.698 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 3 * Number of states: 1 (bat.cha.SOC) * Number of discrete variables: 32 (off.localActive,charge.localActive,hold.localActive,discharge.localActive,$cse1,$cse2,$cse3,$cse4,$whenCondition1,bat.cha.underCharged,bat.cha.overCharged,startCharge.y,greaterEqualThreshold.y,startDischarge.y,lessEqualThreshold.y,off.newActive,off.oldActive,off.active,toOn.enableFire,charge.newActive,charge.oldActive,charge.active,toHold.enableFire,hold.newActive,hold.oldActive,hold.active,toDischarge.enableFire,discharge.newActive,discharge.oldActive,discharge.active,toOff.enableFire,stateGraphRoot.activeSteps) * Number of discrete states: 6 (discharge.newActive,hold.newActive,charge.newActive,off.newActive,bat.cha.underCharged,bat.cha.overCharged) * Top-level inputs: 0 Notification: Strong component statistics for simulation (51): * Single equations (assignments): 47 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 4 * 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.0002377/1.089, allocations: 126.1 kB / 1.076 GB, free: 13.97 MB / 0.698 GB Notification: Performance of simCode: created initialization part: time 0.001017/1.09, allocations: 0.6463 MB / 1.076 GB, free: 13.5 MB / 0.698 GB Notification: Performance of simCode: created event and clocks part: time 3.397e-06/1.09, allocations: 0 / 1.076 GB, free: 13.5 MB / 0.698 GB Notification: Performance of simCode: created simulation system equations: time 0.0002366/1.091, allocations: 162.3 kB / 1.077 GB, free: 13.39 MB / 0.698 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0005503/1.091, allocations: 83.14 kB / 1.077 GB, free: 13.33 MB / 0.698 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.00137/1.092, allocations: 0.6942 MB / 1.077 GB, free: 12.69 MB / 0.698 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0005411/1.093, allocations: 0.9229 MB / 1.078 GB, free: 11.75 MB / 0.698 GB Notification: Performance of simCode: alias equations: time 0.0004409/1.093, allocations: 116.5 kB / 1.078 GB, free: 11.63 MB / 0.698 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001081/1.094, allocations: 47.38 kB / 1.078 GB, free: 11.59 MB / 0.698 GB Notification: Performance of SimCode: time 2.184e-06/1.094, allocations: 0 / 1.078 GB, free: 11.59 MB / 0.698 GB Notification: Performance of Templates: time 0.01079/1.104, allocations: 5.379 MB / 1.084 GB, free: 6.273 MB / 0.698 GB make -j1 -f Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery.makefile (rm -f Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery.pipe ; mkfifo Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery.pipe ; head -c 1048576 < Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery.pipe >> ../files/Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery.sim & ./Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery -abortSlowSimulation -alarm=480 -emit_protected -lv LOG_STATS > Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery.pipe 2>&1) diffSimulationResults("Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery_res.mat","/mnt/ReferenceFiles/Buildings/csv/Buildings_Electrical_DC_Storage_Examples_Battery.csv","../files/Buildings_maint.7.0.x_Buildings.Electrical.DC.Storage.Examples.Battery.diff",relTol=0.003,relTolDiffMinMax=0.003,rangeDelta=0.001) Reference file matches