We present a method for fitting monotone curves using cubic B-splines, which is equivalent to putting a monotonicity constraint on the coefficients. We explore different ways of enforcing this constraint and analyze their theoretical and empirical properties. We propose two algorithms for solving the spline fitting problem: one that uses standard optimization techniques and one that trains a Multi-Layer Perceptrons (MLP) generator to approximate the solutions under various settings and perturbations. The generator approach can speed up the fitting process when we need to solve the problem repeatedly, such as when constructing confidence bands using bootstrap. We evaluate our method against several existing methods, some of which do not use the monotonicity constraint, on some monotone curves with varying noise levels. We demonstrate that our method outperforms the other methods, especially in high-noise scenarios. We also apply our method to analyze the polarization-hole phenomenon during star formation in astrophysics. The source code is accessible at \texttt{\url{https://github.com/szcf-weiya/MonotoneSplines.jl}}.
翻译:我们提出了一种使用三次B样条拟合单调曲线的方法,该方法等价于对样条系数施加单调性约束。我们探讨了实施该约束的不同方式,并分析了其理论与经验性质。我们提出了两种求解样条拟合问题的算法:一种使用标准优化技术,另一种训练多层感知器(MLP)生成器,以近似在各种设置和扰动下的解。当需要重复解决问题时(例如在通过自助法构建置信带时),生成器方法能加速拟合过程。我们在不同噪声水平的单调曲线上,将本方法与若干现有方法(其中部分方法未使用单调性约束)进行了比较。结果表明,本方法优于其他方法,尤其在噪声较大的场景下表现更为突出。我们还应用本方法分析了天体物理学中恒星形成过程中的极化空穴现象。源代码可在 \texttt{\url{https://github.com/szcf-weiya/MonotoneSplines.jl}} 获取。