function Mat_G=FormG(PD,QD,Loadi) Mat_G=[ sparse(PD(Loadi)); sparse(QD(Loadi)); ]; end