GRSISort "v4.0.0.5"
An extension of the ROOT analysis Framework
Loading...
Searching...
No Matches
TFipps.cxx
Go to the documentation of this file.
1#include "TFipps.h"
2
3#include <sstream>
4#include <iostream>
5#include <iomanip>
6
7#include "TRandom.h"
8#include "TMath.h"
9#include "TInterpreter.h"
10#include "TMnemonic.h"
11
12#include "TGRSIOptions.h"
13
14bool DefaultFippsAddback(const TDetectorHit* one, const TDetectorHit* two)
15{
16 return ((one->GetDetector() == two->GetDetector()) &&
17 (std::fabs(one->GetTime() - two->GetTime()) < TGRSIOptions::AnalysisOptions()->AddbackWindow()));
18}
19
21
22bool DefaultFippsSuppression(const TDetectorHit* hit, const TDetectorHit* bgoHit)
23{
24 return ((hit->GetDetector() == bgoHit->GetDetector()) &&
25 (std::fabs(hit->GetTime() - bgoHit->GetTime()) < TGRSIOptions::AnalysisOptions()->SuppressionWindow()) &&
27}
28
30
31// Fipps detector locations.
32// Angles are in ISO standard
33// x = cos(theta)*sin(phi) // Points port
34// y = sin(theta)*sin(phi) // Points upwards
35// z = sin(theta) // Points in the direction of the neutrons
36// TVector(x,y,z)
37// TODO: Add link to picture showing detector positions when uploaded
38TVector3 TFipps::gCloverPosition[17] = {
39 TVector3(TMath::Sin(TMath::DegToRad() * (0.0)) * TMath::Cos(TMath::DegToRad() * (0.0)),
40 TMath::Sin(TMath::DegToRad() * (0.0)) * TMath::Sin(TMath::DegToRad() * (0.0)),
41 TMath::Cos(TMath::DegToRad() * (0.0))), // Zeroth Position
42 // Corona
43 TVector3(TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Cos(TMath::DegToRad() * (90.0)),
44 TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Sin(TMath::DegToRad() * (90.0)),
45 TMath::Cos(TMath::DegToRad() * (90.0))), // Fipps Pos 0
46 TVector3(TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Cos(TMath::DegToRad() * (45.0)),
47 TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Sin(TMath::DegToRad() * (45.0)),
48 TMath::Cos(TMath::DegToRad() * (90.0))), // Fipps Pos 1
49 TVector3(TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Cos(TMath::DegToRad() * (0.0)),
50 TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Sin(TMath::DegToRad() * (0.0)),
51 TMath::Cos(TMath::DegToRad() * (90.0))), // Fipps Pos 2
52 TVector3(TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Cos(TMath::DegToRad() * (315.0)),
53 TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Sin(TMath::DegToRad() * (315.0)),
54 TMath::Cos(TMath::DegToRad() * (90.0))), // Fipps Pos 3
55 TVector3(TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Cos(TMath::DegToRad() * (270.0)),
56 TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Sin(TMath::DegToRad() * (270.0)),
57 TMath::Cos(TMath::DegToRad() * (90.0))), // Fipps Pos 4
58 TVector3(TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Cos(TMath::DegToRad() * (225.0)),
59 TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Sin(TMath::DegToRad() * (225.0)),
60 TMath::Cos(TMath::DegToRad() * (90.0))), // Fipps Pos 5
61 TVector3(TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Cos(TMath::DegToRad() * (180.0)),
62 TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Sin(TMath::DegToRad() * (180.0)),
63 TMath::Cos(TMath::DegToRad() * (90.0))), // Fipps Pos 6
64 TVector3(TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Cos(TMath::DegToRad() * (135.0)),
65 TMath::Sin(TMath::DegToRad() * (90.0)) * TMath::Sin(TMath::DegToRad() * (135.0)),
66 TMath::Cos(TMath::DegToRad() * (90.0))), // Fipps Pos 7
67 // Downstream lampshade
68 TVector3(TMath::Sin(TMath::DegToRad() * (45.0)) * TMath::Cos(TMath::DegToRad() * (90.0)),
69 TMath::Sin(TMath::DegToRad() * (45.0)) * TMath::Sin(TMath::DegToRad() * (90.0)),
70 TMath::Cos(TMath::DegToRad() * (45.0))), // Fipps Pos 8
71 TVector3(TMath::Sin(TMath::DegToRad() * (45.0)) * TMath::Cos(TMath::DegToRad() * (0.0)),
72 TMath::Sin(TMath::DegToRad() * (45.0)) * TMath::Sin(TMath::DegToRad() * (0.0)),
73 TMath::Cos(TMath::DegToRad() * (45.0))), // Fipps Pos 9
74 TVector3(TMath::Sin(TMath::DegToRad() * (45.0)) * TMath::Cos(TMath::DegToRad() * (270.0)),
75 TMath::Sin(TMath::DegToRad() * (45.0)) * TMath::Sin(TMath::DegToRad() * (270.0)),
76 TMath::Cos(TMath::DegToRad() * (45.0))), // Fipps Pos 10
77 TVector3(TMath::Sin(TMath::DegToRad() * (45.0)) * TMath::Cos(TMath::DegToRad() * (180.0)),
78 TMath::Sin(TMath::DegToRad() * (45.0)) * TMath::Sin(TMath::DegToRad() * (180.0)),
79 TMath::Cos(TMath::DegToRad() * (45.0))), // Fipps Pos 11
80 // Upstream lampshade
81 TVector3(TMath::Sin(TMath::DegToRad() * (135.0)) * TMath::Cos(TMath::DegToRad() * (90.0)),
82 TMath::Sin(TMath::DegToRad() * (135.0)) * TMath::Sin(TMath::DegToRad() * (90.0)),
83 TMath::Cos(TMath::DegToRad() * (135.0))), // G: 13 F: 12
84 TVector3(TMath::Sin(TMath::DegToRad() * (135.0)) * TMath::Cos(TMath::DegToRad() * (0.0)),
85 TMath::Sin(TMath::DegToRad() * (135.0)) * TMath::Sin(TMath::DegToRad() * (0.0)),
86 TMath::Cos(TMath::DegToRad() * (135.0))), // G: 16 F: 13
87 TVector3(TMath::Sin(TMath::DegToRad() * (135.0)) * TMath::Cos(TMath::DegToRad() * (270.0)),
88 TMath::Sin(TMath::DegToRad() * (135.0)) * TMath::Sin(TMath::DegToRad() * (270.0)),
89 TMath::Cos(TMath::DegToRad() * (135.0))), // G: 15 F: 14
90 TVector3(TMath::Sin(TMath::DegToRad() * (135.0)) * TMath::Cos(TMath::DegToRad() * (180.0)),
91 TMath::Sin(TMath::DegToRad() * (135.0)) * TMath::Sin(TMath::DegToRad() * (180.0)),
92 TMath::Cos(TMath::DegToRad() * (135.0))) // G: 14 F: 15
93};
94
96{
97// Default ctor. Ignores TObjectStreamer in ROOT < 6
98#if ROOT_VERSION_CODE < ROOT_VERSION(6, 0, 0)
99 Class()->IgnoreTObjectStreamer(kTRUE);
100#endif
101 Clear();
102}
103
105{
106// Copy ctor. Ignores TObjectStreamer in ROOT < 6
107#if ROOT_VERSION_CODE < ROOT_VERSION(6, 0, 0)
108 Class()->IgnoreTObjectStreamer(kTRUE);
109#endif
110 rhs.Copy(*this);
111}
112
113void TFipps::Copy(TObject& rhs) const
114{
115 // Copy function.
117
118 for(auto& hit : static_cast<TFipps&>(rhs).fAddbackHits) delete hit;
119 for(auto& hit : static_cast<TFipps&>(rhs).fSuppressedHits) delete hit;
120 for(auto& hit : static_cast<TFipps&>(rhs).fSuppressedAddbackHits) delete hit;
121
122 static_cast<TFipps&>(rhs).fAddbackHits.clear();
123 static_cast<TFipps&>(rhs).fAddbackFrags.clear();
124 static_cast<TFipps&>(rhs).fSuppressedHits.clear();
125 static_cast<TFipps&>(rhs).fSuppressedAddbackHits.clear();
126 static_cast<TFipps&>(rhs).fSuppressedAddbackFrags.clear();
127 static_cast<TFipps&>(rhs).fFippsBits = 0;
128}
129
131{
132 // Default Destructor
133
134 // fHits automatically deleted in TDetector
135 for(auto& hit : fAddbackHits) delete hit;
136 for(auto& hit : fSuppressedHits) delete hit;
137 for(auto& hit : fSuppressedAddbackHits) delete hit;
138}
139
140void TFipps::Clear(Option_t* opt)
141{
142 // Clears the mother, and all of the hits
143 ClearStatus();
145
146 for(auto& hit : fAddbackHits) delete hit;
147 for(auto& hit : fSuppressedHits) delete hit;
148 for(auto& hit : fSuppressedAddbackHits) delete hit;
149
150 fAddbackHits.clear();
151 fSuppressedHits.clear();
153 fAddbackFrags.clear();
155}
156
157void TFipps::Print(Option_t*) const
158{
159 Print(std::cout);
160}
161
162void TFipps::Print(std::ostream& out) const
163{
164 std::ostringstream str;
165 str << "Fipps Contains: " << std::endl;
166 str << std::setw(6) << GetMultiplicity() << " hits" << std::endl;
167
168 if(IsAddbackSet()) {
169 str << std::setw(6) << fAddbackHits.size() << " addback hits" << std::endl;
170 } else {
171 str << std::setw(6) << " "
172 << " Addback not set" << std::endl;
173 }
174
175 str << std::setw(6) << " "
176 << " Cross-talk Set? " << IsCrossTalkSet() << std::endl;
177 out << str.str();
178}
179
181{
182 rhs.Copy(*this);
183 return *this;
184}
185
186std::vector<TDetectorHit*>& TFipps::GetAddbackVector()
187{
188 return fAddbackHits;
189}
190
191std::vector<UShort_t>& TFipps::GetAddbackFragVector()
192{
193 return fAddbackFrags;
194}
195
196std::vector<TDetectorHit*>& TFipps::GetSuppressedVector()
197{
198 return fSuppressedHits;
199}
200
201std::vector<TDetectorHit*>& TFipps::GetSuppressedAddbackVector()
202{
204}
205
207{
209}
210
215
220
225
230
231void TFipps::SetAddback(const Bool_t flag) const
232{
234}
235
236void TFipps::SetCrossTalk(const Bool_t flag) const
237{
239}
240
241void TFipps::SetSuppressed(const Bool_t flag) const
242{
244}
245
246void TFipps::SetSuppressedAddback(const Bool_t flag) const
247{
249}
250
252{
253 try {
254 if(!IsCrossTalkSet()) {
255 FixCrossTalk();
256 }
257 return static_cast<TFippsHit*>(Hits().at(i));
258 } catch(const std::out_of_range& oor) {
259 std::cerr << ClassName() << " Hits are out of range: " << oor.what() << std::endl;
260 if(!gInterpreter) {
261 throw grsi::exit_exception(1);
262 }
263 }
264 return nullptr;
265}
266
268{
269 try {
270 if(!IsCrossTalkSet()) {
271 FixCrossTalk();
272 }
273 return static_cast<TFippsHit*>(fSuppressedHits.at(i));
274 } catch(const std::out_of_range& oor) {
275 std::cerr << ClassName() << "Suppressed hits are out of range: " << oor.what() << std::endl;
276 if(!gInterpreter) {
277 throw grsi::exit_exception(1);
278 }
279 }
280 return nullptr;
281}
282
284{
285 /// Automatically builds the suppressed hits using the fSuppressionCriterion and returns the number of suppressed hits
286 if(!IsCrossTalkSet()) {
287 // Calculate Cross Talk on each hit
288 FixCrossTalk();
289 }
290 auto& hit_vec = GetHitVector();
291 auto& sup_vec = GetSuppressedVector();
292 if(hit_vec.empty()) {
293 return 0;
294 }
295 // if the suppressed has been reset, clear the suppressed hits
296 if(!IsSuppressed()) {
297 for(auto& hit : sup_vec) {
298 delete hit;
299 }
300 sup_vec.clear();
301 }
302 if(sup_vec.empty()) {
303 CreateSuppressed(bgo, hit_vec, sup_vec);
304 SetSuppressed(true);
305 }
306
307 return sup_vec.size();
308}
309
311{
312 // Automatically builds the addback hits using the fAddbackCriterion (if
313 // the size of the fAddbackHits vector is zero) and return the number of
314 // addback hits.
315 if(!IsCrossTalkSet()) {
316 FixCrossTalk();
317 }
318 auto& hit_vec = GetHitVector();
319 auto& ab_vec = GetAddbackVector();
320 auto& frag_vec = GetAddbackFragVector();
321 if(hit_vec.empty()) {
322 return 0;
323 }
324
325 // if the addback has been reset, clear the addback hits
326 if(!IsAddbackSet()) {
327 for(auto& hit : ab_vec) {
328 delete hit;
329 }
330 ab_vec.clear();
331 frag_vec.clear();
332 }
333 if(ab_vec.empty()) {
334 CreateAddback(hit_vec, ab_vec, frag_vec);
335 SetAddback(true);
336 }
337
338 return ab_vec.size();
339}
340
342{
343 // Automatically builds the addback hits using the fAddbackCriterion (if
344 // the size of the fAddbackHits vector is zero) and return the number of
345 // addback hits.
346 if(!IsCrossTalkSet()) {
347 FixCrossTalk();
348 }
349 auto& hit_vec = GetHitVector();
350 auto& ab_vec = GetSuppressedAddbackVector();
351 auto& frag_vec = GetSuppressedAddbackFragVector();
352 if(hit_vec.empty()) {
353 return 0;
354 }
355
356 // if the addback has been reset, clear the addback hits
358 for(auto& hit : ab_vec) {
359 delete hit;
360 }
361 ab_vec.clear();
362 frag_vec.clear();
363 }
364 if(ab_vec.empty()) {
365 CreateSuppressedAddback(bgo, hit_vec, ab_vec, frag_vec);
367 }
368
369 return ab_vec.size();
370}
371
373{
374 try {
375 if(!IsCrossTalkSet()) {
376 FixCrossTalk();
377 }
378 return static_cast<TFippsHit*>(GetAddbackVector().at(i));
379 } catch(const std::out_of_range& oor) {
380 std::cerr << ClassName() << " Addback hits are out of range: " << oor.what() << std::endl;
381 if(!gInterpreter) {
382 throw grsi::exit_exception(1);
383 }
384 }
385 return nullptr;
386}
387
389{
390 try {
391 if(!IsCrossTalkSet()) {
392 FixCrossTalk();
393 }
394 return static_cast<TFippsHit*>(GetSuppressedAddbackVector().at(i));
395 } catch(const std::out_of_range& oor) {
396 std::cerr << ClassName() << " Suppressed addback hits are out of range: " << oor.what() << std::endl;
397 if(!gInterpreter) {
398 throw grsi::exit_exception(1);
399 }
400 }
401 return nullptr;
402}
403
404void TFipps::AddFragment(const std::shared_ptr<const TFragment>& frag, TChannel* chan)
405{
406 // Builds the FIPPS Hits directly from the TFragment. Basically, loops through the hits for an event and sets
407 // observables.
408 // This is done for both FIPPS and it's suppressors.
409 if(frag == nullptr || chan == nullptr) {
410 return;
411 }
412
413 switch(chan->GetMnemonic()->SubSystem()) {
415 auto hit = new TFippsHit(*frag);
416 Hits().push_back(hit);
417 } break;
418 default:
419 break;
420 };
421}
422
423TVector3 TFipps::GetPosition(int DetNbr, int CryNbr, double dist)
424{
425 // Gets the position vector for a crystal specified by CryNbr within Clover DetNbr at a distance of dist mm away.
426 // This is calculated to the most likely interaction point within the crystal.
427 if(DetNbr > 16) {
428 return TVector3(0, 0, 1);
429 }
430
431 TVector3 CloverPosition(gCloverPosition[DetNbr]);
432
433 // XAxis: Array's Port
434 // YAxis: Upwards
435 // ZAxis: Points in the neutron beam direction
436
437 // Interaction points may eventually be set externally. May make these members of each crystal, or pass from
438 // waveforms.
439 Double_t cp = 17.678; //25.0; // Crystal Center Point mm. (diameter 50mm)
440 Double_t id = 40.0; // Crystal interaction depth mm. (length 80mm)
441 // Set Theta's of the center of each DETECTOR face
442 ////Define one Detector position
443 TVector3 CrystalPosition;
444 switch(CryNbr) {
445 case 0: CrystalPosition.SetXYZ(-cp, cp, id); break; // BLUE
446 case 1: CrystalPosition.SetXYZ(cp, cp, id); break; // GREEN
447 case 2: CrystalPosition.SetXYZ(cp, -cp, id); break; // RED
448 case 3: CrystalPosition.SetXYZ(-cp, -cp, id); break; // WHITE
449 default: CrystalPosition.SetXYZ(0, 0, 1); break;
450 };
451 // Rotate counterclockwise from the downstream position
452 CrystalPosition.RotateY(CloverPosition.Theta());
453 // Rotate around the neutron beam
454 CrystalPosition.RotateZ(CloverPosition.Phi());
455 // Set distance of detector from target
456 CloverPosition.SetMag(dist);
457
458 return (CloverPosition + CrystalPosition);
459}
460
462{
463 fFippsBits = 0;
464}
465
467{
468 SetAddback(false);
469 SetCrossTalk(false);
470 for(auto& hit : GetAddbackVector()) {
471 delete hit;
472 }
473 GetAddbackVector().clear();
474 GetAddbackFragVector().clear();
475}
476
478{
479 SetSuppressed(false);
480 for(auto& hit : GetSuppressedVector()) {
481 delete hit;
482 }
483 GetSuppressedVector().clear();
484}
485
487{
489 SetCrossTalk(false);
490 for(auto& hit : GetSuppressedAddbackVector()) {
491 delete hit;
492 }
495}
496
497UShort_t TFipps::GetNAddbackFrags(const size_t& idx)
498{
499 // Get the number of addback "fragments" contributing to the total addback hit
500 // with index idx.
501 if(idx < GetAddbackFragVector().size()) {
502 return GetAddbackFragVector().at(idx);
503 }
504 return 0;
505}
506
507void TFipps::SetBitNumber(enum EFippsBits bit, Bool_t set) const
508{
509 // Used to set the flags that are stored in TFipps.
510 fFippsBits.SetBit(bit, set);
511}
512
513Double_t TFipps::CTCorrectedEnergy(const TFippsHit* const hit_to_correct, const TFippsHit* const other_hit,
514 Bool_t time_constraint)
515{
516 /// Corrects the energy of the hit to correct by ADDING the uncorrected energy of the other hit times the parameter for this combination
517 /// This is different to the very similar TGriffin function that SUBTRACTS instead of ADDING.
518 /// If time_constraint is true it also checks that the two hits are within the addback window to each other.
519 if((hit_to_correct == nullptr) || (other_hit == nullptr)) {
520 std::cerr << "One of the hits is invalid in TFipps::CTCorrectedEnergy" << std::endl;
521 return 0;
522 }
523
524 if(time_constraint) {
525 // Figure out if this passes the selected window
526 if(TMath::Abs(other_hit->GetTime() - hit_to_correct->GetTime()) >
527 TGRSIOptions::AnalysisOptions()->AddbackWindow()) { // placeholder
528 return hit_to_correct->GetEnergy();
529 }
530 }
531
532 if(hit_to_correct->GetDetector() != other_hit->GetDetector()) {
533 return hit_to_correct->GetEnergy();
534 }
535 static bool been_warned[256] = {false};
536 double fixed_energy = hit_to_correct->GetEnergy();
537 try {
538 if(hit_to_correct->GetChannel() != nullptr) {
539 fixed_energy -= hit_to_correct->GetChannel()->GetCTCoeff().at(other_hit->GetCrystal()) * other_hit->GetNoCTEnergy();
540 }
541 } catch(const std::out_of_range& oor) {
542 int id = 16 * hit_to_correct->GetDetector() + 4 * hit_to_correct->GetCrystal() + other_hit->GetCrystal();
543 if(!been_warned[id]) {
544 been_warned[id] = true;
545 std::cerr << DRED << "Missing CT correction for Det: " << hit_to_correct->GetDetector()
546 << " Crystals: " << hit_to_correct->GetCrystal() << " " << other_hit->GetCrystal() << " (id " << id << ")" << RESET_COLOR << std::endl;
547 }
548 return hit_to_correct->GetEnergy();
549 }
550
551 return fixed_energy;
552}
553
555{
556 if(!TGRSIOptions::AnalysisOptions()->IsCorrectingCrossTalk()) return;
557
558 auto hit_vec = GetHitVector();
559 if(hit_vec.size() < 2) {
560 SetCrossTalk(true);
561 return;
562 }
563 for(auto& hit : hit_vec) {
564 static_cast<TFippsHit*>(hit)->ClearEnergy();
565 }
566
567 if(TGRSIOptions::AnalysisOptions()->IsCorrectingCrossTalk()) {
568 for(auto& one : hit_vec) {
569 for(auto& two : hit_vec) {
570 if(one == two) continue;
571 one->SetEnergy(TFipps::CTCorrectedEnergy(static_cast<TFippsHit*>(one), static_cast<TFippsHit*>(two)));
572 }
573 }
574 }
575 SetCrossTalk(true);
576}
577
578const char* TFipps::GetColorFromNumber(int number)
579{
580 switch(number) {
581 case 0: return "R";
582 case 1: return "W";
583 case 2: return "B";
584 case 3: return "G";
585 }
586 return "X";
587}
#define DRED
Definition Globals.h:18
#define RESET_COLOR
Definition Globals.h:5
bool DefaultFippsSuppression(const TDetectorHit *hit, const TDetectorHit *bgoHit)
Definition TFipps.cxx:22
bool DefaultFippsAddback(const TDetectorHit *one, const TDetectorHit *two)
Definition TFipps.cxx:14
double SuppressionWindow() const
double AddbackWindow() const
double SuppressionEnergy() const
Definition TBgo.h:22
std::vector< double > GetCTCoeff() const
Definition TChannel.h:197
const TMnemonic * GetMnemonic() const
virtual double GetEnergy(Option_t *opt="") const
virtual Int_t GetCrystal() const
!
TChannel * GetChannel() const
!
virtual Int_t GetDetector() const
!
virtual Double_t GetTime(const ETimeFlag &correct_flag=ETimeFlag::kAll, Option_t *opt="") const
Returns a time value to the nearest nanosecond!
virtual Short_t GetMultiplicity() const
Definition TDetector.h:73
virtual const std::vector< TDetectorHit * > & GetHitVector() const
Definition TDetector.h:75
std::vector< TDetectorHit * > & Hits()
Definition TDetector.h:78
Double_t GetNoCTEnergy(Option_t *opt="") const
std::vector< TDetectorHit * > & GetAddbackVector()
!
Definition TFipps.cxx:186
std::vector< UShort_t > & GetAddbackFragVector()
!
Definition TFipps.cxx:191
UShort_t GetNAddbackFrags(const size_t &idx)
Definition TFipps.cxx:497
TFipps & operator=(const TFipps &)
!
Definition TFipps.cxx:180
Bool_t TestBitNumber(EFippsBits bit) const
Definition TFipps.h:122
std::vector< UShort_t > fAddbackFrags
! Number of crystals involved in creating the addback hit
Definition TFipps.h:110
static TVector3 GetPosition(int DetNbr, int CryNbr=5, double dist=90.0)
!
Definition TFipps.cxx:423
TFippsHit * GetSuppressedHit(const int &i)
Definition TFipps.cxx:267
std::vector< TDetectorHit * > fSuppressedAddbackHits
! Used to create suppressed addback hits on the fly
Definition TFipps.h:112
static std::function< bool(const TDetectorHit *, const TDetectorHit *)> fSuppressionCriterion
Definition TFipps.h:102
std::vector< UShort_t > fSuppressedAddbackFrags
! Number of crystals involved in creating the suppressed addback hit
Definition TFipps.h:113
void Copy(TObject &) const override
!
Definition TFipps.cxx:113
TFippsHit * GetAddbackHit(const int &i)
Definition TFipps.cxx:372
void ResetSuppressed()
Definition TFipps.cxx:477
void SetCrossTalk(bool flag=true) const
Definition TFipps.cxx:236
bool IsAddbackSet() const
Definition TFipps.cxx:211
TFipps()
Definition TFipps.cxx:95
TFippsHit * GetFippsHit(const Int_t &i)
Definition TFipps.cxx:251
Int_t GetSuppressedAddbackMultiplicity(const TBgo *bgo)
Definition TFipps.cxx:341
void ClearStatus() const
!
Definition TFipps.h:120
TTransientBits< UChar_t > fFippsBits
Definition TFipps.h:107
static const char * GetColorFromNumber(int number)
Definition TFipps.cxx:578
bool IsSuppressed() const
Definition TFipps.cxx:221
~TFipps() override
Definition TFipps.cxx:130
std::vector< TDetectorHit * > & GetSuppressedAddbackVector()
Definition TFipps.cxx:201
void ResetSuppressedAddback()
Definition TFipps.cxx:486
TFippsHit * GetSuppressedAddbackHit(const int &i)
Definition TFipps.cxx:388
std::vector< TDetectorHit * > & GetSuppressedVector()
Definition TFipps.cxx:196
void SetBitNumber(EFippsBits bit, Bool_t set) const
Definition TFipps.cxx:507
void SetSuppressedAddback(bool flag=true) const
Definition TFipps.cxx:246
bool IsSuppressedAddbackSet() const
Definition TFipps.cxx:226
Bool_t IsCrossTalkSet() const
Definition TFipps.cxx:216
static Double_t CTCorrectedEnergy(const TFippsHit *const hit_to_correct, const TFippsHit *const other_hit, Bool_t time_constraint=true)
Definition TFipps.cxx:513
void SetSuppressed(bool flag=true) const
Definition TFipps.cxx:241
std::vector< TDetectorHit * > fSuppressedHits
! Used to create suppressed hits on the fly
Definition TFipps.h:111
void FixCrossTalk()
Definition TFipps.cxx:554
static TVector3 gCloverPosition[17]
! Position of each HPGe Clover
Definition TFipps.h:38
static std::function< bool(const TDetectorHit *, const TDetectorHit *)> fAddbackCriterion
Definition TFipps.h:101
void ResetFlags() const
Definition TFipps.cxx:461
void SetAddback(bool flag=true) const
Definition TFipps.cxx:231
Int_t GetSuppressedMultiplicity(const TBgo *bgo)
Definition TFipps.cxx:283
void Clear(Option_t *opt="all") override
!
Definition TFipps.cxx:140
void ResetAddback()
Definition TFipps.cxx:466
std::vector< UShort_t > & GetSuppressedAddbackFragVector()
Definition TFipps.cxx:206
EFippsBits
Definition TFipps.h:34
std::vector< TDetectorHit * > fAddbackHits
! Used to create addback hits on the fly
Definition TFipps.h:109
Int_t GetAddbackMultiplicity()
Definition TFipps.cxx:310
void Print(Option_t *opt="") const override
!
Definition TFipps.cxx:157
void AddFragment(const std::shared_ptr< const TFragment > &, TChannel *) override
!
Definition TFipps.cxx:404
static TAnalysisOptions * AnalysisOptions()
virtual EMnemonic SubSystem() const
Definition TMnemonic.h:61
void Clear(Option_t *opt="all") override
!
void Copy(TObject &) const override
!
void CreateAddback(const std::vector< T * > &hits, std::vector< T * > &addbacks, std::vector< UShort_t > &nofFragments)
Definition TSuppressed.h:38
void CreateSuppressed(const TBgo *bgo, const std::vector< T * > &hits, std::vector< T * > &suppressedHits)
Definition TSuppressed.h:69
void CreateSuppressedAddback(const TBgo *bgo, const std::vector< T * > &hits, std::vector< T * > &addbacks, std::vector< UShort_t > &nofFragments)
Definition TSuppressed.h:94
void SetBit(T bit, Bool_t flag)