source: ETALON/THZ_filters/2017_THz_FILTER/OverlapCorrections.m @ 733

Last change on this file since 733 was 733, checked in by hodnevuc, 7 years ago
File size: 1.1 KB
Line 
1clear all; close all; clc
2phi=-10:0.1:10;%azimutal angle deg
3 dthet=-10:0.1:10;%polar angle deg, (shift from optic axis of the mirror)
4FWHM=[];
5
6lefts=[];
7rights=[];
8shift=3
9 for Thet=((48:7:125)+shift)
10
11
12
13for c=1:length(dthet)
14Lamb=6*(1-cos((Thet+dthet(c))/180*pi));
15R=Lamb/2;%focal spot (Abbe diffraction limit)
16r=1;%detector radius
17d=50.8*sqrt(tan(phi/180*pi).^2+tan(dthet(c)/180*pi).^2);
18A=@(x,y)x^2*acos(y./x)-y.*sqrt(x^2-y.^2);
19d1=(d.^2-r^2+R^2)./(2*d);
20d2=d-d1;
21Cs=A(R,d1)+A(r,d2);%sum of two lengthes
22
23Map(c,:)=real(Cs);
24end
25figure
26contourf(dthet,phi,Map')
27xlabel('\Theta')
28ylabel('\phi')
29title(num2str(Thet))
30 FWHM=[FWHM,length(Map(101,(Map(101,:)>0.5*max(max(Map)))))*0.1];
31lefts=[lefts,find(Map(101,:)>0.5*max(max(Map)),1)];
32tmp=find(Map(101,:)>0.5*max(max(Map)));
33rights=[rights,tmp(end)];
34
35%  save(['map' num2str(Thet) '.mat'],'Map')
36 end
37 FWHM2=(rights-lefts+1)*0.1;
38R= (rights*0.1+((48:7:125)+shift)-10);
39L= (lefts*0.1+((48:7:125)+shift)-10);
40
41FreqR=3e+8./(6e-3*(1-cos(R/180*pi)));
42FreqL=3e+8./(6e-3*(1-cos(L/180*pi)));
43
44
45
46save freqp3.mat FreqR FreqL
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
Note: See TracBrowser for help on using the repository browser.