使用Eigen求解密集的,受约束的最小二乘拟合 [英] Using Eigen to solve a dense, constrained least squares fit

查看:90
本文介绍了使用Eigen求解密集的,受约束的最小二乘拟合的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于大小为4的向量x,我需要解决形式为Ax = b的经典问题.A约为500个数据点,因此是一个密集的500x4矩阵.

I need to solve a classic problem of the form Ax = b for a vector x that is of size 4. A is on the order of ~500 data points and thus is a dense 500x4 matrix.

目前,我可以使用此处中所述的普通方程式来解决此问题,并且工作正常但是我想将x中的参数之一限制为永远不超过特定值.

Currently I can solve this using the normal equations described here and it works fine however I would like to constrain one of my parameters in x to never be above a certain value.

是否可以使用Eigen以编程方式执行此操作?

Is there a good way to do this programmatically with Eigen?

推荐答案

您可以尝试基于Eigen .您仍然必须形成法线方程.

You can try my quadradic programming solver based on Eigen there. You'll still have to form the normal equation.

这篇关于使用Eigen求解密集的,受约束的最小二乘拟合的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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