Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries/ --ompython_omhome=/usr Buildings_9_Buildings.Electrical.DC.Storage.Examples.Battery.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 9.1.1-maint.9.1.x/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) 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 Buildings with version 9.1.1 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 9.1.1-maint.9.1.x/package.mo) Running command: "" <> buildModelFMU(Buildings.Electrical.DC.Storage.Examples.Battery,fileNamePrefix="Buildings_9_Buildings_Electrical_DC_Storage_Examples_Battery",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Buildings.Electrical.DC.Storage.Examples.Battery,fileNamePrefix="Buildings_9_Buildings_Electrical_DC_Storage_Examples_Battery",fmuType="me",version="2.0",platforms={"static"}) [:1:1-1:32:writable] Error: Class GC_set_max_heap_size not found in scope (looking for a function or record). Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 9.1.1-maint.9.1.x/package.mo): time 1.807/1.807, allocations: 387.2 MB / 394.5 MB, free: 13.71 MB / 314.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.0009736/0.0009736, allocations: 177.3 kB / 487 MB, free: 5.426 MB / 394.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 1.171/1.171, allocations: 221.3 MB / 0.7819 GB, free: 1.484 MB / 0.5417 GB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.0008975/0.0008974, allocations: 105.2 kB / 0.9213 GB, free: 2.734 MB / 0.6823 GB Notification: Performance of FrontEnd - loaded program: time 0.4021/0.4031, allocations: 148.4 MB / 1.066 GB, free: 168.2 MB / 0.7448 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1787/0.5818, allocations: 142.3 MB / 1.205 GB, free: 26.2 MB / 0.7448 GB Notification: Performance of FrontEnd - scodeFlatten: time 0.4942/1.076, allocations: 175 MB / 1.376 GB, free: 1.965 MB / 0.8073 GB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0001851/1.076, allocations: 91.06 kB / 1.376 GB, free: 1.918 MB / 0.8073 GB [/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 9.1.1-maint.9.1.x/Electrical/Interfaces/Source.mo:28:9-28: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 9.1.1-maint.9.1.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: 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.05119/1.127, allocations: 24.4 MB / 1.4 GB, free: 13.65 MB / 0.8386 GB Notification: Performance of prepare preOptimizeDAE: time 2.985e-05/1.127, allocations: 9 kB / 1.4 GB, free: 13.64 MB / 0.8386 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0006344/1.128, allocations: 142.8 kB / 1.4 GB, free: 13.5 MB / 0.8386 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0005563/1.129, allocations: 411 kB / 1.401 GB, free: 13.12 MB / 0.8386 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 3.716e-05/1.129, allocations: 27.98 kB / 1.401 GB, free: 13.09 MB / 0.8386 GB Notification: Performance of preOpt expandDerOperator (simulation): time 9.132e-05/1.129, allocations: 51.25 kB / 1.401 GB, free: 13.05 MB / 0.8386 GB Notification: Performance of preOpt removeEqualFunctionCalls (simulation): time 0.0007853/1.13, allocations: 0.4956 MB / 1.401 GB, free: 12.73 MB / 0.8386 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.001012/1.131, allocations: 0.7515 MB / 1.402 GB, free: 12.09 MB / 0.8386 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.988e-05/1.131, allocations: 8 kB / 1.402 GB, free: 12.08 MB / 0.8386 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 5.241e-05/1.131, allocations: 0 / 1.402 GB, free: 12.08 MB / 0.8386 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 4.624e-05/1.131, allocations: 45.23 kB / 1.402 GB, free: 12.04 MB / 0.8386 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.003297/1.134, allocations: 3.552 MB / 1.405 GB, free: 8.73 MB / 0.8386 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0004753/1.135, allocations: 356.1 kB / 1.406 GB, free: 8.418 MB / 0.8386 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0003319/1.135, allocations: 208.6 kB / 1.406 GB, free: 8.258 MB / 0.8386 GB Notification: Performance of preOpt evalFunc (simulation): time 3.168e-05/1.135, allocations: 8.312 kB / 1.406 GB, free: 8.25 MB / 0.8386 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0002983/1.135, allocations: 248 kB / 1.406 GB, free: 8.043 MB / 0.8386 GB Notification: Performance of pre-optimization done (n=50): time 1.874e-06/1.135, allocations: 3.938 kB / 1.406 GB, free: 8.039 MB / 0.8386 GB Notification: Performance of matching and sorting (n=50): time 0.0004989/1.136, allocations: 311.4 kB / 1.407 GB, free: 7.789 MB / 0.8386 GB Notification: Performance of inlineWhenForInitialization (initialization): time 9.472e-05/1.136, allocations: 173.8 kB / 1.407 GB, free: 7.586 MB / 0.8386 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0002711/1.136, allocations: 302.8 kB / 1.407 GB, free: 7.348 MB / 0.8386 GB Notification: Performance of collectPreVariables (initialization): time 5.197e-05/1.136, allocations: 44.08 kB / 1.407 GB, free: 7.305 MB / 0.8386 GB Notification: Performance of collectInitialEqns (initialization): time 0.0001872/1.136, allocations: 314.5 kB / 1.407 GB, free: 7.02 MB / 0.8386 GB Notification: Performance of collectInitialBindings (initialization): time 0.0001095/1.137, allocations: 127.5 kB / 1.407 GB, free: 6.914 MB / 0.8386 GB Notification: Performance of simplifyInitialFunctions (initialization): time 2.118e-05/1.137, allocations: 0 / 1.407 GB, free: 6.914 MB / 0.8386 GB Notification: Performance of setup shared object (initialization): time 0.0001276/1.137, allocations: 354.4 kB / 1.408 GB, free: 6.578 MB / 0.8386 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0002412/1.137, allocations: 140.5 kB / 1.408 GB, free: 6.492 MB / 0.8386 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0003561/1.137, allocations: 378.4 kB / 1.408 GB, free: 6.098 MB / 0.8386 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.0002745/1.138, allocations: 178.8 kB / 1.408 GB, free: 5.973 MB / 0.8386 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 3.707e-06/1.138, allocations: 0 / 1.408 GB, free: 5.973 MB / 0.8386 GB Notification: Performance of matching and sorting (n=97) (initialization): time 0.0007605/1.138, allocations: 0.5193 MB / 1.409 GB, free: 5.543 MB / 0.8386 GB Notification: Performance of prepare postOptimizeDAE: time 0.0008382/1.139, allocations: 2.698 MB / 1.412 GB, free: 2.684 MB / 0.8386 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.176e-05/1.139, allocations: 8 kB / 1.412 GB, free: 2.676 MB / 0.8386 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.002e-05/1.139, allocations: 12 kB / 1.412 GB, free: 2.664 MB / 0.8386 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0003402/1.14, allocations: 101.6 kB / 1.412 GB, free: 2.57 MB / 0.8386 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.456e-05/1.14, allocations: 23.91 kB / 1.412 GB, free: 2.547 MB / 0.8386 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0003048/1.14, allocations: 39.53 kB / 1.412 GB, free: 2.508 MB / 0.8386 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 4.9e-05/1.14, allocations: 42.67 kB / 1.412 GB, free: 2.473 MB / 0.8386 GB Notification: Performance of prepare postOptimizeDAE: time 6.342e-06/1.14, allocations: 7.938 kB / 1.412 GB, free: 2.465 MB / 0.8386 GB Notification: Performance of postOpt replaceHomotopyWithSimplified (initialization): time 0.000629/1.141, allocations: 446.5 kB / 1.412 GB, free: 2.121 MB / 0.8386 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 7.083e-06/1.141, allocations: 8 kB / 1.412 GB, free: 2.113 MB / 0.8386 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.371e-05/1.141, allocations: 15.91 kB / 1.412 GB, free: 2.098 MB / 0.8386 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.000316/1.141, allocations: 106 kB / 1.412 GB, free: 2 MB / 0.8386 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 8.035e-06/1.141, allocations: 8 kB / 1.412 GB, free: 1.992 MB / 0.8386 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0002871/1.141, allocations: 36.33 kB / 1.412 GB, free: 1.957 MB / 0.8386 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 4.445e-05/1.141, allocations: 34.38 kB / 1.412 GB, free: 1.93 MB / 0.8386 GB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 31 * Number of states: 0 () * Number of discrete variables: 56 ($PRE.toOn.enableFire,$PRE.toHold.enableFire,$PRE.toDischarge.enableFire,$PRE.toOff.enableFire,$PRE.toOn.t_start,toOn.t_start,$PRE.toHold.t_start,toHold.t_start,$PRE.toDischarge.t_start,toDischarge.t_start,$PRE.toOff.t_start,toOff.t_start,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 (97): * Single equations (assignments): 97 * 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.0001295/1.141, allocations: 156.5 kB / 1.413 GB, free: 1.777 MB / 0.8386 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 6.083e-05/1.142, allocations: 43.44 kB / 1.413 GB, free: 1.734 MB / 0.8386 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0005632/1.142, allocations: 331.3 kB / 1.413 GB, free: 1.484 MB / 0.8386 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 8.937e-06/1.142, allocations: 12 kB / 1.413 GB, free: 1.473 MB / 0.8386 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.01e-06/1.142, allocations: 0 / 1.413 GB, free: 1.473 MB / 0.8386 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 1.162e-05/1.142, allocations: 3.984 kB / 1.413 GB, free: 1.469 MB / 0.8386 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.001299/1.143, allocations: 0.981 MB / 1.414 GB, free: 0.6289 MB / 0.8386 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 5.891e-06/1.143, allocations: 8 kB / 1.414 GB, free: 0.6211 MB / 0.8386 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0002105/1.144, allocations: 46.34 kB / 1.414 GB, free: 0.5781 MB / 0.8386 GB Notification: Performance of postOpt tearingSystem (simulation): time 6.762e-06/1.144, allocations: 4 kB / 1.414 GB, free: 0.5742 MB / 0.8386 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.738e-05/1.144, allocations: 7 kB / 1.414 GB, free: 0.5703 MB / 0.8386 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 3.687e-06/1.144, allocations: 4 kB / 1.414 GB, free: 0.5664 MB / 0.8386 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 3.397e-06/1.144, allocations: 3.938 kB / 1.414 GB, free: 0.5625 MB / 0.8386 GB Notification: Performance of postOpt detectJacobianSparsePattern (simulation): time 0.0008022/1.145, allocations: 0.6851 MB / 1.415 GB, free: 15.95 MB / 0.8542 GB Notification: Performance of postOpt generateSymbolicLinearization (simulation): time 0.001093/1.146, allocations: 1.222 MB / 1.416 GB, free: 14.88 MB / 0.8542 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0001525/1.146, allocations: 149.7 kB / 1.416 GB, free: 14.72 MB / 0.8542 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 6.916e-05/1.146, allocations: 19.73 kB / 1.416 GB, free: 14.71 MB / 0.8542 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.000193/1.146, allocations: 4 kB / 1.416 GB, free: 14.7 MB / 0.8542 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001021/1.146, allocations: 51.17 kB / 1.416 GB, free: 14.66 MB / 0.8542 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 3.281e-05/1.146, allocations: 19.36 kB / 1.416 GB, free: 14.65 MB / 0.8542 GB Notification: Performance of sort global known variables: time 0.0001527/1.146, allocations: 189.3 kB / 1.416 GB, free: 14.5 MB / 0.8542 GB Notification: Performance of remove unused functions: time 0.001826/1.148, allocations: 218.1 kB / 1.416 GB, free: 14.29 MB / 0.8542 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 7 * Number of states: 1 (bat.cha.SOC) * Number of discrete variables: 36 (toOff.t_start,toDischarge.t_start,toHold.t_start,toOn.t_start,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: 10 (discharge.newActive,hold.newActive,charge.newActive,off.newActive,bat.cha.underCharged,bat.cha.overCharged,toOn.t_start,toHold.t_start,toDischarge.t_start,toOff.t_start) * Top-level inputs: 0 Notification: Strong component statistics for simulation (55): * Single equations (assignments): 47 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 8 * 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.0001771/1.148, allocations: 149.3 kB / 1.417 GB, free: 14.14 MB / 0.8542 GB Notification: Performance of simCode: created initialization part: time 0.0009034/1.149, allocations: 0.685 MB / 1.417 GB, free: 13.63 MB / 0.8542 GB Notification: Performance of simCode: created event and clocks part: time 2.074e-06/1.149, allocations: 448 / 1.417 GB, free: 13.63 MB / 0.8542 GB Notification: Performance of simCode: created simulation system equations: time 0.0002484/1.15, allocations: 192.3 kB / 1.417 GB, free: 13.5 MB / 0.8542 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0004443/1.15, allocations: 75.41 kB / 1.418 GB, free: 13.44 MB / 0.8542 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.00136/1.151, allocations: 0.7345 MB / 1.418 GB, free: 12.75 MB / 0.8542 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0006111/1.152, allocations: 0.9795 MB / 1.419 GB, free: 11.75 MB / 0.8542 GB Notification: Performance of SimCode: time 2.7e-07/1.152, allocations: 0 / 1.419 GB, free: 11.75 MB / 0.8542 GB (rm -f Buildings_9_Buildings.Electrical.DC.Storage.Examples.Battery.pipe ; mkfifo Buildings_9_Buildings.Electrical.DC.Storage.Examples.Battery.pipe ; head -c 1048576 < Buildings_9_Buildings.Electrical.DC.Storage.Examples.Battery.pipe >> ../files/Buildings_9_Buildings.Electrical.DC.Storage.Examples.Battery.sim & /home/hudson/saved_omc/OMSimulator/install/linux/bin/OMSimulator -r=Buildings_9_Buildings.Electrical.DC.Storage.Examples.Battery_res.mat --tempDir=temp_Buildings_9_Buildings_Electrical_DC_Storage_Examples_Battery_fmu --startTime=0 --stopTime=432000 --timeout=50 --tolerance=1e-06 Buildings_9_Buildings_Electrical_DC_Storage_Examples_Battery.fmu > Buildings_9_Buildings.Electrical.DC.Storage.Examples.Battery.pipe 2>&1)