Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr PowerSysPro_PowerSysPro.Batteries.Examples.BatteryDischargeCharge.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/PowerSysPro 2.3.1-master/package.mo", uses=false) Using package PowerSysPro with version 2.3.1 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/PowerSysPro 2.3.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(PowerSysPro.Batteries.Examples.BatteryDischargeCharge,fileNamePrefix="PowerSysPro_PowerSysPro_Batteries_Examples_BatteryDischargeCharge",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(PowerSysPro.Batteries.Examples.BatteryDischargeCharge,fileNamePrefix="PowerSysPro_PowerSysPro_Batteries_Examples_BatteryDischargeCharge",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.001221/0.001222, allocations: 100.6 kB / 16.45 MB, free: 6.441 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001193/0.001193, allocations: 188.9 kB / 17.38 MB, free: 5.691 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.359/1.359, allocations: 222.9 MB / 241.1 MB, free: 15.08 MB / 206.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/PowerSysPro 2.3.1-master/package.mo): time 0.05118/0.05118, allocations: 8.103 MB / 299.3 MB, free: 6.637 MB / 238.1 MB Notification: Performance of FrontEnd - loaded program: time 0.001719/0.001719, allocations: 55.91 kB / 414 MB, free: 22.07 MB / 302.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.09337/0.0951, allocations: 51.52 MB / 465.6 MB, free: 2.5 MB / 334.1 MB Notification: Performance of NFInst.instantiate(PowerSysPro.Batteries.Examples.BatteryDischargeCharge): time 0.00366/0.0988, allocations: 2.382 MB / 467.9 MB, free: 108 kB / 334.1 MB Notification: Performance of NFInst.instExpressions: time 0.0008701/0.09969, allocations: 0.506 MB / 468.5 MB, free: 15.6 MB / 350.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0001168/0.09982, allocations: 4 kB / 468.5 MB, free: 15.59 MB / 350.1 MB Notification: Performance of NFTyping.typeComponents: time 0.0003708/0.1002, allocations: 95.72 kB / 468.5 MB, free: 15.5 MB / 350.1 MB Notification: Performance of NFTyping.typeBindings: time 0.0002045/0.1004, allocations: 91.38 kB / 468.6 MB, free: 15.41 MB / 350.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.0002312/0.1007, allocations: 79.86 kB / 468.7 MB, free: 15.33 MB / 350.1 MB Notification: Performance of NFFlatten.flatten: time 0.0003027/0.101, allocations: 286.9 kB / 469 MB, free: 15.05 MB / 350.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0002059/0.1012, allocations: 111.3 kB / 469.1 MB, free: 14.94 MB / 350.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0001457/0.1013, allocations: 107.7 kB / 469.2 MB, free: 14.84 MB / 350.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.000224/0.1016, allocations: 139.4 kB / 469.3 MB, free: 14.7 MB / 350.1 MB Notification: Performance of NFPackage.collectConstants: time 5.346e-05/0.1016, allocations: 28 kB / 469.4 MB, free: 14.67 MB / 350.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.0001608/0.1018, allocations: 87.97 kB / 469.5 MB, free: 14.59 MB / 350.1 MB Notification: Performance of NFScalarize.scalarize: time 0.0001797/0.102, allocations: 111.6 kB / 469.6 MB, free: 14.48 MB / 350.1 MB Notification: Performance of NFVerifyModel.verify: time 0.0001526/0.1022, allocations: 151.2 kB / 469.7 MB, free: 14.33 MB / 350.1 MB Notification: Performance of NFConvertDAE.convert: time 0.0004874/0.1026, allocations: 402.5 kB / 470.1 MB, free: 13.93 MB / 350.1 MB Notification: Performance of FrontEnd - DAE generated: time 3.326e-06/0.1027, allocations: 0 / 470.1 MB, free: 13.93 MB / 350.1 MB Notification: Performance of FrontEnd: time 1.493e-06/0.1027, allocations: 0 / 470.1 MB, free: 13.93 MB / 350.1 MB Notification: Performance of Transformations before backend: time 6.302e-06/0.1027, allocations: 0 / 470.1 MB, free: 13.93 MB / 350.1 MB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 40 * Number of variables: 40 Notification: Performance of Generate backend data structure: time 0.001922/0.1046, allocations: 0.8024 MB / 470.9 MB, free: 13.07 MB / 350.1 MB Notification: Performance of prepare preOptimizeDAE: time 3.995e-05/0.1047, allocations: 11.89 kB / 470.9 MB, free: 13.06 MB / 350.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 6.669e-05/0.1047, allocations: 54.73 kB / 471 MB, free: 13 MB / 350.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 7.543e-05/0.1048, allocations: 36.7 kB / 471 MB, free: 12.96 MB / 350.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0004621/0.1053, allocations: 355.6 kB / 471.4 MB, free: 12.58 MB / 350.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 2.068e-05/0.1053, allocations: 8.703 kB / 471.4 MB, free: 12.57 MB / 350.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 4.194e-05/0.1054, allocations: 20.38 kB / 471.4 MB, free: 12.55 MB / 350.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0005245/0.1059, allocations: 283 kB / 471.7 MB, free: 12.25 MB / 350.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 1.412e-05/0.1059, allocations: 3.938 kB / 471.7 MB, free: 12.25 MB / 350.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 2.83e-05/0.1059, allocations: 11.94 kB / 471.7 MB, free: 12.23 MB / 350.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 6.893e-06/0.106, allocations: 4 kB / 471.7 MB, free: 12.23 MB / 350.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0004079/0.1064, allocations: 192.1 kB / 471.9 MB, free: 12.04 MB / 350.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001391/0.1078, allocations: 0.8533 MB / 472.7 MB, free: 11.12 MB / 350.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0006496/0.1084, allocations: 295.7 kB / 473 MB, free: 10.81 MB / 350.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0003488/0.1088, allocations: 140.8 kB / 473.2 MB, free: 10.67 MB / 350.1 MB Notification: Performance of preOpt evalFunc (simulation): time 4.093e-05/0.1088, allocations: 7.984 kB / 473.2 MB, free: 10.66 MB / 350.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 3.059e-05/0.1089, allocations: 42.5 kB / 473.2 MB, free: 10.61 MB / 350.1 MB Notification: Performance of pre-optimization done (n=13): time 1.423e-06/0.1089, allocations: 3.938 kB / 473.2 MB, free: 10.61 MB / 350.1 MB Notification: Performance of matching and sorting (n=13): time 0.0007947/0.1097, allocations: 277.5 kB / 473.5 MB, free: 10.33 MB / 350.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 0.0001637/0.1099, allocations: 213.6 kB / 473.7 MB, free: 10.07 MB / 350.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0004186/0.1103, allocations: 370.6 kB / 474 MB, free: 9.703 MB / 350.1 MB Notification: Performance of collectPreVariables (initialization): time 2.609e-05/0.1103, allocations: 29.7 kB / 474.1 MB, free: 9.668 MB / 350.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.0001216/0.1105, allocations: 164.3 kB / 474.2 MB, free: 9.504 MB / 350.1 MB Notification: Performance of collectInitialBindings (initialization): time 4.353e-05/0.1105, allocations: 43.64 kB / 474.3 MB, free: 9.461 MB / 350.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 8.086e-05/0.1106, allocations: 37.7 kB / 474.3 MB, free: 9.418 MB / 350.1 MB Notification: Performance of setup shared object (initialization): time 0.000137/0.1107, allocations: 342.8 kB / 474.6 MB, free: 9.074 MB / 350.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0002046/0.1109, allocations: 79.94 kB / 474.7 MB, free: 8.996 MB / 350.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0002644/0.1112, allocations: 151.6 kB / 474.9 MB, free: 8.82 MB / 350.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0007847/0.112, allocations: 238.3 kB / 475.1 MB, free: 8.578 MB / 350.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 1.854e-06/0.112, allocations: 0 / 475.1 MB, free: 8.578 MB / 350.1 MB Notification: Performance of matching and sorting (n=15) (initialization): time 0.0004808/0.1125, allocations: 221.4 kB / 475.3 MB, free: 8.355 MB / 350.1 MB Notification: Performance of prepare postOptimizeDAE: time 1.528e-05/0.1125, allocations: 4 kB / 475.3 MB, free: 8.352 MB / 350.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 6.292e-06/0.1125, allocations: 4 kB / 475.3 MB, free: 8.348 MB / 350.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 1.286e-05/0.1126, allocations: 0 / 475.3 MB, free: 8.348 MB / 350.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0001552/0.1127, allocations: 31.97 kB / 475.4 MB, free: 8.316 MB / 350.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 8.095e-06/0.1127, allocations: 4 kB / 475.4 MB, free: 8.312 MB / 350.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.000514/0.1133, allocations: 87.88 kB / 475.5 MB, free: 8.227 MB / 350.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 2.763e-05/0.1133, allocations: 15.98 kB / 475.5 MB, free: 8.211 MB / 350.1 MB Warning: Assuming fixed start value for the following 1 variables: battery.integrator.q:VARIABLE(flow=false start = battery.SOC_start fixed = true ) "Charge as current integration" 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: 2 (pulseSeries.on2,pulseSeries.on1) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (15): * Single equations (assignments): 15 * Array equations: 0 * Algorithm blocks: 0 * 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.0002724/0.1136, allocations: 166.6 kB / 475.6 MB, free: 8.039 MB / 350.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0001125/0.1137, allocations: 35.8 kB / 475.7 MB, free: 8.004 MB / 350.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0005903/0.1143, allocations: 239.3 kB / 475.9 MB, free: 7.762 MB / 350.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 5.22e-06/0.1143, allocations: 4 kB / 475.9 MB, free: 7.758 MB / 350.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 4.899e-06/0.1143, allocations: 0 / 475.9 MB, free: 7.758 MB / 350.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 3.346e-06/0.1143, allocations: 0 / 475.9 MB, free: 7.758 MB / 350.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.001005/0.1153, allocations: 0.6667 MB / 476.6 MB, free: 7.031 MB / 350.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.004e-06/0.1153, allocations: 0 / 476.6 MB, free: 7.031 MB / 350.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0001532/0.1155, allocations: 31.97 kB / 476.6 MB, free: 7 MB / 350.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 2.515e-06/0.1155, allocations: 0 / 476.6 MB, free: 7 MB / 350.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 1.993e-05/0.1155, allocations: 7.969 kB / 476.6 MB, free: 6.992 MB / 350.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 1.239e-05/0.1156, allocations: 4 kB / 476.6 MB, free: 6.988 MB / 350.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.232e-06/0.1156, allocations: 0 / 476.6 MB, free: 6.988 MB / 350.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0007758/0.1163, allocations: 428 kB / 477 MB, free: 6.551 MB / 350.1 MB Notification: Performance of postOpt removeConstants (simulation): time 9.368e-05/0.1164, allocations: 108.9 kB / 477.1 MB, free: 6.426 MB / 350.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 5.061e-05/0.1165, allocations: 11.94 kB / 477.1 MB, free: 6.414 MB / 350.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0005339/0.117, allocations: 83.94 kB / 477.2 MB, free: 6.332 MB / 350.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0002645/0.1173, allocations: 127.8 kB / 477.4 MB, free: 6.207 MB / 350.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 1.878e-05/0.1173, allocations: 7.984 kB / 477.4 MB, free: 6.199 MB / 350.1 MB Notification: Performance of sorting global known variables: time 0.0003159/0.1177, allocations: 269.9 kB / 477.6 MB, free: 5.934 MB / 350.1 MB Notification: Performance of sort global known variables: time 1.2e-07/0.1177, allocations: 3.938 kB / 477.6 MB, free: 5.93 MB / 350.1 MB Notification: Performance of remove unused functions: time 0.0003359/0.118, allocations: 71.88 kB / 477.7 MB, free: 5.859 MB / 350.1 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 2 * Number of states: 1 (battery.integrator.q) * Number of discrete variables: 2 (pulseSeries.on1,pulseSeries.on2) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (13): * Single equations (assignments): 13 * Array equations: 0 * Algorithm blocks: 0 * 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 Backend phase and start with SimCode phase: time 0.001839/0.1199, allocations: 1.12 MB / 478.8 MB, free: 4.793 MB / 350.1 MB Notification: Performance of simCode: created initialization part: time 0.0005236/0.1204, allocations: 203.8 kB / 479 MB, free: 4.594 MB / 350.1 MB Notification: Performance of simCode: created event and clocks part: time 2.685e-06/0.1204, allocations: 3.938 kB / 479 MB, free: 4.59 MB / 350.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0003044/0.1207, allocations: 139.8 kB / 479.2 MB, free: 4.453 MB / 350.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0003252/0.1211, allocations: 27.83 kB / 479.2 MB, free: 4.43 MB / 350.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.004915/0.126, allocations: 3.079 MB / 482.3 MB, free: 1.254 MB / 350.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0004083/0.1264, allocations: 0.7596 MB / 483 MB, free: 476 kB / 350.1 MB Notification: Performance of simCode: alias equations: time 0.0001403/0.1266, allocations: 37.55 kB / 483.1 MB, free: 440 kB / 350.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0002185/0.1268, allocations: 83.41 kB / 483.1 MB, free: 356 kB / 350.1 MB Notification: Performance of SimCode: time 5.01e-07/0.1268, allocations: 0 / 483.1 MB, free: 356 kB / 350.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.03234/0.1591, allocations: 8.177 MB / 491.3 MB, free: 8.266 MB / 366.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 8.095/8.254, allocations: 4.062 kB / 491.3 MB, free: 8.262 MB / 366.1 MB (rm -f PowerSysPro_PowerSysPro.Batteries.Examples.BatteryDischargeCharge.pipe ; mkfifo PowerSysPro_PowerSysPro.Batteries.Examples.BatteryDischargeCharge.pipe ; head -c 1048576 < PowerSysPro_PowerSysPro.Batteries.Examples.BatteryDischargeCharge.pipe >> ../files/PowerSysPro_PowerSysPro.Batteries.Examples.BatteryDischargeCharge.sim & python3 -m fmpy simulate --output-file PowerSysPro_PowerSysPro.Batteries.Examples.BatteryDischargeCharge_res.csv --start-time 0 --stop-time 3600 --timeout 50 --relative-tolerance 1e-06 --interface-type ModelExchange --solver CVode --output-interval 0.1 PowerSysPro_PowerSysPro_Batteries_Examples_BatteryDischargeCharge.fmu > PowerSysPro_PowerSysPro.Batteries.Examples.BatteryDischargeCharge.pipe 2>&1)