Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr ModelicaByExample_ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter.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 3.2.3+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaByExample 0.6.0/package.mo", uses=false) Using package ModelicaByExample with version 0.5.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaByExample 0.6.0/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 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(ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter,fileNamePrefix="ModelicaByExample_ModelicaByExample_Components_SpeedMeasurement_Examples_PlantWithPulseCounter",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter,fileNamePrefix="ModelicaByExample_ModelicaByExample_Components_SpeedMeasurement_Examples_PlantWithPulseCounter",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.001136/0.001136, allocations: 108 kB / 15.6 MB, free: 132 kB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001223/0.001223, allocations: 194.6 kB / 16.53 MB, free: 6.391 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 3.2.3+maint.om/package.mo): time 1.305/1.305, allocations: 205.1 MB / 222.4 MB, free: 4.594 MB / 174.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaByExample 0.6.0/package.mo): time 0.04267/0.04267, allocations: 8.11 MB / 277.9 MB, free: 13.19 MB / 238.1 MB Notification: Modelica requested package Complex of version 3.2.3. Complex 4.0.0 is used instead which states that it is fully compatible without conversion script needed. Notification: Modelica requested package ModelicaServices of version 3.2.3. ModelicaServices 4.0.0 is used instead which states that it is fully compatible without conversion script needed. Notification: ModelicaByExample requested package Modelica of version 3.2.2. Modelica 3.2.3 is used instead which states that it is fully compatible without conversion script needed. Notification: Performance of FrontEnd - loaded program: time 0.001537/0.001537, allocations: 67.91 kB / 337.3 MB, free: 26.43 MB / 254.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.07062/0.07217, allocations: 48.3 MB / 385.6 MB, free: 10.08 MB / 286.1 MB Notification: Performance of NFInst.instantiate(ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter): time 0.002822/0.07503, allocations: 1.982 MB / 387.6 MB, free: 8.078 MB / 286.1 MB Notification: Performance of NFInst.instExpressions: time 0.0008416/0.07588, allocations: 0.6126 MB / 388.2 MB, free: 7.457 MB / 286.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 6.08e-05/0.07596, allocations: 4 kB / 388.2 MB, free: 7.453 MB / 286.1 MB Notification: Performance of NFTyping.typeComponents: time 6.53e-05/0.07604, allocations: 27.72 kB / 388.2 MB, free: 7.426 MB / 286.1 MB Notification: Performance of NFTyping.typeBindings: time 0.0001199/0.07616, allocations: 43.56 kB / 388.3 MB, free: 7.383 MB / 286.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.0001911/0.07636, allocations: 63.86 kB / 388.3 MB, free: 7.32 MB / 286.1 MB Notification: Performance of NFFlatten.flatten: time 0.0002262/0.0766, allocations: 227.1 kB / 388.5 MB, free: 7.098 MB / 286.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0001795/0.07679, allocations: 102.2 kB / 388.6 MB, free: 7 MB / 286.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0001279/0.07692, allocations: 91.7 kB / 388.7 MB, free: 6.91 MB / 286.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0001131/0.07704, allocations: 87.62 kB / 388.8 MB, free: 6.824 MB / 286.1 MB Notification: Performance of NFPackage.collectConstants: time 3.368e-05/0.07708, allocations: 24 kB / 388.8 MB, free: 6.801 MB / 286.1 MB Notification: Performance of NFFlatten.collectFunctions: time 3.317e-05/0.07712, allocations: 20 kB / 388.9 MB, free: 6.781 MB / 286.1 MB Notification: Performance of NFScalarize.scalarize: time 3.981e-05/0.07717, allocations: 43.83 kB / 388.9 MB, free: 6.738 MB / 286.1 MB Notification: Performance of NFVerifyModel.verify: time 9.278e-05/0.07727, allocations: 103.6 kB / 389 MB, free: 6.637 MB / 286.1 MB Notification: Performance of NFConvertDAE.convert: time 0.0001952/0.07747, allocations: 227.5 kB / 389.2 MB, free: 6.414 MB / 286.1 MB Notification: Performance of FrontEnd - DAE generated: time 4.358e-06/0.07748, allocations: 4 kB / 389.2 MB, free: 6.41 MB / 286.1 MB Notification: Performance of FrontEnd: time 1.333e-06/0.07749, allocations: 0 / 389.2 MB, free: 6.41 MB / 286.1 MB Notification: Performance of Transformations before backend: time 4.699e-06/0.0775, allocations: 4 kB / 389.2 MB, free: 6.406 MB / 286.1 MB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 49 * Number of variables: 49 Notification: Performance of Generate backend data structure: time 0.0006096/0.07811, allocations: 0.497 MB / 389.7 MB, free: 5.852 MB / 286.1 MB Notification: Performance of prepare preOptimizeDAE: time 3.178e-05/0.07815, allocations: 11.89 kB / 389.7 MB, free: 5.84 MB / 286.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 4.748e-05/0.07821, allocations: 58.73 kB / 389.8 MB, free: 5.773 MB / 286.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 4.27e-05/0.07826, allocations: 20.75 kB / 389.8 MB, free: 5.754 MB / 286.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0001195/0.07838, allocations: 188.1 kB / 390 MB, free: 5.531 MB / 286.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.776e-05/0.07841, allocations: 16.75 kB / 390 MB, free: 5.516 MB / 286.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 3.922e-05/0.07845, allocations: 28.31 kB / 390.1 MB, free: 5.488 MB / 286.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0002848/0.07874, allocations: 189.9 kB / 390.2 MB, free: 5.293 MB / 286.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 1.123e-05/0.07876, allocations: 0 / 390.2 MB, free: 5.293 MB / 286.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.831e-05/0.07879, allocations: 8 kB / 390.2 MB, free: 5.285 MB / 286.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 6.332e-06/0.0788, allocations: 4 kB / 390.2 MB, free: 5.281 MB / 286.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0001926/0.07899, allocations: 113.1 kB / 390.4 MB, free: 5.172 MB / 286.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0009995/0.08, allocations: 0.7279 MB / 391.1 MB, free: 4.383 MB / 286.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0003231/0.08034, allocations: 247.4 kB / 391.3 MB, free: 4.117 MB / 286.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0002252/0.08057, allocations: 112.8 kB / 391.4 MB, free: 4.004 MB / 286.1 MB Notification: Performance of preOpt evalFunc (simulation): time 1.356e-05/0.0806, allocations: 4 kB / 391.4 MB, free: 4 MB / 286.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0002385/0.08084, allocations: 182.7 kB / 391.6 MB, free: 3.797 MB / 286.1 MB Notification: Performance of pre-optimization done (n=22): time 1.533e-06/0.08085, allocations: 0 / 391.6 MB, free: 3.797 MB / 286.1 MB Notification: Performance of matching and sorting (n=25): time 0.001124/0.08198, allocations: 0.787 MB / 392.4 MB, free: 2.93 MB / 286.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 6.435e-05/0.08206, allocations: 144.5 kB / 392.5 MB, free: 2.758 MB / 286.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 9.222e-05/0.08216, allocations: 133.8 kB / 392.7 MB, free: 2.617 MB / 286.1 MB Notification: Performance of collectPreVariables (initialization): time 2e-05/0.08219, allocations: 29.7 kB / 392.7 MB, free: 2.582 MB / 286.1 MB Notification: Performance of collectInitialEqns (initialization): time 6.457e-05/0.08226, allocations: 140.4 kB / 392.8 MB, free: 2.441 MB / 286.1 MB Notification: Performance of collectInitialBindings (initialization): time 5.46e-05/0.08232, allocations: 82.84 kB / 392.9 MB, free: 2.359 MB / 286.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 7.38e-05/0.0824, allocations: 61.69 kB / 393 MB, free: 2.293 MB / 286.1 MB Notification: Performance of setup shared object (initialization): time 9.331e-05/0.0825, allocations: 322.8 kB / 393.3 MB, free: 1.969 MB / 286.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.000107/0.08261, allocations: 72.17 kB / 393.4 MB, free: 1.898 MB / 286.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0001345/0.08276, allocations: 124.6 kB / 393.5 MB, free: 1.75 MB / 286.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0002855/0.08305, allocations: 263.5 kB / 393.8 MB, free: 1.453 MB / 286.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 1.373e-06/0.08306, allocations: 0 / 393.8 MB, free: 1.453 MB / 286.1 MB Notification: Performance of matching and sorting (n=39) (initialization): time 0.0003721/0.08344, allocations: 296.9 kB / 394 MB, free: 1.152 MB / 286.1 MB Notification: Performance of prepare postOptimizeDAE: time 3.05e-05/0.08348, allocations: 40.14 kB / 394.1 MB, free: 1.109 MB / 286.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 7.113e-06/0.08349, allocations: 4.25 kB / 394.1 MB, free: 1.105 MB / 286.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 1.23e-05/0.08351, allocations: 8 kB / 394.1 MB, free: 1.098 MB / 286.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0002123/0.08373, allocations: 55.91 kB / 394.1 MB, free: 1.043 MB / 286.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 5.991e-06/0.08374, allocations: 4 kB / 394.2 MB, free: 1.039 MB / 286.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 9.659e-05/0.08384, allocations: 12 kB / 394.2 MB, free: 1.027 MB / 286.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 1.629e-05/0.08387, allocations: 12 kB / 394.2 MB, free: 1.016 MB / 286.1 MB Warning: Assuming fixed start value for the following 1 variables: pulseCounter.w:DISCRETE(flow=false fixed = true ) "Sensed speed" type: Real Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 9 * Number of states: 0 () * Number of discrete variables: 11 ($PRE.pulseCounter.w,pulseCounter.w,pulseCounter.count,$PRE.pulseCounter.count,pulseCounter.prev_phi,$PRE.pulseCounter.prev_phi,pulseCounter.next_phi,$PRE.pulseCounter.next_phi,$whenCondition3,$whenCondition1,$whenCondition2) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (37): * Single equations (assignments): 36 * Array equations: 0 * Algorithm blocks: 1 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of prepare postOptimizeDAE: time 0.0001574/0.08403, allocations: 179.4 kB / 394.4 MB, free: 0.8242 MB / 286.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 3.396e-05/0.08407, allocations: 23.75 kB / 394.4 MB, free: 0.8008 MB / 286.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 4.269e-05/0.08412, allocations: 24.83 kB / 394.4 MB, free: 0.7734 MB / 286.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 3.306e-06/0.08413, allocations: 7.938 kB / 394.4 MB, free: 0.7656 MB / 286.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 3.557e-06/0.08414, allocations: 0 / 394.4 MB, free: 0.7656 MB / 286.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 4.578e-06/0.08415, allocations: 3.984 kB / 394.4 MB, free: 0.7617 MB / 286.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0008526/0.085, allocations: 0.6967 MB / 395.1 MB, free: 15.99 MB / 302.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 3.306e-06/0.08502, allocations: 4 kB / 395.1 MB, free: 15.99 MB / 302.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0001905/0.08522, allocations: 39.94 kB / 395.1 MB, free: 15.95 MB / 302.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 2.334e-06/0.08523, allocations: 0 / 395.1 MB, free: 15.95 MB / 302.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 1.998e-05/0.08526, allocations: 8 kB / 395.2 MB, free: 15.95 MB / 302.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 1.884e-06/0.08526, allocations: 4 kB / 395.2 MB, free: 15.94 MB / 302.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.072e-06/0.08527, allocations: 0 / 395.2 MB, free: 15.94 MB / 302.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0005195/0.08579, allocations: 478.6 kB / 395.6 MB, free: 15.45 MB / 302.1 MB Notification: Performance of postOpt removeConstants (simulation): time 4.44e-05/0.08585, allocations: 88.92 kB / 395.7 MB, free: 15.34 MB / 302.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 3.587e-05/0.08589, allocations: 8 kB / 395.7 MB, free: 15.33 MB / 302.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001167/0.08601, allocations: 8 kB / 395.7 MB, free: 15.32 MB / 302.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 4.583e-05/0.08607, allocations: 16.02 kB / 395.7 MB, free: 15.31 MB / 302.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.32e-05/0.0861, allocations: 15.94 kB / 395.8 MB, free: 15.29 MB / 302.1 MB Notification: Performance of sorting global known variables: time 5.181e-05/0.08615, allocations: 99.06 kB / 395.9 MB, free: 15.2 MB / 302.1 MB Notification: Performance of sort global known variables: time 9e-08/0.08616, allocations: 0 / 395.9 MB, free: 15.2 MB / 302.1 MB Notification: Performance of remove unused functions: time 0.0003076/0.08647, allocations: 60 kB / 395.9 MB, free: 15.14 MB / 302.1 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 3 * Number of states: 4 (inertia2.flange_a.phi,inertia2.w,inertia1.flange_a.phi,inertia1.w) * Number of discrete variables: 7 ($whenCondition2,$whenCondition1,$whenCondition3,pulseCounter.w,pulseCounter.next_phi,pulseCounter.prev_phi,pulseCounter.count) * Number of discrete states: 7 (pulseCounter.w,$whenCondition3,pulseCounter.count,pulseCounter.prev_phi,pulseCounter.next_phi,$whenCondition2,$whenCondition1) * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (19): * Single equations (assignments): 18 * Array equations: 0 * Algorithm blocks: 1 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of Backend phase and start with SimCode phase: time 0.0007422/0.08722, allocations: 0.9971 MB / 396.9 MB, free: 14.1 MB / 302.1 MB Notification: Performance of simCode: created initialization part: time 0.0003486/0.08758, allocations: 264.8 kB / 397.2 MB, free: 13.83 MB / 302.1 MB Notification: Performance of simCode: created event and clocks part: time 1.713e-06/0.08759, allocations: 0 / 397.2 MB, free: 13.83 MB / 302.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0001781/0.08778, allocations: 191.3 kB / 397.4 MB, free: 13.63 MB / 302.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002597/0.08805, allocations: 35.73 kB / 397.4 MB, free: 13.6 MB / 302.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.002366/0.09042, allocations: 2.376 MB / 399.8 MB, free: 11.07 MB / 302.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0002447/0.09068, allocations: 0.7319 MB / 400.5 MB, free: 10.32 MB / 302.1 MB Notification: Performance of simCode: alias equations: time 5.248e-05/0.09074, allocations: 13.55 kB / 400.5 MB, free: 10.3 MB / 302.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 8.323e-05/0.09083, allocations: 63.41 kB / 400.6 MB, free: 10.24 MB / 302.1 MB Notification: Performance of SimCode: time 2.61e-07/0.09084, allocations: 4 kB / 400.6 MB, free: 10.24 MB / 302.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.01926/0.1101, allocations: 3.429 MB / 404 MB, free: 6.887 MB / 302.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 7.377/7.487, allocations: 16.25 kB / 404 MB, free: 6.871 MB / 302.1 MB (rm -f ModelicaByExample_ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter.pipe ; mkfifo ModelicaByExample_ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter.pipe ; head -c 1048576 < ModelicaByExample_ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter.pipe >> ../files/ModelicaByExample_ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter.sim & /home/hudson/saved_omc/OMSimulator/install/bin/OMSimulator --tempDir=temp_ModelicaByExample_ModelicaByExample_Components_SpeedMeasurement_Examples_PlantWithPulseCounter_fmu --startTime=0 --stopTime=10 --timeout=50 --tolerance=1e-06 ModelicaByExample_ModelicaByExample_Components_SpeedMeasurement_Examples_PlantWithPulseCounter.fmu > ModelicaByExample_ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter.pipe 2>&1)