Who can help me to solve and run this code to evaluate the perfomance of a wind turbine blade?

1 次查看(过去 30 天)
Good morning, I'm writing here because I know that there are errors in the syntax (in particular with matrix size) but I'm not able to solve them. The code is very easy: there is a for loop (i=1:10) where "i" is the radius of each section of my blade, another for loop (j) that for each "i" has to reach the convergence that I imposed with an If loop. I would be very happy if someone would help me figure out where I'm wrong because it is one of my first codes. I will attach the entire code and also the formula.Thanks!
r=[0.25,0.75,1.25,1.75,2.25,2.75,3.25,3.75,4.25,4.75];
tetap=[0.7529,0.4375,0.2763,0.1885,0.1351,0.0996,0.0744,0.0557,0.0412,0.0297];
c=[0.7966,0.9413,0.7385,0.5787,0.4691,0.3923,0.3362,0.2938,0.2606,0.2341];
lambda=7;
R=5;
B=3;
CL=0.0643*alfa + 0.5662;
%CD=(4*10^-5)*alpha^3 - 0.0004*alpha^2 +0.0018*alpha + 0.0042;
for i=1:1:10
a(1,1)=1/3;
a_primo(1,1)=0;
lambda_r(i) = lambda*(r(i)/R);
sigmaprimo(1)=(B*c(i))/(2*pi*r(i));
for j=1:1:100
tan (fi(i,j))=(1-a(i,j))./((1+(a_primo(i,j))).*lambda_r(i));
fi(i,j)=atan(tan(fi(i,j)));
F(i,j)=(2/pi)*acos(exp(-(((B/2)*(1-(r(i)/R)))/(r(i)/R)*sin(fi(i,j)))));
alpha(i,j)=fi(i,j)-tetap(i);
a(i,j+1)=1/(1+((4*F(i,j)*(sin(fi(i,j)))^2))/(sigmaprimo(i)*CL(i,j)*cos(fi(i,j))));
a_primo(i,j+1)=1/(((4*F(i,j)*cos(fi(i,j)))/(sigmaprimo(i)*CL(i,j)))-1);
if a(i,j+1)-a(i,j)<0.00001 && a_primo(i,j+1)-(a_primo(i,j))<0.00001;
break
end
end
end

回答(1 个)

Walter Roberson
Walter Roberson 2015-12-2
             tanfi(i,j) = (1-a(i,j)) ./ ((1 + (a_primo(i,j))).*lambda_r(i));
             fi(i,j) = atan(tanfi(i,j));

类别

Help CenterFile Exchange 中查找有关 Wind Power 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by