Wrong reading of Pythia events

Uploading: stable.root(1)… Hi.
I read output of Pythia8 converted to file.root. The problem lies in wrong values of such variables as energy, eta, phi and transverse momentum.

#include "TChain.h"
using namespace std;
void func(const char *file)
{
  gSystem->Load("/MG5_aMC_v2_7_0/ExRootAnalysis/libExRootAnalysis.so");
  gSystem->Load("libDelphes");
  TChain* chain= new TChain("Delphes");
chain->Add(file);
    ExRootTreeReader *treeReader = new ExRootTreeReader(chain);
  Long64_t numberOfEntries = treeReader->GetEntries();
   TClonesArray *branch = treeReader->UseBranch("Particle");
  TRootLHEFParticle *particle;
  cout << "(E, PT, Eta, Phi)" << endl;
  for(Int_t entry = 0; entry < 5; ++entry){
  treeReader->ReadEntry(entry);
for(int i = 0; i < branch->GetEntriesFast(); i++){
particle = (TRootLHEFParticle*) branch->At(i);
if(particle->PID == 11 || particle->PID == -11){
cout << "(" <<  particle->E << ", " <<  particle->PT << ", " <<  particle->Eta << ", " <<  particle->Phi << ")" << endl;
}}}}
(E, PT, Eta, Phi)
(5.52438e-315, 3.32308e-07, 0, 0)
(5.24757e-315, 1.23221e-17, 0, 0)
(5.11911e-315, 0.0151686, 0, 1.0566e-120)
(5.2008e-315, 0.0140443, 0, 1.0566e-120)
(5.11923e-315, 0.115801, 0, 1.89731e-116)
(5.16697e-315, 0.0451834, 0, 1.89731e-116)
(1.6224e-314, -13.201, 0, 0)
(1.63173e-314, -53.4389, 0, 0)
(1.62487e-314, -0.213786, 0, 0)
(1.62568e-314, -2.22925, 0, 0)
(5.19263e-315, 0.0565604, 0, 2.71078e-102)
(5.13232e-315, 0.0659506, 0, 6.72878e-128)
(5.06008e-315, 0.122189, 0, 6.72878e-128)
(1.6248e-314, -0.200482, 0, 0)
(1.61236e-314, -0.0050687, 0, 0)
(1.59277e-314, -4.27593, 0, 1.5005e-121)
(1.58121e-314, -4.34659, 0, 1.5005e-121)
(5.40167e-315, 483.933, 0, 7.5345e-121)
(5.08197e-315, 61.6345, 0, 7.5345e-121)
(1.59176e-314, -254.953, 0, 3.80609e-125)
(1.5894e-314, -244.049, 0, 3.80609e-125)
(5.58088e-315, 0.313074, 0, 0)
(5.42648e-315, 6.44173e-05, 0, 0)
(1.56209e-314, -1.23522e-06, 0, 2.33854e-131)
(1.56939e-314, -3.76532e-07, 0, 2.33854e-131)

What do I wrong?

Cheers,
Dmitriy

_ROOT Version: ROOT 6.18/04

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.