# ruler giving wrong answers

**URL:** https://discourse.paraview.org/t/ruler-giving-wrong-answers/6907
**Category:** ParaView Support
**Created:** [April 8, 2021, 11:34pm UTC](https://discourse.paraview.org/t/ruler-giving-wrong-answers/6907 "2021-04-08T23:34:51Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![kuprat](https://discourse.paraview.org/user_avatar/discourse.paraview.org/kuprat/32/6394_2.png) [@kuprat](https://discourse.paraview.org/u/kuprat)
#### Post date: [April 8, 2021, 11:34pm UTC](https://discourse.paraview.org/t/ruler-giving-wrong-answers/6907/1 "2021-04-08T23:34:51Z")

</div>

![image](https://discourse.paraview.org/uploads/default/original/2X/e/e4a56309d687c2a52b4e0264450f01a656a261a4.png)  
This image shows ruler in paraview 5.6.0 64-bit on Windows 10 giving clearly wrong answers. The long line is listed as having a length one-third as long as the short line. There shouldn’t be any weird 3D effect, since these lines are drawn on a perfectly flat inlet surface.

---

<div class="post-metadata">

### Author: ![utkarsh.ayachit](https://discourse.paraview.org/user_avatar/discourse.paraview.org/utkarsh.ayachit/32/39_2.png) [@utkarsh.ayachit](https://discourse.paraview.org/u/utkarsh.ayachit)
#### Post date: [April 9, 2021, 12:32pm UTC](https://discourse.paraview.org/t/ruler-giving-wrong-answers/6907/2 "2021-04-09T12:32:06Z")

</div>

can you post the **Point1** and **Point2** values values for both the ruler sources please? That’s what I’d use to confirm if the distance shown is indeed correct.

---

<div class="post-metadata">

### Author: ![kuprat](https://discourse.paraview.org/user_avatar/discourse.paraview.org/kuprat/32/6394_2.png) [@kuprat](https://discourse.paraview.org/u/kuprat)
#### Post date: [April 9, 2021, 6:28pm UTC](https://discourse.paraview.org/t/ruler-giving-wrong-answers/6907/3 "2021-04-09T18:28:49Z")

</div>

Hi Utkarsh. Thanks for responding. I’ve verified that the point 1 and point 2 values are the stated distance apart. The problem is that the point selection mechanism (depressing the ‘p’ key to select points) does not select a point on the surface of the planar inlet surface. It ends up selecting a point probably deep inside the volume. The displayed line segment shows no evidence that it is penetrating into the volume to indicate that it is much longer than the desired line segment which should be on the surface. So I consider that a bug. However I have found that by placing the cursor on top of a surface grid point and forcing selection of the grid point using ‘ctrl p’ instead of just ‘p’ that indeed the surface grid point is chosen as ‘point 1’ or ‘point 2’ and then the distance calculation is accurate. So anyway the bug remains that simply using ‘p’ to select points on a surface really doesn’t select points on the surface and will give misleading values. Andrew

---

<div class="post-metadata">

### Author: ![wascott](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/w/8e8cbc/32.png) [@wascott](https://discourse.paraview.org/u/wascott)
#### Post date: [April 9, 2021, 11:00pm UTC](https://discourse.paraview.org/t/ruler-giving-wrong-answers/6907/4 "2021-04-09T23:00:41Z")

</div>

Andrew, could you post a dataset, and really detailed directions how you replicate this one? Thanks!

---

<div class="post-metadata">

### Author: ![kuprat](https://discourse.paraview.org/user_avatar/discourse.paraview.org/kuprat/32/6394_2.png) [@kuprat](https://discourse.paraview.org/u/kuprat)
#### Post date: [April 13, 2021, 10:30pm UTC](https://discourse.paraview.org/t/ruler-giving-wrong-answers/6907/5 "2021-04-13T22:30:40Z")

</div>

Walter, it was a CFD geometry from OpenFOAM with Lagrangian particles. FoamTOVTK in openfoam converted it from OpenFOAM output format to a VTK file. However, after reloading the geometry I am not able to replicate the error. I am getting good ruler lengths. If it happens again I’ll try to post it.
