本文介绍了2D插值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经开发了一个让我加载图像,然后进行一些角测量到它的小程序。下面是截图(有没有在这个截图加载的图像)。

I've developed a little program that let me load an image then make some angle measurements onto it. Here is a screenshot (there is no image loaded in this screenshot).

当所有的测量完成我有x,y和角度值的列表。我想要做的是插值他们产生某种图形。我想preFER直接实现这个功能,而不是依赖于任何其他库(只要有可能,而不是复杂的)。

When all the measurements are done I have a list of x, y and angle values. What I'd like to do is interpolate them to generate some kind of graph.I would prefer to directly implement this functionality and not rely on any other library (as long as it's possible and not to complicated).

所以基本上我看到两个步骤,首先插入数据,第二,从它生成的图表。

So basically I see two steps, first interpolating the data, second, generating a graph from it.

起初我要实现一些双三次插值但这种插值需要进行一次定期的网格,我不能保证。

At first I was going to implement some bicubic interpolation but this kind of interpolation needs a regular grid, which I can't ensure.

有关的那一刻,我想我必须主要选项:

For the moment I think I have to main options:

  1. 将我的数据有规律的网格,然后做一个双三次插值。
  2. 找到一个其他种类的内插,不需要常规的网格。

您觉得有什么办法做我应该去和你有什么想法这网重新定义/插值我应该使用?我没有在这两种方法中的任何意见,但我认为这是要带我大量的时间,我不希望实现我在一个死胡同的尽头。

What way do you think I should go and do you have any idea of which grid-redefining/interpolation I should use? I don't have any opinion on both methods but I think this is going to take me a lot of time and I wouldn't like to realize in the end that I am in a dead-end.

如果这是任何意义我正在使用Qt和Windows的。

If this is of any relevance I'm working with Qt and on windows.

编辑:基本上,我想这样的事情到底:

Basically I want something like that in the end:

推荐答案

您正在寻找的是一个二维最小二乘法拟合函数,并产生热图或三维表面。

What you are looking for is a 2D Least squares fitting function, and generating a heat map or a 3D surface.

QWT是好的库,可以帮助绘制图形,但它是可行的,没有它。

QWT is nice library that can help with graphing it, but it is doable without it.

谷歌最小二乘2D计算

这篇关于2D插值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-15 02:23