How to find out the separation between to peaks of the azimuthally polarised beam at full width at half maximum?
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
hi, I have problem to find separation between two peaks at full width at half maximum, if you run following code you find figure(6) from that I have to find out separation between two peaks at full width at half maxumum
- clear all;
- clc;
- close all;
- [kx,ky]=meshgrid(-1:2/31:1,-1:2/31:1);
- c=sqrt(kx.^2+ky.^2)<1;
- N.A=0.5;
- alp=asin(N.A);
- k0=1/sin(alp);
- kz=sqrt(k0.^2-(kx.^2+ky.^2));
- GX=sqrt(k0./kz).*((k0*ky.^2+kz.*kx.^2)./(k0*(kx.^2+ky.^2)));
- GY=sqrt(k0./kz).*((kz-k0).*kx.*ky)./(k0*(kx.^2+ky.^2));
- GZ=-sqrt(k0./kz).*(kx/k0);
- ph=(pi+atan2(kx,ky));
- ph=rot90(ph,3).*c;
- la=-sin(ph).*c;
- lb=rot90(cos(ph).*c,3);
- k=1024;
- Ex=(la.*GX.*c+rot90(-lb.*GY.*c,3));
- FEx=fftshift(fft2(Ex,k,k));
- Ix=FEx.*conj(FEx);
- Ey=(la.*GY.*c+rot90(lb.*GX.*c,3));
- FEy=fftshift(fft2(Ey,k,k));
- Iy=FEy.*conj(FEy);
- Ez=(la.*GZ.*c+rot90(lb.*GZ.*c,3));
- FEz=fftshift(fft2(Ez,k,k));
- Iz=FEz.*conj(FEz);
- I=Ix+Iy;
- %figure(1)
- %imagesc(I),colormap gray;axis image; axis off;
- %figure(2)
- %plot(I(16,:))
- %figure(3)
- %imagesc(Iz),colormap gray;axis image; axis off;
- %figure(4)
- %plot(Iz(16,:))
- I1=Ix+Iy+Iz;
- I0=max(max(I1(k/2,:)));
- I1(k/2,:)=I1(k/2,:)/I0;
- a=max(max(I1(k/2,:)))
- %figure(5)
- %imagesc(I),colormap gray;axis image; axis off;
- figure(6)
- plot(I1(k/2,:))
- thanks in advanceabdul gaffar
1 Commento
Walter Roberson
il 13 Set 2012
It is easier on people if they can copy and paste your code without having to edit out the line numbers.
Risposte (0)
Vedere anche
Categorie
Scopri di più su Interactive Control and Callbacks in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!