Commit 828749f2 authored by Frank Krauss's avatar Frank Krauss

Added a new method, some minor output changes.

parent 86d8de41
#include "ATOOLS/Org/SVN_Info.H"
static ATOOLS::SVN_Info initializer
("AHADIC++/Decays","trunk/SHERPA","31666","a996e1db8b65efc861a3d529d779a078");
#include "ATOOLS/Org/SVN_Info.H"
static ATOOLS::SVN_Info initializer
("AHADIC++/Formation","trunk/SHERPA","31666","be09de7e4768456401f2b4e8fb53e6db");
......@@ -52,10 +52,11 @@ Return_Value::code Ahadic::Hadronize(Blob_List * blobs)
blobs->ColorConservation();
msg_Tracking()<<"ERROR in "<<METHOD<<" :\n"
<<" Hadronization for blob "
<<"("<<blob<<"; "
<<"("<<blobs<<"; "
<<blob->NInP()<<" -> "<<blob->NOutP()<<") "
<<"did not work out,\n"
<<" will trigger retrying the event.\n";
<<" will trigger retrying the event:\n"
<<(*blobs);
CleanUp(blob);
if (rpa->gen.Beam1().IsLepton() ||
rpa->gen.Beam2().IsLepton()) {
......@@ -78,15 +79,11 @@ Return_Value::code Ahadic::Hadronize(Blob_List * blobs)
Return_Value::code Ahadic::Hadronize(Blob * blob, int retry) {
Reset();
//msg_Out()<<"============================================================\n"
// <<"============================================================\n"
// <<"============================================================\n";
m_totmom = blob->CheckMomentumConservation();
if (!ExtractSinglets(blob) || !ShiftBeamParticles() || !CheckSinglets() ||
!DecayGluons() ||!DecayClusters()) {
msg_Error()<<"ERROR in "<<METHOD<<" (formation): Will retry event.\n"
msg_Error()<<"ERROR in "<<METHOD<<": Will retry event!\n"
<<(*blob);
//exit(1);
Reset(blob);
return Return_Value::Retry_Event;
}
......@@ -102,7 +99,6 @@ Return_Value::code Ahadic::Hadronize(Blob * blob, int retry) {
Reset(blob);
return Return_Value::Retry_Event;
}
//msg_Out()<<(*blob)<<"\n";
return Return_Value::Success;
}
......
#include "ATOOLS/Org/SVN_Info.H"
static ATOOLS::SVN_Info initializer
("AHADIC++/Main","trunk/SHERPA","31666","6aec0d693c797d36f254e1137a42f6f9");
......@@ -41,8 +41,8 @@ void Double_Transitions::FillMap(Single_Transitions * singletransitions)
if (pair.second.Kfcode()==4) weight *= m_charm_baryon_modifier;
if (pair.first.Kfcode()==5) weight *= m_beauty_baryon_modifier;
if (pair.second.Kfcode()==5) weight *= m_beauty_baryon_modifier;
msg_Out()<<METHOD<<"["<<pair.first<<", "<<pair.second<<"] "
<<"for popped diquark; weight = "<<weight<<".\n";
//msg_Out()<<METHOD<<"["<<pair.first<<", "<<pair.second<<"] "
// <<"for popped diquark; weight = "<<weight<<".\n";
}
if (m_transitions.find(pair)==m_transitions.end())
m_transitions[pair] = new Double_Transition_List;
......
#include "ATOOLS/Org/SVN_Info.H"
static ATOOLS::SVN_Info initializer
("AHADIC++/Tools","trunk/SHERPA","31666M","e6a2bd38058515655aa4a0b9aba59881");
......@@ -258,7 +258,8 @@ double Soft_Cluster_Handler::Annihilation() {
one.second = one1;
two.first = disc?two2:two1;
two.second = one2;
if (DefineHadronsInAnnihilation(one,two)) return true;
if (DefineHadronsInAnnihilation(one,two) ||
AnnihilateFlavour(one1,one2,two1,two2)) return true;
msg_Error()<<METHOD<<" yields error - no annihilation defined for:\n"
<<(*p_cluster)
<<" Will return false and hope for the best.\n";
......@@ -275,6 +276,50 @@ DiQuarkToQuarks(const Flavour & di,Flavour & q1,Flavour & q2) {
return true;
}
bool Soft_Cluster_Handler::
AnnihilateFlavour(const Flavour & one1,const Flavour & one2,
const Flavour & two1,const Flavour & two2) {
kf_code kf11(one1.Kfcode()),kf12(one2.Kfcode());
kf_code kf21(two1.Kfcode()),kf22(two2.Kfcode());
m_hads[0] = Flavour(kf_photon);;
Flavour_Pair residual;
if (kf12==kf22) {
residual.first = two1; residual.second = one1;
Single_Transition_List * trans = (*p_singletransitions)[residual];
if (trans->rbegin()->first.Mass()<m_mass) {
m_hads[1] = trans->rbegin()->first;
return true;
}
//msg_Out()<<" "<<residual.first<<" + "<<residual.second
// <<" --> "<<trans->rbegin()->first<<"\n";
}
if (kf12==kf21) {
residual.first = two2; residual.second = one1;
Single_Transition_List * trans = (*p_singletransitions)[residual];
if (trans->rbegin()->first.Mass()<m_mass) {
m_hads[1] = trans->rbegin()->first;
return true;
}
}
if (kf11==kf22) {
residual.first = two1; residual.second = one2;
Single_Transition_List * trans = (*p_singletransitions)[residual];
if (trans->rbegin()->first.Mass()<m_mass) {
m_hads[1] = trans->rbegin()->first;
return true;
}
}
if (kf11==kf21) {
residual.first = two2; residual.second = one2;
Single_Transition_List * trans = (*p_singletransitions)[residual];
if (trans->rbegin()->first.Mass()<m_mass) {
m_hads[1] = trans->rbegin()->first;
return true;
}
}
return false;
}
double Soft_Cluster_Handler::
DefineHadronsInAnnihilation(const Flavour_Pair & one,const Flavour_Pair & two) {
Single_Transition_List * ones = (*p_singletransitions)[one];
......
......@@ -36,6 +36,10 @@ namespace AHADIC {
bool FixKinematics();
bool DiQuarkToQuarks(const ATOOLS::Flavour & di,
ATOOLS::Flavour & q1,ATOOLS::Flavour & q2);
bool AnnihilateFlavour(const ATOOLS::Flavour & one1,
const ATOOLS::Flavour & one2,
const ATOOLS::Flavour & two1,
const ATOOLS::Flavour & two2);
double DefineHadronsInAnnihilation(const Flavour_Pair & one,
const Flavour_Pair & two);
bool TreatSingletCluster();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment