BOSS 7.0.3
BESIII Offline Software System
Loading...
Searching...
No Matches
Tof/tofcalgsec/tofcalgsec-00-02-21/tofcalgsec/calib_barrel_left.h
Go to the documentation of this file.
1#ifndef CALIB_BARREL_LEFT_H
2#define CALIB_BARREL_LEFT_H
3
4#include "tofcalgsec/TofCalib.h"
5
6const int nBarrelLeft = 7;
7
8class calib_barrel_left:public TofCalib {
9 public:
11 m_name = string("calib_barrel_left");
12 }
13
14 void calculate_funcs( const Record* r ) {
15 double q = r->qleft();
16 double z = r->zrhit();
17
18 if( q<0.0 ) {
19 for( int i=0; i<nBarrelLeft; i++ ) {
20 funcs[i] = 0.0;
21 }
22 }
23 else {
24 funcs[0] = 1.0;
25 funcs[1] = 1./sqrt(q);
26 funcs[2] = z/sqrt(q);
27 funcs[3] = 1.0/q;
28 funcs[4] = z;
29 funcs[5] = z*z;
30 funcs[6] = z*z*z;
31 }
32
33 return;
34 }
35
36 void calculate_y(const Record* r) {
37 y = r->tleft() - r->texp();
38 return;
39 }
40
42 if( data->size() > 0 ) {
43 std::vector<Record*>::iterator iter = data->begin();
44 for( ; iter!=data->end(); iter++ ) {
46 double tcorr = 0.0;
47 for( int i=0; i<X.num_row(); i++ ) {
48 tcorr += X[i]*funcs[i];
49 }
50 (*iter)->settleft( (*iter)->tleft() - tcorr - (*iter)->texp() );
51 }
52 }
53 return;
54 }
55
56};
57
58#endif
TTree * data
EvtStreamInputIterator< typename Generator::result_type > iter(Generator gen, int N=0)
std::vector< Record * > RecordSet
****INTEGER imax DOUBLE PRECISION m_pi *DOUBLE PRECISION m_amfin DOUBLE PRECISION m_Chfin DOUBLE PRECISION m_Xenph DOUBLE PRECISION m_sinw2 DOUBLE PRECISION m_GFermi DOUBLE PRECISION m_MfinMin DOUBLE PRECISION m_ta2 INTEGER m_out INTEGER m_KeyFSR INTEGER m_KeyQCD *COMMON c_Semalib $ !copy of input $ !CMS energy $ !beam mass $ !final mass $ !beam charge $ !final charge $ !smallest final mass $ !Z mass $ !Z width $ !EW mixing angle $ !Gmu Fermi $ alphaQED at q
Definition: KKsem.h:33