\chapter{Technical Trigger Specifications}
	\label{chapter_trigger_specifics}
All trigger bits at each level described below additionally have overriding vetoes from timing information provided by the calorimeter, C5, SRTD, or Global Calorimeter.  This timing information is used to reject background events including beamgas, halo muon, cosmic muons.
\section{First Level Trigger Selection}
	\label{section_flt_specifics}
The FLT was divided into 64 independent bits, each of which recorded a true or false state for each event depending on specific physical conditions.  The FLT bits used in the principle and secondary selections are listed in table~\ref{table_flt_bits}.  For each trigger analysis, at least one bit in the FLT selection was required to be set to true.  The bits definition depended on the run number, specifically in the case of bits 60 and 63, which changed on run 54115.  

\begin{table}
  \begin{center}
     	\begin{tabular}{|p{3.2cm}|c|c|p{8cm}|}  
 		 FLT bit  number  &  Principle & Alternative & Description \\
      \hline
		31 & \phantom{$\checkmark$} & $\checkmark$ & $ E_{T,Fbp} + E_{T}   \geq 45 ~\GeV$ \\
      \hline
		39 & $\checkmark$ & $\checkmark$ & $E_{BEMC}\geq 3~\GeV$ and $B_{isoe}$ and $\ngoodtracks \geq 1$ and Loose Track Veto\\
      \hline
		40 & $\checkmark$ & $\checkmark$ & $E_{EMC}\geq 25~\GeV$ and Tight Track Veto\\
      \hline
		41 & $\checkmark$ & $\checkmark$ & $E_{T}\geq 30~\GeV$ and Tight Track Veto\\
      \hline
		43 & $\checkmark$ & $\checkmark$ & $E_{T}\geq 12~\GeV$ and $\ngoodtracks\geq 1$ and Tight Track Veto\\
      \hline
		44 & $\checkmark$ & $\checkmark$ & ($E_{BEMC}\geq 10~\GeV$ or $E_{REMC}\geq 3~\GeV$), $B_{isoe}$, $\ngoodtracks\geq 1$, and Tight Track Veto\\
      \hline
		50 & \phantom{$\checkmark$} & $\checkmark$ & $( E_{CAL}  \geq 15~\GeV || E_{EMC}  \geq 10~\GeV || E_{BEMC} \geq 3~\GeV || E)_{REMC} >= 2~\GeV ) \&\& TRK_q95b \&\& ( Et_HFL >= 892 )$ \\
      \hline
		60 (Run $\leq$ 54115)& $\checkmark$ & $\checkmark$ & $(\ptmiss > 5~\GeV$ and $E_{T,-2IR} > 5~\GeV$ and $N_{vtx trk}\geq 1)$ or $(\ptmiss > 8~\GeV$ and $N_{trks}\geq 1)$ or $(\ptmiss > 8~\GeV$ and $E_{FCAL}\geq 10~\GeV)$ and not FCLR beam gas\\
      \hline
		60 (Run $>$ 54115)& $\checkmark$ & $\checkmark$ & $(\ptmiss > 5~\GeV$ and $E_{T,-2IR} > 5~\GeV$ and $N_{vtx trk}\geq 1)$ or $(\ptmiss > 11.5~\GeV$ and $N_{trks}\geq 1)$ or $(\ptmiss > 11.5~\GeV$ and $E_{FCAL}\geq 10~\GeV)$ and not FCLR beam gas\\
      \hline
		63 (Run $>$ 54115)& $\checkmark$ & $\checkmark$ & $(\ptmiss > 5~\GeV$ and $E_{T,-2IR} > 5~\GeV$ and $N_{vtx trk}\geq 1)$ or $(\ptmiss > 8~\GeV$ and $N_{trks}\geq 1)$ or $(\ptmiss > 11.5~\GeV$ and $E_{FCAL}\geq 10~\GeV)$ and not FCLR beam gas\\
	\hline    
	\end{tabular}
  \end{center}
	\caption[First Level Trigger Bits Applied]{\fixspacing{First Level Trigger bits used in this analysis.}}
	\label{table_flt_bits}
\end{table}

	In table~\ref{table_flt_bits}, tight track veto refers to selection vetoes where events were rejected due to a large number of non-vertex tracks.  $B_{isoe}$ is true if an isolated calorimeter deposit in the BCAL was located which is consistent with an isolated electron.  $\ngoodtracks$ is the number of tracks found with strict quality standards. $E_{EMC}$ and $E_{BEMC}$ are the energies located in the entire EMC and Barrel EMC, respectively.  Additional vetoes from the C5 counter and Veto Wall apply to all bits.

	In FLT60 before run 54115, an event was vetoed by the FCLR if the highest energy RCAL cluster had an energy greater than $50 ~\GeV$, and the highest energy tower in the highest energy RCAL cluster was located in the inner ring of the RCAL.  Due to increased dead time during 2005 data taking, the requirements of FLT60 was divided up into two bits: FLT60 and FLT63.  FLT60 and FLT63 after run 54115 had the same veto conditions as FLT60 before run 54115, but afterwards FLT63 additionally was FCLR vetoed if $E-p_z<3~\GeV$ 

\section{Second Level Trigger Selection}
	In the principle selection, events were required to have SLT bit EXO04 set to true.  Elements of SLT EXO04 are defined in table~\ref{table_slt_conditionals}.
\begin{table}
  \begin{center}
     	\begin{tabular}{|r|p{8cm}|}  
	\hline
		${N^{\mbox{\tiny G}}}_{\mbox{\tiny PMT}}$ & The number of PMTs in the global calorimeter\\
	\hline
		CCtimeOK & $\left|T_{\mbox{\tiny G}}\right| < 7\ns$ and ${N^{\mbox{\tiny G}}}_{\mbox{\tiny PMT}} >1$\\
	\hline
		CCCTDOK & $N_{\mbox{\tiny trk}} \geq 1$ and $Z_{\mbox{\tiny vtx}} < 100 \cm$\\
	\hline
		NoOffBeamProton & $\left|p_{y}\right| > 3~\GeV$ or $\ptmiss>15~\GeV$ or $\ptmiss(-1IR) > 6~\GeV$ or $\ptmiss > 0.06 p_{z}$\\
	\hline 
		CC1 & $\ptmiss > 6~\GeV$ and $E_T(-2IR)>6~\GeV$ and $\ngoodtracks>1$\\
		CC2 & $\ptmiss > 9~\GeV$ and $\ptmiss(-1IR)>8~\GeV$ and $E_{FCAL}>20~\GeV$\\
		CC3 & $\ptmiss > 9~\GeV$ and $(\ptmiss)^2>2.31\times E_T$ and $E_{FCAL}>80~\GeV$\\
		CC4 & $E-p_z > 6~\GeV$ and $(\ptmiss)^2>2.25\times E_T$ and $\ngoodtracks>1$\\
	\hline
	\end{tabular}
  \end{center}
	\label{table_slt_conditionals}
	\caption[EXO4 Second Level Trigger Definitions]{\fixspacing{EXO4 Second Level Trigger Definitions}}
\end{table}
% 	This bit was only set to true if there was one functional PMT in the {\it Global Calorimeter}, This bit required one of the following conditions to be met: 
%         EXO04 = (Bool_t)(Sltw[6-1] & (1 << 4+12-1));//jbit(SLTW(6),16) = EXO04 CC!
% 	From http://giroz.desy.de/components/gslt/sw/filters/v82/exo4.html
% 
% C...Add global time condition to EXO4 and EXO5
%          gt_npmt_ok = (CCGgnpmt.gt.1)
%          gt_pass = ((CCGgtime.gt.-7.0).and.(CCGgtime.lt. 7.0))
%      &             .OR. (CCGgtime.eq.90.0)
% 
% C-------
% C...EXO4
% C-------
% 
%          CCtimeOK       = gt_npmt_ok .and. gt_pass
%          CCctdOK        = slf.gt.0 .and. (.not.CTD_BEAMGAS)
%          CCsltgoodtrack = FLTsbt(49) .or. slf.gt.0
% 
%          NoOffBeamProton = abs(CCGpyemc+ccgpyhac).gt.5 .or.
%      &                     CCGetmis.gt.15              .or.
%      &                     CCGetmbp.gt.6               .or.
%      &                     CCGetmis.gt.0.08*(CCGpzemc+CCGpzhac)
% 
%          CC1 = CCsltgoodtrack                          .and.
%      &         CCGetmis.gt.6.                          .and.
%      &         (CCGetran-CCGetfbp-CCGetbp2).gt.6.
%      &          .and.
%      &           gtt_ctd_size.le.ctd_size_cut
%          CC2 = CCGetmis.gt.9.                          .and.
%      &         CCGetmbp.gt.8.                          .and.
%      &         CCGefcal.gt.20.0
%          CC3 = CCGetmis.gt.9.                          .and.
%      &         CCGefcal.gt.80.0                        .and.
%      &         (CCGetmis**2.gt. 4.41 * CCGetran)
%          CC4 = CCsltgoodtrack                          .and.
%      &         CCGemnpz.gt.6.                          .and.
%      &         (CCGetmis**2.gt. 2.25 * CCGetran)
% 
%          IF ( (CCtimeOK.or.CCctdOK).and.NoOffBeamProton) then
%             If (CC1.or.CC2.or.CC3.or.CC4) CALL SBIT1(ISUBTR1(3),16)
%             If (CC1) CALL SBIT1(ISUBTR1(3),25)
%             If (CC2) CALL SBIT1(ISUBTR1(3),26)
%             If (CC3) CALL SBIT1(ISUBTR1(3),27)
%             If (CC4) CALL SBIT1(ISUBTR1(3),28)
%          Endif
% 
% 	Secondary HPP05 
% SLT HPP05: CC DIS
% 
%     * FLT: 28,30,31,39,40,41,42,43,44,50,60
%     * |Zvtx| < 60cm .or. no CTD
%     * at least 1 good track
%     * Et_miss > 8 GeV
%     * ET_cone > 8 GeV
% 
% 
% */
% 
% 
% /*
	SLT EXO04 was true if all of the following conditions were satisfied:
\begin{itemize}
		\item $\left(	 \mbox{CCtimeOK} || \mbox{CCCTDOK} \right)$
		\item $\mbox{NoOffBeamProton}$
		\item $\left(\mbox{CC1} || \mbox{CC2	} || \mbox{CC3} || \mbox{CC4}\right)$
\end{itemize}

The alternate selection required that the SLT bit HPP05  was set to true, which was satisfied if all the following conditions were met:
\begin{itemize}
	\item FLT: 28,30,31,39,40,41,42,43,44,50, or 60
%		         ??,??,31,39,40,41,??,43,44,50,     60 63 
	\item $\ngoodtracks \geq 1$ 
	\item $\ptmiss > 8~\GeV$
	\item $E_{T}^{cone} > 8~\GeV$
	\item $\ptmiss/E_{T}> 0.3$
\end{itemize}



\section{Third Level Trigger Selection}
	The principle selection required that either the TLT bit EXO02 or EXO06 was set to true.  TLT EXO02 was true if all of the following conditions were satisfied:
\begin{itemize}
		\item $\ptmiss>6~\GeV$
		\item $|z_{vtx}|<60~\cm$
		\item UDTimeOK
\end{itemize}
	 where UDTimeOK compares the timing information from the upper and lower half of the calorimeter.  This condition rejected cosmic rays, which often come from above the ZEUS detector, and interact with the top and bottom at different times.  The veto was set to 8ns. EXO06 was set to true if all of the following conditions were met:
\begin{itemize}
	\item $\ptmiss>6~\GeV$
	\item  $\left(E_{FCAL} > 10~\GeV~\|~ \ngoodtracks>0\right)$
	\item \! OffBeamProton
	\item \! BeamGasVertex
	\item (\! TooManyBeamGasTracks || (Good Vertex \&\& $N_{vtx tracks} \geq 2$ )~)
	\item $\left(N_{CTD hits} < 2500 \| \ptmiss > 10~\GeV\right)$
	\item UDTimeOK
\end{itemize}

	The alternative trigger required one of TLT bits HPP05, HPP06, HPP10 to be set to true.  HPP TLT 05 true was equivalent to all of the following being true:
\begin{itemize}
	\item HPP SLT 5 == true
	\item $\ptmiss > 8~\GeV$
	\item $E_{T}^{cone} > 8~\GeV$
\end{itemize}
	HPP TLT 06 true was equivalent to all of the following being true:
\begin{itemize}
    \item HPP SLT 5 == true
    \item $\ptmiss > 8~\GeV$
    \item at least 1 cone jet with $\etjet > 8~\GeV$, $\rapjet < 2.5$
\end{itemize}
	Note that this is the only condition in this thesis where cone jets were considered.  In all other points, a jet will refer explicitly to jets found using the $k_T$ cluster algorithm.	HPP TLT 10 true was equivalent to all of the following being true:
\begin{itemize}
    \item HPP SLT 5 == true
    \item $\ptmiss > 8~\GeV$
    \item at least 1 $k_T$ jet with $\etjet > 8~\GeV$, $\rapjet < 2.5$
\end{itemize}

\section{DST Bits} In the principle trigger selection, data events were required to have DST bit 34 set to true.  This bit was equivalent to the principle trigger selection described in the following sections.  In the secondary selection, at least one of DST bits 34, 68, 69 and 73 was required to be set to true.  These bits form a superset of the alternative trigger selection.

\section{Selection Flags}
 	The ZEUS reconstruction library contains a flag EVTAKE for each event, which is set to true if the event was taken during reliable conditions.  Data events were only selected if the EVTAKE flag was set to true.  MC events were not subject to this selection.

	The two methods of polarization measurement, LPOL and TPOL, produced comparable but different measurements of the average polarization during each data taking run.  The ZEUS reconstruction library contains two boolean flags, LPOLTAKE and TPOLTAKE, which indicate if the event was taken when the LPOL and TPOL were functioning properly.  If the integrated luminosity for a given run measured by the LPOL $L_{\mbox{\tiny{LPOL}}}$ was greater than or equal to that that of the TPOL, $L_{\mbox{\tiny{TPOL}}}$, then data events were only selected if LPOLTAKE was true.  If $L_{\mbox{\tiny{TPOL}}} > L_{\mbox{\tiny{LPOL}}}$ during the run, then events were only taken if TPOLTAKE was true. MC events were not subject to this selection.   The average polarization value and integrated luminosity for each data run was exclusively taken from the LPOL if $L_{\mbox{\tiny{LPOL}}} < L_{\mbox{\tiny{TPOL}}}$, otherwise values from the TPOL were used.	All MC presented here have zero average polarization.
	
	Events were required to have $\ptmiss>9~\GeV$, $\ptmiss/E_T>0.3$, and at least one calorimeter jet within $-1 < \rapjet < 2.5$ and $\etjet > 3~\GeV$, where $\etjet$ was computed purely from cell energies.  These cuts are less restrictive forms of applied cuts and will be described later in this chapter in detail.  Events meeting all these criteria were then retrieved from the ZARAH computing farm and stored on a local workstation for analysis.
