diff options
author | Eugeniy Mikhailov <evgmik@gmail.com> | 2011-10-10 23:18:46 -0400 |
---|---|---|
committer | Eugeniy Mikhailov <evgmik@gmail.com> | 2011-10-10 23:18:46 -0400 |
commit | b7398c7c3adb979791504a5418a48b7064ecf3e6 (patch) | |
tree | 47bfff4f396f99e23ddadc1e00254ddecbd3d20d /xmds2/Nlevels_no_dopler_with_z_4wm | |
parent | cd86f365e3e55034755255d75071185656c8a08d (diff) | |
download | Nresonances-b7398c7c3adb979791504a5418a48b7064ecf3e6.tar.gz Nresonances-b7398c7c3adb979791504a5418a48b7064ecf3e6.zip |
Improved maximum detection
Diffstat (limited to 'xmds2/Nlevels_no_dopler_with_z_4wm')
-rw-r--r-- | xmds2/Nlevels_no_dopler_with_z_4wm/pp.m | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/xmds2/Nlevels_no_dopler_with_z_4wm/pp.m b/xmds2/Nlevels_no_dopler_with_z_4wm/pp.m index 186d822..760aa82 100644 --- a/xmds2/Nlevels_no_dopler_with_z_4wm/pp.m +++ b/xmds2/Nlevels_no_dopler_with_z_4wm/pp.m @@ -60,7 +60,9 @@ title('I_3 before and after cell') [b, a]=butter(3, 0.05); I2_out_after=I2_out_1(:,end); I2_out_after_filtered=filtfilt(b,a,I2_out_after); -[m,max_pos_before]=max(I2_out_1(:,1) ); [m,max_pos_after]=max(I2_out_after_filtered); +settling_time=0.8; %uS +t_good_indx=t_1> min(t_1 + settling_time); +[m,max_pos_before]=max(I2_out_1(t_good_indx,1) ); [m,max_pos_after]=max(I2_out_after_filtered(t_good_indx)); delay_time=t_1(max_pos_after)-t_1(max_pos_before); printf('Second field delay time = %f uS\n',delay_time); @@ -76,8 +78,6 @@ ylabel('I_3 (1/s)^2') title('I_3 before and after cell') figure(4) -settling_time=0.5; %uS -t_good_indx=t_1> min(t_1 + 0.5); I2_max_in=max(I2_out_1(t_good_indx,1)); I2_max_out=max(I2_out_1(t_good_indx,end)); I2_in_norm=(I2_out_1(:,1))/I2_max_in; |