Plotting a sphere with pm3d works fine.
However, when I want to give an offset I get some artifact which I don't unterstand.
Any ideas why I get a "black hole" into my sphere when shifting the coordinates by adding some numbers?
Created with gnuplot 5.2.8
Code:
### plotting artifact with splot and pm3d
reset session
set view equal xyz
set view 45,45, 2
unset tics
unset colorbox
unset key
set margins 0,0,0,0
unset border
set style fill solid 1.0 noborder
set pm3d depthorder noborder
set pm3d lighting specular 0.5
# Create a sphere prototype dataset
set parametric
set isosamples 25
set samples 25
set urange [-pi/2:pi/2]
set vrange [0:2*pi]
Radius = 1
set table $Sphere
splot Radius*cos(u)*cos(v), Radius*cos(u)*sin(v), Radius*sin(u)
unset table
unset parametric
set palette defined (0 "#ff0000", 1 "#ff0000")
set view 153, 90
splot $Sphere u 1:2:3 w pm3d
pause -1 "Press OK to see the next plot"
splot $Sphere u ($1+1.0):($2+2.0):($3+3.0) w pm3d
### end of code
Result:
With offset:


$Spherecontains some extremely small numbers close to zero, like+1e-17or-1e-32. Maybe because of this, the last facettes will not be plotted if you add a (relatively) large number, which results in this "black hole". But I still cannot explain it, and don't know how to workaround it. - theozhepsilon=0.0001; set urange [epsilon - pi/2 : pi/2 - epsilon]- Ethan