Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2.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) 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(Modelica.Mechanics.Rotational.Examples.LossyGearDemo2,fileNamePrefix="Modelica_4_0_0_Modelica_Mechanics_Rotational_Examples_LossyGearDemo2",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Modelica.Mechanics.Rotational.Examples.LossyGearDemo2,fileNamePrefix="Modelica_4_0_0_Modelica_Mechanics_Rotational_Examples_LossyGearDemo2",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.001345/0.001345, allocations: 104.5 kB / 16.92 MB, free: 6.199 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001545/0.001546, allocations: 191.4 kB / 17.85 MB, free: 5.301 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 2.331/2.331, allocations: 222.9 MB / 241.5 MB, free: 15.22 MB / 206.1 MB Notification: Performance of FrontEnd - loaded program: time 0.002037/0.002037, allocations: 50.73 kB / 300.7 MB, free: 5.777 MB / 238.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1787/0.1808, allocations: 49.44 MB / 350.2 MB, free: 4.328 MB / 286.1 MB Notification: Performance of NFInst.instantiate(Modelica.Mechanics.Rotational.Examples.LossyGearDemo2): time 0.008061/0.189, allocations: 2.719 MB / 352.9 MB, free: 1.586 MB / 286.1 MB Notification: Performance of NFInst.instExpressions: time 0.003534/0.1926, allocations: 1.092 MB / 354 MB, free: 496 kB / 286.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0006127/0.1932, allocations: 7.938 kB / 354 MB, free: 488 kB / 286.1 MB Notification: Performance of NFTyping.typeComponents: time 0.0005234/0.1938, allocations: 71.42 kB / 354.1 MB, free: 416 kB / 286.1 MB Notification: Performance of NFTyping.typeBindings: time 0.001353/0.1952, allocations: 194.2 kB / 354.2 MB, free: 224 kB / 286.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.001075/0.1963, allocations: 243.6 kB / 354.5 MB, free: 15.98 MB / 302.1 MB Notification: Performance of NFFlatten.flatten: time 0.001409/0.1977, allocations: 0.643 MB / 355.1 MB, free: 15.34 MB / 302.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0004114/0.1981, allocations: 127.4 kB / 355.2 MB, free: 15.21 MB / 302.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0008257/0.199, allocations: 291.1 kB / 355.5 MB, free: 14.92 MB / 302.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0008506/0.1999, allocations: 339 kB / 355.9 MB, free: 14.59 MB / 302.1 MB Notification: Performance of NFPackage.collectConstants: time 0.0002468/0.2001, allocations: 52 kB / 355.9 MB, free: 14.54 MB / 302.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.000561/0.2007, allocations: 139.8 kB / 356 MB, free: 14.4 MB / 302.1 MB Notification: Performance of NFScalarize.scalarize: time 0.0003557/0.2011, allocations: 139.6 kB / 356.2 MB, free: 14.27 MB / 302.1 MB Notification: Performance of NFVerifyModel.verify: time 0.0005719/0.2017, allocations: 254.7 kB / 356.4 MB, free: 14.02 MB / 302.1 MB Notification: Performance of NFConvertDAE.convert: time 0.001271/0.2029, allocations: 0.635 MB / 357.1 MB, free: 13.38 MB / 302.1 MB Notification: Performance of FrontEnd - DAE generated: time 1.167e-05/0.203, allocations: 3.984 kB / 357.1 MB, free: 13.38 MB / 302.1 MB Notification: Performance of FrontEnd: time 2.205e-06/0.203, allocations: 4 kB / 357.1 MB, free: 13.37 MB / 302.1 MB Notification: Performance of Transformations before backend: time 2.632e-05/0.203, allocations: 0 / 357.1 MB, free: 13.37 MB / 302.1 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.003066/0.2061, allocations: 0.7915 MB / 357.9 MB, free: 12.53 MB / 302.1 MB Notification: Performance of prepare preOptimizeDAE: time 6.5e-05/0.2062, allocations: 11.89 kB / 357.9 MB, free: 12.52 MB / 302.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.0002171/0.2064, allocations: 82.7 kB / 358 MB, free: 12.43 MB / 302.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0006131/0.207, allocations: 64.36 kB / 358 MB, free: 12.36 MB / 302.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0008954/0.208, allocations: 358.5 kB / 358.4 MB, free: 11.98 MB / 302.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0002113/0.2082, allocations: 92.95 kB / 358.5 MB, free: 11.88 MB / 302.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0001485/0.2083, allocations: 44.38 kB / 358.5 MB, free: 11.83 MB / 302.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.001795/0.2101, allocations: 0.5604 MB / 359.1 MB, free: 11.26 MB / 302.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 3.506e-05/0.2102, allocations: 3.906 kB / 359.1 MB, free: 11.25 MB / 302.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 8.217e-05/0.2103, allocations: 16 kB / 359.1 MB, free: 11.24 MB / 302.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 2.566e-05/0.2103, allocations: 12 kB / 359.1 MB, free: 11.23 MB / 302.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.002278/0.2126, allocations: 0.6401 MB / 359.7 MB, free: 10.59 MB / 302.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.004064/0.2167, allocations: 1.291 MB / 361 MB, free: 9.238 MB / 302.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.001959/0.2187, allocations: 0.5461 MB / 361.6 MB, free: 8.68 MB / 302.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.001065/0.2198, allocations: 326.3 kB / 361.9 MB, free: 8.359 MB / 302.1 MB Notification: Performance of preOpt evalFunc (simulation): time 6.599e-05/0.2199, allocations: 12.48 kB / 361.9 MB, free: 8.348 MB / 302.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 5.723e-05/0.2199, allocations: 39.12 kB / 361.9 MB, free: 8.301 MB / 302.1 MB Notification: Performance of pre-optimization done (n=61): time 4.328e-06/0.22, allocations: 4 kB / 362 MB, free: 8.297 MB / 302.1 MB Notification: Performance of matching and sorting (n=69): time 0.01142/0.2314, allocations: 2.856 MB / 364.8 MB, free: 5.316 MB / 302.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 0.0001053/0.2316, allocations: 93.61 kB / 364.9 MB, free: 5.207 MB / 302.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0007725/0.2323, allocations: 338.9 kB / 365.2 MB, free: 4.863 MB / 302.1 MB Notification: Performance of collectPreVariables (initialization): time 9.745e-05/0.2325, allocations: 41.69 kB / 365.3 MB, free: 4.816 MB / 302.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.0001942/0.2327, allocations: 157.6 kB / 365.4 MB, free: 4.66 MB / 302.1 MB Notification: Performance of collectInitialBindings (initialization): time 0.0003503/0.233, allocations: 232.7 kB / 365.7 MB, free: 4.43 MB / 302.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 0.000408/0.2335, allocations: 122.2 kB / 365.8 MB, free: 4.305 MB / 302.1 MB Notification: Performance of setup shared object (initialization): time 0.0002379/0.2337, allocations: 350.8 kB / 366.1 MB, free: 3.953 MB / 302.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.001089/0.2348, allocations: 289.2 kB / 366.4 MB, free: 3.672 MB / 302.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.00114/0.236, allocations: 350.5 kB / 366.7 MB, free: 3.316 MB / 302.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.001859/0.2379, allocations: 0.5304 MB / 367.3 MB, free: 2.777 MB / 302.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 7.725e-06/0.2379, allocations: 3.984 kB / 367.3 MB, free: 2.773 MB / 302.1 MB Notification: Performance of matching and sorting (n=79) (initialization): time 0.002937/0.2408, allocations: 0.8772 MB / 368.1 MB, free: 1.887 MB / 302.1 MB Notification: Performance of prepare postOptimizeDAE: time 4.138e-05/0.2409, allocations: 10.75 kB / 368.2 MB, free: 1.879 MB / 302.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.515e-05/0.2409, allocations: 4 kB / 368.2 MB, free: 1.875 MB / 302.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 0.001748/0.2427, allocations: 475.3 kB / 368.6 MB, free: 1.41 MB / 302.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0006356/0.2433, allocations: 91.81 kB / 368.7 MB, free: 1.32 MB / 302.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.002144/0.2455, allocations: 1.072 MB / 369.8 MB, free: 228 kB / 302.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0008319/0.2463, allocations: 59.92 kB / 369.8 MB, free: 168 kB / 302.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.0001115/0.2465, allocations: 20 kB / 369.9 MB, free: 148 kB / 302.1 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.ideal,bearingFriction.mode,$PRE.bearingFriction.mode,bearingFriction.locked,bearingFriction.startBackward,$PRE.bearingFriction.startBackward,bearingFriction.startForward,$PRE.bearingFriction.startForward,gear.mode,$PRE.gear.mode,gear.locked,gear.startBackward,gear.startForward,gear.tau_aPos) * Number of discrete states: 0 () * Number of clocked 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 (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 {(2,32)} Notification: Performance of prepare postOptimizeDAE: time 0.2849/0.5314, allocations: 180.7 kB / 370 MB, free: 26.03 MB / 302.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0003399/0.5318, allocations: 41.19 kB / 370.1 MB, free: 26.03 MB / 302.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0002731/0.5321, allocations: 65.81 kB / 370.1 MB, free: 26.02 MB / 302.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 1.784e-05/0.5321, allocations: 8.297 kB / 370.2 MB, free: 26.02 MB / 302.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 9.718e-06/0.5321, allocations: 0.5 kB / 370.2 MB, free: 26.02 MB / 302.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 1.948e-05/0.5321, allocations: 7.594 kB / 370.2 MB, free: 26.02 MB / 302.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.00632/0.5385, allocations: 1.766 MB / 371.9 MB, free: 25.66 MB / 302.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 8.446e-06/0.5386, allocations: 1.031 kB / 371.9 MB, free: 25.66 MB / 302.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.000631/0.5392, allocations: 83.31 kB / 372 MB, free: 25.66 MB / 302.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 0.001695/0.5409, allocations: 456.3 kB / 372.5 MB, free: 25.59 MB / 302.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 9.354e-05/0.541, allocations: 18.72 kB / 372.5 MB, free: 25.58 MB / 302.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.001973/0.543, allocations: 1.029 MB / 373.5 MB, free: 24.88 MB / 302.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 6.513e-06/0.543, allocations: 5.688 kB / 373.5 MB, free: 24.87 MB / 302.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.004087/0.5471, allocations: 1.304 MB / 374.8 MB, free: 24.32 MB / 302.1 MB Notification: Performance of postOpt removeConstants (simulation): time 0.0004218/0.5476, allocations: 178.5 kB / 375 MB, free: 24.2 MB / 302.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0001887/0.5478, allocations: 17.31 kB / 375 MB, free: 24.19 MB / 302.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0007581/0.5486, allocations: 50.91 kB / 375.1 MB, free: 24.18 MB / 302.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0003461/0.5489, allocations: 88.56 kB / 375.1 MB, free: 24.16 MB / 302.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 0.0001042/0.549, allocations: 23.92 kB / 375.2 MB, free: 24.16 MB / 302.1 MB Notification: Performance of sorting global known variables: time 0.0004852/0.5495, allocations: 247.5 kB / 375.4 MB, free: 24.04 MB / 302.1 MB Notification: Performance of sort global known variables: time 4.01e-07/0.5495, allocations: 0 / 375.4 MB, free: 24.04 MB / 302.1 MB Notification: Performance of remove unused functions: time 0.0009608/0.5505, allocations: 148.2 kB / 375.6 MB, free: 24.02 MB / 302.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: 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) * Number of clocked states: 0 () * 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 (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 {(2,29)} Notification: Performance of Backend phase and start with SimCode phase: time 0.004896/0.5554, allocations: 1.897 MB / 377.4 MB, free: 22.91 MB / 302.1 MB Notification: Performance of simCode: created initialization part: time 0.003249/0.5587, allocations: 0.7417 MB / 378.2 MB, free: 22.69 MB / 302.1 MB Notification: Performance of simCode: created event and clocks part: time 6.182e-06/0.5587, allocations: 1.156 kB / 378.2 MB, free: 22.69 MB / 302.1 MB Notification: Performance of simCode: created simulation system equations: time 0.00149/0.5602, allocations: 395.4 kB / 378.6 MB, free: 22.57 MB / 302.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0009625/0.5612, allocations: 55.59 kB / 378.6 MB, free: 22.54 MB / 302.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.01541/0.5766, allocations: 5.006 MB / 383.6 MB, free: 19.89 MB / 302.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0007212/0.5774, allocations: 0.8226 MB / 384.5 MB, free: 19.19 MB / 302.1 MB Notification: Performance of simCode: alias equations: time 0.0006101/0.5781, allocations: 64.23 kB / 384.5 MB, free: 19.18 MB / 302.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0004521/0.5786, allocations: 132 kB / 384.7 MB, free: 19.09 MB / 302.1 MB Notification: Performance of SimCode: time 2.275e-06/0.5786, allocations: 0 / 384.7 MB, free: 19.09 MB / 302.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.06758/0.6462, allocations: 13.57 MB / 398.2 MB, free: 9.973 MB / 302.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 17.94/18.59, allocations: 7.062 kB / 398.2 MB, free: 9.969 MB / 302.1 MB (rm -f Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2.pipe ; mkfifo Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2.pipe ; head -c 1048576 < Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2.pipe >> ../files/Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2.sim & python3 -m fmpy simulate --output-file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv --start-time 0 --stop-time 0.5 --timeout 50 --relative-tolerance 1e-06 --interface-type ModelExchange --solver CVode --output-interval 0.001 Modelica_4_0_0_Modelica_Mechanics_Rotational_Examples_LossyGearDemo2.fmu > Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2.pipe 2>&1) diffSimulationResults("Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/Reference-modelica.org/ReferenceResults/MAP-LIB_ReferenceResults/v4.0.0/Modelica/Mechanics/Rotational/Examples/LossyGearDemo2/LossyGearDemo2.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/OpenModelicaLibraryTesting/files/Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2.diff",relTol=0.003,relTolDiffMinMax=0.003,rangeDelta=0.001) "Warning: Resultfile and Reference have different end time points! Reffile[1016]=0.500000 File[366468]=0.063596 Error: Could not read variable bearingFriction.mode in file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv. Warning: Get data of variable bearingFriction.mode from file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv failed! Error: Could not read variable bearingFriction.startBackward in file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv. Warning: Get data of variable bearingFriction.startBackward from file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv failed! Error: Could not read variable bearingFriction.startForward in file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv. Warning: Get data of variable bearingFriction.startForward from file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv failed! Error: Could not read variable gear.mode in file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv. Warning: Get data of variable gear.mode from file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo2_res.csv failed! " Variables in the reference:time,Inertia2.phi,Inertia2.w,bearingFriction.mode,bearingFriction.startBackward,bearingFriction.startForward,gear.mode Variables in the result:time,Inertia2.phi,Inertia2.w