91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

資源簡介

matlab軟件通過COM接口與OPENDSS軟件的連接,可以在matlab中編程對PENDSS內的程序進行更改。以 IEEE-13節點系統潮流計算作為opendss與matlab交互編程的標準示例,可以幫助學習者更快的掌握opendss與matlab的交互。

資源截圖

代碼片段和文件信息

clear?all;
clc;
DSSObj?=?actxserver(‘OpenDSSEngine.DSS‘);
if?~DSSObj.Start(0)
disp(‘Unable?to?start?the?OpenDSS?Engine‘);
return
end
DSSText?=?DSSObj.Text;?%?Used?for?all?text?interfacing?from?matlab?to?opendss
DSSCircuit?=?DSSObj.ActiveCircuit;?%?active?circuit
DSSText.Command=‘Compile?(C:\Users\Admin\Desktop\SaturdayExample\ToUpload\MasterIEEE13.dss)‘;%?Path?where?Master?and?its?associated?files?are?stored.
DSSText.Command=‘batchedit?load..*?Vmin=0.8‘;?%?Set?Vmin?so?that?load?model?property?will?remain?same
DSSTransformers=DSSCircuit.Transformers;
%DSSText.Command=‘Batchedit?regcontrol..*?Enabled=no‘;?%?uncomment?for?tap?change?as?per?user‘s?choice
DSSText.Command=‘batchedit?load..*?daily=PQmult‘;?%?Loadshape
DSSText.Command=‘New?EnergyMeter.Main?Line.650632?1‘;%?Energy?meter
nt=24*1;
TimeArray=1:nt;
%%?Uncomment?following?for?Tap?chang?as?per?user?choice?(manually)
%?Xtap=[15 7 6 6 6 7 8 9 11 12 13 14 14 14 14 14 14 14 14 14 14 14 13 12
%?10 5 4 4 4 4 5 6 7 8 8 9 9 9 9 9 9 9 9 9 9 9 9 9
%?15 6 5 5 5 6 7 9 10 12 13 13 14 14 14 14 14 14 14 14 14 14 13 12?];
%?Reg1Tap=Xtap(1:)-5;
%?Reg2Tap=Xtap(2:)-5;
%?Reg3Tap=Xtap(3:)-5;
%?Vreg1=1+0.00625*Reg1Tap;
%?Vreg2=1+0.00625*Reg2Tap;
%?Vreg3=1+0.00625*Reg3Tap;
DSSText.Command=‘set?mode=daily?stepsize=1h?number=1‘;
DSSText.Command=‘set?hour=0‘;?%?Start?at?second?0?of?hour?5
for?i=1:nt
????DSSText.Command=‘get?hour‘;
????hour=DSSText.Result;
????%%?Uncomment?following?for?change?in?Tap?Positions?of?Regulator?as?per?user?choice
%?DSSText.command?=?[‘Transformer.Reg1.Tap=‘num2str(Vreg1(i))];
%?DSSText.command?=?[‘Transformer.Reg2.Tap=‘num2str(Vreg2(i))];
%?DSSText.command?=?[‘Transformer.Reg3.Tap=‘num2str(Vreg3(i))];
DSSText.Command=‘Solve‘;
SystemLosses(i:)=(DSSCircuit.Losses)/1000;?%?Will?Give?you?Distribution?System?Losses?in?kWs?and?kVArs
%%?Line?Losses
LineLosses(i:)=DSSCircuit.Linelosses;
%%?Transformer?Losses

TranLosses(i:)=SystemLosses(i:)-LineLosses(i:);

%%?Voltage?Magnitude?in?p.u.?for?24-hours?can?be?obtained?in?this?way
V1pu(i:)=DSSCircuit.AllNodeVmagPUByPhase(1);
V2pu(i:)=DSSCircuit.AllNodeVmagPUByPhase(2);
V3pu(i:)=DSSCircuit.AllNodeVmagPUByPhase(3);
DSSText.Command?=?‘??Transformer.Reg1.Taps‘;
Reg1=str2num(DSSText.Result);?
Vreg1S(i:)=Reg1(2);%?Secondary?winding?voltage?of?Reg1?in?24-hr
DSSText.Command?=?‘??Transformer.Reg2.Taps‘;
Reg2=str2num(DSSText.Result);
Vreg2S(i:)=Reg2(2);%?Secondary?winding?voltage?of?Reg2?in?24-hr
DSSText.Command?=?‘??Transformer.Reg3.Taps‘;
Reg3=str2num(DSSText.Result);?
Vreg3S(i:)=Reg3(2);%?Secondary?winding?voltage?of?Reg3?in?24-hr
DSSText.Command=‘Export?Meter‘;?%?A?MasterIEEE13_EXP_METERS.CSV?file?will?be?saved?in?same?path
end
EM=csvread(‘MasterIEEE13_EXP_METERS.CSV‘14);
SubkWh=EM(:1);
SubkVArh=EM(:2);
SubkW24=[SubkWh(TimeArray(1));?SubkWh(TimeArray(2):TimeArray(end))-SubkWh(TimeArray(1):TimeArray(nt-1))];
SubkVAr24=[SubkVArh(TimeArray(1));?SubkVArh(TimeArray(2):TimeArray(end)

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件??????152380??2018-04-26?09:36??DistributionPowerFlowusingOpenDSS.ppsx
?????目錄???????????0??2018-04-26?09:40??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\
?????文件?????????135??2016-07-15?19:11??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\Capacitors.txt
?????文件????????3435??2016-08-08?00:48??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\DailyLoadFlow.m
?????文件????????2572??2016-08-07?22:04??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\Lines.txt
?????文件????????1372??2016-08-07?21:51??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\Loads.txt
?????文件?????????402??2016-08-07?23:14??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\MasterIEEE13.dss
?????文件??????853693??2016-08-08?01:08??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\ReadMe.pdf
?????文件????????1399??2016-08-08?00:49??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\SnapLoadFlow.m
?????文件????????1397??2016-08-07?23:09??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\Transformers.txt
?????文件????????6781??2016-07-31?09:32??Matlab?code?for?Distribution?power?Flow?using?OpenDSS?Matlab??Interface\loadshapes.DSS

評論

共有 條評論