BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
KalFitSuper_Mdc.cxx
Go to the documentation of this file.
1//
2#include "KalFitAlg/KalFitSuper_Mdc.h"
3#include "KalFitAlg/KalFitLayer_Mdc.h"
4#include "KalFitAlg/KalFitList.h"
5#include "KalFitAlg/KalFitWire.h"
6
7//...Globals...
8const unsigned int KalFitSuper_Mdc::_neighborsMask[6] = { 452, 420, 340, 172, 92, 60 };
9// [0] = 452 = FTWireHitAppended + FTWireNeighbor345
10// [1] = 420 = FTWireHitAppended + FTWireNeighbor245
11// definitions of [2] = 340 = FTWireHitAppended + FTWireNeighbor135
12// _neighborsMask[] [3] = 172 = FTWireHitAppended + FTWireNeighbor024
13// [4] = 92 = FTWireHitAppended + FTWireNeighbor013
14// [5] = 60 = FTWireHitAppended + FTWireNeighbor012
15
16KalFitSuper_Mdc::KalFitSuper_Mdc( const int firstWireID, const int NWire,
17 const int firstLayerID, const int NLayer,
18 const int superLayerID )
19 : _superLayerId( superLayerID )
20 , _firstWireId( firstWireID )
21 , _Nwire( NWire )
22 , _firstLayerId( firstLayerID )
23 , _Nlayer( NLayer )
24 , _wireHits( *( new KalFitList<KalFitWire*>( 500 ) ) )
25 , _singleHits( *( new KalFitList<KalFitWire*>( 100 ) ) ) {}
26
28 clear();
29 delete &_wireHits;
30 delete &_singleHits;
31}
32
34 if ( _wireHits.length() )
35 {
36 register KalFitWire** hptr = _wireHits.firstPtr();
37 KalFitWire** const last = _wireHits.lastPtr();
38 do {
39 ( **hptr ).state( WireHitInvalid );
40 } while ( (long)( hptr++ ) ^ (long)last );
41 _wireHits.clear();
42 }
43}
44
45const int KalFitSuper_Mdc::nWire( void ) const { return _Nwire; }
46
47const int KalFitSuper_Mdc::nLayer( void ) const { return _Nlayer; }
48
49const int KalFitSuper_Mdc::localMaxId( void ) const { return ( _Nwire - 1 ); }
50
51const int KalFitSuper_Mdc::layerMaxId( void ) const { return ( _Nlayer - 1 ); }
52
53const int KalFitSuper_Mdc::superLayerId( void ) const { return _superLayerId; }
const int localMaxId(void) const
returns local max ID
KalFitSuper_Mdc(const int firstWireID, const int NWire, const int firstLayerID, const int NLayer, const int superLayerID)
Constructors and destructor.
const int superLayerId(void) const
returns super-layer ID
const int nLayer(void) const
returns number of layers
const int nWire(void) const
returns number of wires
const int layerMaxId(void) const
returns layer max ID
void clear(void)
clear object