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.3 MB / 261.8 MB, free: 5.863 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.0009431/0.000943, allocations: 178.1 kB / 321.3 MB, free: 14.64 MB / 266.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo): time 1.524/1.524, allocations: 205.2 MB / 0.572 GB, free: 10.7 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.001025/0.001025, allocations: 98.52 kB / 0.6764 GB, free: 15.66 MB / 0.5261 GB Notification: Performance of FrontEnd - loaded program: time 3.261e-05/3.264e-05, allocations: 0 / 0.7879 GB, free: 97.11 MB / 0.5417 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.2057/0.2058, allocations: 106.3 MB / 0.8918 GB, free: 6.688 MB / 0.5573 GB Notification: Performance of FrontEnd - scodeFlatten: time 0.7233/0.9292, allocations: 157.9 MB / 1.046 GB, free: 10.91 MB / 0.6667 GB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0002315/0.9294, allocations: 92.64 kB / 1.046 GB, free: 10.86 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.04918/0.9786, allocations: 21.06 MB / 1.067 GB, free: 9.473 MB / 0.6823 GB Notification: Performance of FrontEnd: time 2.054e-06/0.9787, allocations: 0 / 1.067 GB, free: 9.473 MB / 0.6823 GB Notification: Performance of Transformations before backend: time 3.531e-05/0.9787, allocations: 20 kB / 1.067 GB, free: 9.453 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.001296/0.98, allocations: 0.7807 MB / 1.067 GB, free: 8.668 MB / 0.6823 GB Notification: Performance of prepare preOptimizeDAE: time 4.9e-05/0.9801, allocations: 8.031 kB / 1.067 GB, free: 8.66 MB / 0.6823 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0006318/0.9807, allocations: 123 kB / 1.068 GB, free: 8.539 MB / 0.6823 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0006093/0.9813, allocations: 412.5 kB / 1.068 GB, free: 8.152 MB / 0.6823 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 6.005e-05/0.9814, allocations: 69.25 kB / 1.068 GB, free: 8.109 MB / 0.6823 GB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0001131/0.9815, allocations: 85.19 kB / 1.068 GB, free: 8.051 MB / 0.6823 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.001252/0.9828, allocations: 0.8405 MB / 1.069 GB, free: 7.383 MB / 0.6823 GB Notification: Performance of preOpt findStateOrder (simulation): time 2.208e-05/0.9828, allocations: 7.938 kB / 1.069 GB, free: 7.375 MB / 0.6823 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 6.689e-05/0.9829, allocations: 36.98 kB / 1.069 GB, free: 7.363 MB / 0.6823 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 5.575e-05/0.983, allocations: 37.98 kB / 1.069 GB, free: 7.324 MB / 0.6823 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0008751/0.9838, allocations: 0.552 MB / 1.07 GB, free: 6.957 MB / 0.6823 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.003697/0.9876, allocations: 3.698 MB / 1.073 GB, free: 3.539 MB / 0.6823 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0005187/0.9881, allocations: 298.5 kB / 1.073 GB, free: 3.32 MB / 0.6823 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0003262/0.9884, allocations: 190.9 kB / 1.074 GB, free: 3.191 MB / 0.6823 GB Notification: Performance of preOpt evalFunc (simulation): time 4.088e-05/0.9885, allocations: 8.359 kB / 1.074 GB, free: 3.184 MB / 0.6823 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0003342/0.9888, allocations: 215.5 kB / 1.074 GB, free: 3.016 MB / 0.6823 GB Notification: Performance of pre-optimization done (n=46): time 3.536e-06/0.9888, allocations: 0 / 1.074 GB, free: 3.016 MB / 0.6823 GB Notification: Performance of matching and sorting (n=46): time 0.0005895/0.9894, allocations: 325.7 kB / 1.074 GB, free: 2.758 MB / 0.6823 GB Notification: Performance of inlineWhenForInitialization (initialization): time 4.373e-05/0.9895, allocations: 59.34 kB / 1.074 GB, free: 2.688 MB / 0.6823 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0003933/0.9899, allocations: 389.6 kB / 1.075 GB, free: 2.383 MB / 0.6823 GB Notification: Performance of collectPreVariables (initialization): time 5.423e-05/0.9899, allocations: 49.94 kB / 1.075 GB, free: 2.34 MB / 0.6823 GB Notification: Performance of collectInitialEqns (initialization): time 0.0002053/0.9902, allocations: 342.5 kB / 1.075 GB, free: 2.066 MB / 0.6823 GB Notification: Performance of collectInitialBindings (initialization): time 0.0001009/0.9903, allocations: 130.5 kB / 1.075 GB, free: 1.957 MB / 0.6823 GB Notification: Performance of simplifyInitialFunctions (initialization): time 2.397e-05/0.9903, allocations: 10.44 kB / 1.075 GB, free: 1.957 MB / 0.6823 GB Notification: Performance of setup shared object (initialization): time 0.0001363/0.9904, allocations: 359.8 kB / 1.075 GB, free: 1.617 MB / 0.6823 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0002414/0.9907, allocations: 147.8 kB / 1.076 GB, free: 1.527 MB / 0.6823 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0003729/0.9911, allocations: 388.5 kB / 1.076 GB, free: 1.117 MB / 0.6823 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.0003063/0.9914, allocations: 183.9 kB / 1.076 GB, free: 0.9805 MB / 0.6823 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 4.408e-06/0.9914, allocations: 4 kB / 1.076 GB, free: 0.9766 MB / 0.6823 GB Notification: Performance of matching and sorting (n=93) (initialization): time 0.0008361/0.9922, allocations: 0.5844 MB / 1.077 GB, free: 0.5117 MB / 0.6823 GB Notification: Performance of prepare postOptimizeDAE: time 0.001052/0.9933, allocations: 2.699 MB / 1.079 GB, free: 13.65 MB / 0.698 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.47e-05/0.9933, allocations: 8 kB / 1.079 GB, free: 13.64 MB / 0.698 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.815e-05/0.9934, allocations: 16 kB / 1.079 GB, free: 13.62 MB / 0.698 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0003577/0.9937, allocations: 94.64 kB / 1.079 GB, free: 13.54 MB / 0.698 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 2.123e-05/0.9938, allocations: 19.92 kB / 1.079 GB, free: 13.52 MB / 0.698 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0003507/0.9941, allocations: 65.58 kB / 1.079 GB, free: 13.46 MB / 0.698 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 5.163e-05/0.9942, allocations: 27.56 kB / 1.08 GB, free: 13.44 MB / 0.698 GB Notification: Performance of prepare postOptimizeDAE: time 1.09e-05/0.9942, allocations: 5.406 kB / 1.08 GB, free: 13.44 MB / 0.698 GB Notification: Performance of postOpt replaceHomotopyWithSimplified (initialization): time 0.0007214/0.9949, allocations: 0.5146 MB / 1.08 GB, free: 13.05 MB / 0.698 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 7.804e-06/0.9949, allocations: 12.19 kB / 1.08 GB, free: 13.04 MB / 0.698 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.195e-05/0.995, allocations: 12 kB / 1.08 GB, free: 13.03 MB / 0.698 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0003182/0.9953, allocations: 98.83 kB / 1.08 GB, free: 12.94 MB / 0.698 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.666e-05/0.9953, allocations: 19.92 kB / 1.08 GB, free: 12.92 MB / 0.698 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0002765/0.9956, allocations: 57.92 kB / 1.08 GB, free: 12.88 MB / 0.698 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 5.513e-05/0.9957, allocations: 39.28 kB / 1.08 GB, free: 12.84 MB / 0.698 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.0001706/0.9958, allocations: 173.3 kB / 1.08 GB, free: 12.7 MB / 0.698 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 6.967e-05/0.9959, allocations: 43.44 kB / 1.08 GB, free: 12.65 MB / 0.698 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0006595/0.9966, allocations: 382 kB / 1.081 GB, free: 12.38 MB / 0.698 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 7.194e-06/0.9966, allocations: 7.938 kB / 1.081 GB, free: 12.38 MB / 0.698 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 6.903e-06/0.9966, allocations: 4 kB / 1.081 GB, free: 12.37 MB / 0.698 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 9.638e-06/0.9966, allocations: 7.938 kB / 1.081 GB, free: 12.36 MB / 0.698 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.001539/0.9982, allocations: 1.096 MB / 1.082 GB, free: 11.43 MB / 0.698 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 3.847e-06/0.9982, allocations: 0 / 1.082 GB, free: 11.43 MB / 0.698 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0002109/0.9984, allocations: 51.03 kB / 1.082 GB, free: 11.38 MB / 0.698 GB Notification: Performance of postOpt tearingSystem (simulation): time 6.011e-06/0.9984, allocations: 3.953 kB / 1.082 GB, free: 11.38 MB / 0.698 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.994e-05/0.9985, allocations: 14.67 kB / 1.082 GB, free: 11.37 MB / 0.698 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 4.739e-06/0.9985, allocations: 4 kB / 1.082 GB, free: 11.37 MB / 0.698 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.903e-06/0.9985, allocations: 0 / 1.082 GB, free: 11.37 MB / 0.698 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0008305/0.9993, allocations: 0.6331 MB / 1.083 GB, free: 10.85 MB / 0.698 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001598/0.9995, allocations: 151.9 kB / 1.083 GB, free: 10.69 MB / 0.698 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 5.776e-05/0.9995, allocations: 13.81 kB / 1.083 GB, free: 10.69 MB / 0.698 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001748/0.9997, allocations: 14 kB / 1.083 GB, free: 10.68 MB / 0.698 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001209/0.9999, allocations: 47.3 kB / 1.083 GB, free: 10.64 MB / 0.698 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.948e-05/0.9999, allocations: 15.31 kB / 1.083 GB, free: 10.62 MB / 0.698 GB Notification: Performance of sorting global known variables: time 0.0002765/1, allocations: 259.1 kB / 1.083 GB, free: 10.42 MB / 0.698 GB Notification: Performance of sort global known variables: time 1.7e-07/1, allocations: 0 / 1.083 GB, free: 10.42 MB / 0.698 GB Notification: Performance of remove unused functions: time 0.0007941/1.001, allocations: 234.1 kB / 1.083 GB, free: 10.22 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.0002188/1.001, allocations: 138.8 kB / 1.083 GB, free: 10.08 MB / 0.698 GB Notification: Performance of simCode: created initialization part: time 0.001071/1.002, allocations: 0.7204 MB / 1.084 GB, free: 9.543 MB / 0.698 GB Notification: Performance of simCode: created event and clocks part: time 2.665e-06/1.002, allocations: 0 / 1.084 GB, free: 9.543 MB / 0.698 GB Notification: Performance of simCode: created simulation system equations: time 0.0002613/1.003, allocations: 166.5 kB / 1.084 GB, free: 9.383 MB / 0.698 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0005092/1.003, allocations: 97.89 kB / 1.084 GB, free: 9.289 MB / 0.698 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.001383/1.004, allocations: 0.7138 MB / 1.085 GB, free: 8.539 MB / 0.698 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0004746/1.005, allocations: 0.9316 MB / 1.086 GB, free: 7.582 MB / 0.698 GB Notification: Performance of simCode: alias equations: time 0.000467/1.005, allocations: 124.7 kB / 1.086 GB, free: 7.461 MB / 0.698 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001135/1.006, allocations: 47.36 kB / 1.086 GB, free: 7.414 MB / 0.698 GB Notification: Performance of SimCode: time 9.32e-07/1.006, allocations: 0 / 1.086 GB, free: 7.414 MB / 0.698 GB Notification: Performance of Templates: time 0.01152/1.017, allocations: 5.899 MB / 1.092 GB, free: 1.57 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