Ejemplo n.º 1
0
double Qjets::d_ij(const fastjet::PseudoJet& v1,const  fastjet::PseudoJet& v2){
  double p1 = v1.perp();
  double p2 = v2.perp();
  double ret = pow(min(p1,p2),_exp_min) * pow(max(p1,p2),_exp_max) * v1.squared_distance(v2);
  assert(!isnan((float)ret));
  return ret;
}
Ejemplo n.º 2
0
double Qjets::d_ij(const fastjet::PseudoJet& v1,const  fastjet::PseudoJet& v2) {
    double p1 = v1.perp();
    double p2 = v2.perp();

    // small fix here -- nhan
//    double ret = pow(min(p1,p2),_exp_min) * pow(max(p1,p2),_exp_max) * v1.squared_distance(v2);
    double ret = pow(10.,-5.);
    if(v1.squared_distance(v2) != 0.) {
        ret = pow(min(p1,p2),_exp_min) * pow(max(p1,p2),_exp_max) *
              v1.squared_distance(v2);
    }

    assert(!std::isnan(ret));
    return ret;
}
Ejemplo n.º 3
0
void ISRboost(fastjet::PseudoJet& bj1,fastjet::PseudoJet& bj2,
				const fastjet::PseudoJet& j1,
				const vector<int>& candidates,
				fastjet::ClusterSequence & cs,
				const vector<int>& beam_particles,
				double* boostzVec,double *boostxyVec
				){

			  double q0=bj1.E()+bj2.E();
			  double q2=q0*q0;
			  double k0_rec=q0-j1.E();
			  double keith_beta=j1.pz()/k0_rec;
			  double krec2=j1.px()*j1.px()+j1.py()*j1.py()+j1.pz()*j1.pz();
			  double krec=sqrt(krec2);
			  double recMass2=k0_rec*k0_rec-krec2;
				boostzVec[0]=0;boostzVec[1]=0;boostzVec[2]=keith_beta;

			  double jperp=j1.perp();
			double Keith_norm=sqrt(recMass2+jperp*jperp);

			double boostx=-j1.px()/Keith_norm;
			double boosty=-j1.py()/Keith_norm;
			boostxyVec[0]=-boostx;boostxyVec[1]=-boosty;boostxyVec[2]=0;



			TLorentzVector q(-j1.px(),-j1.py(),-j1.pz(),-j1.E());
			TLorentzVector m1(bj1.px(),bj1.py(),bj1.pz(),bj1.E());
			TLorentzVector m2(bj2.px(),bj2.py(),bj2.pz(),bj2.E());
			q=q+m1+m2;
			NAMED_DEBUG("BOOST",
				std::cout << "q0: " << q0 << " keith_beta: " << keith_beta <<  std::endl ;
				std::cout << "rebM2: " << recMass2 << std::endl ;
				std::cout << "keith norm: " << Keith_norm << std::endl ;
			)