source: ETALON/CLIO/Analysis/PercentWarry.m @ 715

Last change on this file since 715 was 715, checked in by hodnevuc, 7 years ago
File size: 890 bytes
Line 
1close all; clear all; clc;
2load percent.mat
3
4load('GFW/SEY.mat')
5FF=Spectrum(3:11)./Integral(3:11)*1e-24;
6eFF=Err(3:11)./Integral(3:11)*1e-24;
7
8Freq=300./(6*(1-cos((62:7:118)/180*pi)));
9% figure
10% hold on
11% errorbar(Freq, FF/9,eFF/9)
12
13
14figure
15
16cd('./KK')
17for c=1:100
18   
19FF2=6*eFF.*rand(size(eFF))+FF-3*eFF;   
20[RSP,ISP]=SRf(flip(Freq),flip(FF2)/9);
21 PhaseH=-(imag(hilbert(log(abs(RSP)))));
22RPH=real((ifft(RSP.*exp(1i.*(PhaseH)))));
23[mx,ps]=max(RPH);
24
25RPH= [zeros(1,150-ps), RPH(1:end-(150-ps))];
26
27
28% plot(RSP,'-r')
29hold on
30plot((1:length(RPH))*1e-9/length(RPH)*1e+12,RPH,'Color',[0.8 0.8 0.8])
31RP(c,:)=RPH(:);
32 FWHM(c)=sum(RPH>max(RPH)/2)*1e-9/length(RPH)
33
34end
35plot((1:length(RPH))*1e-9/length(RPH)*1e+12,mean(RP),'k','linew',2)
36 set(gca,'fontsize',16)
37 xlabel('Time, [ps]')
38 title('Reconstructed profile')
39ylabel('Amplitude, [a.u.]')
40xlim([0, 50])
41grid on
42
43cd('..')
44mean(FWHM)
45std(FWHM)
Note: See TracBrowser for help on using the repository browser.