【问题标题】:Smoothing the boundary of graph - gnuplot平滑图的边界 - gnuplot
【发布时间】:2020-07-11 01:48:39
【问题描述】:

在 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 不是有效函数。那里缺少什么……?

标签: gnuplot smoothing


【解决方案1】:

我认为它应该是g(x,y) = x**2 - y**2。使用参数samplesisosamples。检查help sampleshelp isosamples

例如:

set samples 300
set isosamples 300

结果:

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2014-03-30
    • 1970-01-01
    • 1970-01-01
    • 2021-06-15
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-01-16
    相关资源
    最近更新 更多