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