G4ErrorTrajState Class Reference

#include <G4ErrorTrajState.hh>

Inheritance diagram for G4ErrorTrajState:

G4ErrorFreeTrajState G4ErrorSurfaceTrajState

Public Member Functions

 G4ErrorTrajState ()
 G4ErrorTrajState (const G4String &partType, const G4Point3D &pos, const G4Vector3D &mom, const G4ErrorTrajErr &errmat=G4ErrorTrajErr(5, 0))
virtual ~G4ErrorTrajState ()
void SetData (const G4String &partType, const G4Point3D &pos, const G4Vector3D &mom)
void BuildCharge ()
virtual G4int PropagateError (const G4Track *)
virtual G4int Update (const G4Track *)
void UpdatePosMom (const G4Point3D &pos, const G4Vector3D &mom)
void DumpPosMomError (std::ostream &out=G4cout) const
virtual void Dump (std::ostream &out=G4cout) const =0
const G4StringGetParticleType () const
void SetParticleType (const G4String &partType)
G4Point3D GetPosition () const
virtual void SetPosition (const G4Point3D pos)
G4Vector3D GetMomentum () const
virtual void SetMomentum (const G4Vector3D &mom)
G4ErrorTrajErr GetError () const
virtual void SetError (G4ErrorTrajErr em)
G4TrackGetG4Track () const
void SetG4Track (G4Track *trk)
G4double GetCharge () const
void SetCharge (G4double ch)
virtual G4eTSType GetTSType () const

Protected Attributes

G4String fParticleType
G4Point3D fPosition
G4Vector3D fMomentum
G4double fCharge
G4ErrorTrajErr fError
G4eTSType theTSType
G4TracktheG4Track
G4int iverbose

Friends

std::ostream & operator<< (std::ostream &, const G4ErrorTrajState &ts)

Detailed Description

Definition at line 49 of file G4ErrorTrajState.hh.


Constructor & Destructor Documentation

G4ErrorTrajState::G4ErrorTrajState (  )  [inline]

Definition at line 53 of file G4ErrorTrajState.hh.

00053 : fCharge(0.), theG4Track(0), iverbose(0) {}

G4ErrorTrajState::G4ErrorTrajState ( const G4String partType,
const G4Point3D pos,
const G4Vector3D mom,
const G4ErrorTrajErr errmat = G4ErrorTrajErr(5, 0) 
)

Definition at line 41 of file G4ErrorTrajState.cc.

References iverbose, and G4ErrorPropagatorData::verbose().

00045   : fParticleType(partType), fPosition(pos), fMomentum(mom), fCharge(0.),
00046     fError(errmat), theTSType(G4eTS_FREE), theG4Track(0)
00047 {
00048   iverbose = G4ErrorPropagatorData::verbose();
00049 }

virtual G4ErrorTrajState::~G4ErrorTrajState (  )  [inline, virtual]

Definition at line 60 of file G4ErrorTrajState.hh.

00060 {}


Member Function Documentation

void G4ErrorTrajState::BuildCharge (  ) 

Definition at line 85 of file G4ErrorTrajState.cc.

References FatalException, fCharge, G4ParticleTable::FindParticle(), fParticleType, G4cerr, G4endl, G4Exception(), G4ParticleTable::GetParticleTable(), and G4ParticleDefinition::GetPDGCharge().

Referenced by SetData().

00086 {
00087   G4ParticleTable* particleTable = G4ParticleTable::GetParticleTable();
00088   G4ParticleDefinition* particle = particleTable->FindParticle(fParticleType); 
00089   if( particle == 0)
00090   {
00091     G4cerr << "ERROR - G4ErrorTrajState::BuildCharge()" << G4endl
00092            << "        Particle type not defined: " << fParticleType << G4endl;
00093     G4Exception( "G4ErrorTrajState::BuildCharge()", "GEANT4e-error",
00094                   FatalException, "Particle type not defined!");
00095   }
00096   else
00097   {
00098     fCharge = particle->GetPDGCharge();
00099   }
00100 }

virtual void G4ErrorTrajState::Dump ( std::ostream &  out = G4cout  )  const [pure virtual]

Implemented in G4ErrorFreeTrajState, and G4ErrorSurfaceTrajState.

void G4ErrorTrajState::DumpPosMomError ( std::ostream &  out = G4cout  )  const

Definition at line 104 of file G4ErrorTrajState.cc.

Referenced by operator<<().

00105 {
00106   out << *this;
00107 }

G4double G4ErrorTrajState::GetCharge (  )  const [inline]

Definition at line 114 of file G4ErrorTrajState.hh.

References fCharge.

00115     { return fCharge; }

G4ErrorTrajErr G4ErrorTrajState::GetError (  )  const [inline]

Definition at line 104 of file G4ErrorTrajState.hh.

References fError.

Referenced by G4ErrorSurfaceTrajState::BuildErrorMatrix(), and G4ErrorFreeTrajState::G4ErrorFreeTrajState().

00105     { return fError; }

G4Track* G4ErrorTrajState::GetG4Track (  )  const [inline]

Definition at line 109 of file G4ErrorTrajState.hh.

References theG4Track.

00110     { return theG4Track; }

G4Vector3D G4ErrorTrajState::GetMomentum (  )  const [inline]

Definition at line 99 of file G4ErrorTrajState.hh.

References fMomentum.

Referenced by G4ErrorPropagator::InitG4Track(), G4ErrorPropagator::Propagate(), and G4ErrorPropagator::PropagateOneStep().

00100     { return fMomentum; }

const G4String& G4ErrorTrajState::GetParticleType (  )  const [inline]

Definition at line 89 of file G4ErrorTrajState.hh.

References fParticleType.

Referenced by G4ErrorPropagator::InitG4Track(), G4ErrorPropagator::Propagate(), and G4ErrorPropagator::PropagateOneStep().

00090     { return fParticleType;}

G4Point3D G4ErrorTrajState::GetPosition (  )  const [inline]

Definition at line 94 of file G4ErrorTrajState.hh.

References fPosition.

Referenced by G4ErrorPropagator::InitG4Track().

00095     { return fPosition; }

virtual G4eTSType G4ErrorTrajState::GetTSType (  )  const [inline, virtual]

Definition at line 119 of file G4ErrorTrajState.hh.

References theTSType.

Referenced by G4ErrorPropagator::GetFinalTrajState(), G4ErrorPropagator::InitFreeTrajState(), and PropagateError().

00120     { return theTSType; }

G4int G4ErrorTrajState::PropagateError ( const G4Track  )  [virtual]

Reimplemented in G4ErrorFreeTrajState.

Definition at line 53 of file G4ErrorTrajState.cc.

References FatalException, G4cerr, G4endl, G4Exception(), and GetTSType().

00054 { 
00055   G4cerr << "ERROR - G4ErrorTrajState::PropagateError()" << G4endl
00056          << "        Called for trajectory state type "
00057          << G4int(GetTSType()) << G4endl;
00058   G4Exception("G4ErrorTrajState::PropagateError", "GEANT4e-Error",
00059               FatalException, "Wrong trajectory state type");
00060    return -1; 
00061 }

void G4ErrorTrajState::SetCharge ( G4double  ch  )  [inline]

Definition at line 116 of file G4ErrorTrajState.hh.

References fCharge.

00117     { fCharge = ch; }

void G4ErrorTrajState::SetData ( const G4String partType,
const G4Point3D pos,
const G4Vector3D mom 
)

Definition at line 74 of file G4ErrorTrajState.cc.

References BuildCharge(), fMomentum, fParticleType, and fPosition.

00076 {
00077   fParticleType = partType;
00078   BuildCharge();
00079   fPosition = pos;
00080   fMomentum = mom;
00081 }

virtual void G4ErrorTrajState::SetError ( G4ErrorTrajErr  em  )  [inline, virtual]

Definition at line 106 of file G4ErrorTrajState.hh.

References fError.

00107     { fError = em; }

void G4ErrorTrajState::SetG4Track ( G4Track trk  )  [inline]

Definition at line 111 of file G4ErrorTrajState.hh.

References theG4Track.

Referenced by G4ErrorPropagator::InitG4Track().

00112     { theG4Track = trk; }

virtual void G4ErrorTrajState::SetMomentum ( const G4Vector3D mom  )  [inline, virtual]

Reimplemented in G4ErrorFreeTrajState, and G4ErrorSurfaceTrajState.

Definition at line 101 of file G4ErrorTrajState.hh.

References fMomentum.

00102     { fMomentum = mom; }

void G4ErrorTrajState::SetParticleType ( const G4String partType  )  [inline]

Definition at line 91 of file G4ErrorTrajState.hh.

References fParticleType.

00092     { fParticleType = partType;}

virtual void G4ErrorTrajState::SetPosition ( const G4Point3D  pos  )  [inline, virtual]

Reimplemented in G4ErrorFreeTrajState, and G4ErrorSurfaceTrajState.

Definition at line 96 of file G4ErrorTrajState.hh.

References fPosition.

00097     { fPosition = pos; }

virtual G4int G4ErrorTrajState::Update ( const G4Track  )  [inline, virtual]

Reimplemented in G4ErrorFreeTrajState.

Definition at line 75 of file G4ErrorTrajState.hh.

00075 { return -1; }

void G4ErrorTrajState::UpdatePosMom ( const G4Point3D pos,
const G4Vector3D mom 
)

Definition at line 65 of file G4ErrorTrajState.cc.

References fMomentum, and fPosition.

Referenced by G4ErrorFreeTrajState::Update().

00067 {
00068   fPosition = pos;
00069   fMomentum = mom;
00070 }


Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  out,
const G4ErrorTrajState ts 
) [friend]

Definition at line 111 of file G4ErrorTrajState.cc.

00112 {
00113   //  long mode = out.setf(std::ios::fixed,std::ios::floatfield);
00114   out  
00115     << " G4ErrorTrajState of type " << ts.theTSType << " : partycle: "
00116     << ts.fParticleType << "  position: " << std::setw(6) << ts.fPosition
00117     << "              momentum: " << ts.fMomentum
00118     << "   error matrix ";
00119   G4cout << ts.fError << G4endl;
00120 
00121   return out;
00122 }


Field Documentation

G4double G4ErrorTrajState::fCharge [protected]

Definition at line 127 of file G4ErrorTrajState.hh.

Referenced by BuildCharge(), G4ErrorSurfaceTrajState::BuildErrorMatrix(), G4ErrorFreeTrajState::G4ErrorFreeTrajState(), GetCharge(), and SetCharge().

G4ErrorTrajErr G4ErrorTrajState::fError [protected]

Definition at line 128 of file G4ErrorTrajState.hh.

Referenced by G4ErrorSurfaceTrajState::BuildErrorMatrix(), G4ErrorFreeTrajState::G4ErrorFreeTrajState(), GetError(), operator<<(), G4ErrorFreeTrajState::PropagateError(), and SetError().

G4Vector3D G4ErrorTrajState::fMomentum [protected]

Definition at line 126 of file G4ErrorTrajState.hh.

Referenced by G4ErrorSurfaceTrajState::BuildErrorMatrix(), G4ErrorFreeTrajState::G4ErrorFreeTrajState(), G4ErrorSurfaceTrajState::G4ErrorSurfaceTrajState(), GetMomentum(), operator<<(), SetData(), SetMomentum(), G4ErrorSurfaceTrajState::SetParameters(), G4ErrorFreeTrajState::SetParameters(), G4ErrorSurfaceTrajState::SetPosition(), G4ErrorFreeTrajState::SetPosition(), and UpdatePosMom().

G4String G4ErrorTrajState::fParticleType [protected]

Definition at line 124 of file G4ErrorTrajState.hh.

Referenced by BuildCharge(), GetParticleType(), operator<<(), SetData(), and SetParticleType().

G4Point3D G4ErrorTrajState::fPosition [protected]

Definition at line 125 of file G4ErrorTrajState.hh.

Referenced by G4ErrorSurfaceTrajState::BuildErrorMatrix(), G4ErrorFreeTrajState::G4ErrorFreeTrajState(), G4ErrorSurfaceTrajState::G4ErrorSurfaceTrajState(), GetPosition(), operator<<(), SetData(), G4ErrorSurfaceTrajState::SetMomentum(), G4ErrorFreeTrajState::SetMomentum(), G4ErrorSurfaceTrajState::SetParameters(), G4ErrorFreeTrajState::SetParameters(), SetPosition(), and UpdatePosMom().

G4int G4ErrorTrajState::iverbose [protected]

Definition at line 134 of file G4ErrorTrajState.hh.

Referenced by G4ErrorSurfaceTrajState::BuildErrorMatrix(), G4ErrorFreeTrajState::G4ErrorFreeTrajState(), G4ErrorTrajState(), and G4ErrorFreeTrajState::PropagateError().

G4Track* G4ErrorTrajState::theG4Track [protected]

Definition at line 132 of file G4ErrorTrajState.hh.

Referenced by GetG4Track(), and SetG4Track().

G4eTSType G4ErrorTrajState::theTSType [protected]

Definition at line 130 of file G4ErrorTrajState.hh.

Referenced by GetTSType(), and operator<<().


The documentation for this class was generated from the following files:
Generated on Mon May 27 17:51:56 2013 for Geant4 by  doxygen 1.4.7