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.008418/0.008418, allocations: 100.9 kB / 15.73 MB, free: 5.562 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.00156/0.00156, allocations: 195.1 kB / 16.67 MB, free: 5.504 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.532/1.532, allocations: 205.1 MB / 222.5 MB, free: 12.24 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaByExample 0.6.0/package.mo): time 0.04437/0.04437, allocations: 8.1 MB / 278 MB, free: 3.949 MB / 222.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.002198/0.002198, allocations: 65.8 kB / 386.2 MB, free: 47.44 MB / 318.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.1076/0.1098, allocations: 48.32 MB / 434.5 MB, free: 9.051 MB / 318.1 MB Notification: Performance of NFInst.instantiate(ModelicaByExample.Components.SpeedMeasurement.Examples.PlantWithPulseCounter): time 0.002552/0.1124, allocations: 1.987 MB / 436.5 MB, free: 7.055 MB / 318.1 MB Notification: Performance of NFInst.instExpressions: time 0.0008239/0.1133, allocations: 0.6126 MB / 437.1 MB, free: 6.434 MB / 318.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 7.857e-05/0.1134, allocations: 4 kB / 437.1 MB, free: 6.43 MB / 318.1 MB Notification: Performance of NFTyping.typeComponents: time 6.803e-05/0.1135, allocations: 23.73 kB / 437.1 MB, free: 6.406 MB / 318.1 MB Notification: Performance of NFTyping.typeBindings: time 0.000128/0.1136, allocations: 47.55 kB / 437.2 MB, free: 6.359 MB / 318.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.0002402/0.1138, allocations: 63.88 kB / 437.2 MB, free: 6.297 MB / 318.1 MB Notification: Performance of NFFlatten.flatten: time 0.0002031/0.1141, allocations: 231.1 kB / 437.5 MB, free: 6.07 MB / 318.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0001827/0.1142, allocations: 94.12 kB / 437.5 MB, free: 5.977 MB / 318.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0001242/0.1144, allocations: 87.77 kB / 437.6 MB, free: 5.891 MB / 318.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0001045/0.1145, allocations: 95.61 kB / 437.7 MB, free: 5.797 MB / 318.1 MB Notification: Performance of NFPackage.collectConstants: time 2.848e-05/0.1145, allocations: 20 kB / 437.7 MB, free: 5.777 MB / 318.1 MB Notification: Performance of NFFlatten.collectFunctions: time 2.693e-05/0.1146, allocations: 20 kB / 437.8 MB, free: 5.758 MB / 318.1 MB Notification: Performance of NFScalarize.scalarize: time 3.584e-05/0.1146, allocations: 51.83 kB / 437.8 MB, free: 5.707 MB / 318.1 MB Notification: Performance of NFVerifyModel.verify: time 7.634e-05/0.1147, allocations: 95.59 kB / 437.9 MB, free: 5.613 MB / 318.1 MB Notification: Performance of NFConvertDAE.convert: time 0.0001742/0.1149, allocations: 234.9 kB / 438.1 MB, free: 5.387 MB / 318.1 MB Notification: Performance of FrontEnd - DAE generated: time 4.779e-06/0.1149, allocations: 0 / 438.1 MB, free: 5.387 MB / 318.1 MB Notification: Performance of FrontEnd: time 1.703e-06/0.1149, allocations: 0 / 438.1 MB, free: 5.387 MB / 318.1 MB Notification: Performance of Transformations before backend: time 6.011e-06/0.1149, allocations: 0 / 438.1 MB, free: 5.387 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: 49 * Number of variables: 49 Notification: Performance of Generate backend data structure: time 0.0005839/0.1155, allocations: 0.5009 MB / 438.6 MB, free: 4.828 MB / 318.1 MB Notification: Performance of prepare preOptimizeDAE: time 3.658e-05/0.1155, allocations: 11.89 kB / 438.6 MB, free: 4.816 MB / 318.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 3.971e-05/0.1156, allocations: 54.73 kB / 438.7 MB, free: 4.754 MB / 318.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 4.14e-05/0.1156, allocations: 24.66 kB / 438.7 MB, free: 4.73 MB / 318.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 9.683e-05/0.1157, allocations: 180.2 kB / 438.9 MB, free: 4.516 MB / 318.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 1.321e-05/0.1157, allocations: 12.75 kB / 438.9 MB, free: 4.504 MB / 318.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 3.709e-05/0.1158, allocations: 32.27 kB / 438.9 MB, free: 4.473 MB / 318.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0002436/0.116, allocations: 190 kB / 439.1 MB, free: 4.281 MB / 318.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 1.346e-05/0.116, allocations: 7.875 kB / 439.1 MB, free: 4.273 MB / 318.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 1.884e-05/0.1161, allocations: 8 kB / 439.1 MB, free: 4.266 MB / 318.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 6.032e-06/0.1161, allocations: 4 kB / 439.2 MB, free: 4.262 MB / 318.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0001602/0.1162, allocations: 121.1 kB / 439.3 MB, free: 4.145 MB / 318.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.0008548/0.1171, allocations: 0.7162 MB / 440 MB, free: 3.363 MB / 318.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.0002804/0.1174, allocations: 242.9 kB / 440.2 MB, free: 3.102 MB / 318.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0001774/0.1176, allocations: 112.8 kB / 440.3 MB, free: 2.988 MB / 318.1 MB Notification: Performance of preOpt evalFunc (simulation): time 1.594e-05/0.1176, allocations: 4 kB / 440.3 MB, free: 2.984 MB / 318.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0002342/0.1178, allocations: 178.7 kB / 440.5 MB, free: 2.785 MB / 318.1 MB Notification: Performance of pre-optimization done (n=22): time 1.323e-06/0.1179, allocations: 8 kB / 440.5 MB, free: 2.777 MB / 318.1 MB Notification: Performance of matching and sorting (n=25): time 0.001021/0.1189, allocations: 0.7991 MB / 441.3 MB, free: 1.898 MB / 318.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 4.827e-05/0.1189, allocations: 136.5 kB / 441.5 MB, free: 1.734 MB / 318.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 7.574e-05/0.119, allocations: 133.7 kB / 441.6 MB, free: 1.594 MB / 318.1 MB Notification: Performance of collectPreVariables (initialization): time 1.533e-05/0.119, allocations: 29.7 kB / 441.6 MB, free: 1.559 MB / 318.1 MB Notification: Performance of collectInitialEqns (initialization): time 4.454e-05/0.1191, allocations: 132.5 kB / 441.7 MB, free: 1.426 MB / 318.1 MB Notification: Performance of collectInitialBindings (initialization): time 4.014e-05/0.1191, allocations: 86.83 kB / 441.8 MB, free: 1.34 MB / 318.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 5.919e-05/0.1192, allocations: 61.61 kB / 441.9 MB, free: 1.273 MB / 318.1 MB Notification: Performance of setup shared object (initialization): time 5.254e-05/0.1193, allocations: 326.8 kB / 442.2 MB, free: 0.9453 MB / 318.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 8.513e-05/0.1194, allocations: 60.3 kB / 442.3 MB, free: 0.8828 MB / 318.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0001057/0.1195, allocations: 132.5 kB / 442.4 MB, free: 0.7266 MB / 318.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0002173/0.1197, allocations: 268.2 kB / 442.7 MB, free: 436 kB / 318.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 1.863e-06/0.1197, allocations: 4 kB / 442.7 MB, free: 432 kB / 318.1 MB Notification: Performance of matching and sorting (n=39) (initialization): time 0.0002855/0.12, allocations: 292.1 kB / 442.9 MB, free: 128 kB / 318.1 MB Notification: Performance of prepare postOptimizeDAE: time 2.584e-05/0.12, allocations: 37.64 kB / 443 MB, free: 84 kB / 318.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 6.702e-06/0.12, allocations: 4 kB / 443 MB, free: 80 kB / 318.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 1.503e-05/0.12, allocations: 4 kB / 443 MB, free: 76 kB / 318.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0001951/0.1202, allocations: 64.16 kB / 443.1 MB, free: 12 kB / 318.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 9.428e-06/0.1203, allocations: 4 kB / 443.1 MB, free: 8 kB / 318.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0001162/0.1204, allocations: 12.05 kB / 443.1 MB, free: 15.99 MB / 334.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 1.667e-05/0.1204, allocations: 11.94 kB / 443.1 MB, free: 15.98 MB / 334.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.0002422/0.1207, allocations: 179.8 kB / 443.3 MB, free: 15.79 MB / 334.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 3.022e-05/0.1207, allocations: 15.84 kB / 443.3 MB, free: 15.78 MB / 334.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 4.773e-05/0.1208, allocations: 16.84 kB / 443.3 MB, free: 15.76 MB / 334.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 1.793e-06/0.1208, allocations: 0 / 443.3 MB, free: 15.76 MB / 334.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 9.969e-06/0.1208, allocations: 8 kB / 443.3 MB, free: 15.75 MB / 334.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 1.693e-05/0.1208, allocations: 7.922 kB / 443.3 MB, free: 15.75 MB / 334.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0009462/0.1217, allocations: 0.6967 MB / 444 MB, free: 14.98 MB / 334.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 1.813e-06/0.1218, allocations: 0 / 444 MB, free: 14.98 MB / 334.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0001894/0.122, allocations: 43.92 kB / 444 MB, free: 14.94 MB / 334.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 2.685e-06/0.122, allocations: 64 / 444 MB, free: 14.94 MB / 334.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.219e-05/0.122, allocations: 15.98 kB / 444.1 MB, free: 14.92 MB / 334.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 1.883e-06/0.122, allocations: 3.938 kB / 444.1 MB, free: 14.92 MB / 334.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.233e-06/0.122, allocations: 4 kB / 444.1 MB, free: 14.91 MB / 334.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0005949/0.1226, allocations: 470.5 kB / 444.5 MB, free: 14.43 MB / 334.1 MB Notification: Performance of postOpt removeConstants (simulation): time 4.818e-05/0.1227, allocations: 85.02 kB / 444.6 MB, free: 14.32 MB / 334.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 3.748e-05/0.1227, allocations: 8 kB / 444.6 MB, free: 14.32 MB / 334.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001117/0.1228, allocations: 16.03 kB / 444.6 MB, free: 14.3 MB / 334.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 5.354e-05/0.1229, allocations: 15.98 kB / 444.6 MB, free: 14.29 MB / 334.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 2.966e-05/0.1229, allocations: 11.94 kB / 444.7 MB, free: 14.27 MB / 334.1 MB Notification: Performance of sorting global known variables: time 7.744e-05/0.123, allocations: 106.4 kB / 444.8 MB, free: 14.17 MB / 334.1 MB Notification: Performance of sort global known variables: time 1.21e-07/0.123, allocations: 0 / 444.8 MB, free: 14.17 MB / 334.1 MB Notification: Performance of remove unused functions: time 0.0002986/0.1233, allocations: 48 kB / 444.8 MB, free: 14.12 MB / 334.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.000877/0.1242, allocations: 1.006 MB / 445.8 MB, free: 13.08 MB / 334.1 MB Notification: Performance of simCode: created initialization part: time 0.0003583/0.1246, allocations: 263.3 kB / 446.1 MB, free: 12.82 MB / 334.1 MB Notification: Performance of simCode: created event and clocks part: time 2.424e-06/0.1246, allocations: 0.5 kB / 446.1 MB, free: 12.82 MB / 334.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0001945/0.1248, allocations: 199.3 kB / 446.3 MB, free: 12.61 MB / 334.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002612/0.1251, allocations: 21.06 kB / 446.3 MB, free: 12.59 MB / 334.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.002586/0.1277, allocations: 2.395 MB / 448.7 MB, free: 10.05 MB / 334.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0002931/0.128, allocations: 0.7319 MB / 449.4 MB, free: 9.293 MB / 334.1 MB Notification: Performance of simCode: alias equations: time 6.135e-05/0.128, allocations: 13.55 kB / 449.4 MB, free: 9.281 MB / 334.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 8.251e-05/0.1281, allocations: 51.42 kB / 449.5 MB, free: 9.23 MB / 334.1 MB Notification: Performance of SimCode: time 4.2e-07/0.1281, allocations: 0 / 449.5 MB, free: 9.23 MB / 334.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.02497/0.1531, allocations: 3.59 MB / 453.1 MB, free: 5.754 MB / 334.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 7.634/7.788, allocations: 8.281 kB / 453.1 MB, free: 5.746 MB / 334.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)