Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.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.LossyGearDemo1,fileNamePrefix="Modelica_4_0_0_Modelica_Mechanics_Rotational_Examples_LossyGearDemo1",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Modelica.Mechanics.Rotational.Examples.LossyGearDemo1,fileNamePrefix="Modelica_4_0_0_Modelica_Mechanics_Rotational_Examples_LossyGearDemo1",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.001805/0.001805, allocations: 103.8 kB / 16.92 MB, free: 6.145 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.002236/0.002236, allocations: 187.4 kB / 17.85 MB, free: 5.285 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.479/2.479, allocations: 222.9 MB / 241.5 MB, free: 15.21 MB / 206.1 MB Notification: Performance of FrontEnd - loaded program: time 0.002036/0.002036, allocations: 43.08 kB / 300.7 MB, free: 5.773 MB / 238.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.175/0.1771, allocations: 49.44 MB / 350.2 MB, free: 4.328 MB / 286.1 MB Notification: Performance of NFInst.instantiate(Modelica.Mechanics.Rotational.Examples.LossyGearDemo1): time 0.005975/0.1832, allocations: 2.428 MB / 352.6 MB, free: 1.879 MB / 286.1 MB Notification: Performance of NFInst.instExpressions: time 0.002441/0.1857, allocations: 0.9675 MB / 353.6 MB, free: 0.9023 MB / 286.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0003324/0.186, allocations: 11.94 kB / 353.6 MB, free: 0.8906 MB / 286.1 MB Notification: Performance of NFTyping.typeComponents: time 0.0003294/0.1864, allocations: 47.58 kB / 353.6 MB, free: 0.8438 MB / 286.1 MB Notification: Performance of NFTyping.typeBindings: time 0.001022/0.1874, allocations: 159 kB / 353.8 MB, free: 0.6875 MB / 286.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.0006231/0.1881, allocations: 179.6 kB / 353.9 MB, free: 0.5117 MB / 286.1 MB Notification: Performance of NFFlatten.flatten: time 0.0009023/0.189, allocations: 470.5 kB / 354.4 MB, free: 52 kB / 286.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0003684/0.1894, allocations: 88.94 kB / 354.5 MB, free: 15.96 MB / 302.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0006275/0.19, allocations: 203.4 kB / 354.7 MB, free: 15.76 MB / 302.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0006321/0.1907, allocations: 247.1 kB / 354.9 MB, free: 15.52 MB / 302.1 MB Notification: Performance of NFPackage.collectConstants: time 0.0001686/0.1908, allocations: 40 kB / 355 MB, free: 15.48 MB / 302.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.0004017/0.1913, allocations: 115.9 kB / 355.1 MB, free: 15.36 MB / 302.1 MB Notification: Performance of NFScalarize.scalarize: time 0.0003094/0.1916, allocations: 111.7 kB / 355.2 MB, free: 15.25 MB / 302.1 MB Notification: Performance of NFVerifyModel.verify: time 0.0004746/0.1921, allocations: 187.1 kB / 355.4 MB, free: 15.07 MB / 302.1 MB Notification: Performance of NFConvertDAE.convert: time 0.0008514/0.1929, allocations: 482.8 kB / 355.8 MB, free: 14.6 MB / 302.1 MB Notification: Performance of FrontEnd - DAE generated: time 8.296e-06/0.1929, allocations: 0 / 355.8 MB, free: 14.6 MB / 302.1 MB Notification: Performance of FrontEnd: time 2.214e-06/0.193, allocations: 7.938 kB / 355.9 MB, free: 14.59 MB / 302.1 MB Notification: Performance of Transformations before backend: time 2.014e-05/0.193, allocations: 0 / 355.9 MB, free: 14.59 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: 76 * Number of variables: 76 Notification: Performance of Generate backend data structure: time 0.001742/0.1947, allocations: 0.6744 MB / 356.5 MB, free: 13.87 MB / 302.1 MB Notification: Performance of prepare preOptimizeDAE: time 4.673e-05/0.1948, allocations: 12.03 kB / 356.5 MB, free: 13.86 MB / 302.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.0001074/0.1949, allocations: 66.72 kB / 356.6 MB, free: 13.78 MB / 302.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0003965/0.1953, allocations: 60.45 kB / 356.7 MB, free: 13.72 MB / 302.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0005451/0.1959, allocations: 315.4 kB / 357 MB, free: 13.38 MB / 302.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0001484/0.196, allocations: 92.61 kB / 357.1 MB, free: 13.27 MB / 302.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 8.335e-05/0.1961, allocations: 32.38 kB / 357.1 MB, free: 13.24 MB / 302.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0009066/0.197, allocations: 412.9 kB / 357.5 MB, free: 12.82 MB / 302.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 2.121e-05/0.1971, allocations: 4 kB / 357.5 MB, free: 12.82 MB / 302.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 4.239e-05/0.1971, allocations: 8 kB / 357.5 MB, free: 12.81 MB / 302.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 2.235e-05/0.1972, allocations: 8 kB / 357.5 MB, free: 12.8 MB / 302.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.001196/0.1984, allocations: 486.1 kB / 358 MB, free: 12.33 MB / 302.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.00211/0.2005, allocations: 0.9735 MB / 359 MB, free: 11.3 MB / 302.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.001007/0.2015, allocations: 397.7 kB / 359.4 MB, free: 10.91 MB / 302.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0007096/0.2022, allocations: 238.1 kB / 359.6 MB, free: 10.67 MB / 302.1 MB Notification: Performance of preOpt evalFunc (simulation): time 5.089e-05/0.2023, allocations: 8.422 kB / 359.6 MB, free: 10.66 MB / 302.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 5.636e-05/0.2024, allocations: 43 kB / 359.6 MB, free: 10.61 MB / 302.1 MB Notification: Performance of pre-optimization done (n=49): time 3.797e-06/0.2024, allocations: 192 / 359.6 MB, free: 10.61 MB / 302.1 MB Notification: Performance of matching and sorting (n=55): time 0.006346/0.2087, allocations: 2.163 MB / 361.8 MB, free: 8.34 MB / 302.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 8.051e-05/0.2088, allocations: 81.67 kB / 361.9 MB, free: 8.242 MB / 302.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.000403/0.2093, allocations: 271 kB / 362.1 MB, free: 7.969 MB / 302.1 MB Notification: Performance of collectPreVariables (initialization): time 4.877e-05/0.2093, allocations: 37.7 kB / 362.2 MB, free: 7.926 MB / 302.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.0001105/0.2094, allocations: 137.1 kB / 362.3 MB, free: 7.789 MB / 302.1 MB Notification: Performance of collectInitialBindings (initialization): time 0.0001906/0.2096, allocations: 185.4 kB / 362.5 MB, free: 7.605 MB / 302.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0001843/0.2098, allocations: 86.23 kB / 362.6 MB, free: 7.516 MB / 302.1 MB Notification: Performance of setup shared object (initialization): time 0.0001665/0.21, allocations: 350.8 kB / 362.9 MB, free: 7.164 MB / 302.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0004734/0.2105, allocations: 189 kB / 363.1 MB, free: 6.98 MB / 302.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0005146/0.211, allocations: 248.6 kB / 363.3 MB, free: 6.727 MB / 302.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.001028/0.212, allocations: 392.3 kB / 363.7 MB, free: 6.336 MB / 302.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 2.204e-06/0.2121, allocations: 0 / 363.7 MB, free: 6.336 MB / 302.1 MB Notification: Performance of matching and sorting (n=59) (initialization): time 0.00137/0.2134, allocations: 0.6134 MB / 364.3 MB, free: 5.715 MB / 302.1 MB Notification: Performance of prepare postOptimizeDAE: time 2.21e-05/0.2135, allocations: 7.938 kB / 364.4 MB, free: 5.707 MB / 302.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 8.456e-06/0.2135, allocations: 0 / 364.4 MB, free: 5.707 MB / 302.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 0.0009032/0.2144, allocations: 263.2 kB / 364.6 MB, free: 5.449 MB / 302.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0003097/0.2147, allocations: 63.94 kB / 364.7 MB, free: 5.387 MB / 302.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.004581/0.2193, allocations: 2.931 MB / 367.6 MB, free: 2.32 MB / 302.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0003471/0.2197, allocations: 32 kB / 367.6 MB, free: 2.289 MB / 302.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 4.916e-05/0.2197, allocations: 16 kB / 367.6 MB, free: 2.273 MB / 302.1 MB 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.ideal,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 (33): * Single equations (assignments): 32 * 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,25)} Notification: Performance of prepare postOptimizeDAE: time 0.0002338/0.22, allocations: 165.7 kB / 367.8 MB, free: 2.102 MB / 302.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 9.819e-05/0.2201, allocations: 31.62 kB / 367.8 MB, free: 2.07 MB / 302.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0001167/0.2202, allocations: 51.36 kB / 367.9 MB, free: 2.02 MB / 302.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 6.121e-06/0.2202, allocations: 4 kB / 367.9 MB, free: 2.016 MB / 302.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 3.957e-06/0.2202, allocations: 0 / 367.9 MB, free: 2.016 MB / 302.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 5.491e-06/0.2202, allocations: 4 kB / 367.9 MB, free: 2.012 MB / 302.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.002394/0.2226, allocations: 1.276 MB / 369.2 MB, free: 0.6758 MB / 302.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 4.979e-06/0.2227, allocations: 0 / 369.2 MB, free: 0.6758 MB / 302.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0003358/0.223, allocations: 71.88 kB / 369.2 MB, free: 0.6055 MB / 302.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 0.0007126/0.2237, allocations: 244.7 kB / 369.5 MB, free: 372 kB / 302.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 4.827e-05/0.2238, allocations: 15.94 kB / 369.5 MB, free: 356 kB / 302.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.3138/0.5376, allocations: 2.83 MB / 372.3 MB, free: 24.25 MB / 302.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 5.32e-06/0.5377, allocations: 0.6562 kB / 372.3 MB, free: 24.25 MB / 302.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.003713/0.5414, allocations: 0.96 MB / 373.3 MB, free: 23.95 MB / 302.1 MB Notification: Performance of postOpt removeConstants (simulation): time 0.0003818/0.5418, allocations: 146.6 kB / 373.4 MB, free: 23.84 MB / 302.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0001323/0.542, allocations: 12.83 kB / 373.4 MB, free: 23.83 MB / 302.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0005778/0.5426, allocations: 32.67 kB / 373.5 MB, free: 23.82 MB / 302.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0003644/0.543, allocations: 66.5 kB / 373.5 MB, free: 23.81 MB / 302.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 9.443e-05/0.5431, allocations: 17.42 kB / 373.6 MB, free: 23.8 MB / 302.1 MB Notification: Performance of sorting global known variables: time 0.0005683/0.5437, allocations: 196.2 kB / 373.8 MB, free: 23.7 MB / 302.1 MB Notification: Performance of sort global known variables: time 5.11e-07/0.5437, allocations: 0 / 373.8 MB, free: 23.7 MB / 302.1 MB Notification: Performance of remove unused functions: time 0.001311/0.545, allocations: 151.2 kB / 373.9 MB, free: 23.68 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: 5 (gear.tau_aPos,gear.startForward,gear.startBackward,gear.locked,gear.mode) * Number of discrete states: 1 (gear.mode) * Number of clocked states: 0 () * 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 (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,23)} Notification: Performance of Backend phase and start with SimCode phase: time 0.004137/0.5492, allocations: 1.57 MB / 375.5 MB, free: 22.7 MB / 302.1 MB Notification: Performance of simCode: created initialization part: time 0.003061/0.5523, allocations: 0.7323 MB / 376.2 MB, free: 22.39 MB / 302.1 MB Notification: Performance of simCode: created event and clocks part: time 7.544e-06/0.5523, allocations: 0 / 376.2 MB, free: 22.39 MB / 302.1 MB Notification: Performance of simCode: created simulation system equations: time 0.001668/0.554, allocations: 486.5 kB / 376.7 MB, free: 22.13 MB / 302.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0008556/0.5549, allocations: 37.66 kB / 376.7 MB, free: 22.11 MB / 302.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.01352/0.5684, allocations: 3.823 MB / 380.5 MB, free: 19.89 MB / 302.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0006651/0.5692, allocations: 0.8022 MB / 381.3 MB, free: 19.18 MB / 302.1 MB Notification: Performance of simCode: alias equations: time 0.0004971/0.5697, allocations: 58.48 kB / 381.4 MB, free: 19.18 MB / 302.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0003931/0.5701, allocations: 99.27 kB / 381.5 MB, free: 19.11 MB / 302.1 MB Notification: Performance of SimCode: time 2.525e-06/0.5702, allocations: 4 kB / 381.5 MB, free: 19.11 MB / 302.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.05361/0.6238, allocations: 10.77 MB / 392.3 MB, free: 15.31 MB / 302.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 17.95/18.57, allocations: 15.42 kB / 392.3 MB, free: 15.3 MB / 302.1 MB (rm -f Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.pipe ; mkfifo Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.pipe ; head -c 1048576 < Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.pipe >> ../files/Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.sim & python3 -m fmpy simulate --output-file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1_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_LossyGearDemo1.fmu > Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.pipe 2>&1) diffSimulationResults("Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1_res.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/Reference-modelica.org/ReferenceResults/MAP-LIB_ReferenceResults/v4.0.0/Modelica/Mechanics/Rotational/Examples/LossyGearDemo1/LossyGearDemo1.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/OpenModelicaLibraryTesting/files/Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1.diff",relTol=0.003,relTolDiffMinMax=0.003,rangeDelta=0.001) "Error: Could not read variable gear.mode in file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1_res.csv. Warning: Get data of variable gear.mode from file Modelica_4.0.0_Modelica.Mechanics.Rotational.Examples.LossyGearDemo1_res.csv failed! " Variables in the reference:time,Inertia2.phi,Inertia2.w,gear.mode Variables in the result:time,Inertia2.phi,Inertia2.w