简体   繁体   English

如何检查 LP 的解决方案是否唯一?

[英]How can I check if a solution of an LP is unique?

I want to check if my linear program has just one solution or infinite ones.我想检查我的线性程序是否只有一个解或无限解。 How can I do that using PuLP?我如何使用 PuLP 做到这一点?

In practice, there are virtually always multiple solutions because of numerical tolerances, that is, allowing small violations of primal and dual feasibility in the solutions.在实践中,由于数值容差,实际上总是有多个解决方案,也就是说,允许在解决方案中轻微违反原始和对偶可行性。

I suppose you are rather referring to multiple different optimal bases for your LP.我想您是在为您的 LP 指代多个不同的最佳基础。 This can be checked by testing for degeneracy: Check whether there are basic variables that are on one of their bounds (or tight basic constraints) and check whether there are non-basic variables with 0 reduced costs or dual multipliers.这可以通过退化测试来检查:检查是否有基本变量在它们的边界之一(或严格的基本约束)上,并检查是否有成本降低为 0 或双重乘数的非基本变量。

These checks can only be done if your LP solution is a basic solution in the first place, coming from a simplex-type optimization.仅当您的 LP 解决方案首先是基本解决方案(来自单纯形优化)时,才能进行这些检查。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM