Geant4-11
Public Member Functions | Data Fields
mcscore.MCVertex Class Reference

Public Member Functions

def __del__ (self)
 
def __init__ (self, ax, ay, az)
 
def append_particle (self, aparticle)
 
def dump_vertex (self, stream)
 
def printout (self)
 

Data Fields

 nparticle
 
 particle_list
 
 x
 
 y
 
 z
 

Detailed Description

Definition at line 46 of file mcscore.py.

Constructor & Destructor Documentation

◆ __init__()

def mcscore.MCVertex.__init__ (   self,
  ax,
  ay,
  az 
)

Definition at line 48 of file mcscore.py.

48 def __init__(self, ax, ay, az):
49 self.x = ax
50 self.y = ay
51 self.z = az
52 self.nparticle = 0
53 self.particle_list = []
54

◆ __del__()

def mcscore.MCVertex.__del__ (   self)

Definition at line 74 of file mcscore.py.

74 def __del__(self):
75 np = len(self.particle_list)
76 del self.particle_list[0:np]
77
78
79# ==================================================================
80# I/O interface
81# ==================================================================

References mcscore.MCVertex.particle_list.

Member Function Documentation

◆ append_particle()

def mcscore.MCVertex.append_particle (   self,
  aparticle 
)

Definition at line 55 of file mcscore.py.

55 def append_particle(self, aparticle):
56 self.particle_list.append(aparticle)
57 self.nparticle= self.nparticle+1
58

References mcscore.MCVertex.nparticle, and mcscore.MCVertex.particle_list.

◆ dump_vertex()

def mcscore.MCVertex.dump_vertex (   self,
  stream 
)

Definition at line 65 of file mcscore.py.

65 def dump_vertex(self, stream):
66 aline = "%g %g %g %d\n" % \
67 (self.x/m, self.y/m, self.z/m, self.nparticle)
68 stream.write(aline)
69 for p in self.particle_list:
70 aline = " %s %d %d %g %g %g %g\n" % \
71 (p.name, p.Z, p.A, p.kineticE/MeV, p.px/MeV, p.py/MeV, p.pz/MeV)
72 stream.write(aline)
73

References mcscore.MCVertex.nparticle, mcscore.MCVertex.particle_list, mcscore.MCVertex.x, HepGeom::BasicVector3D< T >.x(), HepGeom::BasicVector3D< double >.x(), HepGeom::BasicVector3D< G4double >.x(), HepGeom::BasicVector3D< float >.x(), CLHEP::HepLorentzVector.x(), CLHEP::Hep3Vector.x(), CLHEP::Hep2Vector.x(), gz_state.x, G4PolyPhiFaceVertex.x, G4Voxel::Index.x, G4INCL::InterpolationNode.x, G4INCL::RootFinder::Solution.x, G4INCL::ThreeVector.x, MCGIDI_pdfsOfXGivenW_sampled_s.x, ptwXYPoint_s.x, G4GMocrenFileSceneHandler::Index3D.x, G4VisCommandSceneAddScale::Scale.x, mcscore.MCVertex.y, HepGeom::BasicVector3D< G4double >.y(), HepGeom::BasicVector3D< double >.y(), HepGeom::BasicVector3D< T >.y(), HepGeom::BasicVector3D< float >.y(), CLHEP::HepLorentzVector.y(), CLHEP::Hep3Vector.y(), CLHEP::Hep2Vector.y(), G4PolyPhiFaceVertex.y, G4Voxel::Index.y, G4INCL::InterpolationNode.y, G4INCL::RootFinder::Solution.y, G4INCL::ThreeVector.y, ptwXYPoint_s.y, G4GMocrenFileSceneHandler::Index3D.y, G4VisCommandSceneAddScale::Scale.y, mcscore.MCVertex.z, HepGeom::BasicVector3D< float >.z(), HepGeom::BasicVector3D< T >.z(), HepGeom::BasicVector3D< G4double >.z(), HepGeom::BasicVector3D< double >.z(), CLHEP::HepLorentzVector.z(), CLHEP::Hep3Vector.z(), G4PolyconeSideRZ.z, G4PolyconeSide.z, G4PolyhedraSideRZ.z, G4PolyhedraSide.z, G4PolyPhiFaceVertex.z, G4GDMLReadSolids::rzPointType.z, G4GDMLReadSolids::zplaneType.z, G4DNACrossSectionDataSet.z, G4Voxel::Index.z, G4CrossSectionDataSet.z, G4EMDataSet.z, G4ShellEMDataSet.z, G4DataSet.z, G4PixeShellDataSet.z, G4INCL::ThreeVector.z, G4GMocrenFileSceneHandler::Index3D.z, and G4VisCommandSceneAddScale::Scale.z.

◆ printout()

def mcscore.MCVertex.printout (   self)

Definition at line 59 of file mcscore.py.

59 def printout(self):
60 print("@@@ vertex: x=(%g,%g,%g) Nsec=%3d" % \
61 (self.x/cm, self.y/cm, self.z/cm, self.nparticle))
62 for p in self.particle_list:
63 p.printout()
64
void print(G4double elem)

References mcscore.MCVertex.nparticle, mcscore.MCVertex.particle_list, print(), mcscore.MCVertex.x, HepGeom::BasicVector3D< T >.x(), HepGeom::BasicVector3D< float >.x(), HepGeom::BasicVector3D< double >.x(), HepGeom::BasicVector3D< G4double >.x(), CLHEP::HepLorentzVector.x(), CLHEP::Hep3Vector.x(), CLHEP::Hep2Vector.x(), gz_state.x, G4PolyPhiFaceVertex.x, G4Voxel::Index.x, G4INCL::InterpolationNode.x, G4INCL::RootFinder::Solution.x, G4INCL::ThreeVector.x, MCGIDI_pdfsOfXGivenW_sampled_s.x, ptwXYPoint_s.x, G4GMocrenFileSceneHandler::Index3D.x, G4VisCommandSceneAddScale::Scale.x, mcscore.MCVertex.y, HepGeom::BasicVector3D< float >.y(), HepGeom::BasicVector3D< G4double >.y(), HepGeom::BasicVector3D< T >.y(), HepGeom::BasicVector3D< double >.y(), CLHEP::HepLorentzVector.y(), CLHEP::Hep3Vector.y(), CLHEP::Hep2Vector.y(), G4PolyPhiFaceVertex.y, G4Voxel::Index.y, G4INCL::InterpolationNode.y, G4INCL::RootFinder::Solution.y, G4INCL::ThreeVector.y, ptwXYPoint_s.y, G4GMocrenFileSceneHandler::Index3D.y, G4VisCommandSceneAddScale::Scale.y, mcscore.MCVertex.z, HepGeom::BasicVector3D< float >.z(), HepGeom::BasicVector3D< double >.z(), HepGeom::BasicVector3D< T >.z(), HepGeom::BasicVector3D< G4double >.z(), CLHEP::HepLorentzVector.z(), CLHEP::Hep3Vector.z(), G4PolyconeSideRZ.z, G4PolyconeSide.z, G4PolyhedraSideRZ.z, G4PolyhedraSide.z, G4PolyPhiFaceVertex.z, G4GDMLReadSolids::rzPointType.z, G4GDMLReadSolids::zplaneType.z, G4DNACrossSectionDataSet.z, G4Voxel::Index.z, G4CrossSectionDataSet.z, G4EMDataSet.z, G4ShellEMDataSet.z, G4DataSet.z, G4PixeShellDataSet.z, G4INCL::ThreeVector.z, G4GMocrenFileSceneHandler::Index3D.z, and G4VisCommandSceneAddScale::Scale.z.

Field Documentation

◆ nparticle

mcscore.MCVertex.nparticle

◆ particle_list

mcscore.MCVertex.particle_list

◆ x

mcscore.MCVertex.x

Definition at line 49 of file mcscore.py.

Referenced by mcscore.MCVertex.dump_vertex(), and mcscore.MCVertex.printout().

◆ y

mcscore.MCVertex.y

Definition at line 50 of file mcscore.py.

Referenced by mcscore.MCVertex.dump_vertex(), and mcscore.MCVertex.printout().

◆ z

mcscore.MCVertex.z

Definition at line 51 of file mcscore.py.

Referenced by mcscore.MCVertex.dump_vertex(), and mcscore.MCVertex.printout().


The documentation for this class was generated from the following file: