Package cnuphys.lund
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 GeneratedParticleRecord
int
Get the integer chargedouble
getKineticEnergy
(LundId lundId) Get the kinetic energy in GeV.double
Get the momentum in GeV/cdouble
getPhi()
Get the initial azimuthal angle in degrees.double
getTheta()
Get the initial polar angle in degrees.double
getTotalEnergy
(LundId lundId) The total energy in GeV.double
Get the the X vertex position in mdouble
Get the the Y vertex position in mdouble
Get the the Z vertex position in mhashKey()
Records a reduced precision String version as a hash keystatic String
Records a reduced precision String version as a hash keystatic void
toString()
static String
valStr
(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
-