1#include "CalibData/Mdc/MdcCalibData.h"
3#include "GaudiKernel/MsgStream.h"
8 newXtTreesArray = NULL;
10 for(
int layid=0; layid<43; layid++){
12 for(
int entr=0; entr<18; entr++){
13 for(
int lr=0; lr<2; lr++){
14 m_newxt[layid][entr][lr] = NULL;
21 for(
int layid=0; layid<43; layid++){
23 for(
int entr=0; entr<18; entr++){
24 for(
int lr=0; lr<2; lr++){
25 if(m_newxt[layid][entr][lr]!=NULL)
delete m_newxt[layid][entr][lr];
29 if(newXtTreesBuf!=NULL) newXtTreesBuf->Clear();
30 if(r2tTreesBuf!=NULL) r2tTreesBuf->Clear();
31 if(newXtTreesArray!=NULL)
delete newXtTreesArray;
32 if(r2tTreesArray!=NULL)
delete r2tTreesArray;
38 std::cout<<
"\n"<<
"here is the update in the MdcCalConst"<<std::endl;
41 m_xtmap = other1.m_xtmap;
43 m_delt0 = other1.m_delt0;
44 m_qtpar0 = other1.m_qtpar0;
45 m_qtpar1 = other1.m_qtpar1;
46 m_sdmap = other1.m_sdmap;
47 return StatusCode::SUCCESS;
51 m_xtmap.insert(
valType(
int(xtkey), val) );
56 TBufferFile* tempBuf =
new TBufferFile(TBuffer::kWrite);
57 newXtTrees->Streamer(*tempBuf);
60 newXtTreesBuf =
new TBufferFile(TBuffer::kRead);
61 newXtTreesBuf->SetBuffer(tempBuf->Buffer(), tempBuf->BufferSize());
63 newXtTreesArray =
new TObjArray();
64 newXtTreesArray->Streamer(*newXtTreesBuf);
65 for(
int layid=0; layid<43; layid++){
66 for(
int entr=0; entr<18; entr++){
67 for(
int lr=0; lr<2; lr++){
68 char newXtTreeName[20];
69 sprintf(newXtTreeName,
"trNewXt%02d_%02d_%d",layid,entr,lr);
70 m_newxt[layid][entr][lr] = (TTree*)newXtTreesArray->FindObject(newXtTreeName);;
79 TBufferFile* tempBuf =
new TBufferFile(TBuffer::kWrite);
80 r2tTrees->Streamer(*tempBuf);
83 r2tTreesBuf =
new TBufferFile(TBuffer::kRead);
84 r2tTreesBuf->SetBuffer(tempBuf->Buffer(), tempBuf->BufferSize());
86 r2tTreesArray =
new TObjArray();
87 r2tTreesArray->Streamer(*r2tTreesBuf);
88 for(
int layid=0; layid<43; layid++){
90 sprintf(r2tTreeName,
"r2t%02d",layid);
91 m_r2t[layid] = (TTree*)r2tTreesArray->FindObject(r2tTreeName);;
97 m_t0.push_back( val );
100 m_delt0.push_back( val );
104 m_qtpar0.push_back( val );
108 m_qtpar1.push_back( val );
112 m_sdmap.insert(
valType(
int(sdkey), val) );
117 double xtpar = -999.0;
119 if( 1 == m_xtmap.count(
key) )
120 xtpar = m_xtmap[
key];
127 return m_newxt[layid][entr][lr];
137 double sdpar = -999.0;
139 if( 1 == m_sdmap.count(
key) ){
150 key = ( (layid << XTLAYER_INDEX) & XTLAYER_MASK ) |
151 ( (entr << XTENTRA_INDEX) & XTENTRA_MASK ) |
152 ( (lr << XTLR_INDEX) & XTLR_MASK ) |
153 ( (order << XTORDER_INDEX) & XTORDER_MASK );
162 key = ( (layid << SDLAYER_INDEX) & SDLAYER_MASK ) |
163 ( (entr << SDENTRA_INDEX) & SDENTRA_MASK ) |
164 ( (lr << SDLR_INDEX) & SDLR_MASK ) |
165 ( (
bin << SDBIN_INDEX) & SDBIN_MASK );
171 m_xtiter = m_xtmap.begin();
175 if( m_xtiter != m_xtmap.end() ){
176 key = (*m_xtiter).first;
177 xtpar = (*m_xtiter).second;
185 m_sditer = m_sdmap.begin();
189 if( m_sditer != m_sdmap.end() ){
190 key = (*m_sditer).first;
191 sdpar = (*m_sditer).second;
std::map< int, double >::value_type valType
*******INTEGER m_nBinMax INTEGER m_NdiMax !No of bins in histogram for cell exploration division $ !Last vertex $ !Last active cell $ !Last cell in buffer $ !No of sampling when dividing cell $ !No of function total $ !Flag for random ceel for $ !Flag for type of for WtMax $ !Flag which decides whether vertices are included in the sampling $ entire domain is hyp !Maximum effective eevents per bin
*************DOUBLE PRECISION m_pi *DOUBLE PRECISION m_HvecTau2 DOUBLE PRECISION m_HvClone2 DOUBLE PRECISION m_gamma1 DOUBLE PRECISION m_gamma2 DOUBLE PRECISION m_thet1 DOUBLE PRECISION m_thet2 INTEGER m_IFPHOT *COMMON c_Taupair $ !Spin Polarimeter vector first Tau $ !Spin Polarimeter vector second Tau $ !Clone Spin Polarimeter vector first Tau $ !Clone Spin Polarimeter vector second Tau $ !Random Euler angle for cloning st tau $ !Random Euler angle for cloning st tau $ !Random Euler angle for cloning st tau $ !Random Euler angle for cloning nd tau $ !Random Euler angle for cloning nd tau $ !Random Euler angle for cloning nd tau $ !phi of HvecTau1 $ !theta of HvecTau1 $ !phi of HvecTau2 $ !theta of HvecTau2 $ !super key
virtual StatusCode update(CalibBase1 &obj, MsgStream *)
void setR2tpar(TObjArray *r2tTrees)
void setQtpar1(double val)
void setXtpar(int xtkey, double val)
void setNewXtpar(TObjArray *newXtTrees)
int getNextXtpar(int &key, double &xtpar)
virtual StatusCode update(CalibBase1 &other, MsgStream *log)
double getXtpar(int layid, int entr, int lr, int order)
TTree * getR2tpar(int layid)
void setSdpar(int sdkey, double val)
void setDelT0(double val)
double getSdpar(int layid, int entr, int lr, int bin)
int getXtKey(int layid, int entr, int lr, int order)
int getNextSdpar(int &key, double &sdpar)
int getSdKey(int layid, int entr, int lr, int bin)
TTree * getNewXtpar(int layid, int entr, int lr)
void setQtpar0(double val)
sprintf(cut,"kal_costheta0_em>-0.93&&kal_costheta0_em<0.93&&kal_pxy0_em>=0.05+%d*0.1&&kal_pxy0_em<0.15+%d*0.1&&NGch>=2", j, j)