Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries/ --ompython_omhome=/usr PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 3.2.2+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.2+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 3.2.2+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/PowerSystems 1.0.0/package.mo", uses=false) Using package PowerSystems with version 1.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/PowerSystems 1.0.0/package.mo) Using package ModelicaServices with version 3.2.2 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 3.2.2+maint.om/package.mo) Using package Modelica with version 3.2.2 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.2+maint.om/package.mo) Using package Complex with version 3.2.2 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 3.2.2+maint.om/package.mo) Running command: translateModel(PowerSystems.Examples.AC3ph.Drives.SM_ctrl,tolerance=1e-05,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl") translateModel(PowerSystems.Examples.AC3ph.Drives.SM_ctrl,tolerance=1e-05,outputFormat="empty",numberOfIntervals=5000,variableFilter="",fileNamePrefix="PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl") [:1:1-1:32:writable] Error: Class GC_set_max_heap_size not found in scope (looking for a function or record). Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 3.2.2+maint.om/package.mo): time 0.001054/0.001054, allocations: 195.2 kB / 8.137 MB, free: 2.184 MB / 5.871 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.2+maint.om/package.mo): time 1.202/1.202, allocations: 194.2 MB / 202.8 MB, free: 8.668 MB / 170.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 3.2.2+maint.om/package.mo): time 0.001738/0.001737, allocations: 117.4 kB / 247.8 MB, free: 6.414 MB / 202.7 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/PowerSystems 1.0.0/package.mo): time 0.178/0.178, allocations: 37.91 MB / 330.5 MB, free: 6.969 MB / 282.7 MB Notification: Performance of FrontEnd - loaded program: time 8.205e-06/8.235e-06, allocations: 0 / 389.8 MB, free: 78.12 MB / 314.7 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1057/0.1057, allocations: 53.22 MB / 443 MB, free: 24.98 MB / 314.7 MB Notification: Performance of FrontEnd - scodeFlatten: time 0.362/0.4678, allocations: 115.3 MB / 0.5453 GB, free: 8.438 MB / 362.7 MB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0002505/0.4681, allocations: 92.94 kB / 0.5454 GB, free: 8.391 MB / 362.7 MB [/home/hudson/saved_omc/libraries/.openmodelica/libraries/PowerSystems 1.0.0/Control/Modulation.mo:17:7-17:46:writable] Error: Variable sm_ctrl.inverter.modulator.m not found in scope PowerSystems.AC3ph.Drives.SM_ctrl$sm_ctrl.Inverter$sm_ctrl$inverter.Modulator.$for loop scope$. [/home/hudson/saved_omc/libraries/.openmodelica/libraries/PowerSystems 1.0.0/Control/Modulation.mo:20:7-20:46:writable] Error: Variable sm_ctrl.inverter.modulator.m not found in scope PowerSystems.AC3ph.Drives.SM_ctrl$sm_ctrl.Inverter$sm_ctrl$inverter.Modulator.$for loop scope$. Notification: Performance of FrontEnd: time 0.09852/0.5666, allocations: 34.22 MB / 0.5788 GB, free: 11.86 MB / 394.7 MB Notification: Performance of Transformations before backend: time 0.0001008/0.5668, allocations: 28 kB / 0.5788 GB, free: 11.83 MB / 394.7 MB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 295 * Number of variables: 295 Notification: Performance of Generate backend data structure: time 0.004385/0.5712, allocations: 1.561 MB / 0.5803 GB, free: 10.27 MB / 394.7 MB Notification: Performance of prepare preOptimizeDAE: time 4.881e-05/0.5712, allocations: 8.031 kB / 0.5803 GB, free: 10.26 MB / 394.7 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0009996/0.5723, allocations: 162.3 kB / 0.5805 GB, free: 10.1 MB / 394.7 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.003682/0.576, allocations: 1.268 MB / 0.5817 GB, free: 9.074 MB / 394.7 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.000194/0.5762, allocations: 154.9 kB / 0.5819 GB, free: 8.91 MB / 394.7 MB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0004191/0.5766, allocations: 79.58 kB / 0.582 GB, free: 8.836 MB / 394.7 MB Notification: Performance of preOpt removeEqualFunctionCalls (simulation): time 0.002435/0.5791, allocations: 1.187 MB / 0.5831 GB, free: 8.09 MB / 394.7 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.002825/0.5819, allocations: 1.547 MB / 0.5846 GB, free: 6.895 MB / 394.7 MB Notification: Performance of preOpt findStateOrder (simulation): time 4.419e-05/0.582, allocations: 4 kB / 0.5846 GB, free: 6.891 MB / 394.7 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 0.0001406/0.5821, allocations: 11.12 kB / 0.5846 GB, free: 6.883 MB / 394.7 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 0.0001325/0.5822, allocations: 75.5 kB / 0.5847 GB, free: 6.816 MB / 394.7 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.009099/0.5914, allocations: 5.868 MB / 0.5904 GB, free: 1.477 MB / 394.7 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0009671/0.5924, allocations: 0.6396 MB / 0.5911 GB, free: 0.8164 MB / 394.7 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0008439/0.5932, allocations: 0.524 MB / 0.5916 GB, free: 292 kB / 394.7 MB Notification: Performance of preOpt evalFunc (simulation): time 5.849e-05/0.5933, allocations: 8.656 kB / 0.5916 GB, free: 284 kB / 394.7 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.000979/0.5943, allocations: 0.6368 MB / 0.5922 GB, free: 15.62 MB / 410.7 MB Notification: Performance of pre-optimization done (n=87): time 3.787e-06/0.5943, allocations: 0 / 0.5922 GB, free: 15.62 MB / 410.7 MB Notification: Performance of matching and sorting (n=92): time 0.005943/0.6003, allocations: 3.19 MB / 0.5953 GB, free: 12.3 MB / 410.7 MB Notification: Performance of inlineWhenForInitialization (initialization): time 8.381e-05/0.6004, allocations: 157.2 kB / 0.5955 GB, free: 12.12 MB / 410.7 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.000877/0.6013, allocations: 0.5346 MB / 0.596 GB, free: 11.58 MB / 410.7 MB Notification: Performance of collectPreVariables (initialization): time 0.0001283/0.6014, allocations: 45.69 kB / 0.596 GB, free: 11.53 MB / 410.7 MB Notification: Performance of collectInitialEqns (initialization): time 0.0004288/0.6018, allocations: 478.5 kB / 0.5965 GB, free: 11.05 MB / 410.7 MB Notification: Performance of collectInitialBindings (initialization): time 0.0003016/0.6021, allocations: 295.8 kB / 0.5968 GB, free: 10.76 MB / 410.7 MB Notification: Performance of simplifyInitialFunctions (initialization): time 5.603e-05/0.6022, allocations: 7.938 kB / 0.5968 GB, free: 10.75 MB / 410.7 MB Notification: Performance of setup shared object (initialization): time 0.0001974/0.6024, allocations: 398.7 kB / 0.5972 GB, free: 10.36 MB / 410.7 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0008273/0.6033, allocations: 0.5258 MB / 0.5977 GB, free: 9.832 MB / 410.7 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.001011/0.6043, allocations: 0.8465 MB / 0.5985 GB, free: 8.844 MB / 410.7 MB Notification: It was not possible to analyze the given system symbolically, because the relevant equations are part of an algebraic loop. This is not supported yet. Notification: Performance of analyzeInitialSystem (initialization): time 0.004797/0.6091, allocations: 1.922 MB / 0.6004 GB, free: 6.891 MB / 410.7 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 1.115e-05/0.6091, allocations: 4 kB / 0.6004 GB, free: 6.887 MB / 410.7 MB Notification: Performance of matching and sorting (n=153) (initialization): time 0.003912/0.613, allocations: 2.038 MB / 0.6024 GB, free: 4.82 MB / 410.7 MB Notification: Performance of prepare postOptimizeDAE: time 0.001425/0.6145, allocations: 3.828 MB / 0.6061 GB, free: 0.6914 MB / 410.7 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 2.674e-05/0.6145, allocations: 8 kB / 0.6061 GB, free: 0.6836 MB / 410.7 MB Notification: Performance of postOpt tearingSystem (initialization): time 0.002232/0.6168, allocations: 0.7642 MB / 0.6069 GB, free: 15.91 MB / 426.7 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0007896/0.6176, allocations: 163.7 kB / 0.607 GB, free: 15.75 MB / 426.7 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.003698/0.6213, allocations: 3.299 MB / 0.6102 GB, free: 12.3 MB / 426.7 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.001026/0.6223, allocations: 63.86 kB / 0.6103 GB, free: 12.24 MB / 426.7 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.0002145/0.6225, allocations: 71.95 kB / 0.6104 GB, free: 12.17 MB / 426.7 MB Notification: Performance of prepare postOptimizeDAE: time 1.183e-05/0.6226, allocations: 4 kB / 0.6104 GB, free: 12.16 MB / 426.7 MB Notification: Performance of postOpt replaceHomotopyWithSimplified (initialization): time 0.003643/0.6262, allocations: 1.878 MB / 0.6122 GB, free: 10.26 MB / 426.7 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 3.008e-05/0.6263, allocations: 12 kB / 0.6122 GB, free: 10.25 MB / 426.7 MB Notification: Performance of postOpt tearingSystem (initialization): time 0.002079/0.6284, allocations: 0.7491 MB / 0.613 GB, free: 9.488 MB / 426.7 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0006847/0.6291, allocations: 171.7 kB / 0.6131 GB, free: 9.32 MB / 426.7 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.003213/0.6323, allocations: 3.19 MB / 0.6162 GB, free: 5.992 MB / 426.7 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0009022/0.6332, allocations: 56 kB / 0.6163 GB, free: 5.938 MB / 426.7 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.0001887/0.6334, allocations: 71.94 kB / 0.6164 GB, free: 5.867 MB / 426.7 MB Warning: Assuming redundant initial conditions for the following 1 initial equations: $DER.sm_ctrl.rotor.w = 0.0 Warning: Iteration variables with default zero start attribute in torn nonlinear equation system: sm_ctrl.motor.psi_s[2]:DUMMY_STATE(unit = "Wb" protected = true ) "magnetic flux stator dq" type: Real [2] sm_ctrl.motor.i_dq[2]:VARIABLE(unit = "A" nominal = 1.0 protected = true ) "current demand {i_d, i_q} pu" type: Real [2] sm_ctrl.motor.w_el:VARIABLE(unit = "rad/s" stateSelect=StateSelect.prefer ) "rotor angular velocity el" type: Real Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 44 * Number of states: 0 () * Number of discrete variables: 28 (system.initime,$whenCondition3,$whenCondition2,$whenCondition1,$PRE.sm_ctrl.inverter.modulator.gates[1],sm_ctrl.inverter.modulator.gates[1],$PRE.sm_ctrl.inverter.modulator.gates[2],sm_ctrl.inverter.modulator.gates[2],$PRE.sm_ctrl.inverter.modulator.gates[3],sm_ctrl.inverter.modulator.gates[3],$PRE.sm_ctrl.inverter.modulator.gates[4],sm_ctrl.inverter.modulator.gates[4],$PRE.sm_ctrl.inverter.modulator.gates[5],sm_ctrl.inverter.modulator.gates[5],$PRE.sm_ctrl.inverter.modulator.gates[6],sm_ctrl.inverter.modulator.gates[6],$PRE.sm_ctrl.inverter.modulator.sigdel_t[1],sm_ctrl.inverter.modulator.sigdel_t[1],$PRE.sm_ctrl.inverter.modulator.sigdel_t[2],sm_ctrl.inverter.modulator.sigdel_t[2],$PRE.sm_ctrl.inverter.modulator.sigdel_t[3],sm_ctrl.inverter.modulator.sigdel_t[3],$PRE.sm_ctrl.inverter.modulator.t0[1],sm_ctrl.inverter.modulator.t0[1],$PRE.sm_ctrl.inverter.modulator.t0[2],sm_ctrl.inverter.modulator.t0[2],$PRE.sm_ctrl.inverter.modulator.t0[3],sm_ctrl.inverter.modulator.t0[3]) * Number of discrete states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (101): * Single equations (assignments): 98 * Array equations: 1 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 2 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems: 1 {(1,100.0%) 2} * Non-linear torn systems: 1 {3 29} Notification: Performance of prepare postOptimizeDAE: time 0.0005759/0.634, allocations: 173.5 kB / 0.6165 GB, free: 5.691 MB / 426.7 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0004266/0.6344, allocations: 82.97 kB / 0.6166 GB, free: 5.609 MB / 426.7 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.002577/0.637, allocations: 1.147 MB / 0.6177 GB, free: 4.426 MB / 426.7 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 2.783e-05/0.6371, allocations: 15.98 kB / 0.6177 GB, free: 4.41 MB / 426.7 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 9.909e-06/0.6371, allocations: 0 / 0.6177 GB, free: 4.41 MB / 426.7 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 1.602e-05/0.6371, allocations: 11.92 kB / 0.6177 GB, free: 4.398 MB / 426.7 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.004344/0.6414, allocations: 2.394 MB / 0.6201 GB, free: 1.918 MB / 426.7 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 6.492e-06/0.6415, allocations: 3.984 kB / 0.6201 GB, free: 1.914 MB / 426.7 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.000846/0.6423, allocations: 151.8 kB / 0.6202 GB, free: 1.766 MB / 426.7 MB Notification: Performance of postOpt tearingSystem (simulation): time 0.0001827/0.6425, allocations: 57.59 kB / 0.6203 GB, free: 1.703 MB / 426.7 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 8.561e-05/0.6426, allocations: 11.98 kB / 0.6203 GB, free: 1.691 MB / 426.7 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.001993/0.6446, allocations: 2.644 MB / 0.6229 GB, free: 14.82 MB / 442.7 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 5.661e-06/0.6446, allocations: 3.906 kB / 0.6229 GB, free: 14.81 MB / 442.7 MB Notification: Performance of postOpt detectJacobianSparsePattern (simulation): time 0.002795/0.6474, allocations: 1.83 MB / 0.6247 GB, free: 12.93 MB / 442.7 MB Notification: Performance of postOpt removeConstants (simulation): time 0.0005914/0.648, allocations: 272 kB / 0.6249 GB, free: 12.64 MB / 442.7 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0003435/0.6484, allocations: 83.86 kB / 0.625 GB, free: 12.56 MB / 442.7 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.001002/0.6494, allocations: 103.9 kB / 0.6251 GB, free: 12.46 MB / 442.7 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001349/0.6496, allocations: 52.7 kB / 0.6252 GB, free: 12.41 MB / 442.7 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 7.871e-05/0.6496, allocations: 31.98 kB / 0.6252 GB, free: 12.38 MB / 442.7 MB Notification: Performance of sort global known variables: time 0.0006041/0.6503, allocations: 403.1 kB / 0.6256 GB, free: 11.99 MB / 442.7 MB Notification: Performance of remove unused functions: time 0.001926/0.6522, allocations: 407.9 kB / 0.626 GB, free: 11.59 MB / 442.7 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 3 * Number of states: 6 (sm_ctrl.motor.phi_el,sm_ctrl.motor.w_el,sm_ctrl.motor.i_s[1],sm_ctrl.motor.i_s[2],sm_ctrl.motor.i_s[3],PI_i_q.I.y) * Number of discrete variables: 16 ($whenCondition3,$whenCondition2,$whenCondition1,sm_ctrl.inverter.modulator.gates[1],sm_ctrl.inverter.modulator.gates[2],sm_ctrl.inverter.modulator.gates[3],sm_ctrl.inverter.modulator.gates[4],sm_ctrl.inverter.modulator.gates[5],sm_ctrl.inverter.modulator.gates[6],sm_ctrl.inverter.modulator.sigdel_t[1],sm_ctrl.inverter.modulator.sigdel_t[2],sm_ctrl.inverter.modulator.sigdel_t[3],sm_ctrl.inverter.modulator.t0[1],sm_ctrl.inverter.modulator.t0[2],sm_ctrl.inverter.modulator.t0[3],system.initime) * Number of discrete states: 12 (sm_ctrl.inverter.modulator.t0[3],sm_ctrl.inverter.modulator.sigdel_t[3],sm_ctrl.inverter.modulator.gates[5],sm_ctrl.inverter.modulator.gates[6],sm_ctrl.inverter.modulator.t0[2],sm_ctrl.inverter.modulator.sigdel_t[2],sm_ctrl.inverter.modulator.gates[3],sm_ctrl.inverter.modulator.gates[4],sm_ctrl.inverter.modulator.t0[1],sm_ctrl.inverter.modulator.sigdel_t[1],sm_ctrl.inverter.modulator.gates[1],sm_ctrl.inverter.modulator.gates[2]) * Top-level inputs: 0 Notification: Strong component statistics for simulation (86): * Single equations (assignments): 70 * Array equations: 1 * Algorithm blocks: 0 * Record equations: 0 * When equations: 13 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 2 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems: 2 {(1,100.0%) 2,(1,100.0%) 1} * Non-linear torn systems: 0 Notification: Performance of Backend phase and start with SimCode phase: time 0.0004797/0.6527, allocations: 227.5 kB / 0.6262 GB, free: 11.36 MB / 442.7 MB Notification: Performance of simCode: created initialization part: time 0.004509/0.6572, allocations: 2.471 MB / 0.6286 GB, free: 8.859 MB / 442.7 MB Notification: Performance of simCode: created event and clocks part: time 3.757e-06/0.6572, allocations: 384 / 0.6286 GB, free: 8.859 MB / 442.7 MB Notification: Performance of simCode: created simulation system equations: time 0.001064/0.6583, allocations: 0.7171 MB / 0.6293 GB, free: 8.125 MB / 442.7 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.001074/0.6594, allocations: 146 kB / 0.6294 GB, free: 7.984 MB / 442.7 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.004638/0.664, allocations: 2.065 MB / 0.6315 GB, free: 5.863 MB / 442.7 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.001365/0.6654, allocations: 1.31 MB / 0.6327 GB, free: 4.527 MB / 442.7 MB Notification: Performance of SimCode: time 1.182e-06/0.6654, allocations: 0 / 0.6327 GB, free: 4.527 MB / 442.7 MB Notification: Performance of Templates: time 0.03568/0.7011, allocations: 18.74 MB / 0.651 GB, free: 1.824 MB / 458.7 MB make -j1 -f PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl.makefile (rm -f PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl.pipe ; mkfifo PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl.pipe ; head -c 1048576 < PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl.pipe >> ../files/PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl.sim & ./PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl -abortSlowSimulation -alarm=480 -lv LOG_STATS > PowerSystems_PowerSystems.Examples.AC3ph.Drives.SM_ctrl.pipe 2>&1)