CFEL - ASG Software Suite  2.5.0
CASS
delayline_detector_analyzer_simple.h
Go to the documentation of this file.
1 //Copyright (C) 2009, 2010 Lutz Foucar
2 
3 /**
4  * @file delayline_detector_analyzer_simple.h file contains the declaration of
5  * classes that analyzses a delayline
6  * detector.
7  *
8  * @author Lutz Foucar
9  */
10 
11 #ifndef __DELAYLINE_DETECTOR_ANALYZER_SIMPLE_H_
12 #define __DELAYLINE_DETECTOR_ANALYZER_SIMPLE_H_
13 
14 #include <tr1/memory>
15 
17 #include "delayline_detector.h"
18 
19 namespace cass
20 {
21 namespace ACQIRIS
22 {
23 class SignalProducer;
24 class PositionCalculator;
25 
26 /** Simple sorter of hits from a Quadanode delayline detector.
27  *
28  * Do a simple sorting by checking the timesum for each MCP Signal that was
29  * identified. This is done for only one pair of anode layers.
30  *
31  * @cassttng AcqirisDetectors/\%detectorname\%/Simple/{Runtime}\n
32  * maximum time a signal will run over the complete delayline.
33  * Default is 150.
34  * @cassttng AcqirisDetectors/\%detectorname\%/Simple/{McpRadius}\n
35  * Radius of the MCP in mm. Default is 88
36  * @cassttng AcqirisDetectors/\%detectorname\%/Simple/{LayersToUse}\n
37  * Layers that should be used for sorting. Default is 0. Possible
38  * choises are:
39  * - 0: Layers X and Y (Quad Anode)
40  * - 1: Layers U and V (Hex Anode)
41  * - 2: Layers U and W (Hex Anode)
42  * - 3: Layers V and W (Hex Anode)
43  * @cassttng AcqirisDetectors/\%detectorname\%/Simple/{TimesumFirstLayerLow|TimesumFirstLayerHigh}\n
44  * the timesum condition range for the first layer.
45  * Default is 0 | 200
46  * @cassttng AcqirisDetectors/\%detectorname\%/Simple/{TimesumSecondLayerLow|TimesumSecondLayerHigh}\n
47  * the timesum condition range for the second layer.
48  * Default is 0 | 200
49  * @cassttng AcqirisDetectors/\%detectorname\%/Simple/{ScalefactorFirstLayer|ScalefactorSecondLayer}\n
50  * the scalefactors that convert ns to mm for the two layers.
51  * Default is 0.4 | 0.4
52  *
53  * @author Lutz Foucar
54  */
57 {
58 public:
59  /** constuctor */
62  _mcp(0)
63  {}
64 
65  /** the function creating the detectorhit list
66  *
67  * @return reference to the hit container
68  * @param hits the hitcontainer
69  */
71 
72  /** load the detector analyzers settings from .ini file
73  *
74  * retrieve all necessary information to be able to sort the signals of
75  * the detector to detector hits. Also retrieve the signal producers of
76  * the layers whos signals we should sort.
77  *
78  * @param s the CASSSetting object
79  * @param d the detector object that we are belonging to
80  */
82 
83 private:
84  /** the mcp */
86 
87  /** the layer combination */
88  std::pair<std::pair<SignalProducer *,SignalProducer *> ,
89  std::pair<SignalProducer *,SignalProducer *> > _layerCombination;
90 
91  /** timesum ranges of the layers */
92  std::pair<std::pair<double, double>,
93  std::pair<double, double> > _tsrange;
94 
95  /** timesums of the layers */
96  std::pair<double,double> _ts;
97 
98  /** the scalefactor for the two layers (convert ns -> mm) */
99  std::pair<double,double> _sf;
100 
101  /** maximum runtime over the layers */
102  double _runtime;
103 
104  /** maximum radius that det hits are allowed to be in, in ns */
105  double _mcpRadius;
106 
107  /** the calculator to calc the position for the correlated wireend signals */
108  std::tr1::shared_ptr<PositionCalculator> _poscalc;
109 };
110 
111 
112 }//end namespace acqiris
113 }//end namespace cass
114 
115 #endif
double _mcpRadius
maximum radius that det hits are allowed to be in, in ns
std::pair< std::pair< SignalProducer *, SignalProducer * >, std::pair< SignalProducer *, SignalProducer * > > _layerCombination
the layer combination
Settings for CASS.
Definition: cass_settings.h:30
std::vector< detectorHit_t > detectorHits_t
define container for all detector hits
std::pair< double, double > _ts
timesums of the layers
Average out the iShit status to get the avererage hits
std::pair< double, double > _sf
the scalefactor for the two layers (convert ns -> mm)
file contains the classes that describe a delayline detector.
Simple sorter of hits from a Quadanode delayline detector.
detectorHits_t & operator()(detectorHits_t &hits)
the function creating the detectorhit list
void loadSettings(CASSSettings &s, DelaylineDetector &d)
load the detector analyzers settings from .ini file
file contains base class for all delayline detector analyzers.
std::tr1::shared_ptr< PositionCalculator > _poscalc
the calculator to calc the position for the correlated wireend signals
std::pair< std::pair< double, double >, std::pair< double, double > > _tsrange
timesum ranges of the layers
Base class for all detector analyzers.