Running command: "" <> buildModelFMU(Modelica.Mechanics.Rotational.Examples.LossyGearDemo2,fileNamePrefix="Modelica_3_2_1_cpp_Modelica_Mechanics_Rotational_Examples_LossyGearDemo2",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadModel(Modelica): time 1.743/1.743, allocations: 171.2 MB / 183.8 MB, free: 12.04 MB / 154.7 MB Notification: Performance of FrontEnd - loaded program: time 4.427e-05/4.434e-05, allocations: 4 kB / 225.1 MB, free: 2.699 MB / 186.7 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.2678/0.2679, allocations: 38.78 MB / 263.9 MB, free: 9.867 MB / 218.7 MB Notification: Performance of FrontEnd - scodeFlatten: time 0.1332/0.4011, allocations: 72.53 MB / 336.4 MB, free: 1.227 MB / 282.7 MB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0003197/0.4015, allocations: 71.95 kB / 336.5 MB, free: 1.156 MB / 282.7 MB Notification: Performance of FrontEnd - DAE generated: time 0.05924/0.4607, allocations: 11.88 MB / 348.3 MB, free: 5.242 MB / 298.7 MB Notification: Performance of FrontEnd: time 1.764e-06/0.4608, allocations: 0 / 348.3 MB, free: 5.242 MB / 298.7 MB Notification: Performance of Transformations before backend: time 3.025e-05/0.4609, allocations: 12 kB / 348.4 MB, free: 5.23 MB / 298.7 MB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 98 * Number of variables: 98 Notification: Performance of Generate backend data structure: time 0.002209/0.4631, allocations: 0.7204 MB / 349.1 MB, free: 4.461 MB / 298.7 MB Notification: Performance of prepare preOptimizeDAE: time 5.178e-05/0.4631, allocations: 8.031 kB / 349.1 MB, free: 4.453 MB / 298.7 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.0001703/0.4633, allocations: 82.53 kB / 349.2 MB, free: 4.363 MB / 298.7 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0004929/0.4638, allocations: 63.41 kB / 349.2 MB, free: 4.301 MB / 298.7 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0007074/0.4646, allocations: 333.5 kB / 349.5 MB, free: 3.934 MB / 298.7 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0001806/0.4648, allocations: 100.1 kB / 349.6 MB, free: 3.824 MB / 298.7 MB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0001413/0.4649, allocations: 40 kB / 349.7 MB, free: 3.785 MB / 298.7 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.001421/0.4663, allocations: 0.5207 MB / 350.2 MB, free: 3.254 MB / 298.7 MB Notification: Performance of preOpt findStateOrder (simulation): time 3.002e-05/0.4664, allocations: 3.906 kB / 350.2 MB, free: 3.25 MB / 298.7 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 8.304e-05/0.4665, allocations: 19.98 kB / 350.2 MB, free: 3.23 MB / 298.7 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 1.632e-05/0.4665, allocations: 12 kB / 350.2 MB, free: 3.219 MB / 298.7 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.001608/0.4681, allocations: 0.5755 MB / 350.8 MB, free: 2.641 MB / 298.7 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.003628/0.4718, allocations: 1.227 MB / 352 MB, free: 1.355 MB / 298.7 MB Notification: Performance of preOpt comSubExp (simulation): time 0.001551/0.4734, allocations: 496.3 kB / 352.5 MB, free: 0.8555 MB / 298.7 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0007861/0.4742, allocations: 298.6 kB / 352.8 MB, free: 0.5586 MB / 298.7 MB Notification: Performance of preOpt evalFunc (simulation): time 7.265e-05/0.4743, allocations: 8.547 kB / 352.8 MB, free: 0.5508 MB / 298.7 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 3.691e-05/0.4744, allocations: 39.12 kB / 352.9 MB, free: 0.5039 MB / 298.7 MB Notification: Performance of pre-optimization done (n=61): time 4.028e-06/0.4744, allocations: 0 / 352.9 MB, free: 0.5039 MB / 298.7 MB Notification: Performance of matching and sorting (n=69): time 0.005997/0.4804, allocations: 2.034 MB / 354.9 MB, free: 14.38 MB / 314.7 MB Notification: Performance of inlineWhenForInitialization (initialization): time 6.629e-05/0.4805, allocations: 81.67 kB / 355 MB, free: 14.28 MB / 314.7 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0005186/0.481, allocations: 275.4 kB / 355.2 MB, free: 14 MB / 314.7 MB Notification: Performance of collectPreVariables (initialization): time 0.0001256/0.4812, allocations: 45.7 kB / 355.3 MB, free: 13.95 MB / 314.7 MB Notification: Performance of collectInitialEqns (initialization): time 0.0001696/0.4814, allocations: 216 kB / 355.5 MB, free: 13.74 MB / 314.7 MB Notification: Performance of collectInitialBindings (initialization): time 0.0002801/0.4817, allocations: 232.7 kB / 355.7 MB, free: 13.51 MB / 314.7 MB Notification: Performance of simplifyInitialFunctions (initialization): time 6.843e-05/0.4817, allocations: 12 kB / 355.7 MB, free: 13.5 MB / 314.7 MB Notification: Performance of setup shared object (initialization): time 0.0001472/0.4819, allocations: 338.8 kB / 356.1 MB, free: 13.16 MB / 314.7 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0007533/0.4827, allocations: 261.5 kB / 356.3 MB, free: 12.91 MB / 314.7 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0008002/0.4835, allocations: 314.4 kB / 356.6 MB, free: 12.59 MB / 314.7 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0006789/0.4842, allocations: 242.1 kB / 356.9 MB, free: 12.35 MB / 314.7 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 3.677e-06/0.4842, allocations: 0 / 356.9 MB, free: 12.35 MB / 314.7 MB Notification: Performance of matching and sorting (n=79) (initialization): time 0.00236/0.4866, allocations: 0.8179 MB / 357.7 MB, free: 11.52 MB / 314.7 MB Notification: Performance of prepare postOptimizeDAE: time 2.767e-05/0.4866, allocations: 4 kB / 357.7 MB, free: 11.52 MB / 314.7 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.064e-05/0.4866, allocations: 0 / 357.7 MB, free: 11.52 MB / 314.7 MB Notification: Performance of postOpt tearingSystem (initialization): time 0.001901/0.4886, allocations: 0.5454 MB / 358.2 MB, free: 10.97 MB / 314.7 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0008344/0.4894, allocations: 87.88 kB / 358.3 MB, free: 10.88 MB / 314.7 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.002037/0.4915, allocations: 1.06 MB / 359.4 MB, free: 9.797 MB / 314.7 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.001029/0.4925, allocations: 91.97 kB / 359.5 MB, free: 9.707 MB / 314.7 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.0001118/0.4927, allocations: 24 kB / 359.5 MB, free: 9.684 MB / 314.7 MB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 3 * Number of states: 0 () * Number of discrete variables: 15 (bearingFriction.free,gear.tau_aPos,gear.startForward,gear.startBackward,gear.locked,$PRE.gear.mode,gear.mode,$PRE.bearingFriction.startForward,bearingFriction.startForward,$PRE.bearingFriction.startBackward,bearingFriction.startBackward,bearingFriction.locked,$PRE.bearingFriction.mode,bearingFriction.mode,gear.ideal) * Number of discrete states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (46): * Single equations (assignments): 45 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 1 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems: 0 * Non-linear torn systems: 1 {2 32} Notification: Performance of prepare postOptimizeDAE: time 0.0002532/0.4929, allocations: 144.9 kB / 359.6 MB, free: 9.535 MB / 314.7 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0001437/0.4931, allocations: 47.38 kB / 359.7 MB, free: 9.488 MB / 314.7 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0002307/0.4933, allocations: 63.77 kB / 359.7 MB, free: 9.426 MB / 314.7 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 1.326e-05/0.4934, allocations: 8 kB / 359.8 MB, free: 9.418 MB / 314.7 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 8.837e-06/0.4934, allocations: 0 / 359.8 MB, free: 9.418 MB / 314.7 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 1.011e-05/0.4934, allocations: 3.984 kB / 359.8 MB, free: 9.414 MB / 314.7 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.00505/0.4985, allocations: 1.75 MB / 361.5 MB, free: 7.598 MB / 314.7 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 7.244e-06/0.4985, allocations: 0 / 361.5 MB, free: 7.598 MB / 314.7 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0007628/0.4993, allocations: 87.91 kB / 361.6 MB, free: 7.512 MB / 314.7 MB Notification: Performance of postOpt tearingSystem (simulation): time 0.001762/0.5011, allocations: 0.5087 MB / 362.1 MB, free: 7 MB / 314.7 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 0.0001073/0.5012, allocations: 31.92 kB / 362.1 MB, free: 6.969 MB / 314.7 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.001904/0.5031, allocations: 1.025 MB / 363.2 MB, free: 5.918 MB / 314.7 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 3.236e-06/0.5032, allocations: 0 / 363.2 MB, free: 5.918 MB / 314.7 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.003524/0.5067, allocations: 1.269 MB / 364.4 MB, free: 4.621 MB / 314.7 MB Notification: Performance of postOpt removeConstants (simulation): time 0.000448/0.5072, allocations: 180.6 kB / 364.6 MB, free: 4.426 MB / 314.7 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0001555/0.5074, allocations: 27.94 kB / 364.6 MB, free: 4.398 MB / 314.7 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0008716/0.5082, allocations: 72 kB / 364.7 MB, free: 4.328 MB / 314.7 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0003309/0.5086, allocations: 96.36 kB / 364.8 MB, free: 4.234 MB / 314.7 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 9.928e-05/0.5087, allocations: 27.98 kB / 364.8 MB, free: 4.207 MB / 314.7 MB Notification: Performance of sorting global known variables: time 0.0003774/0.5091, allocations: 215.1 kB / 365 MB, free: 4 MB / 314.7 MB Notification: Performance of sort global known variables: time 5.01e-07/0.5091, allocations: 0 / 365 MB, free: 4 MB / 314.7 MB Notification: Performance of remove unused functions: time 0.0008646/0.51, allocations: 167.9 kB / 365.2 MB, free: 3.836 MB / 314.7 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 2 * Number of states: 2 (Inertia2.phi,Inertia2.w) * Number of discrete variables: 9 (gear.tau_aPos,gear.startForward,gear.startBackward,gear.locked,gear.mode,bearingFriction.startForward,bearingFriction.startBackward,bearingFriction.locked,bearingFriction.mode) * Number of discrete states: 4 (bearingFriction.mode,bearingFriction.startBackward,bearingFriction.startForward,gear.mode) * Top-level inputs: 0 Notification: Strong component statistics for simulation (39): * Single equations (assignments): 38 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 1 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems: 0 * Non-linear torn systems: 1 {2 29} Notification: Performance of Backend phase and start with SimCode phase: time 0.004206/0.5142, allocations: 1.993 MB / 367.2 MB, free: 1.801 MB / 314.7 MB Notification: Performance of simCode: created initialization part: time 0.001966/0.5162, allocations: 0.6154 MB / 367.8 MB, free: 1.188 MB / 314.7 MB Notification: Performance of simCode: created event and clocks part: time 4.418e-06/0.5163, allocations: 0 / 367.8 MB, free: 1.188 MB / 314.7 MB Notification: Performance of simCode: created simulation system equations: time 0.001124/0.5174, allocations: 349.9 kB / 368.1 MB, free: 0.8438 MB / 314.7 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0006076/0.518, allocations: 44.95 kB / 368.2 MB, free: 0.7969 MB / 314.7 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.2537/0.7717, allocations: 1.108 MB / 369.3 MB, free: 93.47 MB / 314.7 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0006998/0.7725, allocations: 0.8262 MB / 370.1 MB, free: 92.78 MB / 314.7 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0008265/0.7734, allocations: 136.7 kB / 370.3 MB, free: 92.77 MB / 314.7 MB Notification: Performance of SimCode: time 1.823e-06/0.7734, allocations: 0.5 kB / 370.3 MB, free: 92.77 MB / 314.7 MB Notification: Performance of buildModelFMU: Generate C++ for platform static: time 2.986/3.759, allocations: 8.495 MB / 378.8 MB, free: 91.73 MB / 314.7 MB TODO: How the !@#!# did the simulation report success but simulation result Modelica_3.2.1_cpp_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.mat does not exist to compare? outputFormat=mat