12 #ifndef TRIGINDETANALYSISUTILS_TRACKMATCHDELTAR_H
13 #define TRIGINDETANALYSISUTILS_TRACKMATCHDELTAR_H
36 virtual void match(
const std::vector<TIDA::Track*>&
s1,
37 const std::vector<TIDA::Track*>&
s2 )
41 const std::vector<TIDA::Track*>&
ref =
s1;
42 const std::vector<TIDA::Track*>&
test =
s2;
45 for (
int i=
ref.size() ;
i-- ; ) {
54 for (
int j=
test.size() ; j-- ; ) {
58 double R2tmp =
deltaR2( reftrack, testtrack );
61 if ( tmptrack==NULL || R2tmp<R2min ) {
68 if ( tmptrack && R2min<
m_R2 ) {
69 mmatched.insert( map_type::value_type(reftrack,tmptrack) );
70 mrevmatched.insert( map_type::value_type(tmptrack,reftrack) );
72 std::cout <<
"\t\tSUTT matched " << *reftrack <<
"\t -> \t" << *tmptrack <<
"\tDr=" << R2min << std::endl;
79 double deta = reftrack->
eta()-testtrack->
eta();
80 double dphi = reftrack->
phi()-testtrack->
phi();
83 return deta*deta+dphi*dphi;
98 #endif // TRIGINDETANALYSISUTILS_TRACKMATCHDELTAR_H