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/BuildingSystems 2.0.0-master/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) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo", uses=false) Using package NcDataReader2 with version 2.5.1 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/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) 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 BuildingSystems with version 2.0.0-beta (/home/hudson/saved_omc/libraries/.openmodelica/libraries/BuildingSystems 2.0.0-master/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/BuildingSystems 2.0.0-master/package.mo): time 0.7927/0.7927, allocations: 143.3 MB / 158.3 MB, free: 5.785 MB / 122.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001022/0.001022, allocations: 185 kB / 191.5 MB, free: 5.742 MB / 154.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 1.405/1.405, allocations: 223.1 MB / 447.7 MB, free: 4.836 MB / 330.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.0008848/0.0008849, allocations: 100.2 kB / 0.5187 GB, free: 1.18 MB / 410.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/NcDataReader2 2.5.1-master/package.mo): time 0.00175/0.00175, allocations: 270 kB / 0.6005 GB, free: 48.75 MB / 410.7 MB Notification: Performance of FrontEnd - loaded program: time 0.0004401/0.0004402, allocations: 10.5 kB / 0.6929 GB, free: 59.62 MB / 442.7 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.178/0.1784, allocations: 82.8 MB / 0.7738 GB, free: 13.77 MB / 458.7 MB Notification: Performance of FrontEnd - scodeFlatten: time 0.6011/0.7796, allocations: 111.4 MB / 0.8825 GB, free: 32.12 MB / 0.5417 GB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0002838/0.7799, allocations: 74.77 kB / 0.8826 GB, free: 32.12 MB / 0.5417 GB Notification: Performance of FrontEnd - DAE generated: time 0.01225/0.7922, allocations: 4.133 MB / 0.8867 GB, free: 31.46 MB / 0.5417 GB Notification: Performance of FrontEnd: time 1.954e-06/0.7922, allocations: 0 / 0.8867 GB, free: 31.46 MB / 0.5417 GB Notification: Performance of Transformations before backend: time 9.628e-06/0.7922, allocations: 2.906 kB / 0.8867 GB, free: 31.46 MB / 0.5417 GB 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.0007852/0.7931, allocations: 0.4953 MB / 0.8871 GB, free: 31.02 MB / 0.5417 GB Notification: Performance of prepare preOptimizeDAE: time 4.479e-05/0.7931, allocations: 11.28 kB / 0.8871 GB, free: 31.02 MB / 0.5417 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 4.619e-05/0.7932, allocations: 37.69 kB / 0.8872 GB, free: 30.98 MB / 0.5417 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 5.099e-05/0.7932, allocations: 16.47 kB / 0.8872 GB, free: 30.97 MB / 0.5417 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0001527/0.7934, allocations: 220.4 kB / 0.8874 GB, free: 30.74 MB / 0.5417 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.788e-05/0.7934, allocations: 7.859 kB / 0.8874 GB, free: 30.74 MB / 0.5417 GB Notification: Performance of preOpt expandDerOperator (simulation): time 3.264e-05/0.7934, allocations: 7.562 kB / 0.8874 GB, free: 30.74 MB / 0.5417 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0003258/0.7938, allocations: 130.7 kB / 0.8875 GB, free: 30.71 MB / 0.5417 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.259e-05/0.7938, allocations: 1.219 kB / 0.8875 GB, free: 30.71 MB / 0.5417 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.831e-05/0.7938, allocations: 5.172 kB / 0.8876 GB, free: 30.71 MB / 0.5417 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 5.961e-06/0.7938, allocations: 3.5 kB / 0.8876 GB, free: 30.71 MB / 0.5417 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0003494/0.7942, allocations: 117.3 kB / 0.8877 GB, free: 30.7 MB / 0.5417 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0007051/0.7949, allocations: 448.6 kB / 0.8881 GB, free: 30.42 MB / 0.5417 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0003521/0.7953, allocations: 144.5 kB / 0.8882 GB, free: 30.39 MB / 0.5417 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0005843/0.7959, allocations: 439.4 kB / 0.8887 GB, free: 29.93 MB / 0.5417 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0002978/0.7962, allocations: 141.3 kB / 0.8888 GB, free: 29.87 MB / 0.5417 GB Notification: Performance of pre-optimization done (n=16): time 1.593e-06/0.7962, allocations: 0 / 0.8888 GB, free: 29.87 MB / 0.5417 GB Notification: Performance of matching and sorting (n=16): time 0.0006789/0.7969, allocations: 256.2 kB / 0.889 GB, free: 29.82 MB / 0.5417 GB Notification: Performance of inlineWhenForInitialization (initialization): time 2.831e-05/0.7969, allocations: 55.17 kB / 0.8891 GB, free: 29.76 MB / 0.5417 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0001602/0.7971, allocations: 177.5 kB / 0.8893 GB, free: 29.66 MB / 0.5417 GB Notification: Performance of collectPreVariables (initialization): time 2.129e-05/0.7971, allocations: 32.3 kB / 0.8893 GB, free: 29.63 MB / 0.5417 GB Notification: Performance of collectInitialEqns (initialization): time 5.665e-05/0.7972, allocations: 108.2 kB / 0.8894 GB, free: 29.55 MB / 0.5417 GB Notification: Performance of collectInitialBindings (initialization): time 4.686e-05/0.7972, allocations: 64.42 kB / 0.8895 GB, free: 29.51 MB / 0.5417 GB Notification: Performance of simplifyInitialFunctions (initialization): time 1.059e-05/0.7972, allocations: 7.938 kB / 0.8895 GB, free: 29.5 MB / 0.5417 GB Notification: Performance of setup shared object (initialization): time 6.755e-05/0.7973, allocations: 330.2 kB / 0.8898 GB, free: 29.19 MB / 0.5417 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0001935/0.7975, allocations: 78.95 kB / 0.8898 GB, free: 29.18 MB / 0.5417 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0002047/0.7977, allocations: 103.1 kB / 0.8899 GB, free: 29.15 MB / 0.5417 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.000199/0.7979, allocations: 103.2 kB / 0.89 GB, free: 29.11 MB / 0.5417 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 2.785e-06/0.7979, allocations: 0 / 0.89 GB, free: 29.11 MB / 0.5417 GB Notification: Performance of matching and sorting (n=23) (initialization): time 0.0005513/0.7985, allocations: 270.4 kB / 0.8903 GB, free: 29.03 MB / 0.5417 GB Notification: Performance of prepare postOptimizeDAE: time 2.897e-05/0.7985, allocations: 33.12 kB / 0.8903 GB, free: 29 MB / 0.5417 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 6.933e-06/0.7985, allocations: 0.6094 kB / 0.8903 GB, free: 29 MB / 0.5417 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.472e-05/0.7986, allocations: 3.438 kB / 0.8903 GB, free: 29 MB / 0.5417 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0002682/0.7988, allocations: 45.98 kB / 0.8904 GB, free: 29 MB / 0.5417 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 6.723e-06/0.7989, allocations: 1.375 kB / 0.8904 GB, free: 29 MB / 0.5417 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0002085/0.7991, allocations: 34.16 kB / 0.8904 GB, free: 28.98 MB / 0.5417 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 2.27e-05/0.7991, allocations: 10 kB / 0.8904 GB, free: 28.98 MB / 0.5417 GB Warning: Assuming fixed start value for the following 4 variables: battery.E_discharged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy taken from the battery" type: Real battery.E_charged:VARIABLE(start = 0.0 unit = "J" fixed = true ) "Total energy charged to the battery" type: Real battery.EBou:VARIABLE(start = (1.0 - battery.c) * battery.SOC_start * battery.E_nominal unit = "J" fixed = true ) "Bound charge of the battery" type: Real battery.EAva:VARIABLE(start = battery.c * battery.SOC_start * battery.E_nominal unit = "J" fixed = true ) "Available 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 ($whenCondition1,$PRE.gain.T_start,gain.T_start,$PRE.gain.count,gain.count) * 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 (linear and non-linear blocks): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of prepare postOptimizeDAE: time 0.0001873/0.7993, allocations: 141.2 kB / 0.8906 GB, free: 28.87 MB / 0.5417 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 2.912e-05/0.7993, allocations: 16.86 kB / 0.8906 GB, free: 28.86 MB / 0.5417 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.00062/0.8, allocations: 259.3 kB / 0.8908 GB, free: 28.81 MB / 0.5417 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 5.35e-06/0.8, allocations: 2.156 kB / 0.8908 GB, free: 28.81 MB / 0.5417 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.34e-06/0.8, allocations: 5.281 kB / 0.8908 GB, free: 28.8 MB / 0.5417 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 6.252e-06/0.8, allocations: 1.781 kB / 0.8908 GB, free: 28.8 MB / 0.5417 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.000274/0.8003, allocations: 273.8 kB / 0.8911 GB, free: 28.6 MB / 0.5417 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.234e-06/0.8003, allocations: 0.6562 kB / 0.8911 GB, free: 28.6 MB / 0.5417 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0002738/0.8006, allocations: 44.48 kB / 0.8911 GB, free: 28.6 MB / 0.5417 GB Notification: Performance of postOpt tearingSystem (simulation): time 3.527e-06/0.8006, allocations: 2.656 kB / 0.8911 GB, free: 28.6 MB / 0.5417 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.208e-05/0.8006, allocations: 5.141 kB / 0.8911 GB, free: 28.6 MB / 0.5417 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 3.807e-06/0.8006, allocations: 6.812 kB / 0.8912 GB, free: 28.6 MB / 0.5417 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.324e-06/0.8006, allocations: 0.6562 kB / 0.8912 GB, free: 28.6 MB / 0.5417 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.000759/0.8014, allocations: 343.9 kB / 0.8915 GB, free: 28.51 MB / 0.5417 GB Notification: Performance of postOpt removeConstants (simulation): time 9.119e-05/0.8015, allocations: 109.3 kB / 0.8916 GB, free: 28.41 MB / 0.5417 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 3.58e-05/0.8015, allocations: 4.641 kB / 0.8916 GB, free: 28.41 MB / 0.5417 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001849/0.8017, allocations: 26.36 kB / 0.8916 GB, free: 28.4 MB / 0.5417 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 8.175e-05/0.8018, allocations: 20.78 kB / 0.8916 GB, free: 28.4 MB / 0.5417 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 1.649e-05/0.8018, allocations: 3.625 kB / 0.8916 GB, free: 28.4 MB / 0.5417 GB Notification: Performance of sorting global known variables: time 0.00011/0.802, allocations: 143.4 kB / 0.8918 GB, free: 28.32 MB / 0.5417 GB Notification: Performance of sort global known variables: time 1.2e-07/0.802, allocations: 0 / 0.8918 GB, free: 28.32 MB / 0.5417 GB Notification: Performance of remove unused functions: time 0.0003412/0.8023, allocations: 71.75 kB / 0.8918 GB, free: 28.31 MB / 0.5417 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 (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.0009549/0.8033, allocations: 0.9051 MB / 0.8927 GB, free: 27.69 MB / 0.5417 GB Notification: Performance of simCode: created initialization part: time 0.0004695/0.8038, allocations: 233.8 kB / 0.8929 GB, free: 27.62 MB / 0.5417 GB Notification: Performance of simCode: created event and clocks part: time 2.174e-06/0.8038, allocations: 4.125 kB / 0.893 GB, free: 27.62 MB / 0.5417 GB Notification: Performance of simCode: created simulation system equations: time 0.0002135/0.804, allocations: 98.36 kB / 0.893 GB, free: 27.61 MB / 0.5417 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002452/0.8042, allocations: 29.64 kB / 0.8931 GB, free: 27.61 MB / 0.5417 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.003268/0.8075, allocations: 1.721 MB / 0.8948 GB, free: 42.6 MB / 0.5573 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0003403/0.8079, allocations: 0.7305 MB / 0.8955 GB, free: 41.9 MB / 0.5573 GB Notification: Performance of simCode: alias equations: time 0.000134/0.8081, allocations: 25.3 kB / 0.8955 GB, free: 41.89 MB / 0.5573 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.000122/0.8082, allocations: 56.55 kB / 0.8955 GB, free: 41.88 MB / 0.5573 GB Notification: Performance of SimCode: time 9.42e-07/0.8082, allocations: 0 / 0.8955 GB, free: 41.88 MB / 0.5573 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.02114/0.8293, allocations: 4.46 MB / 0.8999 GB, free: 41.56 MB / 0.5573 GB Notification: Performance of buildModelFMU: configured platform static using cached values: time 0.0002592/0.8297, allocations: 206.6 kB / 0.9001 GB, free: 41.32 MB / 0.5573 GB Notification: Performance of buildModelFMU: Generate platform static: time 1.849/2.678, allocations: 4 kB / 0.9001 GB, free: 41.32 MB / 0.5573 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 & /home/hudson/saved_omc/OMSimulator/install/linux/bin/OMSimulator --tempDir=temp_BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatterySimple_fmu --startTime=0 --stopTime=3.1536e+07 --timeout=50 --tolerance=1e-06 BuildingSystems_BuildingSystems_Technologies_ElectricalStorages_Examples_BatterySimple.fmu > BuildingSystems_BuildingSystems.Technologies.ElectricalStorages.Examples.BatterySimple.pipe 2>&1)