| 1 | \chapter{Hits and Digitization}
|
|---|
| 2 |
|
|---|
| 3 | \section{Design Philosophy}
|
|---|
| 4 | In {\sc Geant4} a {\it hit} is a snapshot of a physical interaction or an
|
|---|
| 5 | accumulation of interactions of a track or tracks in a ``sensitive'' detector
|
|---|
| 6 | component. A digitization, or {\it digit}, represents a detector output, such
|
|---|
| 7 | as an ADC/TDC count or a trigger signal. A {\it digit} is created from one or
|
|---|
| 8 | more hits and/or other {\it digits}. Given the wide variety of {\sc Geant4}
|
|---|
| 9 | applications, ways of describing detector sensitivity and the quantities to
|
|---|
| 10 | be stored in the {\it hits} and {\it digits} vary greatly. This category
|
|---|
| 11 | therefore provides only abstract classes for both detector sensitivity and
|
|---|
| 12 | {\it hits}/{\it digits}. It also provides tools for organizing the
|
|---|
| 13 | {\it hits}/{\it digits} into collections.
|
|---|
| 14 |
|
|---|
| 15 | \section{Class Design}
|
|---|
| 16 |
|
|---|
| 17 | \begin{itemize}
|
|---|
| 18 |
|
|---|
| 19 | \item {\bf G4SensitiveDetectorManager} -
|
|---|
| 20 | a list of G4SensitiveDetectors.
|
|---|
| 21 |
|
|---|
| 22 | \item {\bf G4HitsStructure} -
|
|---|
| 23 | a tree-like structure of G4Hit collections. Each branch represents the
|
|---|
| 24 | hits in given sub-detector. For example, the first level of branches
|
|---|
| 25 | may consist of a tracker, ECAL, and HCAL, while the second level, in HCAL,
|
|---|
| 26 | consists of the barrel and endcaps. Finally the barrel may have phi-slices,
|
|---|
| 27 | Z-slices, etc.
|
|---|
| 28 |
|
|---|
| 29 | \item {\bf G4VSensitiveDetector} -
|
|---|
| 30 | an abstract class of all of sensitive volumes.
|
|---|
| 31 |
|
|---|
| 32 | \item {\bf G4HitsCollection} -
|
|---|
| 33 | a collection of hits. Instantiates an RWCollection class.
|
|---|
| 34 |
|
|---|
| 35 | \item {\bf G4VHit} -
|
|---|
| 36 | this class has all the information about a particular hit caused by a
|
|---|
| 37 | single step.
|
|---|
| 38 |
|
|---|
| 39 | \item {\bf G4VDigitizer} -
|
|---|
| 40 | the class of objects which transform the hits deposited by particles into
|
|---|
| 41 | digitizations.
|
|---|
| 42 |
|
|---|
| 43 | \item {\bf G4DigitizerManager} -
|
|---|
| 44 | the (single) object dispatching common messages to individual digitizers.
|
|---|
| 45 |
|
|---|
| 46 | \item {\bf G4VDigi} -
|
|---|
| 47 | an abstract (base) class for all G4 digitizations. This could be data as
|
|---|
| 48 | simple as a singe byte, or as complex as an Ntuple.
|
|---|
| 49 |
|
|---|
| 50 | \item {\bf G4DigiStructure} -
|
|---|
| 51 | digitizations are organized as a structure, which could be anything
|
|---|
| 52 | between a single value and an Ntuple.
|
|---|
| 53 |
|
|---|
| 54 | \end{itemize}
|
|---|
| 55 |
|
|---|
| 56 |
|
|---|
| 57 | The object-oriented design of the 'hit' related classes is shown in the
|
|---|
| 58 | following class diagrams. The diagrams are described in the Booch notation.
|
|---|
| 59 | Fig. \ref{figure:hit-1} shows the general management of hit classes.
|
|---|
| 60 | Fig. \ref{figure:hit-2} shows the OO design of user-related hit classes.
|
|---|
| 61 | Fig. \ref{figure:hit-3} shows the OO design of the readout geometry.
|
|---|
| 62 |
|
|---|
| 63 | \begin{figure}
|
|---|
| 64 | \begin{center}
|
|---|
| 65 | \includegraphics[angle=0,scale=0.55]{OOAnalysisDesign/Hit/classDgmHitMain.eps}
|
|---|
| 66 | \vspace{10pt}
|
|---|
| 67 | \caption{Overview of hit classes management}
|
|---|
| 68 | \label{figure:hit-1}
|
|---|
| 69 | \end{center}
|
|---|
| 70 | \end{figure}
|
|---|
| 71 |
|
|---|
| 72 | \begin{figure}
|
|---|
| 73 | \begin{center}
|
|---|
| 74 | \includegraphics[angle=0,scale=0.5]{OOAnalysisDesign/Hit/classDgmHitUser.eps}
|
|---|
| 75 | \vspace{10pt}
|
|---|
| 76 | \caption{User hit classes}
|
|---|
| 77 | \label{figure:hit-2}
|
|---|
| 78 | \end{center}
|
|---|
| 79 | \end{figure}
|
|---|
| 80 |
|
|---|
| 81 | \begin{figure}
|
|---|
| 82 | \begin{center}
|
|---|
| 83 | \includegraphics[angle=0,scale=0.6]{OOAnalysisDesign/Hit/classDgmReadoutGeom.eps}
|
|---|
| 84 | \vspace{10pt}
|
|---|
| 85 | \caption{Readout geometry}
|
|---|
| 86 | \label{figure:hit-3}
|
|---|
| 87 | \end{center}
|
|---|
| 88 | \end{figure}
|
|---|
| 89 |
|
|---|
| 90 | \section{Status of this chapter}
|
|---|
| 91 |
|
|---|
| 92 | 27.06.05 section on design philosophy added (from Geant4 general paper) by
|
|---|
| 93 | D.H. Wright \\
|
|---|