I need an optimization solution for the above integer linear programming using matlab.

1 次查看(过去 30 天)
|Its an optimization problem of placing minimum no. of PMU in a network. If you place a PMU in node say 2, we say that nodes 1,3,6 & 7 also become observable along with 2 due to Kirchoff’s Voltage & Current laws. Then if you place a PMU in node 4, we say that nodes 5&7 also become observable along with 4. Hence placing only 2 PMUs i.e at 2 & 4 the whole 7 bus system becomes observable. Need a mat lab code for this kind of problem. Kindly help. Please find below the details of formulating the same.
F(x) = AX>=b
X=[x1,x2,x3,x4,x5,x6,x7] Transpose (7 X 1)
B=[1,1,1,1,1,1,1] Transpose(7 X 1)
A=(7 x 7) matrix = node incidence matrix
1 1 0 0 0 0 0 (Node 1 is connected to itself & node 2)
1 1 1 0 0 1 1
0 1 1 1 0 1 0
0 0 1 1 1 0 1
0 0 0 1 1 0 0
0 1 1 0 0 1 0
0 1 0 1 0 0 1
F1=x1+x2>=1
F2=x1+x2+x3+x6+x7 >=1
F3=x2+x3+x4+x6>=1
F4=x3+x4+x5+x7>=1
F5=x4+x5>=1
F6=x2+x3+x6>=1
F7=x2+x4+x7>=1
I need an optimization solution for the above integer linear programming using matlab. Need to find values of x1,x2, x3,x4,x5,x6,x7 such that it satisfies above equations. X1 to x7 can either be 0 or 1.
If x1 is zero its considered as no equipment is placed in node 1. If x1 is one its considered that equipment is placed in node 1.
If there are more solutions the same should be displayed. The optimal solution is to place the equipment in node 2 & node4 i.e x2=1 & x4=1 & others zero. But I do not how to solve it
Please send the matlab codes for the above.|

回答(1 个)

John D'Errico
John D'Errico 2014-9-21
编辑:John D'Errico 2014-9-21
This is silly. You have a simple problem, with variables that can take on only binary values, and only 7 variables. So there are 128 possible solutions, and ONLY that many.
So while you could use bintprog, it is trivial to evaluate all possible solutions using a matrix multiply, then just take the best option. Why use a Mack truck to take a pea to Boston?
x_possible = dec2bin(0:127)' - '0';

类别

Help CenterFile Exchange 中查找有关 Solver Outputs and Iterative Display 的更多信息

标签

产品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by