加入了画电压分布的代码

Signed-off-by: facat <dugg@21cn.com>
This commit is contained in:
facat 2013-03-27 15:55:34 +08:00
parent 942120eb70
commit 0f95f9c04b
10 changed files with 79 additions and 7 deletions

3
OPF.m
View File

@ -7,7 +7,8 @@ clear
thesis=ForThesis(1,45);
for II=1:1
[kmax,Precision,UAngel,Volt,Busnum,PVi,PVu,Balance,Y,Angle,P0,Q0,r,c,GB,Linei,Linej,Transfori,Transforj,GenU,GenL,GenC,PG,QG,PD,QD,CenterA,PGi,PVQU,PVQL,Liner,Linex,Lineb,Transforr,Transforx,Branchi,Branchg,Branchb,Transfork0]= ...
pf('E:\\926_21671693_2012-09-06\newFIle4 - .txt');
pf('E://<EFBFBD>926_21671693_2012-09-06/newFIle20.txt');
% pf('E:\\<EFBFBD>926_21671693_2012-09-06\newFIle16.txt');
%pf('D:\Project\ÇàÐã½µËðÏîÄ¿\×îС»¯³±Á÷\×îС³±Á÷ËãÀý\ԭʼ\½òÍ·Õ¾½òÊÓ922£¨3-1£©_0.5_120%.txt');
%pf('D:\Project\×îС»¯³±Á÷\×îС³±Á÷ËãÀý\Ïɺ£919.txt');
%pf('c:/file31.txt');

View File

@ -20,9 +20,9 @@ wQG=0;
%randInt=randperm(size(Loadi,1));
%randPDind=randInt(1:10);
randPDind=0;
wPD=1/.05^2*zeros(size(Loadi,1),1);
wPD=1/.05^2*ones(size(Loadi,1),1);
wPD(1:2:end)=0;
wQD=1/.05^2*ones(size(Loadi,1),1);
wQD=1/.05^2*zeros(size(Loadi,1),1);
wQD(1:2:end)=0;
%wD(randPDind)=0;%一些负荷不约束
%wD(7)=0;

View File

@ -20,10 +20,10 @@ wQG=0;
%randInt=randperm(size(Loadi,1));
%randPDind=randInt(1:10);
randPDind=0;
wPD=1/.05^2*zeros(size(Loadi,1),1);
wPD(1:2:end)=0;
wQD=1/.05^2*zeros(size(Loadi,1),1);
wQD(1:2:end)=0;
wPD=1/.05^2*ones(size(Loadi,1),1);
% wPD(1:2:end)=0;
wQD=1/.05^2*ones(size(Loadi,1),1);
% wQD(1:2:end)=0;
%wD(randPDind)=0;%
%wD(7)=0;
% wD(11)=0;

BIN
case1V.mat Normal file

Binary file not shown.

BIN
case2V.mat Normal file

Binary file not shown.

BIN
case3V.mat Normal file

Binary file not shown.

BIN
caseM.mat Normal file

Binary file not shown.

BIN
caseR.mat Normal file

Binary file not shown.

26
plotVolt.asv Normal file
View File

@ -0,0 +1,26 @@
%% 画电压,为了写论文用
load('case1V.mat');
CV1=Volt;
load('case2V.mat');
CV2=Volt;
load('case3V.mat');
CV3=Volt;
load('caseR.mat');
CVR=Volt;
load('caseM.mat');
CVM=Volt;
subplot(3,2,1)
hist(CVR)
title('真实值')
subplot(2,2,3)
hist(CV1)
title('Case 1')
subplot(2,2,4)
hist(CV2)
title('Case 2')
subplot(2,2,5)
hist(CV3)
title('Case 3')

45
plotVolt.m Normal file
View File

@ -0,0 +1,45 @@
%%
load('case1V.mat');
CV1=Volt;
load('case2V.mat');
CV2=Volt;
load('case3V.mat');
CV3=Volt;
load('caseR.mat');
CVR=Volt;
load('caseM.mat');
CVM=Volt;
subplot(3,2,1)
hist(CVR)
title('')
subplot(3,2,2)
hist(CVM)
title('')
subplot(3,2,3)
hist(CV1)
title('Case 1')
subplot(3,2,4)
hist(CV2)
title('Case 2')
subplot(3,2,5)
hist(CV3)
title('Case 3')
% figure()
% hold on
%
% plot(CVR)
% title('')
%
% plot(CVM)
% title('')
%
% plot(CV1)
% title('Case 1')
%
% plot(CV2)
% title('Case 2')
%
% plot(CV3)
% title('Case 3')