Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr AES_AES.Coursework.ElecSys_case_studies.foo.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_case_studies.foo,fileNamePrefix="AES_AES_Coursework_ElecSys_case_studies_foo",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(AES.Coursework.ElecSys_case_studies.foo,fileNamePrefix="AES_AES_Coursework_ElecSys_case_studies_foo",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.001132/0.001132, 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.001285/0.001285, allocations: 196.7 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.342/1.342, allocations: 222.9 MB / 240.2 MB, free: 4.402 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/AES main/package.mo): time 0.2018/0.2018, allocations: 22.34 MB / 312.7 MB, free: 12.51 MB / 254.1 MB Notification: Performance of FrontEnd - loaded program: time 0.002426/0.002426, allocations: 63.91 kB / 380.9 MB, free: 10.52 MB / 318.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.2652/0.2677, allocations: 54.94 MB / 435.9 MB, free: 39.53 MB / 350.1 MB Notification: Performance of NFInst.instantiate(AES.Coursework.ElecSys_case_studies.foo): time 0.003217/0.2709, allocations: 1.864 MB / 437.7 MB, free: 38.23 MB / 350.1 MB Notification: Performance of NFInst.instExpressions: time 0.0008714/0.2718, allocations: 0.5106 MB / 438.2 MB, free: 37.88 MB / 350.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0001372/0.272, allocations: 0 / 438.2 MB, free: 37.88 MB / 350.1 MB Notification: Performance of NFTyping.typeComponents: time 0.0003004/0.2723, allocations: 35.97 kB / 438.3 MB, free: 37.86 MB / 350.1 MB Notification: Performance of NFTyping.typeBindings: time 0.0002018/0.2725, allocations: 46.83 kB / 438.3 MB, free: 37.83 MB / 350.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.0001778/0.2727, allocations: 53.77 kB / 438.4 MB, free: 37.8 MB / 350.1 MB Notification: Performance of NFFlatten.flatten: time 0.000245/0.273, allocations: 201.8 kB / 438.6 MB, free: 37.72 MB / 350.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0001434/0.2731, allocations: 37.25 kB / 438.6 MB, free: 37.7 MB / 350.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0001881/0.2733, allocations: 87 kB / 438.7 MB, free: 37.66 MB / 350.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0001913/0.2735, allocations: 96.89 kB / 438.8 MB, free: 37.62 MB / 350.1 MB Notification: Performance of NFPackage.collectConstants: time 3.814e-05/0.2736, allocations: 15.41 kB / 438.8 MB, free: 37.62 MB / 350.1 MB Notification: Performance of NFFlatten.collectFunctions: time 3.092e-05/0.2736, allocations: 14.94 kB / 438.8 MB, free: 37.62 MB / 350.1 MB Notification: Performance of NFScalarize.scalarize: time 6.682e-05/0.2737, allocations: 37.34 kB / 438.8 MB, free: 37.6 MB / 350.1 MB Notification: Performance of NFVerifyModel.verify: time 8.017e-05/0.2738, allocations: 71.23 kB / 438.9 MB, free: 37.55 MB / 350.1 MB Notification: Performance of NFConvertDAE.convert: time 0.0001685/0.2739, allocations: 148.3 kB / 439.1 MB, free: 37.49 MB / 350.1 MB Notification: Performance of FrontEnd - DAE generated: time 4.478e-06/0.274, allocations: 0 / 439.1 MB, free: 37.49 MB / 350.1 MB Notification: Performance of FrontEnd: time 1.853e-06/0.274, allocations: 0 / 439.1 MB, free: 37.49 MB / 350.1 MB Notification: Performance of Transformations before backend: time 9.558e-06/0.274, allocations: 2.469 kB / 439.1 MB, free: 37.49 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: 26 * Number of variables: 26 Notification: Performance of Generate backend data structure: time 0.0009979/0.275, allocations: 0.4918 MB / 439.6 MB, free: 37.06 MB / 350.1 MB Notification: Performance of prepare preOptimizeDAE: time 3.781e-05/0.275, allocations: 10.53 kB / 439.6 MB, free: 37.06 MB / 350.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 4.087e-05/0.2751, allocations: 44.67 kB / 439.6 MB, free: 37.02 MB / 350.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 5.285e-05/0.2751, allocations: 17.09 kB / 439.6 MB, free: 37.01 MB / 350.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0003619/0.2755, allocations: 253.3 kB / 439.9 MB, free: 36.78 MB / 350.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.802e-05/0.2755, allocations: 11.16 kB / 439.9 MB, free: 36.77 MB / 350.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 3.475e-05/0.2756, allocations: 20.69 kB / 439.9 MB, free: 36.76 MB / 350.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0002103/0.2758, allocations: 117.3 kB / 440 MB, free: 36.7 MB / 350.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 9.498e-06/0.2758, allocations: 0 / 440 MB, free: 36.7 MB / 350.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.46e-05/0.2758, allocations: 4 kB / 440 MB, free: 36.69 MB / 350.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 5.921e-06/0.2758, allocations: 2.812 kB / 440 MB, free: 36.69 MB / 350.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0001852/0.276, allocations: 87.72 kB / 440.1 MB, free: 36.66 MB / 350.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0008588/0.2769, allocations: 473.1 kB / 440.6 MB, free: 36.31 MB / 350.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0003391/0.2773, allocations: 163.2 kB / 440.7 MB, free: 36.23 MB / 350.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0001077/0.2774, allocations: 61.58 kB / 440.8 MB, free: 36.21 MB / 350.1 MB Notification: Performance of preOpt evalFunc (simulation): time 1.699e-05/0.2774, allocations: 2.969 kB / 440.8 MB, free: 36.21 MB / 350.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 2.969e-05/0.2774, allocations: 34.56 kB / 440.8 MB, free: 36.17 MB / 350.1 MB Notification: Performance of pre-optimization done (n=15): time 1.352e-06/0.2774, allocations: 0 / 440.8 MB, free: 36.17 MB / 350.1 MB Notification: Performance of matching and sorting (n=16): time 0.0008714/0.2783, allocations: 0.5403 MB / 441.4 MB, free: 35.77 MB / 350.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 2.408e-05/0.2783, allocations: 54.25 kB / 441.4 MB, free: 35.71 MB / 350.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0002733/0.2786, allocations: 197.1 kB / 441.6 MB, free: 35.59 MB / 350.1 MB Notification: Performance of collectPreVariables (initialization): time 1.405e-05/0.2787, allocations: 25.7 kB / 441.6 MB, free: 35.56 MB / 350.1 MB Notification: Performance of collectInitialEqns (initialization): time 5.46e-05/0.2787, allocations: 113 kB / 441.8 MB, free: 35.45 MB / 350.1 MB Notification: Performance of collectInitialBindings (initialization): time 3.71e-05/0.2788, allocations: 65.16 kB / 441.8 MB, free: 35.4 MB / 350.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 4.968e-05/0.2788, allocations: 35.91 kB / 441.9 MB, free: 35.37 MB / 350.1 MB Notification: Performance of setup shared object (initialization): time 4.772e-05/0.2789, allocations: 325 kB / 442.2 MB, free: 35.05 MB / 350.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 8.87e-05/0.279, allocations: 47.77 kB / 442.2 MB, free: 35.04 MB / 350.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 9.629e-05/0.2791, allocations: 74.19 kB / 442.3 MB, free: 35 MB / 350.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0006809/0.2798, allocations: 264.4 kB / 442.5 MB, free: 34.9 MB / 350.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 1.893e-06/0.2798, allocations: 0 / 442.5 MB, free: 34.9 MB / 350.1 MB Warning: The linear system: 1 : Ge1.Pm = Ge1.Pcmd 2 : Ge1.Pm = Ge1.Pcmd [ 1.0 , -1.0 ; 1.0 , -1.0 ] * [ Ge1.Pm ; Ge1.Pcmd ] = [ 0.0 ; 0.0 ] might be structurally or numerically singular for variable Ge1.Pcmd since U(2,2) = 0.0. It might be hard to solve. Compilation continues anyway. Notification: Performance of matching and sorting (n=21) (initialization): time 0.0004509/0.2802, allocations: 389.9 kB / 442.9 MB, free: 34.59 MB / 350.1 MB Notification: Performance of prepare postOptimizeDAE: time 1.242e-05/0.2802, allocations: 5.812 kB / 442.9 MB, free: 34.59 MB / 350.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 5.079e-06/0.2803, allocations: 8.016 kB / 442.9 MB, free: 34.58 MB / 350.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 0.0001551/0.2804, allocations: 50.08 kB / 443 MB, free: 34.55 MB / 350.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.000165/0.2806, allocations: 36.66 kB / 443 MB, free: 34.55 MB / 350.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.001602/0.2822, allocations: 4.638 MB / 447.7 MB, free: 29.81 MB / 350.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0001685/0.2824, allocations: 16.45 kB / 447.7 MB, free: 29.81 MB / 350.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 1.171e-05/0.2824, allocations: 9.844 kB / 447.7 MB, free: 29.8 MB / 350.1 MB Warning: Assuming fixed start value for the following 1 variables: Ge1.deltag:VARIABLE(unit = "rad" fixed = true ) "generator angle wrt port" type: Real Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 2 * Number of states: 0 () * Number of discrete variables: 0 () * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (17): * 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: 2 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems (#iteration vars, #inner vars, density): 1 system {(1,1,100.0%)} * Non-linear torn systems (#iteration vars, #inner vars): 1 system {(1,3)} Notification: Performance of prepare postOptimizeDAE: time 9.862e-05/0.2825, allocations: 144.1 kB / 447.8 MB, free: 29.66 MB / 350.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 3.99e-05/0.2826, allocations: 17.25 kB / 447.8 MB, free: 29.66 MB / 350.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 3.708e-05/0.2826, allocations: 20.78 kB / 447.9 MB, free: 29.64 MB / 350.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 2.976e-06/0.2826, allocations: 3.938 kB / 447.9 MB, free: 29.64 MB / 350.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 2.514e-06/0.2826, allocations: 3.031 kB / 447.9 MB, free: 29.64 MB / 350.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 3.026e-06/0.2826, allocations: 0 / 447.9 MB, free: 29.64 MB / 350.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0005145/0.2831, allocations: 0.502 MB / 448.4 MB, free: 29.24 MB / 350.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.033e-06/0.2832, allocations: 0 / 448.4 MB, free: 29.24 MB / 350.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.00014/0.2833, allocations: 27.56 kB / 448.4 MB, free: 29.24 MB / 350.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 0.0001189/0.2834, allocations: 35.81 kB / 448.4 MB, free: 29.23 MB / 350.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 1.562e-05/0.2835, allocations: 10.75 kB / 448.4 MB, free: 29.22 MB / 350.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.0007749/0.2842, allocations: 1.614 MB / 450.1 MB, free: 27.62 MB / 350.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.082e-06/0.2842, allocations: 0 / 450.1 MB, free: 27.62 MB / 350.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0003724/0.2846, allocations: 338.4 kB / 450.4 MB, free: 27.4 MB / 350.1 MB Notification: Performance of postOpt removeConstants (simulation): time 3.693e-05/0.2847, allocations: 92.23 kB / 450.5 MB, free: 27.3 MB / 350.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 2.477e-05/0.2847, allocations: 11.03 kB / 450.5 MB, free: 27.29 MB / 350.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001828/0.2849, allocations: 15.55 kB / 450.5 MB, free: 27.29 MB / 350.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 4.304e-05/0.2849, allocations: 20.14 kB / 450.5 MB, free: 27.28 MB / 350.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 9.017e-06/0.285, allocations: 6.812 kB / 450.5 MB, free: 27.27 MB / 350.1 MB Notification: Performance of sorting global known variables: time 0.0002077/0.2852, allocations: 158.2 kB / 450.7 MB, free: 27.18 MB / 350.1 MB Notification: Performance of sort global known variables: time 3.91e-07/0.2852, allocations: 0 / 450.7 MB, free: 27.18 MB / 350.1 MB Notification: Performance of remove unused functions: time 0.0004105/0.2856, allocations: 36.06 kB / 450.7 MB, free: 27.17 MB / 350.1 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 1 * Number of states: 4 (Ge1.thetap,Ge1.deltag,Ge1.wg,C.x_scaled[1]) * 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 (13): * Single equations (assignments): 12 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 1 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems (#iteration vars, #inner vars, density): 0 systems * Non-linear torn systems (#iteration vars, #inner vars): 1 system {(1,3)} Notification: Performance of Backend phase and start with SimCode phase: time 0.0005329/0.2861, allocations: 0.8712 MB / 451.6 MB, free: 26.42 MB / 350.1 MB Notification: Performance of simCode: created initialization part: time 0.0004128/0.2866, allocations: 368.4 kB / 452 MB, free: 26.15 MB / 350.1 MB Notification: Performance of simCode: created event and clocks part: time 2.365e-06/0.2866, allocations: 0 / 452 MB, free: 26.15 MB / 350.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0002116/0.2868, allocations: 185.6 kB / 452.1 MB, free: 26.01 MB / 350.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002847/0.2871, allocations: 16.86 kB / 452.2 MB, free: 26 MB / 350.1 MB Warning: The linear system: 1 : Ge1.Pm = Ge1.Pcmd 2 : Ge1.Pm = Ge1.Pcmd [ -1.0 , 1.0 ; -1.0 , 1.0 ] * [ Ge1.Pcmd ; Ge1.Pm ] = [ 0.0 ; 0.0 ] might be structurally or numerically singular for variable Ge1.Pm since U(2,2) = 0.0. It might be hard to solve. Compilation continues anyway. Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.002603/0.2897, allocations: 2.607 MB / 454.8 MB, free: 23.93 MB / 350.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0001655/0.2899, allocations: 0.7225 MB / 455.5 MB, free: 23.24 MB / 350.1 MB Notification: Performance of simCode: alias equations: time 8.858e-05/0.29, allocations: 25.62 kB / 455.5 MB, free: 23.23 MB / 350.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 7.553e-05/0.2901, allocations: 48.33 kB / 455.6 MB, free: 23.2 MB / 350.1 MB Notification: Performance of SimCode: time 2.2e-07/0.2901, allocations: 0 / 455.6 MB, free: 23.2 MB / 350.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.02518/0.3153, allocations: 3.728 MB / 459.3 MB, free: 22.69 MB / 350.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 11.15/11.46, allocations: 13.72 kB / 459.3 MB, free: 22.68 MB / 350.1 MB (rm -f AES_AES.Coursework.ElecSys_case_studies.foo.pipe ; mkfifo AES_AES.Coursework.ElecSys_case_studies.foo.pipe ; head -c 1048576 < AES_AES.Coursework.ElecSys_case_studies.foo.pipe >> ../files/AES_AES.Coursework.ElecSys_case_studies.foo.sim & python3 -m fmpy simulate --output-file AES_AES.Coursework.ElecSys_case_studies.foo_res.csv --start-time 0 --stop-time 2000 --timeout 50 --relative-tolerance 1e-06 --interface-type ModelExchange --solver CVode --output-interval 0.4 AES_AES_Coursework_ElecSys_case_studies_foo.fmu > AES_AES.Coursework.ElecSys_case_studies.foo.pipe 2>&1)