.net 有谁知道 MS Excel 求解器的更好替代方案?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/531026/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-03 11:13:15  来源:igfitidea点击:

Does anyone know a better alternative to MS Excel's Solver?

.netexcelopen-sourcesolver

提问by tundal45

My company has to crunch a lot of data and part of the process involves running the solver and plotting a graph through resulting data points. Obviously there is a lot of copy and paste involved and the whole process is shaky, error prone and all round cluster-fudge. I was wondering if there was an alternative to the solver that can be used so that even if we have to use excel to plot the final graph, there will be a lot less data that needs to be copied and pasted back and forth. It would be great especially if the tool could be easily integrated into a .NET application but I am open to suggestions that may require a little bit of code-fu to get this to work.

我的公司必须处理大量数据,部分过程涉及运行求解器并通过结果数据点绘制图形。显然,这涉及到大量的复​​制和粘贴,整个过程不稳定、容易出错且全面模糊。我想知道是否有可以使用求解器的替代方案,这样即使我们必须使用 excel 来绘制最终图形,需要来回复制和粘贴的数据也会少很多。如果该工具可以轻松集成到 .NET 应用程序中,那就太好了,但我愿意接受可能需要一点代码才能使其工作的建议。

Thanks!

谢谢!

回答by jason

The solver is essentially an iterative technique used to find roots of functions. Depending on the particular form of the function that you are trying to find a root of, you can roll your own or use existing implementations of the bisection method or Newton's method (or many other iterative root-finding techniques). If you post more about the specific problem that you are trying to solve, I might be able to point you to a more specific technique. Alternatively, you can read about root-findingand look at the Extreme Optimization library.

求解器本质上是一种用于寻找函数根的迭代技术。根据您尝试求根的函数的特定形式,您可以滚动自己的或使用二分法或牛顿法(或许多其他迭代求根技术)的现有实现。如果您发布更多有关您要解决的特定问题的信息,我可能会为您提供更具体的技术。或者,您可以阅读有关寻根的信息并查看极限优化

回答by Mark

Check out Microsoft Solver Foundation they provide .Net libraries to solve different kind of optimization problems http://code.msdn.microsoft.com/solverfoundation

查看 Microsoft Solver Foundation 他们提供的 .Net 库来解决不同类型的优化问题 http://code.msdn.microsoft.com/solverfoundation

You can integrate it into your code very easily

您可以非常轻松地将其集成到您的代码中

回答by Frederick The Fool

Netliboffers a comprehensive list of open-source solvers for various purposes. You may find some that you like.

Netlib提供了用于各种目的的开源求解器的完整列表。你可能会找到一些你喜欢的。

回答by Benjol

You might like to take a look at this, I haven't looked too closely.

你可能想看看这个,我没有仔细看。

Eureqais a software tool for detecting equations and hidden mathematical relationships in your data. Its primary goal is to identify the simplest mathematical formulas which could describe the underlying mechanisms that produced the data. Eureqa is free to download and use.

Eureqa是一种软件工具,用于检测数据中的方程和隐藏的数学关系。它的主要目标是确定可以描述产生数据的潜在机制的最简单的数学公式。Eureqa 可以免费下载和使用。

回答by user364130

You might be interested in the open source OpenSolver we have developed for Excel; it's available from http://www.opensolver.org. This uses the free COIN-OR CBC solver, and can solve linear and integer problems (but not non-linear models). It installs as an Excel add-in. It can solve much larger problems, and typically does so faster than Solver. Hope you find it useful.

您可能对我们为 Excel 开发的开源 OpenSolver 感兴趣;它可以从http://www.opensolver.org 获得。这使用免费的 COIN-OR CBC 求解器,可以解决线性和整数问题(但不是非线性模型)。它作为 Excel 加载项安装。它可以解决更大的问题,而且通常比 Solver 更快。希望你觉得它有用。

回答by Marcin

OpenOffice has a new nonlinear solver plugin which uses completely different methods of finding solutions to optimization problems than the steepest-descent methods used in Excel's solver.

OpenOffice 有一个新的非线性求解器插件,它使用与 Excel 求解器中使用的最速下降方法完全不同的方法来寻找优化问题的解决方案。

From your description it sounds like your data has a lot of outliers. For that you need some sort of robust fitting.

从您的描述来看,您的数据似乎有很多异常值。为此,您需要某种坚固的配件。

Matlab is the best program to do all these things, and it can be linked from .NET

Matlab 是完成所有这些事情的最佳程序,它可以从 .NET 链接

回答by kpatvt

I've automated the solver interface for different projects. Have you considered some-sort of VBA macro? This support article from MS goes through the whole VBA interface: http://support.microsoft.com/kb/843304. I'd assume it's accessible through .NET as well.

我已经为不同的项目自动化了求解器界面。你有没有考虑过某种 VBA 宏?MS 的这篇支持文章贯穿了整个 VBA 界面:http: //support.microsoft.com/kb/843304。我认为它也可以通过 .NET 访问。

回答by Sparr

gretl, the Gnu Regression Econometrics and Time-series Library, does the sort of things you need, and is highly efficient and well documented. I doubt there is a .NET API, but you can control it via scripting if necessary.

gretl,Gnu 回归计量经济学和时间序列库,可以完成您需要的事情,并且非常高效且有据可查。我怀疑是否有 .NET API,但如有必要,您可以通过脚本来控制它。

回答by Sparr

One of the MAJOR BUGS in the Solver/Excel VBA interface is not visible until you take your Excel Spreadsheet (which references the Solver Interface) to another machine.

Solver/Excel VBA 界面中的一个主要错误是不可见的,直到您将 Excel 电子表格(引用了求解器界面)带到另一台机器上。

There you will get an error that basically says that the Solver add-in is not loaded. You must go in to VBA and into Tools, References and re-establish the reference to the Solver library.

在那里你会得到一个错误,基本上说 Solver 加载项没有加载。您必须进入 VBA 并进入工具、参考并重新建立对求解器库的引用。

VERY ANNOYING.

很烦人。