用0.03的方差难以,或者无法收敛。

Signed-off-by: dmy@lab <dmy@lab.lab>
This commit is contained in:
dmy@lab
2015-03-19 21:17:30 +08:00
parent 2dd7ffb183
commit 5ad2614d3f
3 changed files with 11 additions and 8 deletions

View File

@@ -26,6 +26,8 @@ Y=this.Y;
VMatrix=sparse(r,c,SEVAngel(r)-SEVAngel(c)-Angel,busNum,busNum);
PD_=PG-diag(SEVolt)*(Y.*cos(VMatrix))*SEVolt;
QD_=QG-diag(SEVolt)*(Y.*spfun(@sin,VMatrix))*SEVolt;
% wPD=ones(length(wPD),1);
% wQD=ones(length(wPD),1);
t4=(wPD(PDi).*(PD_(PDi)-PD0(PDi))).^2;
t5=(wQD(QDi).*(QD_(QDi)-QD0(QDi))).^2;
% loadCurrent=LoadCurrent( SEVolt,SEVAngel,PD0(PDi),QD0(QDi),PDi,QDi );
@@ -34,7 +36,7 @@ t5=(wQD(QDi).*(QD_(QDi)-QD0(QDi))).^2;
% t7=(wLoadCurrent.*(loadCurrent-mLoadCurrent)).^2;
% t7=wLoadCurrent.*((loadCurrent-mLoadCurrent)./mLoadCurrent).^2;
% output_args=sum(t4)+sum(t5)+sum(t6);
output_args=sum(t6)+sum(t4)+sum(t5);
output_args=sum(t6)+sum(t5)+sum(t4);
output_args=full(output_args);