% plot the Bessel function J0

set(0,                           ...
   'defaultaxesfontsize', 20,   ...
   'defaultaxeslinewidth', 1.0, ...
   'defaultlinelinewidth', 1.2, ...
   'defaultpatchlinewidth', 0.7);
cmykflg=0;
%if cmykflg=1, this code will make cmyk figure files
%cmykflg = 1;

Lx = 25;
x = [0:.1:Lx];
nord = 0; % specify the order of the Bessel function
J = besselj(nord,x);  %the matlab function

figure(1)
plot(x,J,x,zeros(length(x),1),'--','linewidth',2);
axis([0,Lx -1,1]);
xlabel('r','fontsize',20)
ylabel('J_0(r)','fontsize',20)

if(cmykflg==1)
print('../../figs_c/chapt_5/J0','-deps','-cmyk')
 end