【问题标题】:SciPy's interp1d endpointsSciPy 的 interp1d 端点
【发布时间】:2016-12-25 01:56:44
【问题描述】:

在 SciPy 的插值模块中有一个名为 interp1d 的函数。文档说它是样条插值:http://docs.scipy.org/doc/scipy/reference/generated/scipy.interpolate.interp1d.html 但是我无法找到端点上的边界条件。例如,在三次样条的情况下,应该指定端点处的导数(或二阶导数)。 interp1d 使用的值是什么?

【问题讨论】:

  • 默认情况下,interp1d 代码使用splmake 函数和kind=smoothest。这落在_find_smoothest 函数here 中。虽然这到底是什么计算,我不太确定。 :-) 看起来这与自然样条曲线不同,这是我的第一个猜测。

标签: python scipy interpolation cubic-spline


【解决方案1】:

CubicSpline 是 scipy 0.18 中的新功能,允许用户控制边界条件。 FITPACK 和 interp1d 都没有。

【讨论】:

    猜你喜欢
    • 2016-01-05
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-07-28
    • 2015-06-23
    • 1970-01-01
    相关资源
    最近更新 更多