how to get the actual value instead of 1x1 sym
3 次查看(过去 30 天)
显示 更早的评论
clc clear digits(4)
Ae = sym('Ae'); %?e cd = sym('cd');% CLw cl = sym('cl');%CL clt = sym('clt');%CLT clw = sym('clw'); %CLw ct = sym('ct');
ht=input('Enter the Altitude '); Temp=288.16+(lapse*ht); ro=1.225*((Temp/288.16)^(-((g/(lapse*R)+1)))); Vt=(st*lt)/(s*cw);%Tail volume n=input('enter the speed'); disp(' V Ae ct cd clt clw cl awi setae Ati nei Li Ti Di ldi') for v=n; %True airspeed range (knots) vi= v*0.515; %True airspeed (m/s)
eqn = [(((2*m*g)*sin(Ae+Ve)/(ro*s))/vi^2)-ct*cos(k)+cd*cos(Ae)-cl*sin(Ae)==0, ... %Total axial force (ox body axis) (((2*m*g)*cos(Ae+Ve)/(ro*s))/vi^2)-cl*cos(Ae)-cd*sin(Ae)-cd*sin(k)==0, ... %Total normal force (oz body axis) (cm0+((h-h0)*clw))-(Vt*clt)+ct*(ztw/cw)==0, ... %Pitching moment about cg cl-clw-(clt*st/s)==0, ... %Total lift coefficient cd-cd0-K*cl^2==0, ...%Total drag coefficient clw-a*(Ae+awr-aw0)==0 ];%Wing/body lift coefficient [Ae_,ct_,cd_,clt_,clw_,cl_] = vpasolve(eqn,Ae,ct,cd,clt,clw,cl);
awi=Ae_+awr;%Wing incidence
ldi=clw_/cd_; %Lift to drag ratio
setae=Ve+awi-awr;%Pitch attitude
Ati=(awi*(1-de))+nt-e0-awr;%Tail angle of attack
nei=(clt_/a2)-((a1/a2)*Ati);%Trim elevator angle
Li=0.5*ro*s*cl_*(vi^2);%Total lift force(N)
Ti=0.5*ro*s*ct_*(vi^2);% Total drag force(N)
Di=0.5*ro*s*cd_*(vi^2);% Total thrust (N)
disp([v', Ae_', ct_', cd_', clt_', clw_', cl_',awi',setae',Ati',nei',Li',Ti',Di',ldi'])
table(Ae_,ct_)
end
0 个评论
回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!