其中算法将被要求做到这一点? [英] Which algorithm will be required to do this?

查看:128
本文介绍了其中算法将被要求做到这一点?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有这种形式的数据:

  • 对于x = 1,y是一个{1,4,6,7,9,18,16,19}
  • 对于x = 2,y是{1,5,7,4}
  • 一个
  • 对于x = 3,y是一个{2,6,4,8,2}
  • ...
  • 对于x = 100,y是一个{2,7,89,4,5}

只有在每一组中的一个值是正确的值,其余的是随机噪声。

Only one of the values in each set is the correct value, the rest is random noise.

我知道,正确的价值观描述了一个正弦函数,它的参数是未知的。我如何才能找到值的正确组合,从每个组? 我期待像货郎担组合优化算法

I know that the correct values describe a sinusoid function whose parameters are unknown. How can I find the correct combination of values, one from each set? i am looking something like "travelling salesman"combinatorial optimization algorithm

推荐答案

这取决于你所说的完全的意思,和你事先知道。如果您知道频率w和的正弦曲线是无偏的,你有一个公式

It depends on what you mean by "exactly", and what you know beforehand. If you know the frequency w, and that the sinusoid is unbiased, you have an equation

一个COS(W * X)+ B罪(W * X)

a cos(w * x) + b sin(w * x)

有两个(X,Y)点在不同的x值,你可以找到A和B,然后检查生成的曲线对所有其他点。选择具有最小的数y观察的两个X值,并尝试它全部的Y的。如果有偏差,即你的方程是

with two (x,y) points at different x values you can find a and b, and then check the generated curve against all the other points. Choose the two x values with the smallest number of y observations and try it for all the y's. If there is a bias, i.e. your equation is

a cos(w * x) + b sin(w * x) + c

您需要看三个x值。

如果您不知道的频率,你可以尝试同样的技术,不幸的是,解决方案可能不是唯一的,有可能不止1瓦特适合。

If you do not know the frequency, you can try the same technique, unfortunately the solutions may not be unique, there may be more than one w that fits.

修改作为我理解你的问题,你对每个x一个真正的y值和一帮不正确的。你想找到真正的价值。要做到这一点,最好的办法就是通过少量的点,以适应曲线和检查,看看是否曲线拟合中的其他设置一些y值。

Edit As I understand your problem, you have a real y value for each x and a bunch of incorrect ones. You want to find the real values. The best way to do this is to fit curves through a small number of points and check to see if the curve fits some y value in the other sets.

如果不是所有的x值具有有效的y值那么相同的技术应用,但是你需要看一组对大得多,三倍或四倍(基本上每对,三重或不同的y值点,四)

If not all the x values have valid y values then the same technique applies, but you need to look at a much larger set of pairs, triples or quadruples (essentially every pair, triple, or quad of points with different y values)

如果你的问题是别的东西,我怀疑它,请指定它。

If your problem is something else, and I suspect it is, please specify it.

  1. 定义正弦曲线。大多数人认为这意味着表单 A COS(W * X)+ B罪(W * X)+ C 的功能。如果你的意思是不同的,指定它。
  1. Define sinusoid. Most people take that to mean a function of the form a cos(w * x) + b sin(w * x) + c. If you mean something different, specify it.

2指定正是成功的样子。举个例子说,10分,而不是100将是很好的。

2 Specify exactly what success looks like. An example with say 10 points instead of 100 would be nice.

这是非常清楚这是什么,是因为有组合优化。

It is extremely unclear what this has to do with combinatorial optimization.

这篇关于其中算法将被要求做到这一点?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆