Error in Plotting The Surface graph.
조회 수: 49 (최근 30일)
이전 댓글 표시
clc
clear all
close all
%% Aircraft Parameters
b= 222.6664; %ft
l=247.9163; % ft
S=6200; %ft^2
CR=45.4165; %ft
CT=15.332; %ft
AR=7.3;
TR=0.34;
lamda= 25; %degree
W=650000; %pound
mach=0.77;
sound_speed=967.52; %in feet/sec
density=5.87; % in slug/ft^3
cruise_weight=650000; %in pounds
%% Wake model
b_red=(3.14/4)*b;
velocity=mach*sound_speed;
Circulation=cruise_weight/(velocity*density*b_red);
y=-0.3*b:9:0.1*b;
z=-0.3*b:9:0.1*b;
[y,z]=meshgrid(y,z);
x=2*b +zeros(10,10);
rc=5;
% %%upwash_avg
syms s
chord_length=((2*S)/(b*(1+TR))*(1-(1-TR)*(2*s)/b));
right_wing=(Circulation/(4*3.14))*((y+s)./( (y+s).^2+ z.^2 + rc.^2)).*(1+(x./sqrt(x.^2+(y+s).^2+z.^2)))*chord_length;
left_wing=(Circulation/(4*3.14))*((y+b+s)./( (y+b+s).^2+ z.^2 + rc.^2)).*(1+(x./sqrt(x.^2+(y+b+s).^2+z.^2)));
I = (1/b)*((left_wing+right_wing)*chord_length);
qwe=int(I,s,0,b);
surf( y/b,z/b,qwe)
%%Error is Showing
Error using matlab.graphics.chart.primitive.Surface
Invalid parameter/value pair arguments.
Error in surf (line 145)
hh = matlab.graphics.chart.primitive.Surface(allargs{:});
Error in research_ff (line 38)
surf( y/b,z/b,qwe)
>>
댓글 수: 0
채택된 답변
Walter Roberson
2022년 4월 24일
qwe=int(I,s,0,b);
That is symbolic
surf( y/b,z/b,qwe)
surf cannot handle symbolic arguments, even if the symbols could be fully approximated as double.
You need to double(qwe) if it does not contain any free variables after integrating. If it contains free variables then fsurf()
댓글 수: 1
Walter Roberson
2022년 4월 25일
clc
clear all
close all
%% Aircraft Parameters
b= 222.6664; %ft
l=247.9163; % ft
S=6200; %ft^2
CR=45.4165; %ft
CT=15.332; %ft
AR=7.3;
TR=0.34;
lamda= 25; %degree
W=650000; %pound
mach=0.77;
sound_speed=967.52; %in feet/sec
density=5.87; % in slug/ft^3
cruise_weight=650000; %in pounds
%% Wake model
b_red=(3.14/4)*b;
velocity=mach*sound_speed;
Circulation=cruise_weight/(velocity*density*b_red);
y=-0.3*b:9:0.1*b;
z=-0.3*b:9:0.1*b;
[y,z]=meshgrid(y,z);
x=2*b +zeros(10,10);
rc=5;
% %%upwash_avg
syms s
chord_length=((2*S)/(b*(1+TR))*(1-(1-TR)*(2*s)/b));
right_wing=(Circulation/(4*3.14))*((y+s)./( (y+s).^2+ z.^2 + rc.^2)).*(1+(x./sqrt(x.^2+(y+s).^2+z.^2)))*chord_length;
left_wing=(Circulation/(4*3.14))*((y+b+s)./( (y+b+s).^2+ z.^2 + rc.^2)).*(1+(x./sqrt(x.^2+(y+b+s).^2+z.^2)));
I = (1/b)*((left_wing+right_wing)*chord_length);
qwe = vpaintegral(I, s, 0, b);
whos
surf( y/b, z/b, double(qwe))
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Particle & Nuclear Physics에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!