ClassImp(AliHBTPair)
-//value of rev
/************************************************************************/
-AliHBTPair::AliHBTPair(Bool_t rev)
+AliHBTPair::AliHBTPair(Bool_t rev):
+ fPart1(0x0),
+ fPart2(0x0)
{
//value of rev defines if it is Swaped
//if you pass kTRUE swpaped pair will NOT be created
}
/************************************************************************/
+
+AliHBTPair::AliHBTPair(AliHBTParticle* part1, AliHBTParticle* part2, Bool_t rev):
+ fPart1(part1),
+ fPart2(part2)
+ {
+//value of rev defines if it is Swaped
+//if you pass kTRUE swpaped pair will NOT be created
+//though you wont be able to get the swaped pair from this pair
+
+ if(!rev) fSwapedPair = new AliHBTPair(part2,part1,kTRUE); //if false create swaped pair
+ else fSwapedPair = 0x0; //if true set the pointer to NULL
+
+ }
+/************************************************************************/
+
Double_t AliHBTPair::GetInvMass()
{
//Returns qinv value for a pair
{
public:
AliHBTPair(Bool_t rev = kFALSE); //contructor
+ AliHBTPair(AliHBTParticle* part1, AliHBTParticle* part2, Bool_t rev = kFALSE); //contructor
virtual ~AliHBTPair(){}
void SetParticles(AliHBTParticle*,AliHBTParticle*); //sets particles in the pair
AliHBTPair* GetSwapedPair() {return fSwapedPair;} //returns pair with swapped particles
AliHBTParticle* Particle1() const {return fPart1;} //returns pointer to first particle
AliHBTParticle* Particle2() const {return fPart2;} //returns pointer to decond particle
+ void Changed();
//Center Mass System - Longitudinally Comoving
Double_t GetInvMass(); //returns invariant mass of the pair
-
-
+
+
Double_t GetQInv(); //returns Q invariant
Double_t GetQSideCMSLC(); //returns Q Side CMS longitudionally co-moving
Double_t GetQOutCMSLC(); //returns Q out CMS longitudionally co-moving
fPart2 = p2;
if (fSwapedPair) //if we have Swaped (so we are not)
fSwapedPair->SetParticles(p2,p1); //set particles for him too
-
- // Resel all calculations (flags)
+ Changed();
+ //and do nothing until will be asked for
+}
+/****************************************************************/
+inline
+void AliHBTPair::Changed()
+{
+ // Resel all calculations (flags)
fChanged = kTRUE;
fSumsNotCalc = kTRUE;
fDiffsNotCalc = kTRUE;
fKtNotCalc = kTRUE;
fKStarNotCalc = kTRUE;
fQInvLNotCalc = kTRUE;
-
- //and do nothing until will be asked for
}
/****************************************************************/
-/****************************************************************/
inline
void AliHBTPair::CalculateInvMassSqr()
{