[d2n-analysis-talk] Scintillator Calibrations: Comparision to Vince's Code
David Flay
flay at jlab.org
Fri Jun 4 16:30:41 EDT 2010
After working through my first method as described previously, I wanted to
compare it to that of Vince's code. This is how his code works:
1. Alignment of S2m Time Averages for Each Paddle: Vince's Code
The code plots the <difference> of average times of neighboring paddles
[that is, t = 0.5*(t_L + t_R)] vs. paddle number in the following way:
y-axis:
0.5*(L.s2.lt[L.s2.t_pads[0]]+L.s2.rt[L.s2.t_pads[0]]) -
0.5*(L.s2.lt[L.s2.t_pads[1]]+L.s2.rt[L.s2.t_pads[1]])
x-axis:
L.s2.t_pads[0] <-- Gives paddles that had a [coincident] L & R TDC.
This examines events for which multiple paddles have fired.
The [0] and [1] ensures that we are looking at events that
have a hit in the first paddle <and> a hit in the overlapping
paddle just behind it.
We then take the projection of this plot onto the y-axis,
and for each paddle, we grab the mean of this 1D histogram.
=> dt = mean of 1D histogram.
The new offset for paddle i [so that its time average will align with
paddle i-1] is:
off[i] = off[i-1] + dt.
The code then <chooses> the central paddle as the 'reference point.'
That is, we <subtract> the middle paddle offset from all offsets:
off[i] -= shift,
where 'shift' is the middle paddle's offset. The new time averages are
calculated as:
t_avg[i] = - off[i].
To determine what needs to go into the DB for the left and right PMTs,
we need the time difference between left and right PMTs:
t_diff = (t0_L - t0_R).
This is done by plotting the TDC time difference versus the position
along the scintillator paddles, L.s2.try, for each paddle. We then
take the projection of this plot onto the x-axis. The constant term from
the fit is the time difference offset for the paddle, while the linear
term from the fit is related to the speed of light through the paddle.
From here, the times for left and right PMTs are calculated as:
t_R = t_avg - 0.5*t_diff,
t_L = t_avg + 0.5*t_diff
This method isn't exactly perfect; therefore, there are 'tune' arrays
built into the code to make the average times line up better. These
values are done 'by hand.' The best way [I've found] is to plot the
time averages as 1D histograms, get the mean, and shift the peaks as
needed [instead of hard-coding these values into Vince's script] in the
DB.
If we then look at the plot of the time average for S2m vs. paddle
number, each paddle is in much closer agreement with one another (see
attached plot).
My main motivation of the comparison is to see what difference it makes
to use the relevant TDCs firing as a requirement of multiple paddles
firing, compared to the variable L.s2.t_pads[]. From a logical
perspective, I would think that either way <should> work, but maybe
Vince's use of this variable is more proper than my naive requirement
of L and R TDCs of the paddles of interest firing?
Dave
-------------------------------------------------
David Flay
Physics Department
Temple University
Philadelphia, PA 19122
office: Barton Hall, BA319
phone: (215) 204-1331
e-mail: flay at jlab.org
flay at temple.edu
website: http://www.jlab.org/~flay
http://quarks.temple.edu
-------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: beta_track_vince_20676_6_4_10.png
Type: image/png
Size: 47681 bytes
Desc: not available
Url : https://mailman.jlab.org/pipermail/d2n-analysis-talk/attachments/20100604/749588d8/attachment-0002.png
-------------- next part --------------
A non-text attachment was scrubbed...
Name: scint_toffs_vince_20676_6_4_10.png
Type: image/png
Size: 44520 bytes
Desc: not available
Url : https://mailman.jlab.org/pipermail/d2n-analysis-talk/attachments/20100604/749588d8/attachment-0003.png
More information about the d2n-analysis-talk
mailing list