issue with power calculation
3 ビュー (過去 30 日間)
古いコメントを表示
i have to calculate the voltage drop at maximum power in a transmission line. i have the code written for that and is correct. the the problem i am having is that e would like to increase the transmitted power. Consider increasing values of PR and add a fixed amount of injected reactive power (∆Q1) at the receiving end whenever the voltage VR is less than 10% of the nominal voltage. When this situation occurs, ∆Q1 is kept constant for all higher values of PR. ∆Q1 is determined as 20% of the value of PR when the voltage condition occurs. As this is an injected power, then QR=QLoad−∆Q1. If for higher values of PR, the voltage VR once again falls below 10% of the nominal voltage, another fixed amount of reactive power ∆Q2 must be added. now this should be able to be accomplished with a simple if statement yet mine is not giving the desired plot. anyone have any suggestions? here is the code.
if true
% code % This MATLAB routine calculates the voltage at the receiving end of a
% short-line, lossless, for a given power factor also at the receiving end.
% Data
Vs = 110/sqrt(3);
XL = 50;
pf = 0.95;
N = 1000;
% Calculating PRmax
a = XL/Vs^2;
phi = acos(pf);
b = tan(phi);
c = -Vs^2/(4*XL);
PRmax = (-b+sqrt(b^2-4*a*c))/(2*a);
VRcrit = sqrt(0.5*Vs^2-XL*PRmax*b); % Voltage VR at maximum power
% Delta power
DPR = PRmax/N;
% Initial power values
PR = 0;
QR = 0;
Power = [];
Voltage_U = [];
Voltage_L = [];
Delta = [];
% While condition
condition = 0;
% While loop
while condition==0
Vupper = sqrt( Vs^2/2-XL*QR+sqrt(Vs^4/4-XL*(QR*Vs^2+XL*PR^2)) );
Vlower = sqrt( Vs^2/2-XL*QR-sqrt(Vs^4/4-XL*(QR*Vs^2+XL*PR^2)) );
% Calculating angle delta (using the upper voltage)
delta = asin(XL*PR/(Vs*Vupper));
% Storing
Power = [Power; PR];
Voltage_U = [Voltage_U; Vupper];
Voltage_L = [Voltage_L; Vlower];
Delta = [Delta; delta];
% Setting new power values
PR = PR + DPR;
QR = tan(phi)*PR;
if (Vupper < (.9*Vs))
QR=QR+(.2*PR);
% Checking condition
if PR>PRmax
condition = 1;
end
end
end
% Plotting curves
figure(2);
hold on;grid on;
plot(Delta*180/pi,Power,'r','linewidth',1.5);
plot([0:180],Vs^2*sin([0:180]*pi/180)/XL,'k--');
ylabel('Power at the receiving end [MW]');
xlabel('\delta = \theta_S-\theta_R [degrees]');
figure(1);
hold on;grid on;
plot(Power,Voltage_U,'r',Power,Voltage_L,'r--','linewidth',1.5);
legend('V_{R,1}','V_{R,2}','Location','NorthOutside');
plot(PRmax*[1 1],[VRcrit 0],'k--');
plot(PRmax,VRcrit,'ko');
text(1.01*PRmax,1.05*VRcrit,'Maximum');
text(1.01*PRmax,0.95*VRcrit,'power');
ylabel('Voltage [kV]');
xlabel('Power at the receiving end [MW]');
end
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Sensors and Transducers についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!