Issues in gnuplot: pm3d and dgrid3d

1 reply · 7K views · last reply
abonatto
Messages
13
Reaction score
0
Dear All,

I am using gnuplot to make plots from data files generated using a fortran program. Those data files are basically big lists of 3d coordinates, just like like (not my real data, just an example):

10.0 1.00 0.01
20.0 1.00 0.14
...

So, when I use splot, I generate plot 1 (attached), and it is ok. But, after that, when I use pm3d ("set pm3d") and dgrid3d ("set dgrid3d 64,64,1", for example), it plots plot 2 (attached), which is pretty different from B]plot 1[/B]: the surface generated is "sliced", and it is not a continuous and smooth surface that it should be.

I have tried to plot with higher values in dgrid3d (256,256,3 and others...), but the problem still happens).

I really would appreciate any help on this :-)

Alexandre
 
Attachments
  • 3D surface plot of red grid points rising to peaks near 0.0008 on the vertical axis, with a title reading smooth oscillation... and axes labelled 0 to 2.5e+06 and -50 to 50.
    plot 1.png
    33.4 KB · Views: 948
  • 3D surface plot rendered with a purple pm3d colour map over a grid, showing a jagged, stepped surface with spiky peaks, and the caption "slices... points are not making a continuous, smooth surface..."
    plot 2.png
    15.3 KB · Views: 1,020
Dear All,

Its me again! I have "solved" the problem, and I will post here what I did (I hope it helps someone someday :)

All I did was to divide the x-values (0 to 2.5e+06; look in plot 2 attached in the previous post) for 1e+06 (in gnuplot I changed column 1 for "($1/1000000)": please see in plot 3, attached in this post, that x-values now are between 0 and 2.5). Now I got a continuous and smooth surface, just as I was expecting to see (based on plot 1 grid of points). Would this be a bug with pm3d function in gnuplot?

Thanks to everybody who read this post!
 
Attachments
  • Gnuplot 3D surface plot with pm3d colouring from black through purple to yellow, colour bar 0 to 0.0007; the surface rises to a plateau at the left edge and drops at the right.
    Plot 3.png
    24.7 KB · Views: 1,076