1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
| n=2;%bessel fonction oredr n
m=1;%mth root
l=0;
alpha=find_pth_bessel_root(n,m)
Nt=400; %nb of point
Nl=400; %nb of point
R=0.15;%diameter
L=0.1%cylinder length
[theta,z]=meshgrid(linspace(0,2*pi,Nt),linspace(0,L,Nl));
rho=R*ones(size(theta));
p=cos(l*pi*z/L).*besselj(n,alpha*rho/R).*cos(n*theta);
[x,y,z]=pol2cart(theta,rho,z);
figure(2)
surf(x,y,z,p,'edgecolor','none');
colormap jet;
hold on
patch(x(1,:),y(1,:),z(1,:),p(1,:));
patch(x(end,:),y(end,:),z(end,:),p(end,:)); |
Partager