Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries/ --ompython_omhome=/usr Modelica_3.2.3_cpp_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 3.2.3+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 3.2.3+maint.om/package.mo", uses=false) Using package ModelicaServices with version 3.2.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 3.2.3+maint.om/package.mo) Using package Modelica with version 3.2.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo) Using package Complex with version 3.2.3 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 3.2.3+maint.om/package.mo) Running command: "" <> buildModelFMU(Modelica.Mechanics.Rotational.Examples.LossyGearDemo1,fileNamePrefix="Modelica_3_2_3_cpp_Modelica_Mechanics_Rotational_Examples_LossyGearDemo1",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Modelica.Mechanics.Rotational.Examples.LossyGearDemo1,fileNamePrefix="Modelica_3_2_3_cpp_Modelica_Mechanics_Rotational_Examples_LossyGearDemo1",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 3.2.3+maint.om/package.mo): time 0.002353/0.002353, allocations: 181.8 kB / 8.365 MB, free: 0.7109 MB / 5.871 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo): time 2.112/2.112, allocations: 205.3 MB / 214.1 MB, free: 14.11 MB / 187.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 3.2.3+maint.om/package.mo): time 0.001108/0.001108, allocations: 83.23 kB / 262.1 MB, free: 13.87 MB / 219.1 MB Notification: Performance of FrontEnd - loaded program: time 2.524e-05/2.531e-05, allocations: 0 / 314.9 MB, free: 9.051 MB / 267.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.3411/0.3411, allocations: 47.56 MB / 362.4 MB, free: 45.75 MB / 299.1 MB Notification: Performance of FrontEnd - scodeFlatten: time 0.1349/0.4761, allocations: 80.15 MB / 442.6 MB, free: 6.074 MB / 331.1 MB Notification: Performance of FrontEnd - mkProgramGraph: time 0.0002689/0.4764, allocations: 71.44 kB / 442.6 MB, free: 6.008 MB / 331.1 MB Notification: Performance of FrontEnd - DAE generated: time 0.05011/0.5265, allocations: 10.12 MB / 452.8 MB, free: 11.91 MB / 347.1 MB Notification: Performance of FrontEnd: time 1.643e-06/0.5266, allocations: 0 / 452.8 MB, free: 11.91 MB / 347.1 MB Notification: Performance of Transformations before backend: time 2.446e-05/0.5266, allocations: 4.938 kB / 452.8 MB, free: 11.9 MB / 347.1 MB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 76 * Number of variables: 76 Notification: Performance of Generate backend data structure: time 0.001651/0.5283, allocations: 0.5987 MB / 453.4 MB, free: 11.26 MB / 347.1 MB Notification: Performance of prepare preOptimizeDAE: time 5.425e-05/0.5283, allocations: 12.03 kB / 453.4 MB, free: 11.25 MB / 347.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0005048/0.5289, allocations: 51.59 kB / 453.4 MB, free: 11.2 MB / 347.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0006164/0.5295, allocations: 296.7 kB / 453.7 MB, free: 10.87 MB / 347.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0001737/0.5297, allocations: 80.17 kB / 453.8 MB, free: 10.78 MB / 347.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0001015/0.5298, allocations: 20 kB / 453.8 MB, free: 10.76 MB / 347.1 MB Notification: Performance of preOpt removeEqualFunctionCalls (simulation): time 0.001119/0.5309, allocations: 401.3 kB / 454.2 MB, free: 10.37 MB / 347.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0009077/0.5319, allocations: 349.3 kB / 454.5 MB, free: 10.02 MB / 347.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 2.51e-05/0.5319, allocations: 0 / 454.5 MB, free: 10.02 MB / 347.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 5.736e-05/0.532, allocations: 5.688 kB / 454.6 MB, free: 10.01 MB / 347.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 1.2e-05/0.532, allocations: 4 kB / 454.6 MB, free: 10.01 MB / 347.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.002222/0.5342, allocations: 0.8289 MB / 455.4 MB, free: 9.129 MB / 347.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0009776/0.5353, allocations: 327.6 kB / 455.7 MB, free: 8.801 MB / 347.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0004854/0.5358, allocations: 186.1 kB / 455.9 MB, free: 8.617 MB / 347.1 MB Notification: Performance of preOpt evalFunc (simulation): time 5.329e-05/0.5359, allocations: 4.438 kB / 455.9 MB, free: 8.613 MB / 347.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 3.603e-05/0.5359, allocations: 43 kB / 455.9 MB, free: 8.562 MB / 347.1 MB Notification: Performance of pre-optimization done (n=49): time 3.366e-06/0.5359, allocations: 192 / 455.9 MB, free: 8.562 MB / 347.1 MB Notification: Performance of matching and sorting (n=55): time 0.00456/0.5405, allocations: 1.429 MB / 457.4 MB, free: 7.043 MB / 347.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 5.865e-05/0.5406, allocations: 85.67 kB / 457.4 MB, free: 6.941 MB / 347.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0003163/0.5409, allocations: 187.6 kB / 457.6 MB, free: 6.75 MB / 347.1 MB Notification: Performance of collectPreVariables (initialization): time 7.19e-05/0.541, allocations: 25.7 kB / 457.7 MB, free: 6.719 MB / 347.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.0001344/0.5411, allocations: 211.4 kB / 457.9 MB, free: 6.512 MB / 347.1 MB Notification: Performance of collectInitialBindings (initialization): time 0.0002217/0.5414, allocations: 173.4 kB / 458 MB, free: 6.34 MB / 347.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 3.812e-05/0.5414, allocations: 3.938 kB / 458 MB, free: 6.336 MB / 347.1 MB Notification: Performance of setup shared object (initialization): time 0.0001306/0.5416, allocations: 326.8 kB / 458.4 MB, free: 6.008 MB / 347.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0004501/0.542, allocations: 161.1 kB / 458.5 MB, free: 5.848 MB / 347.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0004836/0.5425, allocations: 200.9 kB / 458.7 MB, free: 5.645 MB / 347.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0005956/0.5431, allocations: 154.1 kB / 458.9 MB, free: 5.492 MB / 347.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 3.456e-06/0.5432, allocations: 0 / 458.9 MB, free: 5.492 MB / 347.1 MB Notification: Performance of matching and sorting (n=59) (initialization): time 0.001507/0.5447, allocations: 0.5081 MB / 459.4 MB, free: 4.98 MB / 347.1 MB Notification: Performance of prepare postOptimizeDAE: time 2.765e-05/0.5447, allocations: 4 kB / 459.4 MB, free: 4.977 MB / 347.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 9.338e-06/0.5448, allocations: 4 kB / 459.4 MB, free: 4.973 MB / 347.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 0.00113/0.5459, allocations: 231.8 kB / 459.6 MB, free: 4.746 MB / 347.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0006457/0.5466, allocations: 79.83 kB / 459.7 MB, free: 4.668 MB / 347.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.005917/0.5525, allocations: 2.588 MB / 462.3 MB, free: 1.953 MB / 347.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0006437/0.5532, allocations: 28.06 kB / 462.3 MB, free: 1.926 MB / 347.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.000101/0.5534, allocations: 20 kB / 462.3 MB, free: 1.906 MB / 347.1 MB Warning: Iteration variables with default zero start attribute in torn nonlinear equation system: gear.flange_a.tau:VARIABLE(flow=true unit = "N.m" ) "Cut torque in the flange" type: Real gear.sa:VARIABLE(unit = "1" ) "Path parameter for acceleration and torque loss" 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: 7 (gear.tau_aPos,gear.startForward,gear.startBackward,gear.locked,$PRE.gear.mode,gear.mode,gear.ideal) * Number of discrete states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (33): * Single equations (assignments): 32 * 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 25} Notification: Performance of prepare postOptimizeDAE: time 0.0002885/0.5537, allocations: 114.9 kB / 462.4 MB, free: 1.789 MB / 347.1 MB Notification: Performance of postOpt createAliasVarsForOutputStates (simulation): time 0.001874/0.5556, allocations: 0.505 MB / 462.9 MB, free: 1.277 MB / 347.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0002004/0.5558, allocations: 32.66 kB / 463 MB, free: 1.246 MB / 347.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0001661/0.556, allocations: 47.39 kB / 463 MB, free: 1.203 MB / 347.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 1.072e-05/0.556, allocations: 4 kB / 463 MB, free: 1.199 MB / 347.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.149e-06/0.5561, allocations: 0 / 463 MB, free: 1.199 MB / 347.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 8.346e-06/0.5561, allocations: 0 / 463 MB, free: 1.199 MB / 347.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.003261/0.5593, allocations: 1.101 MB / 464.1 MB, free: 52 kB / 347.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 7.495e-06/0.5594, allocations: 0 / 464.1 MB, free: 52 kB / 347.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0006946/0.5601, allocations: 68 kB / 464.2 MB, free: 15.98 MB / 363.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 0.00106/0.5612, allocations: 220.8 kB / 464.4 MB, free: 15.76 MB / 363.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 8.865e-05/0.5613, allocations: 11.98 kB / 464.4 MB, free: 15.75 MB / 363.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.005501/0.5668, allocations: 2.507 MB / 466.9 MB, free: 13.13 MB / 363.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 6.953e-06/0.5669, allocations: 0.6562 kB / 466.9 MB, free: 13.13 MB / 363.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.002322/0.5692, allocations: 0.8183 MB / 467.7 MB, free: 12.29 MB / 363.1 MB Notification: Performance of postOpt removeConstants (simulation): time 0.0003609/0.5696, allocations: 152.7 kB / 467.9 MB, free: 12.12 MB / 363.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 9.012e-05/0.5697, allocations: 0 / 467.9 MB, free: 12.12 MB / 363.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0005845/0.5704, allocations: 32.09 kB / 467.9 MB, free: 12.09 MB / 363.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0003077/0.5707, allocations: 76.48 kB / 468 MB, free: 12.01 MB / 363.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 7.608e-05/0.5708, allocations: 19.98 kB / 468 MB, free: 11.99 MB / 363.1 MB Notification: Performance of sorting global known variables: time 0.0002392/0.571, allocations: 149.4 kB / 468.2 MB, free: 11.85 MB / 363.1 MB Notification: Performance of sort global known variables: time 4.21e-07/0.571, allocations: 0 / 468.2 MB, free: 11.85 MB / 363.1 MB Notification: Performance of remove unused functions: time 0.001048/0.5721, allocations: 136 kB / 468.3 MB, free: 11.71 MB / 363.1 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: 5 (gear.tau_aPos,gear.startForward,gear.startBackward,gear.locked,gear.mode) * Number of discrete states: 1 (gear.mode) * Top-level inputs: 0 Notification: Strong component statistics for simulation (31): * Single equations (assignments): 30 * 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 23} Notification: Performance of Backend phase and start with SimCode phase: time 0.003259/0.5754, allocations: 1.502 MB / 469.8 MB, free: 10.17 MB / 363.1 MB Notification: Performance of simCode: created initialization part: time 0.001754/0.5772, allocations: 0.5838 MB / 470.4 MB, free: 9.578 MB / 363.1 MB Notification: Performance of simCode: created event and clocks part: time 6.883e-06/0.5773, allocations: 0 / 470.4 MB, free: 9.578 MB / 363.1 MB Notification: Performance of simCode: created simulation system equations: time 0.001063/0.5783, allocations: 417.8 kB / 470.8 MB, free: 9.156 MB / 363.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0005291/0.5789, allocations: 15.98 kB / 470.8 MB, free: 9.141 MB / 363.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.002458/0.5814, allocations: 0.6923 MB / 471.5 MB, free: 8.402 MB / 363.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0004952/0.5819, allocations: 0.8075 MB / 472.3 MB, free: 7.574 MB / 363.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0003919/0.5823, allocations: 103.4 kB / 472.4 MB, free: 7.473 MB / 363.1 MB Notification: Performance of SimCode: time 1.212e-06/0.5823, allocations: 0.75 kB / 472.4 MB, free: 7.473 MB / 363.1 MB Notification: Performance of buildModelFMU: Generate C++ for platform static: time 3.176/3.759, allocations: 6.948 MB / 479.3 MB, free: 0.5781 MB / 363.1 MB (rm -f Modelica_3.2.3_cpp_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.pipe ; mkfifo Modelica_3.2.3_cpp_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.pipe ; head -c 1048576 < Modelica_3.2.3_cpp_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.pipe >> ../files/Modelica_3.2.3_cpp_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.sim & /home/hudson/saved_omc/OMSimulator/install/linux/bin/OMSimulator -r=Modelica_3.2.3_cpp_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1_res.mat --tempDir=temp_Modelica_3_2_3_cpp_Modelica_Mechanics_Rotational_Examples_LossyGearDemo1_fmu --startTime=0 --stopTime=0.5 --timeout=50 --tolerance=1e-06 Modelica_3_2_3_cpp_Modelica_Mechanics_Rotational_Examples_LossyGearDemo1.fmu > Modelica_3.2.3_cpp_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.pipe 2>&1) TODO: How the !@#!# did the simulation report success but simulation result Modelica_3.2.3_cpp_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1_res.mat does not exist to compare? outputFormat=mat