intpteff - ds=A*dy dx=-x(x/s*ds if min(x< 0 | min(s< 0...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
function [dx,dy,ds]=intpteff(A,b,c,x,y,s) % Finds a affine scaling search direction for LP in SEF % Input: % A,b,c data for LP problem max c'x s.t. Ax=b, x>=0 % x,y,s current (int) feasible primal-dual pair, x>0, s>0 % [m,n]=size(A); %M=[ % zeros(n) A' -eye(n) % A zeros(m) zeros(m,n) % diag(s) zeros(n,m) diag(x) % ]; dy=-(A*diag(x./s)*A')\b;
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ds=A'*dy; dx=-x-(x./s).*ds; if min(x) < 0 | min(s) < 0 | norm(A*x-b)> 100*eps | norm(A'*y-s-c)> 100*eps, disp('WARNING: x,y not feasible or not a strictly feasible point') end %RHS=[-(A'*y-s-c) ; -(A*x-b);-x.*s]; %RHS=[zeros(n,1) ; zeros(m,1);-x.*s]; %sol=M\RHS; %dx=sol(1:n);dy=sol(n+1:n+m);ds=sol(n+m+1:end);...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online