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: "" <> buildModelFMU(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple,fileNamePrefix="BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatterySimple",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple,fileNamePrefix="BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatterySimple",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001315/0.001315, allocations: 108 kB / 15.61 MB, free: 152 kB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001342/0.001342, allocations: 194.5 kB / 16.53 MB, free: 6.664 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.374/1.374, allocations: 222.9 MB / 240.2 MB, free: 4.41 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.002344/0.002344, allocations: 282.9 kB / 290.7 MB, free: 2.016 MB / 238.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/package.mo): time 1.029/1.029, allocations: 178.6 MB / 0.5073 GB, free: 4.586 MB / 382.1 MB Notification: Performance of FrontEnd - loaded program: time 0.002649/0.002649, allocations: 95.48 kB / 0.6065 GB, free: 24.73 MB / 430.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1584/0.1611, allocations: 89.15 MB / 0.6936 GB, free: 4.203 MB / 494.1 MB Notification: Performance of NFInst.instantiate(BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple): time 0.003258/0.1644, allocations: 1.931 MB / 0.6955 GB, free: 2.266 MB / 494.1 MB Notification: Performance of NFInst.instExpressions: time 0.001365/0.1658, allocations: 0.8737 MB / 0.6963 GB, free: 1.387 MB / 494.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 8.78e-05/0.1659, allocations: 4 kB / 0.6963 GB, free: 1.383 MB / 494.1 MB Notification: Performance of NFTyping.typeComponents: time 0.0002129/0.1661, allocations: 44.27 kB / 0.6964 GB, free: 1.34 MB / 494.1 MB Notification: Performance of NFTyping.typeBindings: time 0.0001082/0.1662, allocations: 53.52 kB / 0.6964 GB, free: 1.289 MB / 494.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.0002817/0.1665, allocations: 87.77 kB / 0.6965 GB, free: 1.203 MB / 494.1 MB Notification: Performance of NFFlatten.flatten: time 0.0002712/0.1668, allocations: 192 kB / 0.6967 GB, free: 1.016 MB / 494.1 MB Notification: Performance of NFFlatten.resolveConnections: time 9.883e-05/0.1669, allocations: 19.8 kB / 0.6967 GB, free: 1 MB / 494.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0001681/0.1671, allocations: 85.94 kB / 0.6968 GB, free: 0.918 MB / 494.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0001598/0.1672, allocations: 83.56 kB / 0.6969 GB, free: 0.8359 MB / 494.1 MB Notification: Performance of NFPackage.collectConstants: time 3.015e-05/0.1673, allocations: 8 kB / 0.6969 GB, free: 0.8281 MB / 494.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.0001408/0.1674, allocations: 63.94 kB / 0.6969 GB, free: 0.7656 MB / 494.1 MB Notification: Performance of NFScalarize.scalarize: time 4.68e-05/0.1675, allocations: 27.91 kB / 0.697 GB, free: 0.7383 MB / 494.1 MB Notification: Performance of NFVerifyModel.verify: time 8.799e-05/0.1676, allocations: 71.59 kB / 0.697 GB, free: 0.668 MB / 494.1 MB Notification: Performance of NFConvertDAE.convert: time 0.0002505/0.1678, allocations: 188 kB / 0.6972 GB, free: 496 kB / 494.1 MB Notification: Performance of FrontEnd - DAE generated: time 4.047e-06/0.1678, allocations: 7.938 kB / 0.6972 GB, free: 488 kB / 494.1 MB Notification: Performance of FrontEnd: time 1.242e-06/0.1678, allocations: 0 / 0.6972 GB, free: 488 kB / 494.1 MB Notification: Performance of Transformations before backend: time 9.137e-06/0.1679, allocations: 0 / 0.6972 GB, free: 488 kB / 494.1 MB 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.0009389/0.1688, allocations: 0.5003 MB / 0.6977 GB, free: 15.92 MB / 0.4981 GB Notification: Performance of prepare preOptimizeDAE: time 4.201e-05/0.1689, allocations: 8.031 kB / 0.6977 GB, free: 15.91 MB / 0.4981 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 4.254e-05/0.1689, allocations: 42.73 kB / 0.6978 GB, free: 15.86 MB / 0.4981 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 4.772e-05/0.169, allocations: 16.75 kB / 0.6978 GB, free: 15.85 MB / 0.4981 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0002654/0.1692, allocations: 240.4 kB / 0.698 GB, free: 15.57 MB / 0.4981 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.551e-05/0.1693, allocations: 12.38 kB / 0.698 GB, free: 15.56 MB / 0.4981 GB Notification: Performance of preOpt expandDerOperator (simulation): time 3.44e-05/0.1693, allocations: 8.375 kB / 0.698 GB, free: 15.55 MB / 0.4981 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0002999/0.1696, allocations: 128.2 kB / 0.6982 GB, free: 15.43 MB / 0.4981 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.34e-05/0.1696, allocations: 4 kB / 0.6982 GB, free: 15.42 MB / 0.4981 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.318e-05/0.1696, allocations: 0 / 0.6982 GB, free: 15.42 MB / 0.4981 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 5.671e-06/0.1696, allocations: 3.984 kB / 0.6982 GB, free: 15.42 MB / 0.4981 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0003086/0.17, allocations: 103.9 kB / 0.6983 GB, free: 15.32 MB / 0.4981 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0006425/0.1706, allocations: 420.4 kB / 0.6987 GB, free: 14.86 MB / 0.4981 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0003507/0.171, allocations: 126.5 kB / 0.6988 GB, free: 14.72 MB / 0.4981 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0001861/0.1712, allocations: 78.5 kB / 0.6989 GB, free: 14.64 MB / 0.4981 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0006623/0.1718, allocations: 445.5 kB / 0.6993 GB, free: 14.12 MB / 0.4981 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0003332/0.1722, allocations: 127.5 kB / 0.6994 GB, free: 13.98 MB / 0.4981 GB Notification: Performance of pre-optimization done (n=16): time 1.583e-06/0.1722, allocations: 4 kB / 0.6994 GB, free: 13.98 MB / 0.4981 GB Notification: Performance of matching and sorting (n=16): time 0.0006296/0.1728, allocations: 230.7 kB / 0.6996 GB, free: 13.75 MB / 0.4981 GB Notification: Performance of inlineWhenForInitialization (initialization): time 4.273e-05/0.1729, allocations: 55.41 kB / 0.6997 GB, free: 13.68 MB / 0.4981 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.000174/0.1731, allocations: 179.6 kB / 0.6999 GB, free: 13.5 MB / 0.4981 GB Notification: Performance of collectPreVariables (initialization): time 2.879e-05/0.1731, allocations: 29.7 kB / 0.6999 GB, free: 13.46 MB / 0.4981 GB Notification: Performance of collectInitialEqns (initialization): time 8.268e-05/0.1732, allocations: 116 kB / 0.7 GB, free: 13.34 MB / 0.4981 GB Notification: Performance of collectInitialBindings (initialization): time 5.405e-05/0.1733, allocations: 51.27 kB / 0.7 GB, free: 13.29 MB / 0.4981 GB Notification: Performance of simplifyInitialFunctions (initialization): time 7.133e-05/0.1733, allocations: 49.62 kB / 0.7001 GB, free: 13.24 MB / 0.4981 GB Notification: Performance of setup shared object (initialization): time 0.0001498/0.1735, allocations: 330.8 kB / 0.7004 GB, free: 12.91 MB / 0.4981 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0001959/0.1737, allocations: 80.73 kB / 0.7005 GB, free: 12.82 MB / 0.4981 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0001943/0.1739, allocations: 82.53 kB / 0.7006 GB, free: 12.73 MB / 0.4981 GB Notification: Performance of analyzeInitialSystem (initialization): time 2.896/3.07, allocations: 378.8 MB / 1.07 GB, free: 252.4 MB / 0.7325 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 2.996e-06/3.07, allocations: 0 / 1.07 GB, free: 252.4 MB / 0.7325 GB Notification: Performance of matching and sorting (n=23) (initialization): time 0.000465/3.07, allocations: 261.3 kB / 1.071 GB, free: 252.3 MB / 0.7325 GB Notification: Performance of prepare postOptimizeDAE: time 2.777e-05/3.07, allocations: 33.77 kB / 1.071 GB, free: 252.2 MB / 0.7325 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 6.593e-06/3.07, allocations: 0 / 1.071 GB, free: 252.2 MB / 0.7325 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.804e-05/3.07, allocations: 4 kB / 1.071 GB, free: 252.2 MB / 0.7325 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0002117/3.071, allocations: 42.22 kB / 1.071 GB, free: 252.2 MB / 0.7325 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 7.023e-06/3.071, allocations: 0 / 1.071 GB, free: 252.2 MB / 0.7325 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0001785/3.071, allocations: 18.58 kB / 1.071 GB, free: 252.2 MB / 0.7325 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 1.866e-05/3.071, allocations: 7.812 kB / 1.071 GB, free: 252.2 MB / 0.7325 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.6850000000000001 * 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.0001867/3.071, allocations: 162 kB / 1.071 GB, free: 252 MB / 0.7325 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 3.684e-05/3.071, allocations: 14.72 kB / 1.071 GB, free: 252 MB / 0.7325 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0005292/3.072, allocations: 244.6 kB / 1.071 GB, free: 251.8 MB / 0.7325 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 3.556e-06/3.072, allocations: 0 / 1.071 GB, free: 251.8 MB / 0.7325 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 4.648e-06/3.072, allocations: 0 / 1.071 GB, free: 251.8 MB / 0.7325 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 4.349e-06/3.072, allocations: 0 / 1.071 GB, free: 251.8 MB / 0.7325 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.000171/3.072, allocations: 255.2 kB / 1.071 GB, free: 251.6 MB / 0.7325 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.905e-06/3.072, allocations: 0.75 kB / 1.071 GB, free: 251.6 MB / 0.7325 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0002168/3.072, allocations: 41.88 kB / 1.072 GB, free: 251.5 MB / 0.7325 GB Notification: Performance of postOpt tearingSystem (simulation): time 3.326e-06/3.072, allocations: 0 / 1.072 GB, free: 251.5 MB / 0.7325 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 1.816e-05/3.072, allocations: 7.062 kB / 1.072 GB, free: 251.5 MB / 0.7325 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 2.545e-06/3.072, allocations: 0 / 1.072 GB, free: 251.5 MB / 0.7325 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.665e-06/3.072, allocations: 1.812 kB / 1.072 GB, free: 251.5 MB / 0.7325 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0005512/3.073, allocations: 319.2 kB / 1.072 GB, free: 251.3 MB / 0.7325 GB Notification: Performance of postOpt removeConstants (simulation): time 6.967e-05/3.073, allocations: 108.6 kB / 1.072 GB, free: 251.2 MB / 0.7325 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 3.29e-05/3.073, allocations: 7.5 kB / 1.072 GB, free: 251.2 MB / 0.7325 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001519/3.073, allocations: 11.36 kB / 1.072 GB, free: 251.1 MB / 0.7325 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 6.405e-05/3.073, allocations: 22.81 kB / 1.072 GB, free: 251.1 MB / 0.7325 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 1.231e-05/3.073, allocations: 15.83 kB / 1.072 GB, free: 251.1 MB / 0.7325 GB Notification: Performance of sorting global known variables: time 7.304e-05/3.073, allocations: 135.5 kB / 1.072 GB, free: 251 MB / 0.7325 GB Notification: Performance of sort global known variables: time 1.7e-07/3.073, allocations: 0 / 1.072 GB, free: 251 MB / 0.7325 GB Notification: Performance of remove unused functions: time 0.0002527/3.073, allocations: 56.12 kB / 1.072 GB, free: 251 MB / 0.7325 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.0007522/3.074, allocations: 0.8682 MB / 1.073 GB, free: 250.1 MB / 0.7325 GB Notification: Performance of simCode: created initialization part: time 0.0004309/3.074, allocations: 230.2 kB / 1.073 GB, free: 250 MB / 0.7325 GB Notification: Performance of simCode: created event and clocks part: time 1.884e-06/3.074, allocations: 0 / 1.073 GB, free: 250 MB / 0.7325 GB Notification: Performance of simCode: created simulation system equations: time 0.000175/3.075, allocations: 87.2 kB / 1.073 GB, free: 249.9 MB / 0.7325 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002696/3.075, allocations: 40.47 kB / 1.073 GB, free: 249.9 MB / 0.7325 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.002282/3.077, allocations: 2.295 MB / 1.076 GB, free: 247.6 MB / 0.7325 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001073/3.077, allocations: 0.7242 MB / 1.076 GB, free: 246.8 MB / 0.7325 GB Notification: Performance of simCode: alias equations: time 0.0001372/3.077, allocations: 25.55 kB / 1.076 GB, free: 246.8 MB / 0.7325 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 8.629e-05/3.078, allocations: 63.41 kB / 1.076 GB, free: 246.7 MB / 0.7325 GB Notification: Performance of SimCode: time 5.01e-07/3.078, allocations: 0 / 1.076 GB, free: 246.7 MB / 0.7325 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.02731/3.105, allocations: 4.622 MB / 1.081 GB, free: 242.3 MB / 0.7325 GB Notification: Performance of buildModelFMU: Generate platform static: time 7.557/10.66, allocations: 7.688 kB / 1.081 GB, free: 242.3 MB / 0.7325 GB (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 & python3 -m fmpy simulate --output-file BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple_res.csv --start-time 0 --stop-time 3.1536e+07 --timeout 50 --relative-tolerance 1e-06 --interface-type ModelExchange --solver CVode --output-interval 12614.4 BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatterySimple.fmu > BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe 2>&1)