Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr AES_AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec.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/AES main/package.mo", uses=false) Using package AES with version (/home/hudson/saved_omc/libraries/.openmodelica/libraries/AES main/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(AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec,fileNamePrefix="AES_AES_Coursework_ElecSys_power_frequency_control_BO_rigid_two_generators_PriSec",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec,fileNamePrefix="AES_AES_Coursework_ElecSys_power_frequency_control_BO_rigid_two_generators_PriSec",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.001691/0.001691, 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.001872/0.001872, allocations: 194.1 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.391/1.391, allocations: 222.9 MB / 240.2 MB, free: 4.391 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/AES main/package.mo): time 0.1966/0.1966, allocations: 22.35 MB / 312.7 MB, free: 12.59 MB / 254.1 MB Notification: Performance of FrontEnd - loaded program: time 0.001368/0.001368, allocations: 63.89 kB / 380.9 MB, free: 10.5 MB / 318.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.258/0.2594, allocations: 54.95 MB / 435.9 MB, free: 39.62 MB / 350.1 MB Notification: Performance of NFInst.instantiate(AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec): time 0.002351/0.2618, allocations: 1.404 MB / 437.3 MB, free: 38.68 MB / 350.1 MB Notification: Performance of NFInst.instExpressions: time 0.001611/0.2634, allocations: 1.369 MB / 438.6 MB, free: 37.68 MB / 350.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.000158/0.2636, allocations: 4.875 kB / 438.7 MB, free: 37.68 MB / 350.1 MB Notification: Performance of NFTyping.typeComponents: time 0.0003451/0.264, allocations: 88.83 kB / 438.7 MB, free: 37.63 MB / 350.1 MB Notification: Performance of NFTyping.typeBindings: time 0.0002204/0.2642, allocations: 92.08 kB / 438.8 MB, free: 37.58 MB / 350.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.0002905/0.2645, allocations: 176.8 kB / 439 MB, free: 37.49 MB / 350.1 MB Notification: Performance of NFFlatten.flatten: time 0.0003067/0.2648, allocations: 355.8 kB / 439.4 MB, free: 37.36 MB / 350.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0001689/0.265, allocations: 93.84 kB / 439.4 MB, free: 37.31 MB / 350.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0001486/0.2652, allocations: 148.3 kB / 439.6 MB, free: 37.25 MB / 350.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0001939/0.2654, allocations: 164.5 kB / 439.7 MB, free: 37.17 MB / 350.1 MB Notification: Performance of NFPackage.collectConstants: time 4.36e-05/0.2654, allocations: 17.69 kB / 439.8 MB, free: 37.17 MB / 350.1 MB Notification: Performance of NFFlatten.collectFunctions: time 3.683e-05/0.2655, allocations: 20.75 kB / 439.8 MB, free: 37.17 MB / 350.1 MB Notification: Performance of NFScalarize.scalarize: time 8.959e-05/0.2656, allocations: 73.53 kB / 439.9 MB, free: 37.14 MB / 350.1 MB Notification: Performance of NFVerifyModel.verify: time 8.531e-05/0.2657, allocations: 122.2 kB / 440 MB, free: 37.05 MB / 350.1 MB Notification: Performance of NFConvertDAE.convert: time 0.0002088/0.2659, allocations: 250.2 kB / 440.2 MB, free: 36.93 MB / 350.1 MB Notification: Performance of FrontEnd - DAE generated: time 3.236e-06/0.2659, allocations: 0 / 440.2 MB, free: 36.93 MB / 350.1 MB Notification: Performance of FrontEnd: time 1.533e-06/0.2659, allocations: 0 / 440.2 MB, free: 36.93 MB / 350.1 MB Notification: Performance of Transformations before backend: time 8.236e-06/0.2659, allocations: 0 / 440.2 MB, free: 36.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: 43 * Number of variables: 43 Notification: Performance of Generate backend data structure: time 0.001377/0.2673, allocations: 0.6915 MB / 440.9 MB, free: 36.43 MB / 350.1 MB Notification: Performance of prepare preOptimizeDAE: time 3.931e-05/0.2674, allocations: 11.56 kB / 440.9 MB, free: 36.43 MB / 350.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 4.179e-05/0.2674, allocations: 51.67 kB / 441 MB, free: 36.38 MB / 350.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 6.106e-05/0.2675, allocations: 34.97 kB / 441 MB, free: 36.36 MB / 350.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0008687/0.2683, allocations: 382.8 kB / 441.4 MB, free: 36.09 MB / 350.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 2.141e-05/0.2684, allocations: 22.02 kB / 441.4 MB, free: 36.07 MB / 350.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 4.228e-05/0.2684, allocations: 18.28 kB / 441.4 MB, free: 36.07 MB / 350.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0002849/0.2687, allocations: 214.1 kB / 441.6 MB, free: 35.94 MB / 350.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 9.859e-06/0.2687, allocations: 3.938 kB / 441.6 MB, free: 35.93 MB / 350.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.85e-05/0.2688, allocations: 7.25 kB / 441.6 MB, free: 35.93 MB / 350.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 7.424e-06/0.2688, allocations: 2.625 kB / 441.6 MB, free: 35.93 MB / 350.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0002521/0.269, allocations: 157.4 kB / 441.8 MB, free: 35.88 MB / 350.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0009265/0.27, allocations: 0.9542 MB / 442.8 MB, free: 35.13 MB / 350.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0005146/0.2705, allocations: 238.4 kB / 443 MB, free: 35.05 MB / 350.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0001206/0.2706, allocations: 86.52 kB / 443.1 MB, free: 35.01 MB / 350.1 MB Notification: Performance of preOpt evalFunc (simulation): time 1.869e-05/0.2707, allocations: 6.969 kB / 443.1 MB, free: 35 MB / 350.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 1.464e-05/0.2707, allocations: 30.56 kB / 443.1 MB, free: 34.96 MB / 350.1 MB Notification: Performance of pre-optimization done (n=20): time 2.254e-06/0.2707, allocations: 3.984 kB / 443.1 MB, free: 34.96 MB / 350.1 MB Notification: Performance of matching and sorting (n=20): time 0.0004425/0.2711, allocations: 251.9 kB / 443.4 MB, free: 34.86 MB / 350.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 2.184e-05/0.2712, allocations: 54.28 kB / 443.4 MB, free: 34.79 MB / 350.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0006273/0.2718, allocations: 369.4 kB / 443.8 MB, free: 34.62 MB / 350.1 MB Notification: Performance of collectPreVariables (initialization): time 1.493e-05/0.2718, allocations: 32.67 kB / 443.8 MB, free: 34.59 MB / 350.1 MB Notification: Performance of collectInitialEqns (initialization): time 7.957e-05/0.2719, allocations: 179.8 kB / 444 MB, free: 34.43 MB / 350.1 MB Notification: Performance of collectInitialBindings (initialization): time 4.327e-05/0.272, allocations: 74.08 kB / 444 MB, free: 34.38 MB / 350.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 6.287e-05/0.272, allocations: 50.09 kB / 444.1 MB, free: 34.34 MB / 350.1 MB Notification: Performance of setup shared object (initialization): time 5.754e-05/0.2721, allocations: 350.9 kB / 444.4 MB, free: 34.01 MB / 350.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0001118/0.2722, allocations: 60.98 kB / 444.5 MB, free: 33.98 MB / 350.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0001179/0.2723, allocations: 100.3 kB / 444.6 MB, free: 33.92 MB / 350.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0009627/0.2733, allocations: 375.2 kB / 445 MB, free: 33.78 MB / 350.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 2.525e-06/0.2733, allocations: 3.938 kB / 445 MB, free: 33.77 MB / 350.1 MB Notification: Performance of matching and sorting (n=28) (initialization): time 0.0003466/0.2737, allocations: 250.9 kB / 445.2 MB, free: 33.66 MB / 350.1 MB Notification: Performance of prepare postOptimizeDAE: time 1.528e-05/0.2737, allocations: 5.75 kB / 445.2 MB, free: 33.66 MB / 350.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 7.444e-06/0.2737, allocations: 2.812 kB / 445.2 MB, free: 33.66 MB / 350.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 1.646e-05/0.2737, allocations: 6.875 kB / 445.2 MB, free: 33.66 MB / 350.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0001802/0.2739, allocations: 52.44 kB / 445.3 MB, free: 33.64 MB / 350.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 8.215e-06/0.2739, allocations: 3.281 kB / 445.3 MB, free: 33.64 MB / 350.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0002814/0.2742, allocations: 43.62 kB / 445.3 MB, free: 33.63 MB / 350.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 1.342e-05/0.2742, allocations: 6.094 kB / 445.3 MB, free: 33.63 MB / 350.1 MB Warning: Assuming fixed start value for the following 2 variables: g2.x_scaled[1]:VARIABLE(fixed = true protected = true ) "Scaled vector x" type: Real [1] g1.x_scaled[1]:VARIABLE(fixed = true protected = true ) "Scaled vector x" type: Real [1] Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 5 * Number of states: 0 () * Number of discrete variables: 2 (Cs.local_reset,N.local_reset) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (28): * Single equations (assignments): 28 * 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.0001517/0.2744, allocations: 159 kB / 445.5 MB, free: 33.48 MB / 350.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 5.15e-05/0.2745, allocations: 27.09 kB / 445.5 MB, free: 33.47 MB / 350.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 6.015e-05/0.2745, allocations: 38.23 kB / 445.6 MB, free: 33.45 MB / 350.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 4.428e-06/0.2745, allocations: 6.906 kB / 445.6 MB, free: 33.44 MB / 350.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 7.063e-06/0.2745, allocations: 0 / 445.6 MB, free: 33.44 MB / 350.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 4.508e-06/0.2746, allocations: 3.328 kB / 445.6 MB, free: 33.44 MB / 350.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0002687/0.2748, allocations: 320 kB / 445.9 MB, free: 33.2 MB / 350.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 1.763e-06/0.2748, allocations: 0 / 445.9 MB, free: 33.2 MB / 350.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0001882/0.275, allocations: 30.25 kB / 445.9 MB, free: 33.2 MB / 350.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 2.565e-06/0.275, allocations: 0 / 445.9 MB, free: 33.2 MB / 350.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 1.858e-05/0.2751, allocations: 10.94 kB / 445.9 MB, free: 33.19 MB / 350.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 1.884e-06/0.2751, allocations: 3.938 kB / 445.9 MB, free: 33.18 MB / 350.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.233e-06/0.2751, allocations: 2.875 kB / 445.9 MB, free: 33.18 MB / 350.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0004371/0.2755, allocations: 386.5 kB / 446.3 MB, free: 32.95 MB / 350.1 MB Notification: Performance of postOpt removeConstants (simulation): time 5.822e-05/0.2756, allocations: 111.9 kB / 446.4 MB, free: 32.84 MB / 350.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 3.755e-05/0.2756, allocations: 4 kB / 446.4 MB, free: 32.84 MB / 350.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0003015/0.2759, allocations: 44.61 kB / 446.5 MB, free: 32.82 MB / 350.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 4.701e-05/0.276, allocations: 11.14 kB / 446.5 MB, free: 32.82 MB / 350.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 9.378e-06/0.276, allocations: 3.312 kB / 446.5 MB, free: 32.82 MB / 350.1 MB Notification: Performance of sorting global known variables: time 0.0005311/0.2765, allocations: 287.4 kB / 446.7 MB, free: 32.7 MB / 350.1 MB Notification: Performance of sort global known variables: time 1.81e-07/0.2766, allocations: 0 / 446.7 MB, free: 32.7 MB / 350.1 MB Notification: Performance of remove unused functions: time 0.0002848/0.2768, allocations: 46.22 kB / 446.8 MB, free: 32.69 MB / 350.1 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 1 * Number of states: 4 (N.y,g1.x_scaled[1],g2.x_scaled[1],Cs.y) * Number of discrete variables: 0 () * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (20): * Single equations (assignments): 20 * 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.0006127/0.2775, allocations: 0.9347 MB / 447.7 MB, free: 31.91 MB / 350.1 MB Notification: Performance of simCode: created initialization part: time 0.0003275/0.2778, allocations: 181.8 kB / 447.9 MB, free: 31.86 MB / 350.1 MB Notification: Performance of simCode: created event and clocks part: time 2.134e-06/0.2778, allocations: 0 / 447.9 MB, free: 31.86 MB / 350.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0001208/0.2779, allocations: 84.33 kB / 448 MB, free: 31.84 MB / 350.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0004163/0.2784, allocations: 63.41 kB / 448.1 MB, free: 31.81 MB / 350.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.003489/0.2819, allocations: 2.885 MB / 450.9 MB, free: 29.98 MB / 350.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001698/0.282, allocations: 0.782 MB / 451.7 MB, free: 29.28 MB / 350.1 MB Notification: Performance of simCode: alias equations: time 0.0001136/0.2822, allocations: 38.27 kB / 451.8 MB, free: 29.28 MB / 350.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001112/0.2823, allocations: 86.94 kB / 451.8 MB, free: 29.21 MB / 350.1 MB Notification: Performance of SimCode: time 2.4e-07/0.2823, allocations: 0 / 451.8 MB, free: 29.21 MB / 350.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.02212/0.3044, allocations: 4.913 MB / 456.8 MB, free: 28.68 MB / 350.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 7.385/7.69, allocations: 12.66 kB / 456.8 MB, free: 28.67 MB / 350.1 MB (rm -f AES_AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec.pipe ; mkfifo AES_AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec.pipe ; head -c 1048576 < AES_AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec.pipe >> ../files/AES_AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec.sim & python3 -m fmpy simulate --output-file AES_AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec_res.csv --start-time 0 --stop-time 600 --timeout 50 --relative-tolerance 1e-06 --interface-type ModelExchange --solver CVode --output-interval 1.2 AES_AES_Coursework_ElecSys_power_frequency_control_BO_rigid_two_generators_PriSec.fmu > AES_AES.Coursework.ElecSys_power_frequency_control.BO_rigid_two_generators_PriSec.pipe 2>&1)