n=size(G,2);
m=size(N,2);

% Pick any of the original constraint equations to "leave out" and reinsert
% after having computed the LDL for the rest of the matrix.
k1=2000;
k2=2009;

N1=N(:,1:k1-1);
N2=N(:,k2+1:m);
Nm=[N1 N2];
np=N(:,k1:k2);
KKTm=[G Nm;Nm' zeros(m-k2+k1-1)];

tic;[L,D,p]=ldl(KKTm,'vector');toc

np(n+m-k2+k1-1,k2-k1+1)=0;

tic;Linvnp=L\np;toc

B=[D Linvnp;Linvnp' zeros(k2-k1+1)];

tic;[Lnew,Dnew,pnew]=ldl(B,'vector');toc
