I’m experiencing a little issue here when plotting over line. When I try to visualise the attached data in 2D everything works well. But if I want to plot, say on the x=0 axis, some values don’t appear (wholes in the line) whereas they appear on the 2D visualisation.
Not at all. If you want to investigate the issue yourself, you will have to build ParaView in debug and run it with a debugger. Not an easy task unless you are a programmer.
The problem is that you are trying to plot right on the edge of your mesh, and numerical inaccuracies are causing points of the line to be outside of your mesh. (This is not a criticism of your data. Rather, this is just the nature of floating point numbers on a computer.)
Take a look at this captured screenshot. Here I have zoomed in the mesh at one of the places where the Plot Over Line is giving a NaN value. (It is the topmost point in the mesh and the rightmost point in the plot.) Then I have selected 3 mesh points around that location and I’m showing the numeric information for those 3 points in the superimposed Find Data dialog.
You can see that although the points with ids 387 and 713 have an x coordinate value of 0. However, the point with id 8 (which happens to be in the middle) has x coordinate value of -1.71663e-16. This is just slightly to the left of the line you are plotting on. The difference is imperceptible and I’m sure below any realistic significant digits. However, it means that when Plot Over Line intersects the line around those mesh cells, it computes it as just outside the boundary of the mesh, and thus assigns NaN values (which is the correct behavior).
The solution is simple. Move the line to the left by an epsilon amount so that it is always inside the mesh. I changed the x coordinate of both Point 1 and Point 2 to be -1e-15, and that seemed to work just fine as shown in this second screen capture.
Hi Kenneth ! Thanks for the help ! I was starting to imagine that the reason was something like that. I’ll find a solution for a better meshing.
I found that trick of moving an epsilon to the left but couldn’t figure why it worked: now I do!