% mathieu_example.m
q= 10;
n= 2;
[q,n]= meshgrid(q,n);
x= linspace(-2*pi,2*pi,150);
position= 4;
figure(1), clf
[ce,lc]= cen(x,q,n);
[se,ls]= sen(x,q,n);
subplot(2,1,1)
plot(x,ce,'.','MarkerSize',12)
axis tight, title(['Even Mathieu Function, index n: ',...
num2str(n) , ' parameter q: ', num2str(q)])
legend(['eigenvalue: ',num2str(lc)], position);
line(x,ce)
subplot(2,1,2)
plot(x,se,'.','MarkerSize',12)
axis tight, title(['Odd Mathieu Function, index n: ',...
num2str(n) , ' parameter q: ', num2str(q)])
legend(['eigenvalue: ',num2str(lc)], position);
line(x,se)