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.001685/0.001685, allocations: 113.8 kB / 17.06 MB, free: 6.012 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.001881/0.001881, allocations: 189.4 kB / 18 MB, free: 5.098 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 1.373/1.373, allocations: 222.9 MB / 241.7 MB, free: 15.08 MB / 206.1 MB Notification: Performance of FrontEnd - loaded program: time 0.001402/0.001402, allocations: 51.92 kB / 350.8 MB, free: 3.738 MB / 286.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.2534/0.2548, allocations: 49.43 MB / 400.2 MB, free: 8.41 MB / 318.1 MB Notification: Performance of NFInst.instantiate(Modelica.Mechanics.Rotational.Examples.LossyGearDemo1): time 0.004001/0.2589, allocations: 2.436 MB / 402.7 MB, free: 6.375 MB / 318.1 MB Notification: Performance of NFInst.instExpressions: time 0.002121/0.261, allocations: 0.9676 MB / 403.6 MB, free: 5.398 MB / 318.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0002213/0.2613, allocations: 4 kB / 403.6 MB, free: 5.395 MB / 318.1 MB Notification: Performance of NFTyping.typeComponents: time 0.0002599/0.2615, allocations: 47.52 kB / 403.7 MB, free: 5.348 MB / 318.1 MB Notification: Performance of NFTyping.typeBindings: time 0.0006073/0.2622, allocations: 151.1 kB / 403.8 MB, free: 5.199 MB / 318.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.0004158/0.2626, allocations: 183.6 kB / 404 MB, free: 5.02 MB / 318.1 MB Notification: Performance of NFFlatten.flatten: time 0.000536/0.2632, allocations: 470.5 kB / 404.5 MB, free: 4.559 MB / 318.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0002098/0.2634, allocations: 92.91 kB / 404.6 MB, free: 4.465 MB / 318.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0003068/0.2637, allocations: 219.3 kB / 404.8 MB, free: 4.25 MB / 318.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0003284/0.264, allocations: 243.2 kB / 405 MB, free: 4.012 MB / 318.1 MB Notification: Performance of NFPackage.collectConstants: time 6.813e-05/0.2641, allocations: 40 kB / 405 MB, free: 3.973 MB / 318.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.0002505/0.2644, allocations: 123.8 kB / 405.2 MB, free: 3.852 MB / 318.1 MB Notification: Performance of NFScalarize.scalarize: time 0.0001518/0.2645, allocations: 107.7 kB / 405.3 MB, free: 3.746 MB / 318.1 MB Notification: Performance of NFVerifyModel.verify: time 0.0002042/0.2648, allocations: 191 kB / 405.5 MB, free: 3.559 MB / 318.1 MB Notification: Performance of NFConvertDAE.convert: time 0.0006729/0.2654, allocations: 497.2 kB / 405.9 MB, free: 3.074 MB / 318.1 MB Notification: Performance of FrontEnd - DAE generated: time 5.22e-06/0.2655, allocations: 3.938 kB / 405.9 MB, free: 3.07 MB / 318.1 MB Notification: Performance of FrontEnd: time 1.713e-06/0.2655, allocations: 0 / 405.9 MB, free: 3.07 MB / 318.1 MB Notification: Performance of Transformations before backend: time 7.544e-06/0.2655, allocations: 4 kB / 405.9 MB, free: 3.066 MB / 318.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.001445/0.2669, allocations: 0.6817 MB / 406.6 MB, free: 2.336 MB / 318.1 MB Notification: Performance of prepare preOptimizeDAE: time 5.686e-05/0.267, allocations: 8.031 kB / 406.6 MB, free: 2.328 MB / 318.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.0001222/0.2671, allocations: 74.66 kB / 406.7 MB, free: 2.246 MB / 318.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0003478/0.2675, allocations: 56.67 kB / 406.8 MB, free: 2.191 MB / 318.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0005944/0.2681, allocations: 315.7 kB / 407.1 MB, free: 1.844 MB / 318.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0001486/0.2682, allocations: 88.56 kB / 407.2 MB, free: 1.746 MB / 318.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 6.786e-05/0.2683, allocations: 32.36 kB / 407.2 MB, free: 1.715 MB / 318.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.000867/0.2692, allocations: 416.9 kB / 407.6 MB, free: 1.293 MB / 318.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 2.49e-05/0.2692, allocations: 7.953 kB / 407.6 MB, free: 1.285 MB / 318.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 3.978e-05/0.2693, allocations: 12 kB / 407.6 MB, free: 1.273 MB / 318.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 1.235e-05/0.2693, allocations: 8 kB / 407.6 MB, free: 1.266 MB / 318.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.001053/0.2704, allocations: 470.3 kB / 408.1 MB, free: 0.8086 MB / 318.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001941/0.2723, allocations: 0.9621 MB / 409 MB, free: 15.79 MB / 334.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0008782/0.2732, allocations: 413.2 kB / 409.5 MB, free: 15.38 MB / 334.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0004845/0.2737, allocations: 234.1 kB / 409.7 MB, free: 15.14 MB / 334.1 MB Notification: Performance of preOpt evalFunc (simulation): time 4.282e-05/0.2738, allocations: 16.36 kB / 409.7 MB, free: 15.13 MB / 334.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 4.267e-05/0.2738, allocations: 35 kB / 409.7 MB, free: 15.09 MB / 334.1 MB Notification: Performance of pre-optimization done (n=49): time 1.963e-06/0.2738, allocations: 0 / 409.7 MB, free: 15.09 MB / 334.1 MB Notification: Performance of matching and sorting (n=55): time 0.005499/0.2793, allocations: 2.168 MB / 411.9 MB, free: 12.81 MB / 334.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 6.801e-05/0.2794, allocations: 89.67 kB / 412 MB, free: 12.7 MB / 334.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0003578/0.2798, allocations: 267 kB / 412.2 MB, free: 12.43 MB / 334.1 MB Notification: Performance of collectPreVariables (initialization): time 4.566e-05/0.2798, allocations: 37.64 kB / 412.3 MB, free: 12.39 MB / 334.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.0001052/0.2799, allocations: 137.3 kB / 412.4 MB, free: 12.25 MB / 334.1 MB Notification: Performance of collectInitialBindings (initialization): time 0.0001657/0.2801, allocations: 190.3 kB / 412.6 MB, free: 12.06 MB / 334.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0001662/0.2803, allocations: 90.23 kB / 412.7 MB, free: 11.97 MB / 334.1 MB Notification: Performance of setup shared object (initialization): time 0.0001664/0.2805, allocations: 338.8 kB / 413 MB, free: 11.63 MB / 334.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0004736/0.2809, allocations: 201 kB / 413.2 MB, free: 11.43 MB / 334.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0005115/0.2815, allocations: 240.6 kB / 413.5 MB, free: 11.19 MB / 334.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0008895/0.2824, allocations: 396.3 kB / 413.8 MB, free: 10.8 MB / 334.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 2.134e-06/0.2824, allocations: 0 / 413.8 MB, free: 10.8 MB / 334.1 MB Notification: Performance of matching and sorting (n=59) (initialization): time 0.001406/0.2838, allocations: 0.6175 MB / 414.5 MB, free: 10.17 MB / 334.1 MB Notification: Performance of prepare postOptimizeDAE: time 2.439e-05/0.2838, allocations: 15.88 kB / 414.5 MB, free: 10.15 MB / 334.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 7.193e-06/0.2839, allocations: 0 / 414.5 MB, free: 10.15 MB / 334.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 0.0008107/0.2847, allocations: 262.6 kB / 414.7 MB, free: 9.895 MB / 334.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0003109/0.285, allocations: 59.89 kB / 414.8 MB, free: 9.836 MB / 334.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.004494/0.2895, allocations: 2.941 MB / 417.7 MB, free: 6.75 MB / 334.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0003747/0.2899, allocations: 28 kB / 417.8 MB, free: 6.723 MB / 334.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 6.113e-05/0.29, allocations: 23.98 kB / 417.8 MB, free: 6.699 MB / 334.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.0002594/0.2902, allocations: 157.7 kB / 417.9 MB, free: 6.535 MB / 334.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0001013/0.2904, allocations: 31.81 kB / 418 MB, free: 6.504 MB / 334.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0001225/0.2905, allocations: 51.3 kB / 418 MB, free: 6.457 MB / 334.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 6.142e-06/0.2905, allocations: 8.062 kB / 418 MB, free: 6.449 MB / 334.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 3.607e-06/0.2905, allocations: 0 / 418 MB, free: 6.449 MB / 334.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 7.665e-06/0.2905, allocations: 3.984 kB / 418 MB, free: 6.445 MB / 334.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.002457/0.293, allocations: 1.262 MB / 419.3 MB, free: 5.125 MB / 334.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 4.889e-06/0.293, allocations: 4.031 kB / 419.3 MB, free: 5.121 MB / 334.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0003313/0.2934, allocations: 67.89 kB / 419.4 MB, free: 5.055 MB / 334.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 0.0007039/0.2941, allocations: 240.6 kB / 419.6 MB, free: 4.816 MB / 334.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 4.399e-05/0.2941, allocations: 15.98 kB / 419.6 MB, free: 4.801 MB / 334.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.004179/0.2983, allocations: 2.849 MB / 422.5 MB, free: 1.82 MB / 334.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.224e-06/0.2983, allocations: 4.031 kB / 422.5 MB, free: 1.816 MB / 334.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001967/0.3003, allocations: 0.9664 MB / 423.4 MB, free: 0.832 MB / 334.1 MB Notification: Performance of postOpt removeConstants (simulation): time 0.0001994/0.3005, allocations: 148.9 kB / 423.6 MB, free: 0.668 MB / 334.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 6.58e-05/0.3006, allocations: 15.94 kB / 423.6 MB, free: 0.6523 MB / 334.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0002992/0.3009, allocations: 27.97 kB / 423.6 MB, free: 0.625 MB / 334.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001784/0.3011, allocations: 72.39 kB / 423.7 MB, free: 0.5547 MB / 334.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 3.949e-05/0.3012, allocations: 19.98 kB / 423.7 MB, free: 0.5352 MB / 334.1 MB Notification: Performance of sorting global known variables: time 0.0002653/0.3014, allocations: 192.6 kB / 423.9 MB, free: 356 kB / 334.1 MB Notification: Performance of sort global known variables: time 2.21e-07/0.3014, allocations: 0 / 423.9 MB, free: 356 kB / 334.1 MB Notification: Performance of remove unused functions: time 0.0006415/0.3021, allocations: 159.9 kB / 424.1 MB, free: 196 kB / 334.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.00256/0.3047, allocations: 1.561 MB / 425.6 MB, free: 14.59 MB / 350.1 MB Notification: Performance of simCode: created initialization part: time 0.001632/0.3063, allocations: 0.7188 MB / 426.3 MB, free: 13.86 MB / 350.1 MB Notification: Performance of simCode: created event and clocks part: time 6.902e-06/0.3063, allocations: 4 kB / 426.3 MB, free: 13.85 MB / 350.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0009377/0.3073, allocations: 479.8 kB / 426.8 MB, free: 13.37 MB / 350.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.000474/0.3078, allocations: 46.73 kB / 426.8 MB, free: 13.32 MB / 350.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.006808/0.3146, allocations: 3.829 MB / 430.7 MB, free: 9.391 MB / 350.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0005282/0.3152, allocations: 0.7968 MB / 431.5 MB, free: 8.57 MB / 350.1 MB Notification: Performance of simCode: alias equations: time 0.000237/0.3154, allocations: 54.95 kB / 431.5 MB, free: 8.52 MB / 350.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001887/0.3156, allocations: 103.3 kB / 431.6 MB, free: 8.418 MB / 350.1 MB Notification: Performance of SimCode: time 1.102e-06/0.3156, allocations: 0 / 431.6 MB, free: 8.418 MB / 350.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.04274/0.3584, allocations: 10.96 MB / 442.6 MB, free: 13.62 MB / 366.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 12.38/12.74, allocations: 11.34 kB / 442.6 MB, free: 13.61 MB / 366.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