若奥·迈亚(Joao Maia)
在gnuplot中,给定f和g从平面到实线的两个函数,我将在g获得正值时绘制f。我有以下代码:
set xrange [-2:2]
set yrange [-2:2]
set isosamples 100,100
unset grid
unset key
set view map
f(x,y) = x*x*exp(-x*x)*y*y*exp(-y*y)
g(x,y) = x**2 - y**2
h(x,y) = g(x,y)> 0 ? f(x,y) : 1/0
splot h(x,y) with pm3d
我得到这个:
我想平滑此图像的边界。
提前致谢
西奥日
我认为应该阅读g(x,y) = x**2 - y**2
。播放参数samples
和isosamples
。检查help samples
和help isosamples
。
例如:
set samples 300
set isosamples 300
结果:
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
编辑于
我来说两句