Class GeneratedParticleRecord
java.lang.Object
cnuphys.lund.GeneratedParticleRecord
- All Implemented Interfaces:
Serializable
Holds the Lund ID, vertex, momentum, and the initial angles giving the
direction of the particle's momentum.
- Author:
- heddle
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionGeneratedParticleRecord(int charge, double xo, double yo, double zo, double momentum, double theta, double phi) -
Method Summary
Modifier and TypeMethodDescriptionstatic GeneratedParticleRecordintGet the integer chargedoublegetKineticEnergy(LundId lundId) Get the kinetic energy in GeV.doubleGet the momentum in GeV/cdoublegetPhi()Get the initial azimuthal angle in degrees.doublegetTheta()Get the initial polar angle in degrees.doublegetTotalEnergy(LundId lundId) The total energy in GeV.doubleGet the the X vertex position in mdoubleGet the the Y vertex position in mdoubleGet the the Z vertex position in mhashKey()Records a reduced precision String version as a hash keystatic StringRecords a reduced precision String version as a hash keystatic voidtoString()static StringvalStr(double f)
-
Constructor Details
-
GeneratedParticleRecord
public GeneratedParticleRecord(int charge, double xo, double yo, double zo, double momentum, double theta, double phi) - Parameters:
charge- the charge: -1 for electron, 1 for proton, etcxo- the x vertex position in myo- the y vertex position in mzo- the z vertex position in mmomentum- initial momentum in GeV/ctheta- initial polar angle in degreesphi- initial azimuthal angle in degrees
-
-
Method Details
-
getCharge
public int getCharge()Get the integer charge- Returns:
- the integer charge
-
getVertexX
public double getVertexX()Get the the X vertex position in m- Returns:
- the X vertex position in m
-
getVertexY
public double getVertexY()Get the the Y vertex position in m- Returns:
- the Y vertex position in m
-
getVertexZ
public double getVertexZ()Get the the Z vertex position in m- Returns:
- the Z vertex position in m
-
getMomentum
public double getMomentum()Get the momentum in GeV/c- Returns:
- the momentum in GeV/c
-
getTheta
public double getTheta()Get the initial polar angle in degrees.- Returns:
- the initial polar angle in degrees.
-
getPhi
public double getPhi()Get the initial azimuthal angle in degrees.- Returns:
- the initial azimuthal angle in degrees.
-
getTotalEnergy
The total energy in GeV. This requires that we specify what particle this is.- Parameters:
lundid- the lundid of the particle- Returns:
- the total energy in GeV
-
getKineticEnergy
Get the kinetic energy in GeV. This requires that we specify what particle this is.- Parameters:
lundid- the lundid of the particle- Returns:
- the kinetic energy in GeV
-
toString
-
hashKey
Records a reduced precision String version as a hash key- Parameters:
rpr- the GeneratedParticleRecord- Returns:
- a reduced precision String version
-
hashKey
Records a reduced precision String version as a hash key- Parameters:
rpr- the GeneratedParticleRecord- Returns:
- a reduced precision String version
-
valStr
-
fromHash
-
main
-