/[PAMELA software]/PamCut/CaloCuts/CaloTrackChi2Cut/CaloTrackChi2Cut.h
ViewVC logotype

Annotation of /PamCut/CaloCuts/CaloTrackChi2Cut/CaloTrackChi2Cut.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2.2.1 - (hide annotations) (download)
Thu Jul 8 10:43:13 2010 UTC (14 years, 4 months ago) by pam-fi
Branch: V8
CVS Tags: MergedToHEAD_1, nuclei_reproc
Changes since 1.2: +4 -1 lines
File MIME type: text/plain
Support for external CaloAxis library added.

1 pam-fi 1.1 /*
2     * CaloTrackChi2Cut.h
3     *
4     * Created on: 18-mar-2009
5     * Author: mori
6     */
7    
8     /*! @file CaloTrackChi2Cut.h The CaloTrackChi2Cut class definition file */
9    
10 pam-fi 1.2.2.1 #ifndef NO_CALOAXIS
11    
12 pam-fi 1.1 #ifndef CALOTRACKCHI2CUT_H_
13     #define CALOTRACKCHI2CUT_H_
14    
15     #include "../../PamCutBase/PamCutBase.h"
16 pam-fi 1.2.2.1 #include <CaloAxis.h>
17 pam-fi 1.1
18     /*! @brief The calorimeter track chi2 quality cut.
19     *
20     * This cut performs a check on chi2 of the calorimeter track. The current
21     * implementation uses the CaloAxis objects; to save computing time, the class
22     * assumes that the track is externally computed for each event and stored in
23     * CaloAxis objects; pointers to these objects are passed as arguments to the constructor.
24     * The Check method will then ignore the PamLevel2 *event and assume that the
25     * current content of the CaloAxis objects are relative to the current event.
26     * It is an user's task to ensure that these assumptions are fulfilled every time
27     * Check or ApplyCut are called.
28     *
29     * CUT DEPENDENCIES: CaloTrackCut for the existence of the track (it can also provide the CaloAxis objects).
30     */
31    
32     class CaloTrackChi2Cut: public PamCut {
33    
34     public:
35     /*! @brief Constructor.
36     *
37     * The CaloAxis arguments are pointers to objects which contain the calorimeter
38     * track information for current event.
39     *
40     * @param cutName The cut name.
41     * @param xCaloAxis Pointer to the CaloAxis object for X axis.
42     * @param yCaloAxis Pointer to the CaloAxis object for Y axis.
43 pam-fi 1.2 * @param maxChi2 The maximum allowed Chi2 (default value is optimized for single-track fit FitAxis).
44     * @param minChi2 The minimum allowed Chi2 (default value is optimized for single-track fit FitAxis).
45 pam-fi 1.1 */
46     CaloTrackChi2Cut(const char *cutName, CaloAxis *xCaloAxis, CaloAxis *yCaloAxis, float maxChi2=0.03, float minChi2=0.005) :
47     PamCut(cutName), _xCaloAxis(xCaloAxis), _yCaloAxis(yCaloAxis), _maxChi2(maxChi2), _minChi2(minChi2) {
48     }
49     /*! @brief Destructor. */
50     ~CaloTrackChi2Cut() {
51     }
52    
53     /*! @brief The calorimeter chi2 quality check.
54     *
55     * @param event The event to analyze.
56     * @return #CUTOK if Chi2 from CaloAxis is strictly greater than minChi2 and strictly lesser than maxChi2.
57     * @return 0 otherwise
58     */
59     int Check(PamLevel2 *event);
60    
61     private:
62     CaloAxis *_xCaloAxis, *_yCaloAxis;
63     float _maxChi2, _minChi2;
64     };
65    
66     #endif /* CALOTRACKCHI2CUT_H_ */
67 pam-fi 1.2.2.1 #endif /* NO_CALOAXIS */

  ViewVC Help
Powered by ViewVC 1.1.23