001
002
003
004
005
006
007
008
009
010
011
012
013 #include "AtlfastAlgs/DefaultReconstructor.h"
014
015 #include "CLHEP/Vector/LorentzVector.h"
016 #include "CLHEP/Random/JamesRandom.h"
017 #include "CLHEP/Random/RandGauss.h"
018 #include "CLHEP/Random/RandFlat.h"
019
020
021
022 namespace Atlfast {
023
024 DefaultReconstructor::DefaultReconstructor(const int aseed) {
025
026 HepRandomEngine* randomEngine = new HepJamesRandom( aseed );
027 m_randGauss = new RandGauss( randomEngine );
028 m_randFlat = new RandFlat( *randomEngine );
029 m_randSeed = aseed;
030 }
031
032
033 DefaultReconstructor::~DefaultReconstructor() {
034
035
036
037 if (m_randFlat) {
038 delete m_randFlat;
039 }
040
041 if (m_randGauss) {
042 delete m_randGauss;
043 }
044
045
046
047
048
049 }
050
051 ReconstructedParticle DefaultReconstructor::reconstruct( const ReconstructedParticle &particle )const{
052
053
054
055 HepLorentzVector bvec;
056
057 bvec.setE( m_randGauss->fire(particle.e(), 1.0) );
058 bvec.setPx(m_randGauss->fire(particle.px(),1.0) );
059 bvec.setPy(m_randGauss->fire(particle.py(),1.0) );
060 bvec.setPz(m_randGauss->fire(particle.pz(),1.0) );
061
062 ReconstructedParticle return_particle(particle);
063 return_particle.set_momentum(bvec);
064 return return_particle;
065 }
066
067
068 int DefaultReconstructor::setSmearParameters (const std::vector<double>& ){
069 return 0;
070 }
071
072 int DefaultReconstructor::setSmearParamSchema ( const int ){
073 return 0;
074 }
075
076 }
077
| Due to the LXR bug, the updates fail sometimes to remove references to deleted files. The Saturday's full rebuilds fix these problems |
|
This page was automatically generated by the
LXR engine.
|
|