diff --git a/MC/config/PWGDQ/external/generator/GeneratorBeautyToJpsi_EvtGen.C b/MC/config/PWGDQ/external/generator/GeneratorBeautyToJpsi_EvtGen.C deleted file mode 100644 index 05801a67d..000000000 --- a/MC/config/PWGDQ/external/generator/GeneratorBeautyToJpsi_EvtGen.C +++ /dev/null @@ -1,84 +0,0 @@ -// usage (fwdy) : -// o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_fwdy.ini -// usage (midy) : -// o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_midy.ini -// -// -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGDQ/EvtGen) -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGHF/external/generator) -#include "GeneratorEvtGen.C" -#include "GeneratorHF.C" - -FairGenerator* - GeneratorBeautyToJpsi_EvtGenMidY(double rapidityMin = -1.5, double rapidityMax = 1.5, bool ispp = true, bool verbose = false, TString pdgs = "511;521;531;541;5112;5122;5232;5132;5332") -{ - auto gen = new o2::eventgen::GeneratorEvtGen(); - gen->setRapidity(rapidityMin, rapidityMax); - gen->setPDG(5); - TString pathO2table = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/pythia8/decayer/switchOffBhadrons.cfg"); - gen->readFile(pathO2table.Data()); - - gen->setVerbose(verbose); - if (ispp) - gen->setFormula("1"); - else - gen->setFormula("max(1.,120.*(x<5.)+80.*(1.-x/20.)*(x>5.)*(x<11.)+240.*(1.-x/13.)*(x>11.))"); - std::string spdg; - TObjArray* obj = pdgs.Tokenize(";"); - gen->SetSizePdg(obj->GetEntriesFast()); - for (int i = 0; i < obj->GetEntriesFast(); i++) { - spdg = obj->At(i)->GetName(); - gen->AddPdg(std::stoi(spdg), i); - printf("PDG %d \n", std::stoi(spdg)); - } - gen->SetForceDecay(kEvtBJpsiDiElectron); - - // set random seed - gen->readString("Random:setSeed on"); - uint random_seed; - unsigned long long int random_value = 0; - ifstream urandom("/dev/urandom", ios::in|ios::binary); - urandom.read(reinterpret_cast(&random_value), sizeof(random_seed)); - gen->readString(Form("Random:seed = %d", random_value % 900000001)); - - // print debug - // gen->PrintDebug(); - - return gen; -} - -FairGenerator* - GeneratorBeautyToJpsi_EvtGenFwdY(double rapidityMin = -4.3, double rapidityMax = -2.2, bool ispp = true, bool verbose = false, TString pdgs = "511;521;531;541;5112;5122;5232;5132;5332") -{ - auto gen = new o2::eventgen::GeneratorEvtGen(); - gen->setRapidity(rapidityMin, rapidityMax); - gen->setPDG(5); - TString pathO2table = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/pythia8/decayer/switchOffBhadrons.cfg"); - gen->readFile(pathO2table.Data()); - - gen->setVerbose(verbose); - if (ispp) - gen->setFormula("1"); - else - gen->setFormula("max(1.,120.*(x<5.)+80.*(1.-x/20.)*(x>5.)*(x<11.)+240.*(1.-x/13.)*(x>11.))"); - std::string spdg; - TObjArray* obj = pdgs.Tokenize(";"); - gen->SetSizePdg(obj->GetEntriesFast()); - for (int i = 0; i < obj->GetEntriesFast(); i++) { - spdg = obj->At(i)->GetName(); - gen->AddPdg(std::stoi(spdg), i); - printf("PDG %d \n", std::stoi(spdg)); - } - gen->SetForceDecay(kEvtBJpsiDiMuon); - // set random seed - gen->readString("Random:setSeed on"); - uint random_seed; - unsigned long long int random_value = 0; - ifstream urandom("/dev/urandom", ios::in|ios::binary); - urandom.read(reinterpret_cast(&random_value), sizeof(random_seed)); - gen->readString(Form("Random:seed = %d", random_value % 900000001)); - // print debug - // gen->PrintDebug(); - - return gen; -} diff --git a/MC/config/PWGDQ/external/generator/GeneratorBeautyToMu_EvtGen.C b/MC/config/PWGDQ/external/generator/GeneratorBeautyToMu_EvtGen.C deleted file mode 100644 index 76c233ee4..000000000 --- a/MC/config/PWGDQ/external/generator/GeneratorBeautyToMu_EvtGen.C +++ /dev/null @@ -1,47 +0,0 @@ -// usage (fwdy) : -//o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_fwdy.ini -// usage (midy) : -//o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_midy.ini -// -// -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGDQ/EvtGen) -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGHF/external/generator) -#include "GeneratorEvtGen.C" -#include "GeneratorHF.C" - - -FairGenerator* -GeneratorBeautyToMu_EvtGenFwdY(double rapidityMin = -4.3, double rapidityMax = -2.2, bool ispp = true, bool forcedecay = true, bool verbose = false, TString pdgs = "511;521;531;541;5112;5122;5232;5132;5332") -{ - auto gen = new o2::eventgen::GeneratorEvtGen(); - gen->setRapidity(rapidityMin,rapidityMax); - gen->setPDG(5); - TString pathO2table = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/pythia8/decayer/switchOffBhadrons.cfg"); - gen->readFile(pathO2table.Data()); - - gen->setVerbose(verbose); - if(ispp) gen->setFormula("1"); - else gen->setFormula("max(1.,120.*(x<5.)+80.*(1.-x/20.)*(x>5.)*(x<11.)+240.*(1.-x/13.)*(x>11.))"); - std::string spdg; - TObjArray *obj = pdgs.Tokenize(";"); - gen->SetSizePdg(obj->GetEntriesFast()); - for(int i=0; iGetEntriesFast(); i++) { - spdg = obj->At(i)->GetName(); - gen->AddPdg(std::stoi(spdg),i); - printf("PDG %d \n",std::stoi(spdg)); - } - if(forcedecay) gen->SetForceDecay(kEvtSemiMuonic); - else gen->SetForceDecay(kEvtAll); - // set random seed - gen->readString("Random:setSeed on"); - uint random_seed; - unsigned long long int random_value = 0; - ifstream urandom("/dev/urandom", ios::in|ios::binary); - urandom.read(reinterpret_cast(&random_value), sizeof(random_seed)); - gen->readString(Form("Random:seed = %d", random_value % 900000001)); - // print debug - // gen->PrintDebug(); - - return gen; -} - diff --git a/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsiAndJpsi_EvtGen.C b/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsiAndJpsi_EvtGen.C deleted file mode 100644 index 3cae508c6..000000000 --- a/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsiAndJpsi_EvtGen.C +++ /dev/null @@ -1,84 +0,0 @@ -// usage (fwdy) : -// o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_PsiAndJpsi_midy.ini -// usage (midy) : -// o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_PsiAndJpsi_fwdy.ini -// -// -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGDQ/EvtGen) -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGHF/external/generator) -#include "GeneratorEvtGen.C" -#include "GeneratorHF.C" - -FairGenerator* - GeneratorBeautyToPsiAndJpsi_EvtGenMidY(double rapidityMin = -1.5, double rapidityMax = 1.5, bool ispp = true, bool verbose = false, TString pdgs = "511;521;531;541;5112;5122;5232;5132;5332") -{ - auto gen = new o2::eventgen::GeneratorEvtGen(); - gen->setRapidity(rapidityMin, rapidityMax); - gen->setPDG(5); - TString pathO2table = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/pythia8/decayer/switchOffBhadrons.cfg"); - gen->readFile(pathO2table.Data()); - - gen->setVerbose(verbose); - if (ispp) - gen->setFormula("1"); - else - gen->setFormula("max(1.,120.*(x<5.)+80.*(1.-x/20.)*(x>5.)*(x<11.)+240.*(1.-x/13.)*(x>11.))"); - std::string spdg; - TObjArray* obj = pdgs.Tokenize(";"); - gen->SetSizePdg(obj->GetEntriesFast()); - for (int i = 0; i < obj->GetEntriesFast(); i++) { - spdg = obj->At(i)->GetName(); - gen->AddPdg(std::stoi(spdg), i); - printf("PDG %d \n", std::stoi(spdg)); - } - gen->SetForceDecay(kEvtBPsiAndJpsiDiElectron); - - // set random seed - gen->readString("Random:setSeed on"); - uint random_seed; - unsigned long long int random_value = 0; - ifstream urandom("/dev/urandom", ios::in|ios::binary); - urandom.read(reinterpret_cast(&random_value), sizeof(random_seed)); - gen->readString(Form("Random:seed = %d", random_value % 900000001)); - - // print debug - // gen->PrintDebug(); - - return gen; -} - -FairGenerator* - GeneratorBeautyToPsiAndJpsi_EvtGenFwdY(double rapidityMin = -4.3, double rapidityMax = -2.2, bool ispp = true, bool verbose = false, TString pdgs = "511;521;531;541;5112;5122;5232;5132;5332") -{ - auto gen = new o2::eventgen::GeneratorEvtGen(); - gen->setRapidity(rapidityMin, rapidityMax); - gen->setPDG(5); - TString pathO2table = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/pythia8/decayer/switchOffBhadrons.cfg"); - gen->readFile(pathO2table.Data()); - - gen->setVerbose(verbose); - if (ispp) - gen->setFormula("1"); - else - gen->setFormula("max(1.,120.*(x<5.)+80.*(1.-x/20.)*(x>5.)*(x<11.)+240.*(1.-x/13.)*(x>11.))"); - std::string spdg; - TObjArray* obj = pdgs.Tokenize(";"); - gen->SetSizePdg(obj->GetEntriesFast()); - for (int i = 0; i < obj->GetEntriesFast(); i++) { - spdg = obj->At(i)->GetName(); - gen->AddPdg(std::stoi(spdg), i); - printf("PDG %d \n", std::stoi(spdg)); - } - gen->SetForceDecay(kEvtBPsiAndJpsiDiMuon); - // set random seed - gen->readString("Random:setSeed on"); - uint random_seed; - unsigned long long int random_value = 0; - ifstream urandom("/dev/urandom", ios::in|ios::binary); - urandom.read(reinterpret_cast(&random_value), sizeof(random_seed)); - gen->readString(Form("Random:seed = %d", random_value % 900000001)); - // print debug - // gen->PrintDebug(); - - return gen; -} diff --git a/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsi_EvtGen.C b/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsi_EvtGen.C deleted file mode 100644 index 1a0561af5..000000000 --- a/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsi_EvtGen.C +++ /dev/null @@ -1,82 +0,0 @@ -// usage (fwdy) : -// o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_Psi2S_fwdy.ini -// usage (midy) : -// o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_Psi2S_midy.ini -// -// -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGDQ/EvtGen) -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGHF/external/generator) -#include "GeneratorEvtGen.C" -#include "GeneratorHF.C" - -FairGenerator* - GeneratorBeautyToPsi_EvtGenMidY(double rapidityMin = -1.5, double rapidityMax = 1.5, bool ispp = true, bool verbose = false, TString pdgs = "511;521;531;541;5112;5122;5132;5332") -{ - auto gen = new o2::eventgen::GeneratorEvtGen(); - gen->setRapidity(rapidityMin, rapidityMax); - gen->setPDG(5); - TString pathO2table = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/pythia8/decayer/switchOffBhadrons.cfg"); - gen->readFile(pathO2table.Data()); - - gen->setVerbose(verbose); - if (ispp) - gen->setFormula("1"); - else - gen->setFormula("max(1.,120.*(x<5.)+80.*(1.-x/20.)*(x>5.)*(x<11.)+240.*(1.-x/13.)*(x>11.))"); - std::string spdg; - TObjArray* obj = pdgs.Tokenize(";"); - gen->SetSizePdg(obj->GetEntriesFast()); - for (int i = 0; i < obj->GetEntriesFast(); i++) { - spdg = obj->At(i)->GetName(); - gen->AddPdg(std::stoi(spdg), i); - printf("PDG %d \n", std::stoi(spdg)); - } - gen->SetForceDecay(kEvtBPsiDiElectron); - // set random seed - gen->readString("Random:setSeed on"); - uint random_seed; - unsigned long long int random_value = 0; - ifstream urandom("/dev/urandom", ios::in|ios::binary); - urandom.read(reinterpret_cast(&random_value), sizeof(random_seed)); - gen->readString(Form("Random:seed = %d", random_value % 900000001)); - // print debug - // gen->PrintDebug(); - - return gen; -} - -FairGenerator* - GeneratorBeautyToPsi_EvtGenFwdY(double rapidityMin = -4.3, double rapidityMax = -2.2, bool ispp = true, bool verbose = false, TString pdgs = "511;521;531;541;5112;5122;5132;5332") -{ - auto gen = new o2::eventgen::GeneratorEvtGen(); - gen->setRapidity(rapidityMin, rapidityMax); - gen->setPDG(5); - TString pathO2table = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/pythia8/decayer/switchOffBhadrons.cfg"); - gen->readFile(pathO2table.Data()); - - gen->setVerbose(verbose); - if (ispp) - gen->setFormula("1"); - else - gen->setFormula("max(1.,120.*(x<5.)+80.*(1.-x/20.)*(x>5.)*(x<11.)+240.*(1.-x/13.)*(x>11.))"); - std::string spdg; - TObjArray* obj = pdgs.Tokenize(";"); - gen->SetSizePdg(obj->GetEntriesFast()); - for (int i = 0; i < obj->GetEntriesFast(); i++) { - spdg = obj->At(i)->GetName(); - gen->AddPdg(std::stoi(spdg), i); - printf("PDG %d \n", std::stoi(spdg)); - } - gen->SetForceDecay(kEvtBPsiDiMuon); - // set random seed - gen->readString("Random:setSeed on"); - uint random_seed; - unsigned long long int random_value = 0; - ifstream urandom("/dev/urandom", ios::in|ios::binary); - urandom.read(reinterpret_cast(&random_value), sizeof(random_seed)); - gen->readString(Form("Random:seed = %d", random_value % 900000001)); - // print debug - // gen->PrintDebug(); - - return gen; -} diff --git a/MC/config/PWGDQ/external/generator/GeneratorBplusToJpsiKaon_EvtGen.C b/MC/config/PWGDQ/external/generator/GeneratorBplusToJpsiKaon_EvtGen.C deleted file mode 100644 index 9c6b125c1..000000000 --- a/MC/config/PWGDQ/external/generator/GeneratorBplusToJpsiKaon_EvtGen.C +++ /dev/null @@ -1,45 +0,0 @@ -// o2-sim -j 1 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configKeyValues "GeneratorExternal.fileName=GeneratorBplusToJpsiKaon_EvtGen.C;GeneratorExternal.funcName=GeneratorBplusToJpsiKaon_EvtGen()" --configFile GeneratorHF_bbbarToBplus_midy.ini -// -// -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGDQ/EvtGen) -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGHF/external/generator) -#include "GeneratorEvtGen.C" -#include "GeneratorHF.C" - -FairGenerator* - GeneratorBplusToJpsiKaon_EvtGen(double rapidityMin = -1.5, double rapidityMax = 1.5, bool ispp = true, bool verbose = false, TString pdgs = "521") -{ - auto gen = new o2::eventgen::GeneratorEvtGen(); - gen->setRapidity(rapidityMin, rapidityMax); - gen->setPDG(5); - TString pathO2table = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/pythia8/decayer/switchOffBplus.cfg"); - gen->readFile(pathO2table.Data()); - - gen->setVerbose(verbose); - if (ispp) - gen->setFormula("1"); - else - gen->setFormula("max(1.,120.*(x<5.)+80.*(1.-x/20.)*(x>5.)*(x<11.)+240.*(1.-x/13.)*(x>11.))"); - std::string spdg; - TObjArray* obj = pdgs.Tokenize(";"); - gen->SetSizePdg(obj->GetEntriesFast()); - for (int i = 0; i < obj->GetEntriesFast(); i++) { - spdg = obj->At(i)->GetName(); - gen->AddPdg(std::stoi(spdg), i); - printf("PDG %d \n", std::stoi(spdg)); - } - - TString pathO2 = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/EvtGen/DecayTablesEvtgen"); - gen->SetDecayTable(Form("%s/BPLUSTOKAONJPSITOELE.DEC", pathO2.Data())); - // print debug - // gen->PrintDebug(); - // set random seed - gen->readString("Random:setSeed on"); - uint random_seed; - unsigned long long int random_value = 0; - ifstream urandom("/dev/urandom", ios::in|ios::binary); - urandom.read(reinterpret_cast(&random_value), sizeof(random_seed)); - gen->readString(Form("Random:seed = %d", random_value % 900000001)); - - return gen; -} diff --git a/MC/config/PWGDQ/external/generator/GeneratorCharmToMu_EvtGen.C b/MC/config/PWGDQ/external/generator/GeneratorCharmToMu_EvtGen.C deleted file mode 100644 index 63c16bce9..000000000 --- a/MC/config/PWGDQ/external/generator/GeneratorCharmToMu_EvtGen.C +++ /dev/null @@ -1,46 +0,0 @@ -// usage (fwdy) : -//o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_fwdy.ini -// usage (midy) : -//o2-sim -j 4 -n 10 -g external -t external -m "PIPE ITS TPC" -o sgn --configFile GeneratorHF_bbbar_midy.ini -// -// -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGDQ/EvtGen) -R__ADD_INCLUDE_PATH($O2DPG_MC_CONFIG_ROOT/MC/config/PWGHF/external/generator) -#include "GeneratorEvtGen.C" -#include "GeneratorHF.C" - - -FairGenerator* -GeneratorCharmToMu_EvtGenFwdY(double rapidityMin = -4.3, double rapidityMax = -2.2, bool ispp = true, bool verbose = false, TString pdgs = "411;421;431;4122;4232;4332") -{ - auto gen = new o2::eventgen::GeneratorEvtGen(); - gen->setRapidity(rapidityMin,rapidityMax); - gen->setPDG(4); - TString pathO2table = gSystem->ExpandPathName("${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/pythia8/decayer/switchOffChadrons.cfg"); - gen->readFile(pathO2table.Data()); - - gen->setVerbose(verbose); - if(ispp) gen->setFormula("1"); - else gen->setFormula("max(1.,120.*(x<5.)+80.*(1.-x/20.)*(x>5.)*(x<11.)+240.*(1.-x/13.)*(x>11.))"); - std::string spdg; - TObjArray *obj = pdgs.Tokenize(";"); - gen->SetSizePdg(obj->GetEntriesFast()); - for(int i=0; iGetEntriesFast(); i++) { - spdg = obj->At(i)->GetName(); - gen->AddPdg(std::stoi(spdg),i); - printf("PDG %d \n",std::stoi(spdg)); - } - gen->SetForceDecay(kEvtSemiMuonic); - // set random seed - gen->readString("Random:setSeed on"); - uint random_seed; - unsigned long long int random_value = 0; - ifstream urandom("/dev/urandom", ios::in|ios::binary); - urandom.read(reinterpret_cast(&random_value), sizeof(random_seed)); - gen->readString(Form("Random:seed = %d", random_value % 900000001)); - // print debug - // gen->PrintDebug(); - - return gen; -} - diff --git a/MC/config/PWGDQ/ini/GeneratorHF_bbbarToBplus_midy.ini b/MC/config/PWGDQ/ini/GeneratorHF_bbbarToBplus_midy.ini deleted file mode 100644 index df4c6280a..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_bbbarToBplus_midy.ini +++ /dev/null @@ -1,28 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorBplusToJpsiKaon_EvtGen.C -funcName = GeneratorBplusToJpsiKaon_EvtGen() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_bbbar(-1.5,1.5) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectHFwithinAcc(521,kFALSE,-1.5,1.5) - -### The setup inhibits transport of primary particles which are produce at forward rapidity. -### The settings below only transports particles in the barrel, which is currently defined as |eta| < 2 - -[Stack] -transportPrimary = barrel diff --git a/MC/config/PWGDQ/ini/GeneratorHF_bbbarToDDbarToMuons_fwdy.ini b/MC/config/PWGDQ/ini/GeneratorHF_bbbarToDDbarToMuons_fwdy.ini deleted file mode 100644 index c8b1d5d1f..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_bbbarToDDbarToMuons_fwdy.ini +++ /dev/null @@ -1,23 +0,0 @@ - -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorBeautyToMu_EvtGen.C -funcName = GeneratorBeautyToMu_EvtGenFwdY(-4.3,-2.3,true,false) - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_bbbar(-4.3,-2.3) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectDaughterFromHFwithinAcc(13,kTRUE,-4.3,-2.3) diff --git a/MC/config/PWGDQ/ini/GeneratorHF_bbbarToMuonsSemileptonic_fwdy.ini b/MC/config/PWGDQ/ini/GeneratorHF_bbbarToMuonsSemileptonic_fwdy.ini deleted file mode 100644 index 17d38f12e..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_bbbarToMuonsSemileptonic_fwdy.ini +++ /dev/null @@ -1,22 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorBeautyToMu_EvtGen.C -funcName = GeneratorBeautyToMu_EvtGenFwdY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_bbbar(-4.3,-2.3) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectDaughterFromHFwithinAcc(13,kTRUE,-4.3,-2.3) diff --git a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_Psi2S_fwdy.ini b/MC/config/PWGDQ/ini/GeneratorHF_bbbar_Psi2S_fwdy.ini deleted file mode 100644 index ffec91f86..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_Psi2S_fwdy.ini +++ /dev/null @@ -1,22 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsi_EvtGen.C -funcName = GeneratorBeautyToPsi_EvtGenFwdY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_bbbar(-4.3,-2.3) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectDaughterFromHFwithinAcc(100443,kTRUE,-4.3,-2.3) diff --git a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_Psi2S_midy.ini b/MC/config/PWGDQ/ini/GeneratorHF_bbbar_Psi2S_midy.ini deleted file mode 100644 index ed67b53e2..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_Psi2S_midy.ini +++ /dev/null @@ -1,28 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsi_EvtGen.C -funcName = GeneratorBeautyToPsi_EvtGenMidY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_bbbar(-1.5,1.5) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectDaughterFromHFwithinAcc(100443,kTRUE,-1.5,1.5) - -### The setup inhibits transport of primary particles which are produce at forward rapidity. -### The settings below only transports particles in the barrel, which is currently defined as |eta| < 2 - -[Stack] -transportPrimary = barrel diff --git a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_PsiAndJpsi_fwdy.ini b/MC/config/PWGDQ/ini/GeneratorHF_bbbar_PsiAndJpsi_fwdy.ini deleted file mode 100644 index 8ced4368a..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_PsiAndJpsi_fwdy.ini +++ /dev/null @@ -1,22 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsiAndJpsi_EvtGen.C -funcName = GeneratorBeautyToPsiAndJpsi_EvtGenFwdY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_bbbar(-4.3,-2.3) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selecMultipletHFwithinAcc("443;100443",kTRUE,-4.3,-2.3) diff --git a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_PsiAndJpsi_midy.ini b/MC/config/PWGDQ/ini/GeneratorHF_bbbar_PsiAndJpsi_midy.ini deleted file mode 100644 index b71a7d9eb..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_PsiAndJpsi_midy.ini +++ /dev/null @@ -1,28 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorBeautyToPsiAndJpsi_EvtGen.C -funcName = GeneratorBeautyToPsiAndJpsi_EvtGenMidY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_bbbar(-1.5,1.5) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selecMultipletHFwithinAcc("443;100443",kTRUE,-1.5,1.5) - -### The setup inhibits transport of primary particles which are produce at forward rapidity. -### The settings below only transports particles in the barrel, which is currently defined as |eta| < 2 - -[Stack] -transportPrimary = barrel diff --git a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_fwdy.ini b/MC/config/PWGDQ/ini/GeneratorHF_bbbar_fwdy.ini deleted file mode 100644 index 08c67d77f..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_fwdy.ini +++ /dev/null @@ -1,22 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorBeautyToJpsi_EvtGen.C -funcName = GeneratorBeautyToJpsi_EvtGenFwdY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_bbbar(-4.3,-2.3) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectDaughterFromHFwithinAcc(443,kTRUE,-4.3,-2.3) diff --git a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_midy.ini b/MC/config/PWGDQ/ini/GeneratorHF_bbbar_midy.ini deleted file mode 100644 index d046db211..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_bbbar_midy.ini +++ /dev/null @@ -1,28 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorBeautyToJpsi_EvtGen.C -funcName = GeneratorBeautyToJpsi_EvtGenMidY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_bbbar(-1.5,1.5) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectDaughterFromHFwithinAcc(443,kTRUE,-1.5,1.5) - -### The setup inhibits transport of primary particles which are produce at forward rapidity. -### The settings below only transports particles in the barrel, which is currently defined as |eta| < 2 - -[Stack] -transportPrimary = barrel diff --git a/MC/config/PWGDQ/ini/GeneratorHF_ccbarToMuonsSemileptonic_fwdy.ini b/MC/config/PWGDQ/ini/GeneratorHF_ccbarToMuonsSemileptonic_fwdy.ini deleted file mode 100644 index 98f1144ac..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_ccbarToMuonsSemileptonic_fwdy.ini +++ /dev/null @@ -1,22 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorCharmToMu_EvtGen.C -funcName = GeneratorCharmToMu_EvtGenFwdY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_hf.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_ccbar(-4.3,-2.3) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectDaughterFromHFwithinAcc(13,kTRUE,-4.3,-2.3) diff --git a/MC/config/PWGDQ/ini/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel.ini b/MC/config/PWGDQ/ini/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel.ini deleted file mode 100644 index fd0fb2398..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel.ini +++ /dev/null @@ -1,22 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorCharmToMu_EvtGen.C -funcName = GeneratorCharmToMu_EvtGenFwdY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_inel.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_ccbar(-4.3,-2.3) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectDaughterFromHFwithinAcc(13,kTRUE,-4.3,-2.3) diff --git a/MC/config/PWGDQ/ini/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel_cr2.ini b/MC/config/PWGDQ/ini/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel_cr2.ini deleted file mode 100644 index 67dbde167..000000000 --- a/MC/config/PWGDQ/ini/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel_cr2.ini +++ /dev/null @@ -1,22 +0,0 @@ -### The setup uses an external event generator -### This part sets the path of the file and the function call to retrieve it - -[GeneratorExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/external/generator/GeneratorCharmToMu_EvtGen.C -funcName = GeneratorCharmToMu_EvtGenFwdY() - -### The external generator derives from GeneratorPythia8. -### This part configures the bits of the interface: configuration and user hooks - -[GeneratorPythia8] -config = ${O2DPG_MC_CONFIG_ROOT}/MC/config/common/pythia8/generator/pythia8_pp_cr2.cfg -hooksFileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGHF/pythia8/hooks/pythia8_userhooks_qqbar.C -hooksFuncName = pythia8_userhooks_ccbar(-4.3,-2.3) - -### The setup uses an external even generator trigger which is -### defined in the following file and it is retrieved and configured -### according to the specified function call - -[TriggerExternal] -fileName = ${O2DPG_MC_CONFIG_ROOT}/MC/config/PWGDQ/trigger/selectDaughterFromHFwithinAcc.C -funcName = selectDaughterFromHFwithinAcc(13,kTRUE,-4.3,-2.3) diff --git a/MC/config/PWGDQ/ini/tests/GeneratorHF_bbbarToDDbarToMuons_fwdy.C b/MC/config/PWGDQ/ini/tests/GeneratorHF_bbbarToDDbarToMuons_fwdy.C deleted file mode 100644 index 271e0ff39..000000000 --- a/MC/config/PWGDQ/ini/tests/GeneratorHF_bbbarToDDbarToMuons_fwdy.C +++ /dev/null @@ -1,85 +0,0 @@ -int External() -{ - int checkPdgDecay = 13; - std::string path{"o2sim_Kine.root"}; - TFile file(path.c_str(), "READ"); - if (file.IsZombie()) { - std::cerr << "Cannot open ROOT file " << path << "\n"; - return 1; - } - auto tree = (TTree*)file.Get("o2sim"); - std::vector* tracks{}; - tree->SetBranchAddress("MCTrack", &tracks); - - int nLeptons{}; - int nLeptonsInAcceptance{}; - int nLeptonsToBeDone{}; - int nSignalPairs{}; - int nLeptonPairs{}; - int nLeptonPairsInAcceptance{}; - int nLeptonPairsToBeDone{}; - auto nEvents = tree->GetEntries(); - - for (int i = 0; i < nEvents; i++) { - tree->GetEntry(i); - int nleptonseinacc = 0; - int nleptonse = 0; - int nleptonseToBeDone = 0; - int nopenHeavy = 0; - for (auto& track : *tracks) { - auto pdg = track.GetPdgCode(); - auto y = track.GetRapidity(); - if (std::abs(pdg) == checkPdgDecay) { - int igmother = track.getMotherTrackId(); - if (igmother > 0) { - auto gmTrack = (*tracks)[igmother]; - int gmpdg = gmTrack.GetPdgCode(); - if ( int(std::abs(gmpdg)/100.) == 4 || int(std::abs(gmpdg)/1000.) == 4 || int(std::abs(gmpdg)/100.) == 5 || int(std::abs(gmpdg)/1000.) == 5 ) { - nLeptons++; - nleptonse++; - if (-4.3 < y && y < -2.3) { - nleptonseinacc++; - nLeptonsInAcceptance++; - } - if (track.getToBeDone()) { - nLeptonsToBeDone++; - nleptonseToBeDone++; - } - } - } - } else if (std::abs(pdg) == 411 || std::abs(pdg) == 421 || std::abs(pdg) == 431 || std::abs(pdg) == 4122 || std::abs(pdg) == 4132 || std::abs(pdg) == 4232 || std::abs(pdg) == 4332 || std::abs(pdg) == 511 || std::abs(pdg) == 521 || std::abs(pdg) == 531 || std::abs(pdg) == 541 || std::abs(pdg) == 5112 || std::abs(pdg) == 5122 || std::abs(pdg) == 5232 || std::abs(pdg) == 5132 || std::abs(pdg) == 5332) { - nopenHeavy++; - } - } - if (nopenHeavy > 1) nSignalPairs++; - if (nleptonse > 1) nLeptonPairs++; - if (nleptonseToBeDone > 1) nLeptonPairsToBeDone++; - if (nleptonseinacc > 1) nLeptonPairsInAcceptance++; - } - std::cout << "#events: " << nEvents << "\n" - << "#muons in acceptance: " << nLeptonsInAcceptance << "\n" - << "#muon pairs in acceptance: " << nLeptonPairsInAcceptance << "\n" - << "#muons: " << nLeptons << "\n" - << "#muons to be done: " << nLeptonsToBeDone << "\n" - << "#signal pairs: " << nSignalPairs << "\n" - << "#muon pairs: " << nLeptonPairs << "\n" - << "#muon pairs to be done: " << nLeptonPairsToBeDone << "\n"; - if (nSignalPairs <= nLeptonPairs) { - std::cerr << "Number of muon pairs should be less than HF hadron pairs\n"; - return 1; - } - if (nSignalPairs < nEvents) { - std::cerr << "Number of signal pairs should be at least equaled to the number of events\n"; - return 1; - } - if (nLeptonPairs != nLeptonPairsToBeDone) { - std::cerr << "The number of muon pairs should be the same as the number of muon pairs which should be transported.\n"; - return 1; - } - if (nLeptons != nLeptonsToBeDone) { - std::cerr << "The number of muons should be the same as the number of muons which should be transported.\n"; - return 1; - } - - return 0; -} diff --git a/MC/config/PWGDQ/ini/tests/GeneratorHF_bbbar_PsiAndJpsi_fwdy.C b/MC/config/PWGDQ/ini/tests/GeneratorHF_bbbar_PsiAndJpsi_fwdy.C deleted file mode 100644 index 52d699151..000000000 --- a/MC/config/PWGDQ/ini/tests/GeneratorHF_bbbar_PsiAndJpsi_fwdy.C +++ /dev/null @@ -1,92 +0,0 @@ -int External() -{ - int checkPdgSignal[] = {443,100443}; - int checkPdgDecay = 13; - std::string path{"o2sim_Kine.root"}; - std::cout << "Check for\nsignal PDG " << checkPdgSignal << "\ndecay PDG " << checkPdgDecay << "\n"; - TFile file(path.c_str(), "READ"); - if (file.IsZombie()) { - std::cerr << "Cannot open ROOT file " << path << "\n"; - return 1; - } - - auto tree = (TTree*)file.Get("o2sim"); - std::vector* tracks{}; - tree->SetBranchAddress("MCTrack", &tracks); - - int nLeptons{}; - int nAntileptons{}; - int nLeptonPairs{}; - int nLeptonPairsToBeDone{}; - int nSignalJpsi{}; - int nSignalPsi2S{}; - int nSignalJpsiWithinAcc{}; - int nSignalPsi2SWithinAcc{}; - auto nEvents = tree->GetEntries(); - o2::steer::MCKinematicsReader mcreader("o2sim", o2::steer::MCKinematicsReader::Mode::kMCKine); - Int_t bpdgs[] = {511, 521, 531, 5112, 5122, 5232, 5132}; - Int_t sizePdg = sizeof(bpdgs)/sizeof(Int_t); - Bool_t hasBeautyMoth = kFALSE; - - for (int i = 0; i < nEvents; i++) { - tree->GetEntry(i); - for (auto& track : *tracks) { - auto pdg = track.GetPdgCode(); - auto rapidity = track.GetRapidity(); - auto idMoth = track.getMotherTrackId(); - if (pdg == checkPdgDecay) { - // count leptons - nLeptons++; - } else if(pdg == -checkPdgDecay) { - // count anti-leptons - nAntileptons++; - } else if (pdg == checkPdgSignal[0] || pdg == checkPdgSignal[1]) { - // check if mothers are beauty hadrons - hasBeautyMoth = kFALSE; - if(idMoth){ // check beauty mother - auto tdM = mcreader.getTrack(i, idMoth); - for(int i=0; iGetPdgCode()) == bpdgs[i] ) hasBeautyMoth = kTRUE; } - } - if(hasBeautyMoth){ - // count signal PDG - pdg == checkPdgSignal[0] ? nSignalJpsi++ : nSignalPsi2S++; - // count signal PDG within acceptance - if(rapidity > -4.3 && rapidity < -2.3) { pdg == checkPdgSignal[0] ? nSignalJpsiWithinAcc++ : nSignalPsi2SWithinAcc++;} - } - auto child0 = o2::mcutils::MCTrackNavigator::getDaughter0(track, *tracks); - auto child1 = o2::mcutils::MCTrackNavigator::getDaughter1(track, *tracks); - if (child0 != nullptr && child1 != nullptr) { - // check for parent-child relations - auto pdg0 = child0->GetPdgCode(); - auto pdg1 = child1->GetPdgCode(); - std::cout << "First and last children of parent " << checkPdgSignal << " are PDG0: " << pdg0 << " PDG1: " << pdg1 << "\n"; - if (std::abs(pdg0) == checkPdgDecay && std::abs(pdg1) == checkPdgDecay && pdg0 == -pdg1) { - nLeptonPairs++; - if (child0->getToBeDone() && child1->getToBeDone()) { - nLeptonPairsToBeDone++; - } - } - } - } - } - } - std::cout << "#events: " << nEvents << "\n" - << "#leptons: " << nLeptons << "\n" - << "#antileptons: " << nAntileptons << "\n" - << "#signal (jpsi <- b): " << nSignalJpsi << "; within acceptance (-4.3 < y < -2.3): " << nSignalJpsiWithinAcc << "\n" - << "#signal (psi2S <- b): " << nSignalPsi2S << "; within acceptance (-4.3 < y < -2.3): " << nSignalPsi2SWithinAcc << "\n" - << "#lepton pairs: " << nLeptonPairs << "\n" - << "#lepton pairs to be done: " << nLeptonPairs << "\n"; - - - if (nLeptonPairs == 0 || nLeptons == 0 || nAntileptons == 0) { - std::cerr << "Number of leptons, number of anti-leptons as well as number of lepton pairs should all be greater than 1.\n"; - return 1; - } - if (nLeptonPairs != nLeptonPairsToBeDone) { - std::cerr << "The number of lepton pairs should be the same as the number of lepton pairs which should be transported.\n"; - return 1; - } - - return 0; -} diff --git a/MC/config/PWGDQ/ini/tests/GeneratorHF_bbbar_PsiAndJpsi_midy.C b/MC/config/PWGDQ/ini/tests/GeneratorHF_bbbar_PsiAndJpsi_midy.C deleted file mode 100644 index 8a0964910..000000000 --- a/MC/config/PWGDQ/ini/tests/GeneratorHF_bbbar_PsiAndJpsi_midy.C +++ /dev/null @@ -1,92 +0,0 @@ -int External() -{ - int checkPdgSignal[] = {443,100443}; - int checkPdgDecay = 11; - std::string path{"o2sim_Kine.root"}; - std::cout << "Check for\nsignal PDG " << checkPdgSignal << "\ndecay PDG " << checkPdgDecay << "\n"; - TFile file(path.c_str(), "READ"); - if (file.IsZombie()) { - std::cerr << "Cannot open ROOT file " << path << "\n"; - return 1; - } - - auto tree = (TTree*)file.Get("o2sim"); - std::vector* tracks{}; - tree->SetBranchAddress("MCTrack", &tracks); - - int nLeptons{}; - int nAntileptons{}; - int nLeptonPairs{}; - int nLeptonPairsToBeDone{}; - int nSignalJpsi{}; - int nSignalPsi2S{}; - int nSignalJpsiWithinAcc{}; - int nSignalPsi2SWithinAcc{}; - auto nEvents = tree->GetEntries(); - o2::steer::MCKinematicsReader mcreader("o2sim", o2::steer::MCKinematicsReader::Mode::kMCKine); - Int_t bpdgs[] = {511, 521, 531, 5112, 5122, 5232, 5132}; - Int_t sizePdg = sizeof(bpdgs)/sizeof(Int_t); - Bool_t hasBeautyMoth = kFALSE; - - for (int i = 0; i < nEvents; i++) { - tree->GetEntry(i); - for (auto& track : *tracks) { - auto pdg = track.GetPdgCode(); - auto rapidity = track.GetRapidity(); - auto idMoth = track.getMotherTrackId(); - if (pdg == checkPdgDecay) { - // count leptons - nLeptons++; - } else if(pdg == -checkPdgDecay) { - // count anti-leptons - nAntileptons++; - } else if (pdg == checkPdgSignal[0] || pdg == checkPdgSignal[1]) { - // check if mothers are beauty hadrons - hasBeautyMoth = kFALSE; - if(idMoth){ // check beauty mother - auto tdM = mcreader.getTrack(i, idMoth); - for(int i=0; iGetPdgCode()) == bpdgs[i] ) hasBeautyMoth = kTRUE; } - } - if(hasBeautyMoth){ - // count signal PDG - pdg == checkPdgSignal[0] ? nSignalJpsi++ : nSignalPsi2S++; - // count signal PDG within acceptance - if(std::abs(rapidity) < 1.0) { pdg == checkPdgSignal[0] ? nSignalJpsiWithinAcc++ : nSignalPsi2SWithinAcc++;} - } - auto child0 = o2::mcutils::MCTrackNavigator::getDaughter0(track, *tracks); - auto child1 = o2::mcutils::MCTrackNavigator::getDaughter1(track, *tracks); - if (child0 != nullptr && child1 != nullptr) { - // check for parent-child relations - auto pdg0 = child0->GetPdgCode(); - auto pdg1 = child1->GetPdgCode(); - std::cout << "First and last children of parent " << checkPdgSignal << " are PDG0: " << pdg0 << " PDG1: " << pdg1 << "\n"; - if (std::abs(pdg0) == checkPdgDecay && std::abs(pdg1) == checkPdgDecay && pdg0 == -pdg1) { - nLeptonPairs++; - if (child0->getToBeDone() && child1->getToBeDone()) { - nLeptonPairsToBeDone++; - } - } - } - } - } - } - std::cout << "#events: " << nEvents << "\n" - << "#leptons: " << nLeptons << "\n" - << "#antileptons: " << nAntileptons << "\n" - << "#signal (jpsi <- b): " << nSignalJpsi << "; within acceptance (|y| < 1): " << nSignalJpsiWithinAcc << "\n" - << "#signal (psi2S <- b): " << nSignalPsi2S << "; within acceptance (|y| < 1): " << nSignalPsi2SWithinAcc << "\n" - << "#lepton pairs: " << nLeptonPairs << "\n" - << "#lepton pairs to be done: " << nLeptonPairs << "\n"; - - - if (nLeptonPairs == 0 || nLeptons == 0 || nAntileptons == 0) { - std::cerr << "Number of leptons, number of anti-leptons as well as number of lepton pairs should all be greater than 1.\n"; - return 1; - } - if (nLeptonPairs != nLeptonPairsToBeDone) { - std::cerr << "The number of lepton pairs should be the same as the number of lepton pairs which should be transported.\n"; - return 1; - } - - return 0; -} diff --git a/MC/config/PWGDQ/ini/tests/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel.C b/MC/config/PWGDQ/ini/tests/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel.C deleted file mode 100644 index 012e45b90..000000000 --- a/MC/config/PWGDQ/ini/tests/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel.C +++ /dev/null @@ -1,81 +0,0 @@ -int External() -{ - int checkPdgDecay = 13; - std::string path{"o2sim_Kine.root"}; - TFile file(path.c_str(), "READ"); - if (file.IsZombie()) { - std::cerr << "Cannot open ROOT file " << path << "\n"; - return 1; - } - auto tree = (TTree*)file.Get("o2sim"); - std::vector* tracks{}; - tree->SetBranchAddress("MCTrack", &tracks); - - int nLeptons{}; - int nLeptonsInAcceptance{}; - int nLeptonsToBeDone{}; - int nSignalPairs{}; - int nLeptonPairs{}; - int nLeptonPairsInAcceptance{}; - int nLeptonPairsToBeDone{}; - auto nEvents = tree->GetEntries(); - - for (int i = 0; i < nEvents; i++) { - tree->GetEntry(i); - int nleptonseinacc = 0; - int nleptonse = 0; - int nleptonseToBeDone = 0; - int nopenHeavy = 0; - for (auto& track : *tracks) { - auto pdg = track.GetPdgCode(); - auto y = track.GetRapidity(); - if (std::abs(pdg) == checkPdgDecay) { - int igmother = track.getMotherTrackId(); - if (igmother > 0) { - auto gmTrack = (*tracks)[igmother]; - int gmpdg = gmTrack.GetPdgCode(); - if ( int(std::abs(gmpdg)/100.) == 4 || int(std::abs(gmpdg)/1000.) == 4 || int(std::abs(gmpdg)/100.) == 5 || int(std::abs(gmpdg)/1000.) == 5 ) { - nLeptons++; - nleptonse++; - if (-4.3 < y && y < -2.2) { - nleptonseinacc++; - nLeptonsInAcceptance++; - } - if (track.getToBeDone()) { - nLeptonsToBeDone++; - nleptonseToBeDone++; - } - } - } - } else if (std::abs(pdg) == 411 || std::abs(pdg) == 421 || std::abs(pdg) == 431 || std::abs(pdg) == 4122 || std::abs(pdg) == 4132 || std::abs(pdg) == 4232 || std::abs(pdg) == 4332) { - nopenHeavy++; - } - } - if (nopenHeavy > 1) nSignalPairs++; - if (nleptonse > 1) nLeptonPairs++; - if (nleptonseToBeDone > 1) nLeptonPairsToBeDone++; - if (nleptonseinacc > 1) nLeptonPairsInAcceptance++; - } - std::cout << "#events: " << nEvents << "\n" - << "#muons in acceptance: " << nLeptonsInAcceptance << "\n" - << "#muon pairs in acceptance: " << nLeptonPairsInAcceptance << "\n" - << "#muons: " << nLeptons << "\n" - << "#muons to be done: " << nLeptonsToBeDone << "\n" - << "#signal pairs: " << nSignalPairs << "\n" - << "#muon pairs: " << nLeptonPairs << "\n" - << "#muon pairs to be done: " << nLeptonPairsToBeDone << "\n"; - if (nSignalPairs < nEvents) { - std::cerr << "Number of signal pairs should be at least equaled to the number of events\n"; - return 1; - } - if (nLeptonPairs != nLeptonPairsToBeDone) { - std::cerr << "The number of muon pairs should be the same as the number of muon pairs which should be transported.\n"; - return 1; - } - if (nLeptons != nLeptonsToBeDone) { - std::cerr << "The number of muons should be the same as the number of muons which should be transported.\n"; - return 1; - } - - return 0; -} diff --git a/MC/config/PWGDQ/ini/tests/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel_cr2.C b/MC/config/PWGDQ/ini/tests/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel_cr2.C deleted file mode 100644 index 012e45b90..000000000 --- a/MC/config/PWGDQ/ini/tests/GeneratorHF_ccbarToMuonsSemileptonic_fwdy_inel_cr2.C +++ /dev/null @@ -1,81 +0,0 @@ -int External() -{ - int checkPdgDecay = 13; - std::string path{"o2sim_Kine.root"}; - TFile file(path.c_str(), "READ"); - if (file.IsZombie()) { - std::cerr << "Cannot open ROOT file " << path << "\n"; - return 1; - } - auto tree = (TTree*)file.Get("o2sim"); - std::vector* tracks{}; - tree->SetBranchAddress("MCTrack", &tracks); - - int nLeptons{}; - int nLeptonsInAcceptance{}; - int nLeptonsToBeDone{}; - int nSignalPairs{}; - int nLeptonPairs{}; - int nLeptonPairsInAcceptance{}; - int nLeptonPairsToBeDone{}; - auto nEvents = tree->GetEntries(); - - for (int i = 0; i < nEvents; i++) { - tree->GetEntry(i); - int nleptonseinacc = 0; - int nleptonse = 0; - int nleptonseToBeDone = 0; - int nopenHeavy = 0; - for (auto& track : *tracks) { - auto pdg = track.GetPdgCode(); - auto y = track.GetRapidity(); - if (std::abs(pdg) == checkPdgDecay) { - int igmother = track.getMotherTrackId(); - if (igmother > 0) { - auto gmTrack = (*tracks)[igmother]; - int gmpdg = gmTrack.GetPdgCode(); - if ( int(std::abs(gmpdg)/100.) == 4 || int(std::abs(gmpdg)/1000.) == 4 || int(std::abs(gmpdg)/100.) == 5 || int(std::abs(gmpdg)/1000.) == 5 ) { - nLeptons++; - nleptonse++; - if (-4.3 < y && y < -2.2) { - nleptonseinacc++; - nLeptonsInAcceptance++; - } - if (track.getToBeDone()) { - nLeptonsToBeDone++; - nleptonseToBeDone++; - } - } - } - } else if (std::abs(pdg) == 411 || std::abs(pdg) == 421 || std::abs(pdg) == 431 || std::abs(pdg) == 4122 || std::abs(pdg) == 4132 || std::abs(pdg) == 4232 || std::abs(pdg) == 4332) { - nopenHeavy++; - } - } - if (nopenHeavy > 1) nSignalPairs++; - if (nleptonse > 1) nLeptonPairs++; - if (nleptonseToBeDone > 1) nLeptonPairsToBeDone++; - if (nleptonseinacc > 1) nLeptonPairsInAcceptance++; - } - std::cout << "#events: " << nEvents << "\n" - << "#muons in acceptance: " << nLeptonsInAcceptance << "\n" - << "#muon pairs in acceptance: " << nLeptonPairsInAcceptance << "\n" - << "#muons: " << nLeptons << "\n" - << "#muons to be done: " << nLeptonsToBeDone << "\n" - << "#signal pairs: " << nSignalPairs << "\n" - << "#muon pairs: " << nLeptonPairs << "\n" - << "#muon pairs to be done: " << nLeptonPairsToBeDone << "\n"; - if (nSignalPairs < nEvents) { - std::cerr << "Number of signal pairs should be at least equaled to the number of events\n"; - return 1; - } - if (nLeptonPairs != nLeptonPairsToBeDone) { - std::cerr << "The number of muon pairs should be the same as the number of muon pairs which should be transported.\n"; - return 1; - } - if (nLeptons != nLeptonsToBeDone) { - std::cerr << "The number of muons should be the same as the number of muons which should be transported.\n"; - return 1; - } - - return 0; -}