what way do i remove the flow
8 ビュー (過去 30 日間)
古いコメントを表示
採用された回答
VBBV
2023 年 7 月 2 日
編集済み: VBBV
2023 年 7 月 2 日
syms alpha beta theta
U = 8; % Uniform flow velocity
z0 = 0.6; % Center of the cylinder
R = 2; % Radius of the cylinder
alpha = pi/10; % Angle of complex potential term
beta = pi/10; % Angle for additional term
xmin = -5;
xmax = 5;
ymin = -5;
ymax = 5;
npoints = 100;
tol = +2e-2; % geometric grid tolerance for flow visualization
sx = 0.5; % displacement of circle center in real axis. // velocity potential
sy = 0.1 ; % displacement of circle center in imaginary axis. // stream function
s = sx + i*sy; % resultant displacement in the z plane
[x, y] = meshgrid(linspace(xmin, xmax, npoints), linspace(ymin, ymax, npoints));
z = x + 1i*y;
% grid tolerance check for flow visualization
for p = 1:length(x)
for q = 1:length(y)
if abs(z(p,q)-s) <= R - tol
z(p,q) = NaN;
end
end
end
f = U*((z-z0).*exp(-1i*alpha) + R^2.*exp(1i*alpha)./(z-z0)) + 1i*2*R*U*sin(alpha+beta)*log(z-z0);
figure;
contourf(x, y, imag(f), 40);
hold on;
theta = linspace(0, 2*pi, 100);
xc = real(z0) + R * cos(linspace(0, 2*pi, 100))-0.1;
yc = imag(z0) + R * sin(linspace(0, 2*pi, 100))+0.1;
plot(xc, yc, 'k', 'LineWidth', 2);
axis equal;
2 件のコメント
VBBV
2023 年 7 月 2 日
編集済み: VBBV
2023 年 7 月 2 日
Add goemetric grid tolerance as shwon above, for the streamlines flow around the cylinder defined by the Jukouskwi aerodynamic potential function.
According to Jukouskwi method, apply also the offset displacement for the cylinder along the x and y directions along the real and imaginary axis which represent the velocity potential & streamline functions.
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Numerical Integration and Differential Equations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
