StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ParityCorrFctn.cxx
1 /***************************************************************************
2  *
3  * Author: Mike Lisa, Ohio State, lisa@mps.ohio-state.edu
4  ***************************************************************************
5  *
6  * Description: part of STAR HBT Framework: StHbtMaker package
7  * this is a special correlation function for Parity Violation studies.
8  * this CorrFctn is special because it interacts with the ParityEventCut
9  * closely. This correlation function has no histograms... the histos
10  * are in the EventCut!!!
11  *
12  ***************************************************************************/
13 
14 #include "StHbtMaker/CorrFctn/ParityCorrFctn.h"
15 //#include "StHbtMaker/Infrastructure/StHbtHisto.hh"
16 #include <cstdio>
17 
18 #ifdef __ROOT__
19 ClassImp(ParityCorrFctn)
20 #endif
21 
22 //____________________________
23 ParityCorrFctn::ParityCorrFctn(ParityEventCut* PEC){
24  mParityEventCut = PEC;
25 }
26 
27 //____________________________
28 ParityCorrFctn::~ParityCorrFctn(){
29  /* noop */
30 }
31 //_________________________
32 void ParityCorrFctn::Finish(){
33  /* noop */
34 }
35 
36 //____________________________
37 StHbtString ParityCorrFctn::Report(){
38  string stemp = "Parity Correlation Function Report:\n Hello there\n";
39  StHbtString returnThis = stemp;
40  return returnThis;
41 }
42 //____________________________
43 void ParityCorrFctn::AddRealPair(const StHbtPair* pair){
44  // this should increment the RealQuantity of the EventCut by (p1 x p2) dot z
45  StHbtThreeVector CrossProd = pair->track1()->FourMomentum().vect().cross(pair->track2()->FourMomentum().vect());
46  mParityEventCut->RealQuantity += CrossProd.z();
47  mParityEventCut->nReals++;
48 }
49 //____________________________
50 void ParityCorrFctn::AddMixedPair(const StHbtPair* pair){
51  StHbtThreeVector CrossProd = pair->track1()->FourMomentum().vect().cross(pair->track2()->FourMomentum().vect());
52  mParityEventCut->MixedQuantity += CrossProd.z();
53  mParityEventCut->nMixed++;
54 }
55 
56