Linear programming in complex numbers
2 次查看(过去 30 天)
显示 更早的评论
I wanted to solve a linear programming to find the minimum of a problem such as "minimize x such as f = Min {cx; Ax = b, x >= 0 }". When A, b, and c are the matrices or vectors whose elements are complex numbers, linprog function does not work.
Is there any way to solve a linear programming problems when all values are complex numbers?
0 个评论
回答(1 个)
Alan Weiss
2016-9-20
Generally, complex numbers are not well-ordered, meaning it is unclear what it means to say z1 > z2 when z1 and z2 are complex. So how can you minimize anything with complex numbers, and how can you set bounds or linear constraints?
If you can somehow make sense of things using real and imaginary parts of the problem, then reformulate it in purely real terms and go from there.
Good luck,
Alan Weiss
MATLAB mathematical toolbox documentation
2 个评论
Alan Weiss
2016-9-21
I am sorry, but you cannot compare complex numbers. If you read the doc for the MATLAB comparator, you see the following statement: A > B returns a logical array with elements set to logical 1 (true) where A is greater than B; otherwise, the element is logical 0 (false). The test compares only the real part of numeric arrays.
Once again, The test compares only the real part of numeric arrays.
To belabor the point, which is bigger, 1+i or -1+200i? The answer is clear: neither is bigger, they are not comparable. One has a bigger real part, one has a bigger imaginary part, one has a bigger magnitude, but the complex numbers are not ordered.
If you want to formulate a linear programming problem, you must do so using only real quantities.
Alan Weiss
MATLAB mathematical toolbox documentation
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!