pes2014/func_deltF.m

11 lines
286 B
Mathematica
Raw Normal View History

2013-04-04 22:50:20 +08:00
function deltF=func_deltF(Volt,PG,QG,PVi,PGi,wPG,wQG,wPD,wQD,wVolt,PG0,QG0,PD0,PD,QD,QD0,Volt0,Busnum,Loadi)
t3=2*wPD.*(PD(Loadi)-PD0(Loadi));
2012-11-16 22:47:06 +08:00
t4=2*wQD.*(QD(Loadi)-QD0(Loadi));
2013-04-04 22:50:20 +08:00
t5=2*wVolt.*(Volt-Volt0);
2013-01-21 22:52:03 +08:00
deltF=[sparse(t3);
2012-11-16 22:47:06 +08:00
sparse(t4);
2013-04-04 22:50:20 +08:00
sparse(t5');
sparse(1*Busnum,1);
2012-05-22 11:33:21 +08:00
];
end