source: trunk/MagicSoft/TDAS-Extractor/Algorithms.tex@ 6654

Last change on this file since 6654 was 6653, checked in by gaug, 20 years ago
*** empty log message ***
File size: 48.3 KB
Line 
1\section{Signal Reconstruction Algorithms \label{sec:algorithms}}
2
3\subsection{Implementation of Signal Extractors in MARS}
4
5We performed all studies presented in this note using and developing the common MAGIC software framework
6MARS~\cite{MARS}.
7\par
8All signal extractor classes are stored in the MARS-directory {\textit{\bf msignal/}}.
9There, the base classes {\textit{\bf MExtractor}}, {\textit{\bf MExtractTime}}, {\textit{\bf MExtractTimeAndCharge}} and
10all individual extractors can be found. Figure~\ref{fig:extractorclasses} gives a sketch of the
11inheritances and tasks of each class.
12
13\begin{figure}[htp]
14\includegraphics[width=0.99\linewidth]{ExtractorClasses.eps}
15\caption{Sketch of the inheritances of three exemplary MARS signal extractor classes:
16MExtractFixedWindow, MExtractTimeFastSpline and MExtractTimeAndChargeDigitalFilter}
17\label{fig:extractorclasses}
18\end{figure}
19
20The following base classes for the extractor tasks are used:
21\begin{description}
22\item[MExtractor:\xspace] This class provides the basic data members, equal for all extractors, which are:
23 \begin{enumerate}
24 \item Global extraction ranges, defined by the variables
25 {\textit{\bf fHiGainFirst, fHiGainLast, fLoGainFirst, fLoGainLast}} and the function {\textit{\bf SetRange()}}.
26 The ranges always {\textit{\bf include}} the edge slices.
27 \item An internal variable {\textit{\bf fHiLoLast}} regulating the overlap of the desired high-gain
28 extraction range into the low-gain array.
29 \item The maximum possible FADC value, before the slice is declared as saturated, defined
30 by the variable {\textit{\bf fSaturationLimit}} (default:\,254).
31 \item The typical delay between high-gain and low-gain slices, expressed in FADC slices and parameterized
32 by the variable {\textit{\bf fOffsetLoGain}} (default:\,1.51)
33 \item Pointers to the storage containers {\textit{\bf MRawEvtData, MRawRunHeader, MPedestalCam}}
34 and~{\textit{\bf MExtractedSignalCam}}, defined by the variables
35 {\textit{\bf fRawEvt, fRunHeader, fPedestals}} and~{\textit{\bf fSignals}}.
36 \item Names of the storage containers to be searched for in the parameter list, parameterized
37 by the variables {\textit{\bf fNamePedestalCam}} and~{\textit{\bf fNameSignalCam}} (default: ``MPedestalCam''
38 and~''MExtractedSignalCam'').
39 \item The equivalent number of FADC samples, used for the calculation of the pedestal RMS and then the
40 number of photo-electrons with the F-Factor method (see eq.~\ref{eq:rmssubtraction} and
41 section~\ref{sec:photo-electrons}). This number is parameterized by the variables
42 {\textit{\bf fNumHiGainSamples}} and~{\textit{\bf fNumLoGainSamples}}.
43 \end{enumerate}
44
45 {\textit {\bf MExtractor}} is able to loop over all events, if the {\textit{\bf Process()}}-function is not overwritten.
46 It uses the following (virtual) functions, to be overwritten by the derived extractor class:
47
48 \begin{enumerate}
49 \item void {\textit {\bf FindSignalHiGain}}(Byte\_t* firstused, Byte\_t* logain, Float\_t\& sum, Byte\_t\& sat) const
50 \item void {\textit {\bf FindSignalLoGain}}(Byte\_t* firstused, Float\_t\& sum, Byte\_t\& sat) const
51 \end{enumerate}
52
53 where the pointers ``firstused'' point to the first used FADC slice declared by the extraction ranges,
54 the pointer ``logain'' points to the beginning of the ``low-gain'' FADC slices array (to be used for
55 pulses reaching into the low-gain array) and the variables ``sum'' and ``sat'' get filled with the
56 extracted signal and the number of saturating FADC slices, respectively.
57 \par
58 The pedestals get subtracted automatically {\textit {\bf after}} execution of these two functions.
59
60\item[MExtractTime:\xspace] This class provides - additionally to those already declared in {\textit{\bf MExtractor}} -
61 the basic data members, equal for all time extractors, which are:
62 \begin{enumerate}
63 \item Pointer to the storage container {\textit{\bf MArrivalTimeCam}}
64 parameterized by the variable
65 {\textit{\bf fArrTime}}.
66 \item The name of the ``MArrivalTimeCam''-container to be searched for in the parameter list,
67 parameterized by the variables {\textit{\bf fNameTimeCam}} (default: ``MArrivalTimeCam'' ).
68 \end{enumerate}
69
70 {\textit {\bf MExtractTime}} is able to loop over all events, if the {\textit{\bf Process()}}-function is not
71 overwritten.
72 It uses the following (virtual) functions, to be overwritten by the derived extractor class:
73
74 \begin{enumerate}
75 \item void {\textit {\bf FindTimeHiGain}}(Byte\_t* firstused, Float\_t\& time, Float\_t\& dtime, Byte\_t\& sat, const MPedestlPix \&ped) const
76 \item void {\textit {\bf FindTimeLoGain}}(Byte\_t* firstused, Float\_t\& time, Float\_t\& dtime, Byte\_t\& sat, const MPedestalPix \&ped) const
77 \end{enumerate}
78
79 where the pointers ``firstused'' point to the first used FADC slice declared by the extraction ranges,
80 and the variables ``time'', ``dtime'' and ``sat'' get filled with the
81 extracted arrival time, its error and the number of saturating FADC slices, respectively.
82 \par
83 The pedestals can be used for the arrival time extraction via the reference ``ped''.
84
85\item[MExtractTimeAndCharge:\xspace] This class provides - additionally to those already declared in
86 {\textit{\bf MExtractor}} and {\textit{\bf MExtractTime}} -
87 the basic data members, equal for all time and charge extractors, which are:
88 \begin{enumerate}
89 \item The actual extraction window sizes, parameterized by the variables
90 {\textit{\bf fWindowSizeHiGain}} and {\textit{\bf fWindowSizeLoGain}}.
91 \item The shift of the low-gain extraction range start w.r.t. to the found high-gain arrival
92 time, parameterized by the variable {\textit{\bf fLoGainStartShift}} (default: -2.8)
93 \end{enumerate}
94
95 {\textit {\bf MExtractTimeAndCharge}} is able to loop over all events, if the {\textit{\bf Process()}}-function is not
96 overwritten.
97 It uses the following (virtual) functions, to be overwritten by the derived extractor class:
98
99 \begin{enumerate}
100 \item void {\textit {\bf FindTimeAndChargeHiGain}}(Byte\_t* firstused, Byte\_t* logain, Float\_t\& sum, Float\_t\& dsum,
101 Float\_t\& time, Float\_t\& dtime, Byte\_t\& sat,
102 const MPedestlPix \&ped, const Bool\_t abflag) const
103 \item void {\textit {\bf FindTimeAndChargeLoGain}}(Byte\_t* firstused, Float\_t\& sum, Float\_t\& dsum,
104 Float\_t\& time, Float\_t\& dtime, Byte\_t\& sat,
105 const MPedestalPix \&ped, const Bool\_t abflag) const
106 \end{enumerate}
107
108 where the pointers ``firstused'' point to the first used FADC slice declared by the extraction ranges,
109 the pointer ``logain'' point to the beginning of the low-gain FADC slices array (to be used for
110 pulses reaching into the ``low-gain'' array),
111 the variables ``sum'', ``dsum'' get filled with the
112 extracted signal and its error. The variables ``time'', ``dtime'' and ``sat'' get filled with the
113 extracted arrival time, its error and the number of saturating FADC slices, respectively.
114 \par
115 The pedestals can be used for the extraction via the reference ``ped'', also the AB-flag is given
116 for AB-clock noise correction.
117\end{description}
118
119
120\subsection{Pure Signal Extractors}
121
122The pure signal extractors have in common that they reconstruct only the
123charge, but not the arrival time. All extractors treated here derive from the MARS-base
124class {\textit{\bf MExtractor}} which provides the following facilities:
125
126\begin{itemize}
127\item The global extraction limits can be set from outside
128\item FADC saturation is kept track of
129\end{itemize}
130
131The following adjustable parameters have to be set from outside:
132\begin{description}
133\item[Global extraction limits:\xspace] Limits in between which the extractor is allowed
134to extract the signal, for high gain and low gain, respectively.
135\end{description}
136
137As the pulses jitter by about one FADC slice,
138not every pulse lies exactly within the optimal limits, especially if one chooses small
139extraction windows.
140Moreover, the readout position with respect to the trigger position has changed a couple
141of times during last year, therefore a very careful adjustment of the extraction limits
142is mandatory before using these extractors.
143
144\subsubsection{Fixed Window}
145
146This extractor is implemented in the MARS-class {\textit{\bf MExtractFixedWindow}}.
147It simply adds the FADC slice contents in the assigned ranges.
148As it does not correct for the clock-noise, only an even number of samples is allowed.
149Figure~\ref{fig:fixedwindowsketch} gives a sketch of the extraction ranges used in this
150paper and for two typical calibration pulses.
151
152\begin{figure}[htp]
153 \includegraphics[width=0.49\linewidth]{MExtractFixedWindow_5Led_UV.eps}
154 \includegraphics[width=0.49\linewidth]{MExtractFixedWindow_23Led_Blue.eps}
155\caption[Sketch extraction ranges MExtractFixedWindow]{%
156Sketch of the extraction ranges for the extractor {\textit{\bf MExtractFixedWindow}}
157for two typical calibration pulses (pedestals have been subtracted) and a typical inner pixel.
158The pulse would be shifted half a slice to the right for an outer pixel. }
159\label{fig:fixedwindowsketch}
160\end{figure}
161
162
163\subsubsection{Fixed Window with Integrated Cubic Spline}
164
165This extractor is implemented in the MARS-class {\textit{\bf MExtractFixedWindowSpline}}. It
166uses a cubic spline algorithm, adapted from \cite{NUMREC} and integrates the
167spline interpolated FADC slice values from a fixed extraction range. The edge slices are counted as half.
168As it does not correct for the clock-noise, only an odd number of samples is allowed.
169Figure~\ref{fig:fixedwindowsplinesketch} gives a sketch of the extraction ranges used in this
170paper and for typical calibration pulses.
171
172\begin{figure}[htp]
173 \includegraphics[width=0.49\linewidth]{MExtractFixedWindowSpline_5Led_UV.eps}
174 \includegraphics[width=0.49\linewidth]{MExtractFixedWindowSpline_23Led_Blue.eps}
175\caption[Sketch extraction ranges MExtractFixedWindowSpline]{%
176Sketch of the extraction ranges for the extractor {\textit{\bf MExtractFixedWindowSpline}}
177for two typical calibration pulses (pedestals have been subtracted) and a typical inner pixel.
178The pulse would be shifted half a slice to the right for an outer pixel. }
179\label{fig:fixedwindowsplinesketch}
180\end{figure}
181
182\subsubsection{Fixed Window with Global Peak Search}
183
184This extractor is implemented in the MARS-class {\textit{\bf MExtractFixedWindowPeakSearch}}.
185The basic idea of this extractor is to correct for coherent movements in arrival time for all pixels,
186as e.g. caused by the trigger jitter.
187In a first loop over the pixels, it determined a reference point slices number defined by the highest sum of
188consecutive non-saturating FADC slices in a (smaller) peak-search window.
189\par
190In a second loop over the pixels,
191it adds the contents of the FADC slices starting from the reference point over an extraction window of a pre-defined window size.
192It loops twice over all pixels in every event, because it has to find the reference point, first.
193As it does not correct for the clock-noise, only extraction windows with an even number of samples are allowed.
194For a high intensity calibration run causing high-gain saturation in the whole camera, this
195extractor apparently fails since only dead pixels are taken into account in the peak search
196 which cannot produce a saturated signal.
197For this special case, we modified {\textit{\bf MExtractFixedWindowPeakSearch}}
198such to define the peak search window as the one starting from the mean position of the first saturating slice.
199\par
200The following adjustable parameters have to be set from outside:
201\begin{description}
202\item[Peak Search Window:\xspace] Defines the ``sliding window'' size within which the peaking sum is
203searched for (default: 4 slices)
204\item[Offset from Window:\xspace] Defines the offset of the start of the extraction window w.r.t. the
205starting point of the obtained peak search window (default: 1 slice)
206\item[Low-Gain Peak shift:\xspace] Defines the shift in the low-gain with respect to the peak found
207in the high-gain (default: 1 slice)
208\end{description}
209
210Figure~\ref{fig:fixedwindowpeaksearchsketch} gives a sketch of the possible peak-search and extraction
211window positions in two typical calibration pulses.
212
213\begin{figure}[htp]
214 \includegraphics[width=0.49\linewidth]{MExtractFixedWindowPeakSearch_5Led_UV.eps}
215 \includegraphics[width=0.49\linewidth]{MExtractFixedWindowPeakSearch_23Led_Blue.eps}
216\caption[Sketch extraction ranges MExtractFixedWindowPeakSearch]{%
217Sketch of the extraction ranges for the extractor {\textit{\bf MExtractFixedWindowPeakSearch}}
218for two typical calibration pulses (pedestals have been subtracted) and a typical inner pixel.
219The pulse would be shifted half a slice to the right for an outer pixel. }
220\label{fig:fixedwindowpeaksearchsketch}
221\end{figure}
222
223\subsection{Combined Extractors}
224
225The combined extractors have in common that for a given pulse, they reconstruct
226both the arrival time and
227the charge.
228All combined extractors described here derive from the MARS-base
229class {\textit{\bf MExtractTimeAndCharge}} which itself derives from MExtractor and MExtractTime.
230It provides the following facilities:
231
232\begin{itemize}
233\item Only one loop over all pixels is performed.
234\item The individual FADC slice values get the clock-noise-corrected pedestals immediately subtracted.
235\item The low-gain extraction range is adapted dynamically, based on the arrival time computed from the high-gain samples.
236\item Arrival times extracted from the low-gain samples get corrected for the intrinsic time delay of the low-gain
237 pulse.
238\item The global extraction limits can be set from outside.
239\item FADC saturation is kept track of.
240\end{itemize}
241
242The following adjustable parameters have to be set from outside, additionally to those declared in the
243base classes MExtractor and MExtractTime:
244
245\begin{description}
246\item[Global extraction limits:\xspace] Limits in between which the extractor is allowed
247to search. They are fixed by the extractor for the high-gain, but re-adjusted for
248every event in the low-gain, depending on the arrival time found in the low-gain.
249However, the dynamically adjusted window is not allowed to pass beyond the global
250limits.
251\item[Low-gain start shift:\xspace] Global shift between the computed high-gain arrival
252time and the start of the low-gain extraction limit (corrected for the intrinsic time offset).
253This variable tells where the extractor is allowed to start searching for the low-gain signal
254if the high-gain arrival time is known. It avoids that the extractor gets confused by possible high-gain
255signals leaking into the ``low-gain'' region (default: -2.8).
256\end{description}
257
258\subsubsection{Sliding Window with Amplitude-Weighted Time}
259
260This extractor is implemented in the MARS-class {\textit{\bf MExtractTimeAndChargeSlidingWindow}}.
261It extracts the signal from a sliding window of an adjustable size, for high-gain and low-gain
262individually (default: 6 and 6). The signal is the one which maximizes the summed
263(clock-noise and pedestal-corrected) consecutive FADC slice contents.
264\par
265The amplitude-weighted arrival time is calculated from the window with
266the highest FADC slice contents integral using the following formula:
267
268\begin{equation}
269 t = \frac{\sum_{i=i_0}^{i_0+\mathrm{\it ws}-1} s_i \cdot i}{\sum_{i=i_0}^{i_0+\mathrm{\it ws}-1} i}
270\end{equation}
271where $i$ denotes the FADC slice index, starting from slice $i_0$
272and running over a window of size $\mathrm{\it ws}$. $s_i$ the clock-noise and
273pedestal-corrected FADC slice contents at slice position $i$.
274\par
275The following adjustable parameters have to be set from outside:
276\begin{description}
277\item[Window sizes:\xspace] Independently for high-gain and low-gain (default: 6,6)
278\end{description}
279
280\begin{figure}[htp]
281 \includegraphics[width=0.49\linewidth]{MExtractTimeAndChargeSlidingWindow_5Led_UV.eps}
282 \includegraphics[width=0.49\linewidth]{MExtractTimeAndChargeSlidingWindow_23Led_Blue.eps}
283\caption[Sketch calculated arrival times MExtractTimeAndChargeSlidingWindow]{%
284Sketch of the calculated arrival times for the extractor {\textit{\bf MExtractTimeAndChargeSlidingWindow}}
285for two typical calibration pulses (pedestals have been subtracted) and a typical inner pixel.
286The extraction window sizes modify the position of the (amplitude-weighted) mean FADC-slices slightly.
287The pulse would be shifted half a slice to the right for an outer pixel. }
288\label{fig:slidingwindowsketch}
289\end{figure}
290
291\subsubsection{Cubic Spline with Sliding Window or Amplitude Extraction}
292
293This extractor is implemented in the MARS-class {\textit{\bf MExtractTimeAndChargeSpline}}.
294It interpolates the FADC contents using a cubic spline algorithm, adapted from \cite{NUMREC}.
295In a second step, it searches for the position of the spline maximum. From then on, two
296possibilities are offered:
297
298\begin{description}
299\item[Extraction Type Amplitude:\xspace] The amplitude of the spline maximum is taken as charge signal
300and the (precise) position of the maximum is returned as arrival time. This type is faster, since a spline integration is not performed.
301\item[Extraction Type Integral:\xspace] The integrated spline between maximum position minus
302rise time (default: 1.5 slices) and maximum position plus fall time (default: 4.5 slices)
303is taken as charge signal and the position of the half maximum left from the position of the maximum
304is returned as arrival time (default).
305The low-gain signal stretches the rise and fall time by a stretch factor (default: 1.5). This type
306is slower, but yields more precise results (see section~\ref{sec:performance}) .
307The charge integration resolution is set to 0.1 FADC slices.
308\end{description}
309
310The following adjustable parameters have to be set from outside:
311
312\begin{description}
313\item[Charge Extraction Type:\xspace] The amplitude of the spline maximum can be chosen while the position
314of the maximum is returned as arrival time. This type is fast. \\
315Otherwise, the integrated spline between maximum position minus rise time (default: 1.5 slices)
316and maximum position plus fall time (default: 4.5 slices) is taken as signal and the position of the
317half maximum is returned as arrival time (default).
318The low-gain signal stretches the rise and fall time by a stretch factor (default: 1.5). This type
319is slower, but more precise. The charge integration resolution is 0.1 FADC slices.
320\item[Rise Time and Fall Time:\xspace] Can be adjusted for the integration charge extraction type.
321\item[Resolution:\xspace] Defined as the maximum allowed difference between the calculated half maximum value and
322the computed spline value at the arrival time position. Can be adjusted for the half-maximum time extraction
323type.
324\item[Low Gain Stretch:\xspace] Can be adjusted to account for the larger rise and fall times in the
325low-gain as compared to the high gain pulses (default: 1.5)
326\end{description}
327
328\begin{figure}[htp]
329 \includegraphics[width=0.49\linewidth]{MExtractTimeAndChargeSpline_5Led_UV.eps}
330 \includegraphics[width=0.49\linewidth]{MExtractTimeAndChargeSpline_23Led_Blue.eps}
331\caption[Sketch calculated arrival times MExtractTimeAndChargeSpline]{%
332Sketch of the calculated arrival times for the extractor {\textit{\bf MExtractTimeAndChargeSpline}}
333for two typical calibration pulses (pedestals have been subtracted) and a typical inner pixel.
334The extraction window sizes modify the position of the (amplitude-weighted) mean FADC-slices slightly.
335The pulse would be shifted half a slice to the right for an outer pixel. }
336\label{fig:splinesketch}
337\end{figure}
338
339\subsubsection{Digital Filter}
340
341This extractor is implemented in the MARS-class {\textit{\bf MExtractTimeAndChargeDigitalFilter}}.
342
343
344The goal of the digital filtering method \cite{OF94,OF77} is to optimally reconstruct the amplitude and time origin of a signal with a known signal shape
345from discrete measurements of the signal. Thereby, the noise contribution to the amplitude reconstruction is minimized.
346
347For the digital filtering method, three assumptions have to be made:
348
349\begin{itemize}
350\item{The normalized signal shape has to be always constant, especially independent of the signal amplitude and in time.}
351\item{The noise properties have to be independent of the signal amplitude.}
352\item{The noise auto-correlation matrix does not change its form significantly with time and operation conditions.}
353\end{itemize}
354
355
356The pulse shape is mainly determined by the artificial pulse stretching by about 6\,ns on the receiver board.
357Thus the first assumption holds to a good approximation for all pulses with intrinsic signal widths much smaller than
358the shaping constant. Also the second assumption is fulfilled: Signal and noise are independent
359and the measured pulse is the linear superposition of the signal and noise. The validity of the third
360assumption is discussed below, especially for different night sky background conditions.
361
362Let $g(t)$ be the normalized signal shape, $E$ the signal amplitude and $\tau$ the time shift
363of the physical signal from the predicted signal shape. Then the time dependence of the signal, $y(t)$, is given by:
364
365\begin{equation}
366y(t)=E \cdot g(t-\tau) + b(t) \ ,
367\end{equation}
368
369where $b(t)$ is the time-dependent noise contribution. For small time shifts $\tau$ (usually smaller than
370one FADC slice width),
371the time dependence can be linearized by the use of a Taylor expansion:
372
373\begin{equation} \label{shape_taylor_approx}
374y(t)=E \cdot g(t) - E\tau \cdot \dot{g}(t) + b(t) \ ,
375\end{equation}
376
377where $\dot{g}(t)$ is the time derivative of the signal shape. Discrete
378measurements $y_i$ of the signal at times $t_i \ (i=1,...,n)$ have the form:
379
380\begin{equation}
381y_i=E \cdot g_i- E\tau \cdot \dot{g}_i +b_i \ .
382\end{equation}
383
384The correlation of the noise contributions at times $t_i$ and $t_j$ can be expressed in the
385noise autocorrelation matrix $\boldsymbol{B}$:
386
387\begin{equation}
388B_{ij} = \langle b_i b_j \rangle - \langle b_i \rangle \langle b_j
389\rangle \ .
390\label{eq:autocorr}
391\end{equation}
392%\equiv \langle b_i b_j \rangle with $\langle b_i \rangle = 0$.
393
394The signal amplitude $E$, and the product of amplitude and time shift $E \tau$, can be estimated from the given set of
395measurements $\boldsymbol{y} = (y_1, ... ,y_n)$ by minimizing the excess noise contribution with respect to the known noise
396auto-correlation:
397
398\begin{eqnarray}
399\chi^2(E, E\tau) &=& \sum_{i,j}(y_i-E g_i-E\tau \dot{g}_i) (\boldsymbol{B}^{-1})_{ij} (y_j - E g_j-E\tau \dot{g}_j) \\
400&=& (\boldsymbol{y} - E
401\boldsymbol{g} - E\tau \dot{\boldsymbol{g}})^T \boldsymbol{B}^{-1} (\boldsymbol{y} - E \boldsymbol{g}- E\tau \dot{\boldsymbol{g}}) \ ,
402\end{eqnarray}
403
404where the last expression is matricial.
405$\chi^2$ is a continuous function of $\tau$ and will have to be discretized itself for a
406desired resolution.
407$\chi^2$ is in principle independent of the noise level if alway the appropriate noise autocorrelation matrix is used. In our case however, we decided to use one matrix $\boldsymbol{B}$ for all levels of night-sky background. Changes in the noise level lead only to a multiplicative factor for all matrix elements and thus do not affect the position of the minimum of $\chi^2$.
408The minimum of $\chi^2$ is obtained for:
409
410\begin{equation}
411\frac{\partial \chi^2(E, E\tau)}{\partial E} = 0 \qquad \text{and} \qquad \frac{\partial \chi^2(E, E\tau)}{\partial(E\tau)} = 0 \ .
412\end{equation}
413
414
415Taking into account that $\boldsymbol{B}$ is a symmetric matrix, this leads to the following
416two equations for the estimated amplitude $\overline{E}$ and the estimation for the product of amplitude
417and time offset $\overline{E\tau}$:
418
419\begin{eqnarray}
4200&=&-\boldsymbol{g}^T\boldsymbol{B}^{-1}\boldsymbol{y}
421 +\boldsymbol{g}^T\boldsymbol{B}^{-1}\boldsymbol{g}\overline{E}
422 +\boldsymbol{g}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}\overline{E\tau}
423\\
4240&=&-\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\boldsymbol{y}
425 +\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\boldsymbol{g}\overline{E}
426 +\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}\overline{E\tau} \ .
427\end{eqnarray}
428
429Solving these equations one gets the following solutions:
430
431\begin{equation}
432\overline{E}(\tau) = \boldsymbol{w}_{\text{amp}}^T (\tau)\boldsymbol{y} \quad \mathrm{with} \quad
433 \boldsymbol{w}_{\text{amp}}
434 = \frac{ (\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}) \boldsymbol{B}^{-1} \boldsymbol{g} -(\boldsymbol{g}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}) \boldsymbol{B}^{-1} \dot{\boldsymbol{g}}}
435 {(\boldsymbol{g}^T \boldsymbol{B}^{-1} \boldsymbol{g})(\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}) -(\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\boldsymbol{g})^2 } \ ,
436\end{equation}
437
438\begin{equation}
439\overline{E\tau}(\tau)= \boldsymbol{w}_{\text{time}}^T(\tau) \boldsymbol{y} \quad
440 \mathrm{with} \quad \boldsymbol{w}_{\text{time}}
441 = \frac{ ({\boldsymbol{g}}^T\boldsymbol{B}^{-1}{\boldsymbol{g}}) \boldsymbol{B}^{-1} \dot{\boldsymbol{g}} -(\boldsymbol{g}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}) \boldsymbol{B}^{-1} {\boldsymbol{g}}}
442 {(\boldsymbol{g}^T \boldsymbol{B}^{-1} \boldsymbol{g})(\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}) -(\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\boldsymbol{g})^2 } \ .
443\end{equation}
444
445Thus $\overline{E}$ and $\overline{E\tau}$ are given by a weighted sum of the discrete measurements $y_i$
446with the digital filtering weights for the amplitude, $w_{\text{amp}}(\tau)$, and time shift, $w_{\text{time}}(\tau)$. The time dependency gets discretized once again leading to a set of weights samples which themselves depend on the
447discretized time $\tau$.
448\par
449Note the remaining time dependency of the two weights samples. This follows from the dependency of $\boldsymbol{g}$ and
450$\dot{\boldsymbol{g}}$ on the relative position of the signal pulse with respect to FADC slices positions.
451\par
452Because of the truncation of the Taylor series in equation (\ref{shape_taylor_approx}) the above results are
453only valid for vanishing time offsets $\tau$. For non-zero time offsets, one has to iterate the problem using
454the time shifted signal shape $g(t-\tau)$.
455
456The covariance matrix $\boldsymbol{V}$ of $\overline{E}$ and $\overline{E\tau}$ is given by:
457
458\begin{equation}
459\left(\boldsymbol{V}^{-1}\right)_{ij}
460 =\frac{1}{2}\left(\frac{\partial^2 \chi^2(E, E\tau)}{\partial \alpha_i \partial \alpha_j} \right) \quad
461 \text{with} \quad \alpha_i,\alpha_j \in \{E, E\tau\} \ .
462\end{equation}
463
464The expected contribution of the noise to the estimated amplitude, $\sigma_E$, is:
465
466\begin{equation}
467\sigma_E^2=\boldsymbol{V}_{E,E}
468 =\frac{\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}}
469 {(\boldsymbol{g}^T \boldsymbol{B}^{-1} \boldsymbol{g})(\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}) -(\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\boldsymbol{g})^2} \ .
470\label{eq:of_noise}
471\end{equation}
472
473The expected contribution of the noise to the estimated timing, $\sigma_{\tau}$, is:
474
475\begin{equation}
476E^2 \cdot \sigma_{\tau}^2=\boldsymbol{V}_{E\tau,E\tau}
477 =\frac{{\boldsymbol{g}}^T\boldsymbol{B}^{-1}{\boldsymbol{g}}}
478 {(\boldsymbol{g}^T \boldsymbol{B}^{-1} \boldsymbol{g})(\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\dot{\boldsymbol{g}}) -(\dot{\boldsymbol{g}}^T\boldsymbol{B}^{-1}\boldsymbol{g})^2} \ .
479\label{eq:of_noise_time}
480\end{equation}
481
482
483In the MAGIC MC simulations~\cite{MC-Camera}, an night-sky background rate of 0.13 photoelectrons per ns,
484an FADC gain of 7.8 FADC counts per photo-electron and an intrinsic FADC noise of 1.3 FADC counts
485per FADC slice is implemented.
486These numbers simulate the night sky background conditions for an extragalactic source and result
487in a noise contribution of about 4 FADC counts per single FADC slice:
488$\sqrt{B_{ii}} \approx 4$~FADC counts.
489Using the digital filter with weights parameterized over 6 FADC slices ($i=0...5$) the errors of the
490reconstructed signal and time amount to:
491
492\begin{equation}
493\sigma_E \approx 8.3 \ \mathrm{FADC\ counts} \ (\approx 1.1\,\mathrm{phe}) \qquad
494\sigma_{\tau} \approx \frac{6.5\ \Delta T_{\mathrm{FADC}}}{(E\ /\ \mathrm{FADC\ counts})} \ (\approx \frac{2.8\,\mathrm{ns}}{E\,/\ \mathrm{N_{phe}}})\ ,
495\label{eq:of_noise_calc}
496\end{equation}
497
498where $\Delta T_{\mathrm{FADC}} = 3.33$ ns is the sampling interval of the MAGIC FADCs.
499The error in the reconstructed signal corresponds to about one photo electron.
500For signals of the size of two photo electrons, the timing error is about 1.4\,ns.
501\par
502
503An IACT has typically two types of background noise:
504On the one hand, there is the constantly present electronics noise,
505while on the other hand, the light of the night sky introduces a sizeable background
506to the measurement of the Cherenkov photons from air showers.
507
508The electronics noise is largely white, i.e. uncorrelated in time.
509The noise from the night sky background photons is the superposition of the
510detector response to single photo electrons following a Poisson distribution in time.
511Figure \ref{fig:noise_autocorr_allpixels} shows the noise
512autocorrelation matrix for an open camera. The large noise autocorrelation of the current FADC
513system is due to the pulse shaping (with the shaping constant equivalent to about two FADC slices).
514
515In general, the amplitude and time weights, $\boldsymbol{w}_{\text{amp}}$ and $\boldsymbol{w}_{\text{time}}$,
516depend on the pulse shape, the derivative of the pulse shape and the noise autocorrelation.
517In the high gain samples, the correlated night sky background noise dominates over
518the white electronics noise. Thus, different noise levels cause the elements of the noise autocorrelation
519matrix to change by a same factor, which cancels out in the weights calculation. Figure~\ref{fig:noise_autocorr_allpixels}
520shows the noise autocorrelation matrix for two different levels of night sky background (top) and the ratio between the
521corresponding elements of both (bottom). The central regions of $\pm$3 FADC slices around the diagonal (which is used to
522calculate the weights) deviate by less than 10\%.
523Thus, the weights are to a reasonable approximation independent of the night sky background noise level in the high gain.
524\par
525In the low gain samples the correlated noise from the LONS is in the same order of magnitude as the white electronics and digitization noise.
526Moreover, the noise autocorrelation for the low gain samples cannot be determined directly from the data. The low gain is only switched on
527if the pulse exceeds a preset threshold. There are no pedestals in the low gain available. Thus the noise auto-correlation determined from
528MC simulations for an extragalactic background is also used to compute the weights for cosmics and calibration pulses.
529
530%\begin{figure}[h!]
531%\begin{center}
532%\includegraphics[totalheight=7cm]{noise_autocorr_AB_36038_TDAS.eps}
533%\end{center}
534%\caption[Noise autocorrelation one pixel.]{Noise autocorrelation
535%matrix $\boldsymbol{B}$ for open camera including the noise due to night sky background fluctuations
536%for one single pixel (obtained from 1000 events).}
537%\label{fig:noise_autocorr_1pix}
538%\end{figure}
539
540\begin{figure}[htp]
541\begin{center}
542\includegraphics[totalheight=7cm]{noise_38995_smallNSB_all396.eps}
543\includegraphics[totalheight=7cm]{noise_39258_largeNSB_all396.eps}
544\includegraphics[totalheight=7cm]{noise_small_over_large.eps}
545\end{center}
546\caption[Noise autocorrelation average all pixels.]{Noise autocorrelation
547matrix $\boldsymbol{B}$ for open camera and averaged over all pixels. The top figure shows $\boldsymbol{B}$
548obtained with camera pointing off the galactic plane (and low night sky background fluctuations).
549The central figure shows $\boldsymbol{B}$ with the camera pointing into the galactic plane
550(high night sky background) and the
551bottom plot shows the ratio between both. One can see that the entries of $\boldsymbol{B}$ do not
552simply scale with the amount of night sky background.}
553\label{fig:noise_autocorr_allpixels}
554\end{figure}
555
556Using the average reconstructed pulpo pulse shapes, as shown in figure \ref{fig:pulse_shapes}, and the reconstructed noise autocorrelation matrices from a pedestal runs with random triggers, the digital filter weights are computed. As the pulse shapes in the high and low gain and for cosmics, calibration and pulpo events are somewhat different, dedicated digital filter weights are computed for these event classes. Also filter weights optimized for MC simulations are calculated. High/low gain filter weights are computed for the following event classes:
557
558\begin{enumerate}
559\item{cosmics weights: for cosmics events}
560\item{calibration weights UV: for UV calibration pulses}
561\item{calibration weights blue: for blue and green calibration pulses}
562\item{MC weights: for MC simulations}
563\item{pulpo weights: for pulpo runs.}
564\end{enumerate}
565
566
567\begin{table}[h]{\normalsize\center
568\begin{tabular}{lllll}
569 \hline
570 & high gain shape & high gain noise & low gain shape & low gain noise
571\\ cosmics & 25945 (pulpo) & 38995 (extragal.) & 44461 (pulpo) & MC low
572\\ UV & 36040 (UV) & 38995 (extragal.) & 44461 (pulpo) & MC low
573\\ blue & 31762 (blue) & 38995 (extragal.) & 31742 (blue) & MC low
574\\ MC & MC & MC high & MC & MC low
575\\ pulpo & 25945 (pulpo) & 38993 (no LONS) & 44461 (pulpo) & MC low
576\\
577\hline
578\end{tabular}
579\caption{The used runs for the pulse shapes and noise auto-correlations for the digital filter weights of the different event types.}\label{table:weight_files}}
580\end{table}
581
582
583
584
585 Figures \ref{fig:w_time_MC_input_TDAS} and \ref{fig:w_amp_MC_input_TDAS} show the amplitude and timing weights for the MC pulse shape. The first weight $w_{\mathrm{amp/time}}(t_0)$ is plotted as a function of the relative time $t_{\text{rel}}$ the trigger and the
586FADC clock in the range $[-0.5,0.5[ \ T_{\text{ADC}}$, the second weight in the range $[0.5,1.5[ \ T_{\text{ADC}}$ and so on. A binning resolution
587of $0.1\,T_{\text{ADC}}$ has been chosen.
588
589
590\begin{figure}[h!]
591\begin{center}
592\includegraphics[totalheight=7cm]{w_time_MC_input_TDAS.eps}
593\end{center}
594\caption[Time weights.]{Time weights $w_{\mathrm{time}}(t_0) \ldots w_{\mathrm{time}}(t_5)$ for a window size of 6 FADC slices for the pulse shape
595used in the MC simulations. The first weight $w_{\mathrm{time}}(t_0)$ is plotted as a function of the relative time $t_{\text{rel}}$ the trigger and the
596FADC clock in the range $[-0.5,0.5[ \ T_{\text{ADC}}$, the second weight in the range $[0.5,1.5[ \ T_{\text{ADC}}$ and so on. A binning resolution
597of $0.1\,T_{\text{ADC}}$ has been chosen.} \label{fig:w_time_MC_input_TDAS}
598\end{figure}
599
600\begin{figure}[h!]
601\begin{center}
602\includegraphics[totalheight=7cm]{w_amp_MC_input_TDAS.eps}
603\end{center}
604\caption[Amplitude weights.]{Amplitude weights $w_{\mathrm{amp}}(t_0) \ldots w_{\mathrm{amp}}(t_5)$ for a window size of 6 FADC slices for the
605pulse shape used in the MC simulations. The first weight $w_{\mathrm{amp}}(t_0)$ is plotted as a function of the relative time $t_{\text{rel}}$
606the trigger and the FADC clock in the range $[-0.5,0.5[ \ T_{\text{ADC}}$, the second weight in the range $[0.5,1.5[ \ T_{\text{ADC}}$ and so on.
607A binning resolution of $0.1\, T_{\text{ADC}}$ has been chosen.} \label{fig:w_amp_MC_input_TDAS}
608\end{figure}
609
610In the current implementation a two step procedure is applied to reconstruct the signal. The weight functions $w_{\mathrm{amp}}(t)$
611and $w_{\mathrm{time}}(t)$ are computed numerically with a resolution of $1/10$ of an FADC slice.
612In the first step the quantities $e_{i_0}$ and $e\tau_{i_0}$ are computed using a window of $n$ slices:
613
614\begin{equation}
615e_{i_0}=\sum_{i=i_0}^{i_0+n-1} w_{\mathrm{amp}}(t_i)y(t_{i+i_0}) \qquad (e\tau)_{i_0}=\sum_{i=i_0}^{i_0+n-1} w_{\mathrm{time}}(t_i)y(t_{i+i_0})
616\end{equation}
617
618for all possible signal start slices $i_0$. Let $i_0^*$ be the signal start slice with the largest $e_{i_0}$.
619Then in a second step the timing offset $\tau$ is calculated:
620
621\begin{equation}
622\tau=\frac{(e\tau)_{i_0^*}}{e_{i_0^*}}
623\label{eq:offsettau}
624\end{equation}
625
626and the weights iterated:
627
628\begin{equation}
629E=\sum_{i=i_0^*}^{i_0^*+n-1} w_{\mathrm{amp}}(t_i - \tau)y(t_{i+i_0^*}) \qquad
630 E \theta=\sum_{i=i_0^*}^{i_0^*+n-1} w_{\mathrm{time}}(t_i - \tau)y(t_{i+i_0^*}) \ .
631\end{equation}
632
633The reconstructed signal is then taken to be $E$ and the reconstructed arrival time $t_{\text{arrival}}$ is
634
635\begin{equation}
636t_{\text{arrival}} = i_0^* + \tau + \theta \ .
637\end{equation}
638
639
640
641Figure \ref{fig:amp_sliding} shows the result of the applied amplitude and time weights to the recorded FADC time slices of one simulated MC pulse. The left plot shows the result of the applied amplitude weights
642$e(t_0)=\sum_{i=0}^{i=n-1} w_{\mathrm{amp}}(t_0+i \cdot T_{\text{ADC}})y(t_0+i \cdot T_{\text{ADC}})$ and
643the right plot shows the result of the applied timing weights
644$e\tau(t_0)=\sum_{i=0}^{i=n-1} w_{\mathrm{time}}(t_0+i \cdot T_{\text{ADC}})y(t_0+i \cdot T_{\text{ADC}})$ as a function of the time shift $t_0$.
645
646
647% This does not apply for MAGIC as the LONs are giving always a correlated noise (in addition to the artificial shaping)
648
649%In the case of an uncorrelated noise with zero mean the noise autocorrelation matrix is:
650
651%\begin{equation}
652%\boldsymbol{B}_{ij}= \langle b_i b_j \rangle \delta_{ij} = \sigma^2(b_i) \ ,
653%\end{equation}
654
655%where $\sigma(b_i)$ is the standard deviation of the noise of the discrete measurements. Equation (\ref{of_noise}) than becomes:
656
657
658%\begin{equation}
659%\frac{\sigma^2(b_i)}{\sigma_E^2} = \sum_{i=1}^{n}{g_i^2} - \frac{\sum_{i=1}^{n}{g_i \dot{g}_i}}{\sum_{i=1}^{n}{\dot{g}_i^2}} \ .
660%\end{equation}
661
662
663\begin{figure}[h!]
664\begin{center}
665\includegraphics[totalheight=7cm]{amp_sliding.eps}
666\includegraphics[totalheight=7cm]{time_sliding.eps}
667\end{center}
668\caption[Digital filter weights applied.]{Digital filter weights applied to the recorded FADC time slices of
669one simulated MC pulse. The left plot shows the result of the applied amplitude weights
670$e(t_0)=\sum_{i=0}^{i=n-1} w_{\mathrm{amp}}(t_0+i \cdot T_{\text{ADC}})y(t_0+i \cdot T_{\text{ADC}})$ and
671the right plot shows the result of the applied timing weights
672$e\tau(t_0)=\sum_{i=0}^{i=n-1} w_{\mathrm{time}}(t_0+i \cdot T_{\text{ADC}})y(t_0+i \cdot T_{\text{ADC}})$ as a function of the time shift $t_0$.}
673\label{fig:amp_sliding}
674\end{figure}
675
676Figure \ref{fig:shape_fit_TDAS} shows the simulated signal pulse shape of a typical MC event together with the simulated FADC slices of the signal pulse plus noise. The digital filter has been applied to reconstruct the signal size and timing. Using this information together with the average normalized MC pulse shape the simulated signal pulse shape is reconstructed and shown as well.
677
678
679
680
681
682\begin{figure}[h!]
683\begin{center}
684\includegraphics[totalheight=7cm]{shape_fit_TDAS.eps}
685\end{center}
686\caption[Shape fit.]{Simulated signal pulse shape and FADC slices for a typical MC event. The FADC measurements are affected by noise. Using the digital filter and the average MC pulse shape the signal shape is reconstructed. The event shown is the same as in figure \ref{fig:amp_sliding}.} \label{fig:shape_fit_TDAS}
687\end{figure}
688%Full fit to the MC pulse shape with the MC input shape and a numerical fit using the digital filter
689
690
691
692The following free adjustable parameters have to be set from outside:
693
694\begin{description}
695\item[Weights File:\xspace] An ascii-file containing the weights, the binning resolution and
696the window size. Currently, the following weight files have been created:
697\begin{itemize}
698\item "cosmics\_weights.dat'' with a window size of 6 FADC slices
699\item "cosmics\_weights4.dat'' with a window size of 4 FADC slices
700\item "calibration\_weights\_blue.dat'' with a window size of 6 FADC slices
701\item "calibration\_weights4\_blue.dat'' with a window size of 4 FADC slices
702\item "calibration\_weights\_UV.dat'' with a window size of 6 FADC slices and in the low-gain the
703calibration weights obtained from blue pulses\footnote{UV-pulses saturating the high-gain are not yet
704available.}.
705\item "calibration\_weights4\_UV.dat'' with a window size of 4 FADC slices and in the low-gain the
706calibration weights obtained from blue pulses\footnote{UV-pulses saturating the high-gain are not yet
707available.}.
708\end{itemize}
709\end{description}
710
711\begin{figure}[htp]
712 \includegraphics[width=0.49\linewidth]{MExtractTimeAndChargeDigitalFilter_5Led_UV.eps}
713 \includegraphics[width=0.49\linewidth]{MExtractTimeAndChargeDigitalFilter_23Led_Blue.eps}
714\caption[Sketch calculated arrival times MExtractTimeAndChargeDigitalFilter]{%
715Sketch of the calculated arrival times for the extractor {\textit{MExtractTimeAndChargeDigitalFilter}}
716for two typical calibration pulses (pedestals have been subtracted) and a typical inner pixel.
717The extraction window sizes modify the position of the (amplitude-weighted) mean FADC-slices slightly.
718The pulse would be shifted half a slice to the right for an outer pixels. }
719\label{fig:dfsketch}
720\end{figure}
721
722\subsubsection{Digital Filter with Global Peak Search}
723
724This extractor is implemented in the MARS-class {\textit{\bf MExtractTimeAndChargeDigitalFilterPeakSearch}}.
725
726The idea of this extractor is to combine {\textit{\bf MExtractFixedWindowPeakSearch}} and
727{\textit{\bf MExtractTimeAndChargeDigitalFilter}} in order to correct for coherent movements in arrival time
728for all pixels and still use the digital filter fit capabilities.
729 \par
730
731In a first loop, it fixes a reference point defined as the highest sum of
732consecutive non-saturating FADC slices in a (smaller) peak-search window.
733\par
734In a second loop over the pixels,
735it uses the digital filter algorithm within a reduced extraction window.
736It loops twice over all pixels in every event, because it has to find the reference point, first.
737
738As in the case of {\textit{\bf MExtractFixedWindowPeakSearch}}, for a high intensity calibration run
739causing high-gain saturation in the whole camera, this
740extractor apparently fails since only dead pixels
741are taken into account in the peak search which cannot produce a saturated signal.
742
743\par
744For this special case, the extractor then defines the peak search window
745as the one starting from the mean position of the first saturating slice.
746\par
747The following adjustable parameters have to be set from outside, additionally to the ones to be
748set in {\textit{\bf MExtractTimeAndChargeDigitalFilter}}:
749\begin{description}
750\item[Peak Search Window:\xspace] Defines the ``sliding window'' size within which the peaking sum is
751searched for (default: 2 slices)
752\item[Offset left from Peak:\xspace] Defines the left offset of the start of the extraction window w.r.t. the
753starting point of the obtained peak search window (default: 3 slices)
754\item[Offset right from Peak:\xspace] Defines the right offset of the of the extraction window w.r.t. the
755starting point of the obtained peak search window (default: 3 slices)
756\item[Limit for high gain failure events:\xspace] Defines the limit of the number of events which failed
757to be in the high-gain window before the run is rejected.
758\item[Limit for low gain failure events:\xspace] Defines the limit of the number of events which failed
759to be in the low-gain window before the run is rejected.
760\end{description}
761
762In principle, the ``offsets'' can be chosen very small, because both showers and calibration pulses spread
763over a very small time interval, typically less than one FADC slice. However, the MAGIC DAQ produces
764artificial jumps of two FADC slices from time to time\footnote{in 5\% of the events per pixel in December 2004},
765so the 3 slices are made in order not to reject these pixels already with the extractor.
766
767\subsubsection{Real Fit to the Expected Pulse Shape }
768
769The digital filter is a sophisticated numerical tool to fit the read-out FADC samples with the expected wave form taking the autocorrelation of the noise into account. In order to cross-check the results a pulse shape fit has been implemented using the root TH1::Fit routine. For each event the FADC samples of each pixel are filled into a histogram and fit by the expected wave form having the time shift and the area of the fit pulse as free parameters. The results are in very good agreement with the results of the digital filter.
770
771Figure \ref{fig:probability_fit} shows the distribution of the fit probability for simulated MC pulses. Both electronics and NSB noise are simulated. The distribution is mainly flat with a slight excess in the very lowest probability bins.
772\par
773
774This extractor is not (yet) implemented as a MARS-class.
775
776
777
778\begin{figure}[h!]
779\begin{center}
780\includegraphics[totalheight=7cm]{probability_fit_0ns.eps}
781\end{center}
782\caption[Fit Probability.]{Probability of the fit with the input signal shape to the simulated FADC samples
783including electronics and NSB noise.} \label{fig:probability_fit}
784\end{figure}
785
786
787
788\subsection{Used Extractors for this Analysis}
789
790We tested in this TDAS the following parameterized extractors:
791
792\begin{description}
793\item[MExtractFixedWindow]: with the following initialization, if {\textit{maxbin}} defines the
794 mean position of the high-gain FADC slice which carries the pulse maximum \footnote{The function
795{\textit{MExtractor::SetRange(higain first, higain last, logain first, logain last)}} sets the extraction
796range with the high gain start bin {\textit{higain first}} to (including) the last bin {\textit{higain last}}.
797Analogue for the low gain extraction range. Note that in MARS, the low-gain FADC samples start with
798the index 0 again, thus {\textit{maxbin+0.5}} means in reality {\textit{maxbin+15+0.5}}. }
799:
800\begin{enumerate}
801\item SetRange({\textit{maxbin}}-1,{\textit{maxbin}}+2,{\textit{maxbin}}+0.5,{\textit{maxbin}}+3.5);
802\item SetRange({\textit{maxbin}}-1,{\textit{maxbin}}+2,{\textit{maxbin}}-0.5,{\textit{maxbin}}+4.5);
803\item SetRange({\textit{maxbin}}-2,{\textit{maxbin}}+3,{\textit{maxbin}}-0.5,{\textit{maxbin}}+4.5);
804\item SetRange({\textit{maxbin}}-2,{\textit{maxbin}}+5,{\textit{maxbin}}-0.5,{\textit{maxbin}}+6.5);
805\item SetRange({\textit{maxbin}}-3,{\textit{maxbin}}+10,{\textit{maxbin}}-1.5,{\textit{maxbin}}+7.5);
806\suspend{enumerate}
807\item[MExtractFixedWindowSpline]: with the following initialization, if {\textit{maxbin}} defines the
808 mean position of the high-gain FADC slice carrying the pulse maximum \footnote{The function
809{\textit{MExtractor::SetRange(higain first, higain last, logain first, logain last)}} sets the extraction
810range with the high gain start bin {\textit{higain first}} to (including) the last bin {\textit{higain last}}.
811Analogue for the low gain extraction range. Note that in MARS, the low-gain FADC samples start with
812the index 0 again, thus {\textit{maxbin+0.5}} means in reality {\textit{maxbin+15+0.5}}.}:
813\resume{enumerate}
814\item SetRange({\textit{maxbin}}-1,{\textit{maxbin}}+3,{\textit{maxbin}}+0.5,{\textit{maxbin}}+4.5);
815\item SetRange({\textit{maxbin}}-1,{\textit{maxbin}}+3,{\textit{maxbin}}-0.5,{\textit{maxbin}}+5.5);
816\item SetRange({\textit{maxbin}}-2,{\textit{maxbin}}+4,{\textit{maxbin}}-0.5,{\textit{maxbin}}+5.5);
817\item SetRange({\textit{maxbin}}-2,{\textit{maxbin}}+6,{\textit{maxbin}}-0.5,{\textit{maxbin}}+7.5);
818\item SetRange({\textit{maxbin}}-3,{\textit{maxbin}}+11,{\textit{maxbin}}-1.5,{\textit{maxbin}}+8.5);
819\suspend{enumerate}
820\item[MExtractFixedWindowPeakSearch]: with the following initialization: \\
821SetRange(0,18,2,14); and:
822\resume{enumerate}
823\item SetWindows(2,2,2); SetOffsetFromWindow(0);
824\item SetWindows(4,4,2); SetOffsetFromWindow(1);
825\item SetWindows(4,6,4); SetOffsetFromWindow(0);
826\item SetWindows(6,6,4); SetOffsetFromWindow(1);
827\item SetWindows(8,8,4); SetOffsetFromWindow(1);
828\item SetWindows(14,10,4); SetOffsetFromWindow(2);
829\suspend{enumerate}
830\item[MExtractTimeAndChargeSlidingWindow]: with the following initialization: \\
831\resume{enumerate}
832\item SetWindowSize(2,2); SetRange(5,11,7,11);
833\item SetWindowSize(4,4); SetRange(5,13,6,12);
834\item SetWindowSize(4,6); SetRange(5,13,5,13);
835\item SetWindowSize(6,6); SetRange(4,14,5,13);
836\item SetWindowSize(8,8); SetRange(4,16,4,14);
837\item SetWindowSize(14,10); SetRange(5,10,7,11);
838\suspend{enumerate}
839\item[MExtractTimeAndChargeSpline]: with the following initialization:
840\resume{enumerate}
841\item SetChargeType(MExtractTimeAndChargeSpline::kAmplitude); \\
842SetRange(5,10,7,10);
843\suspend{enumerate}
844SetChargeType(MExtractTimeAndChargeSpline::kIntegral); \\
845and:
846\resume{enumerate}
847\item SetRiseTime(0.5); SetFallTime(0.5); SetRange(5,10,7,11);
848\item SetRiseTime(0.5); SetFallTime(1.5); SetRange(5,11,7,12);
849\item SetRiseTime(1.0); SetFallTime(3.0); SetRange(4,12,5,13);
850\item SetRiseTime(1.5); SetFallTime(4.5); SetRange(4,14,3,13);
851\suspend{enumerate}
852\item[MExtractTimeAndChargeDigitalFilter]: with the following initialization:
853\resume{enumerate}
854\item SetWeightsFile(``cosmics\_weights.dat''); SetRange(4,14,5,13);
855\item SetWeightsFile(``cosmics\_weights4.dat''); SetRange(5,13,6,12);
856\item SetWeightsFile(``calibration\_weights\_UV.dat'');
857\item SetWeightsFile(``calibration\_weights4\_UV.dat'');
858\item SetWeightsFile(``calibration\_weights\_blue.dat'');
859\item SetWeightsFile(``calibration\_weights4\_blue.dat'');
860\end{enumerate}
861\end{description}
862
863References: \cite{OF77,OF94}.
864
865
866%%% Local Variables:
867%%% mode: latex
868%%% TeX-master: "MAGIC_signal_reco"
869%%% TeX-master: "MAGIC_signal_reco"
870%%% End:
Note: See TracBrowser for help on using the repository browser.