Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr Modelica_4.1.0-beta.om_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices trunk/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex trunk/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.1.0-beta.om/package.mo", uses=false) Using package Modelica with version 4.1.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.1.0-beta.om/package.mo) Using package Complex with version trunk (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex trunk/package.mo) Using package ModelicaServices with version trunk (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices trunk/package.mo) Running command: "" <> buildModelFMU(Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge,fileNamePrefix="Modelica_4_1_0-beta_om_Modelica_Electrical_Batteries_Examples_BatteryDischargeCharge",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge,fileNamePrefix="Modelica_4_1_0-beta_om_Modelica_Electrical_Batteries_Examples_BatteryDischargeCharge",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices trunk/package.mo): time 0.001217/0.001218, allocations: 117.6 kB / 17.79 MB, free: 5.254 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex trunk/package.mo): time 0.001282/0.001282, allocations: 200.7 kB / 18.73 MB, free: 4.312 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.1.0-beta.om/package.mo): time 1.366/1.366, allocations: 227.7 MB / 247.2 MB, free: 10.18 MB / 206.1 MB Warning: Requested package Modelica of version trunk, but this package was already loaded with version 4.1.0. OpenModelica cannot reason about compatibility between the two packages since they are not semantic versions. Warning: Requested package Complex of version 4.1.0, but this package was already loaded with version trunk. OpenModelica cannot reason about compatibility between the two packages since they are not semantic versions. Warning: Requested package ModelicaServices of version 4.1.0, but this package was already loaded with version trunk. OpenModelica cannot reason about compatibility between the two packages since they are not semantic versions. Notification: Performance of FrontEnd - loaded program: time 0.002856/0.002856, allocations: 63.89 kB / 358.5 MB, free: 13.25 MB / 302.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.277/0.2799, allocations: 50.55 MB / 409.1 MB, free: 1.344 MB / 318.1 MB Notification: Performance of NFInst.instantiate(Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge): time 0.00724/0.2872, allocations: 5.839 MB / 414.9 MB, free: 11.48 MB / 334.1 MB Notification: Performance of NFInst.instExpressions: time 0.004449/0.2917, allocations: 2.745 MB / 417.7 MB, free: 8.727 MB / 334.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0005655/0.2923, allocations: 19.94 kB / 417.7 MB, free: 8.707 MB / 334.1 MB Notification: Performance of NFTyping.typeComponents: time 0.001555/0.2939, allocations: 0.766 MB / 418.4 MB, free: 7.938 MB / 334.1 MB Notification: Performance of NFTyping.typeBindings: time 0.001122/0.295, allocations: 0.5516 MB / 419 MB, free: 7.383 MB / 334.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.001088/0.2961, allocations: 0.5105 MB / 419.5 MB, free: 6.875 MB / 334.1 MB Notification: Performance of NFFlatten.flatten: time 0.001761/0.2979, allocations: 1.605 MB / 421.1 MB, free: 5.266 MB / 334.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0007802/0.2987, allocations: 0.5923 MB / 421.7 MB, free: 4.645 MB / 334.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0007477/0.2994, allocations: 0.615 MB / 422.3 MB, free: 4.027 MB / 334.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0008763/0.3003, allocations: 0.7393 MB / 423.1 MB, free: 3.285 MB / 334.1 MB Notification: Performance of NFPackage.collectConstants: time 0.000191/0.3005, allocations: 136 kB / 423.2 MB, free: 3.152 MB / 334.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.0004056/0.3009, allocations: 204 kB / 423.4 MB, free: 2.953 MB / 334.1 MB Notification: Performance of NFScalarize.scalarize: time 0.0005716/0.3015, allocations: 0.6504 MB / 424 MB, free: 2.301 MB / 334.1 MB Notification: Performance of NFVerifyModel.verify: time 0.0008515/0.3024, allocations: 0.9205 MB / 425 MB, free: 1.375 MB / 334.1 MB Notification: Performance of NFConvertDAE.convert: time 0.002522/0.3049, allocations: 2.505 MB / 427.5 MB, free: 14.86 MB / 350.1 MB Notification: Performance of FrontEnd - DAE generated: time 3.326e-06/0.3049, allocations: 0 / 427.5 MB, free: 14.86 MB / 350.1 MB Notification: Performance of FrontEnd: time 1.413e-06/0.3049, allocations: 4 kB / 427.5 MB, free: 14.86 MB / 350.1 MB Notification: Performance of Transformations before backend: time 2.875e-05/0.305, allocations: 0 / 427.5 MB, free: 14.86 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: 215 * Number of variables: 215 Notification: Performance of Generate backend data structure: time 0.005111/0.3101, allocations: 2.66 MB / 430.1 MB, free: 12.13 MB / 350.1 MB Notification: Performance of prepare preOptimizeDAE: time 4.686e-05/0.3101, allocations: 8.031 kB / 430.1 MB, free: 12.12 MB / 350.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.0001818/0.3103, allocations: 139.5 kB / 430.3 MB, free: 11.98 MB / 350.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0003723/0.3107, allocations: 239.4 kB / 430.5 MB, free: 11.75 MB / 350.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.002328/0.313, allocations: 1.556 MB / 432.1 MB, free: 10.12 MB / 350.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0001211/0.3132, allocations: 107.9 kB / 432.2 MB, free: 10.01 MB / 350.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0001289/0.3133, allocations: 84 kB / 432.2 MB, free: 9.926 MB / 350.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.001853/0.3152, allocations: 1.1 MB / 433.3 MB, free: 8.746 MB / 350.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 2.041e-05/0.3152, allocations: 0 / 433.3 MB, free: 8.746 MB / 350.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 8.635e-05/0.3153, allocations: 40 kB / 433.4 MB, free: 8.707 MB / 350.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 2.164e-05/0.3153, allocations: 24 kB / 433.4 MB, free: 8.684 MB / 350.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.001363/0.3167, allocations: 0.7221 MB / 434.1 MB, free: 7.965 MB / 350.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.007035/0.3237, allocations: 4.608 MB / 438.7 MB, free: 3.184 MB / 350.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.001397/0.3252, allocations: 0.9373 MB / 439.7 MB, free: 2.145 MB / 350.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0007682/0.326, allocations: 389.1 kB / 440.1 MB, free: 1.762 MB / 350.1 MB Notification: Performance of preOpt evalFunc (simulation): time 5.29e-05/0.326, allocations: 4 kB / 440.1 MB, free: 1.758 MB / 350.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 4.154e-05/0.3261, allocations: 46.5 kB / 440.1 MB, free: 1.703 MB / 350.1 MB Notification: Performance of pre-optimization done (n=44): time 2.795e-06/0.3261, allocations: 0 / 440.1 MB, free: 1.703 MB / 350.1 MB Notification: Performance of matching and sorting (n=44): time 0.001835/0.3279, allocations: 0.8249 MB / 440.9 MB, free: 0.8711 MB / 350.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 0.000231/0.3282, allocations: 427.2 kB / 441.3 MB, free: 364 kB / 350.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0038/0.332, allocations: 2.764 MB / 444.1 MB, free: 13.55 MB / 366.1 MB Notification: Performance of collectPreVariables (initialization): time 8.963e-05/0.3321, allocations: 37.7 kB / 444.1 MB, free: 13.51 MB / 366.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.0008037/0.3329, allocations: 0.8991 MB / 445 MB, free: 12.6 MB / 366.1 MB Notification: Performance of collectInitialBindings (initialization): time 0.0001536/0.3331, allocations: 158.6 kB / 445.2 MB, free: 12.45 MB / 366.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0002261/0.3333, allocations: 126.3 kB / 445.3 MB, free: 12.32 MB / 366.1 MB Notification: Performance of setup shared object (initialization): time 0.000148/0.3334, allocations: 326 kB / 445.6 MB, free: 11.99 MB / 366.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0005599/0.334, allocations: 265.1 kB / 445.9 MB, free: 11.73 MB / 366.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0007715/0.3348, allocations: 0.5285 MB / 446.4 MB, free: 11.09 MB / 366.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.001081/0.3359, allocations: 0.6133 MB / 447 MB, free: 10.39 MB / 366.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 4.588e-06/0.3359, allocations: 0 / 447 MB, free: 10.39 MB / 366.1 MB Notification: Performance of matching and sorting (n=76) (initialization): time 0.001909/0.3378, allocations: 0.862 MB / 447.9 MB, free: 9.527 MB / 366.1 MB Notification: Performance of prepare postOptimizeDAE: time 2.233e-05/0.3378, allocations: 8 kB / 447.9 MB, free: 9.52 MB / 366.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.242e-05/0.3379, allocations: 4 kB / 447.9 MB, free: 9.516 MB / 366.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 2.46e-05/0.3379, allocations: 8 kB / 447.9 MB, free: 9.508 MB / 366.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0006028/0.3385, allocations: 167.9 kB / 448.1 MB, free: 9.344 MB / 366.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.754e-05/0.3385, allocations: 11.98 kB / 448.1 MB, free: 9.332 MB / 366.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.001124/0.3397, allocations: 159.4 kB / 448.3 MB, free: 9.176 MB / 366.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 5.497e-05/0.3397, allocations: 32 kB / 448.3 MB, free: 9.145 MB / 366.1 MB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 25 * Number of states: 0 () * Number of discrete variables: 6 (pulseSeries.on2,pulseSeries.on1,energy2.local_reset,battery2.limIntegrator.local_reset,energy1.local_reset,battery1.limIntegrator.local_reset) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (76): * Single equations (assignments): 76 * 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.0008888/0.3406, allocations: 0.5624 MB / 448.9 MB, free: 8.574 MB / 366.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0003385/0.341, allocations: 194.7 kB / 449 MB, free: 8.383 MB / 366.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001452/0.3424, allocations: 0.6885 MB / 449.7 MB, free: 7.691 MB / 366.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 8.616e-06/0.3424, allocations: 7.938 kB / 449.7 MB, free: 7.684 MB / 366.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 7.313e-06/0.3425, allocations: 0 / 449.7 MB, free: 7.684 MB / 366.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 7.454e-06/0.3425, allocations: 11.92 kB / 449.7 MB, free: 7.672 MB / 366.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0034/0.3459, allocations: 2.125 MB / 451.9 MB, free: 5.473 MB / 366.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 4.739e-06/0.3459, allocations: 4.031 kB / 451.9 MB, free: 5.469 MB / 366.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0004903/0.3464, allocations: 103.9 kB / 452 MB, free: 5.367 MB / 366.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 8.096e-06/0.3464, allocations: 7.938 kB / 452 MB, free: 5.359 MB / 366.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 4.079e-05/0.3465, allocations: 15.98 kB / 452 MB, free: 5.344 MB / 366.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 9.908e-06/0.3465, allocations: 4 kB / 452 MB, free: 5.34 MB / 366.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 3.606e-06/0.3465, allocations: 3.938 kB / 452 MB, free: 5.336 MB / 366.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001884/0.3484, allocations: 1.06 MB / 453.1 MB, free: 4.25 MB / 366.1 MB Notification: Performance of postOpt removeConstants (simulation): time 0.0006541/0.349, allocations: 419.7 kB / 453.5 MB, free: 3.82 MB / 366.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0001727/0.3492, allocations: 12 kB / 453.5 MB, free: 3.809 MB / 366.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.001017/0.3503, allocations: 139.8 kB / 453.6 MB, free: 3.672 MB / 366.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0003073/0.3506, allocations: 159.6 kB / 453.8 MB, free: 3.516 MB / 366.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 4.608e-05/0.3506, allocations: 20 kB / 453.8 MB, free: 3.496 MB / 366.1 MB Notification: Performance of sorting global known variables: time 0.002723/0.3534, allocations: 1.964 MB / 455.8 MB, free: 1.512 MB / 366.1 MB Notification: Performance of sort global known variables: time 2.71e-07/0.3534, allocations: 0 / 455.8 MB, free: 1.512 MB / 366.1 MB Notification: Performance of remove unused functions: time 0.0008729/0.3542, allocations: 315.4 kB / 456.1 MB, free: 1.203 MB / 366.1 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 4 * Number of states: 6 (battery1.limIntegrator.y,energy1.y,battery2.limIntegrator.y,battery2.capacitor[1].v,battery2.capacitor[2].v,energy2.y) * 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 (44): * Single equations (assignments): 44 * 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.003821/0.3581, allocations: 1.983 MB / 458.1 MB, free: 15.36 MB / 382.1 MB Notification: Performance of simCode: created initialization part: time 0.001303/0.3594, allocations: 0.5884 MB / 458.6 MB, free: 14.77 MB / 382.1 MB Notification: Performance of simCode: created event and clocks part: time 4.178e-06/0.3594, allocations: 0 / 458.6 MB, free: 14.77 MB / 382.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0006697/0.3601, allocations: 348.6 kB / 459 MB, free: 14.43 MB / 382.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.001399/0.3615, allocations: 313.6 kB / 459.3 MB, free: 14.12 MB / 382.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.02662/0.3881, allocations: 17.26 MB / 476.6 MB, free: 12.48 MB / 398.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.001243/0.3894, allocations: 1.441 MB / 478 MB, free: 11 MB / 398.1 MB Notification: Performance of simCode: alias equations: time 0.0009798/0.3904, allocations: 291.1 kB / 478.3 MB, free: 10.71 MB / 398.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.000959/0.3914, allocations: 0.7101 MB / 479 MB, free: 10 MB / 398.1 MB Notification: Performance of SimCode: time 1.082e-06/0.3914, allocations: 0 / 479 MB, free: 10 MB / 398.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.07597/0.4674, allocations: 38.97 MB / 0.5058 GB, free: 3.387 MB / 430.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 11.03/11.5, allocations: 10.31 kB / 0.5058 GB, free: 3.379 MB / 430.1 MB (rm -f Modelica_4.1.0-beta.om_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe ; mkfifo Modelica_4.1.0-beta.om_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe ; head -c 1048576 < Modelica_4.1.0-beta.om_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe >> ../files/Modelica_4.1.0-beta.om_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.sim & python3 -m fmpy simulate --output-file Modelica_4.1.0-beta.om_Modelica.Electrical.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 Modelica_4_1_0-beta_om_Modelica_Electrical_Batteries_Examples_BatteryDischargeCharge.fmu > Modelica_4.1.0-beta.om_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe 2>&1)