iceCube.uhe.event
Class JulietEventGenerator

java.lang.Object
  extended by iceCube.uhe.event.JulietEventGenerator

public class JulietEventGenerator
extends java.lang.Object


   This is a run manager for the Event class. It initializes all the obejcts
   and parameters necessary for events and then run the Event objects.

   Initial version written by Shigeru Yoshida November 28 2004.
   Ice3 geometry calculation is implemented by S.Yoshida and T.Noda December 29 2004.
   Modified to adopt IceTray framework by K.Hoshina January 27 2005.
      added functions:
        - J3UnitVector getPrimaryParticleDirectionInEarthCenterCoordinate() 
        - J3UnitVector getPrimaryParticleDirectionInIceCubeCoordinate() 
        - J3Vector     getEndLocationInIceCubeCoordinate() 
        - J3Vector     wherePrimaryParticleEndsInIceCubeCoordinate()
      added field:
        - J3Vector endLocation_J3Vector_ice3
   Modified for neutrinos induced simulations by M.Ono Aplel 1 2007.
      modified a function:
        - public void runSingleEvent()
      added :
        - double neutrinoMinimumEnergyInTravel
   Modified for Glashow Resonance by M.Ono December 2 2007.
   Modified for function to shift Geometry by S.Yoshida December 15 2007.
   


Constructor Summary
JulietEventGenerator()
           
JulietEventGenerator(int flavorID, int doubletID, double energy, int mediumID, int doCC, int doNC, int doMuBrems, int doTauBrems, int doMuKnock, int doTauKnock, int doMu2e, int doTau2e, int doMu2mu, int doTau2mu, int doMu2tau, int doTau2tau, int doMuPN, int doTauPN, int doMuDecay, int doTauDecay, int posID)
          The same constructor, but without the glashow resoanance.
JulietEventGenerator(int flavorID, int doubletID, double energy, int mediumID, int doCC, int doNC, int doMuBrems, int doTauBrems, int doMuKnock, int doTauKnock, int doMu2e, int doTau2e, int doMu2mu, int doTau2mu, int doMu2tau, int doTau2tau, int doMuPN, int doTauPN, int doGR, int doMuDecay, int doTauDecay, int posID)
          Constructor.
 
Method Summary
 void configurePropagationGeometry()
          Configure the particle progation geometry.
 void definePropagatingParticle(int flavor, int doublet, double energy)
           
 void definePropagatingParticle(int flavor, int doublet, double energy, J3Line axis)
          Method to set primary energy, flavor, doublet for defining the input propagating particle, and its geomerty(for future use).
 void definePropagationGeometry(double x_ice3, double y_ice3, double z_ice3, double nadirAngle_ice3, double azimuthAngle_ice3)
          define the geometry of propagating particles
 void definePropagationGeometry(double x_ice3, double y_ice3, double z_ice3, double nx, double ny, double nz)
          define the geometry of propagating particles
 void definePropagationGeometry(J3Line particleAxisIce3)
          define the geometry of propagating particles
 J3Vector getGeometryShift()
          Get the geometrical shift in IceCube coordinate
 int getListedEvents(java.io.DataOutputStream out)
          Method to acquire all the listed variables: the cascade particles, their energies, and their locations which occured along the track.
 java.util.ListIterator getLocationIce3Iterator()
          Return location hit iterator which allows an external object to access each location stored in this object
static int getNeutrinoInteractionWeight()
          Get the present neutrino interaction weight in the InteractionBase
 java.util.ListIterator getParticleIterator()
          Return particle hit iterator which allows an external object to access each Particle stored in this object
 J3UnitVector getPrimaryParticleDirectionInEarthCenterCoordinate()
          Get of propagating particle direction represented by Earth center coordinate
 J3UnitVector getPrimaryParticleDirectionInIceCubeCoordinate()
          Get of propagating particle direction represented by IceCube coordinate
 double getStartLocationAlongTheAxis()
          Get the start location of primary particle.
 java.util.ListIterator getTrackLocationIce3Iterator()
           
 java.util.ListIterator getTrackParticleIterator()
           
 void moveParticleAxis(double depth)
          move the propagating axis by given slant depth [g/cm^2]
 void runEventOnMatrix(int numberOfEvent, java.io.DataOutputStream out)
          Method to run multiple events (numberOfEvent) with various primary energies from logE = Particle.getLogEnergyMinimum() all the way up to 10^12 GeV.
 void runSingleEvent()
          Method to run a single event with a monocromatic primary energy given by the constructor.
 void setGeometryShift(J3Vector shift)
          Set the geometrical shift in IceCube coordinate
static void setNeutrinoInteractionWeight(int weight)
          Change the Neutrino interaction weight in the InteractionBase
 void setStartLocationAlongTheAxis(double start)
          Set the start location of primary particle along its trajectory axis (particle point/J3Line)
 J3Vector wherePrimaryParticleEndsInIceCubeCoordinate()
          Get the point location where the particle run starts.
 J3Vector wherePrimaryParticleStartsInEarthCenterCoordinate()
          Get the point location where the particle run starts.
 J3Vector wherePrimaryParticleStartsInIceCubeCoordinate()
          Get the point location where the particle run starts.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JulietEventGenerator

public JulietEventGenerator(int flavorID,
                            int doubletID,
                            double energy,
                            int mediumID,
                            int doCC,
                            int doNC,
                            int doMuBrems,
                            int doTauBrems,
                            int doMuKnock,
                            int doTauKnock,
                            int doMu2e,
                            int doTau2e,
                            int doMu2mu,
                            int doTau2mu,
                            int doMu2tau,
                            int doTau2tau,
                            int doMuPN,
                            int doTauPN,
                            int doGR,
                            int doMuDecay,
                            int doTauDecay,
                            int posID)
                     throws java.io.IOException
Constructor. Here all the obejcts including individual InteractionsBase objects (which implies it reads out the InteractionsMatrix objects dumped in the directory classes/iceCube/uhe/interactions/) and Mu/TauDecayBase objects are generated. Each object is generated in an interactive way to an user.

Throws:
java.io.IOException

JulietEventGenerator

public JulietEventGenerator(int flavorID,
                            int doubletID,
                            double energy,
                            int mediumID,
                            int doCC,
                            int doNC,
                            int doMuBrems,
                            int doTauBrems,
                            int doMuKnock,
                            int doTauKnock,
                            int doMu2e,
                            int doTau2e,
                            int doMu2mu,
                            int doTau2mu,
                            int doMu2tau,
                            int doTau2tau,
                            int doMuPN,
                            int doTauPN,
                            int doMuDecay,
                            int doTauDecay,
                            int posID)
                     throws java.io.IOException
The same constructor, but without the glashow resoanance. This constructor exists to maintain the backward compatibility

Throws:
java.io.IOException

JulietEventGenerator

public JulietEventGenerator()
                     throws java.io.IOException
Throws:
java.io.IOException
Method Detail

setStartLocationAlongTheAxis

public void setStartLocationAlongTheAxis(double start)
Set the start location of primary particle along its trajectory axis (particle point/J3Line)


getStartLocationAlongTheAxis

public double getStartLocationAlongTheAxis()
Get the start location of primary particle. Return the distance [cm] along the particle axis from the Earth(+glacier) surface to the start location.


wherePrimaryParticleStartsInEarthCenterCoordinate

public J3Vector wherePrimaryParticleStartsInEarthCenterCoordinate()
Get the point location where the particle run starts. Represented by Earth center coordinate


wherePrimaryParticleStartsInIceCubeCoordinate

public J3Vector wherePrimaryParticleStartsInIceCubeCoordinate()
Get the point location where the particle run starts. Represented by the IceCube coordinate


wherePrimaryParticleEndsInIceCubeCoordinate

public J3Vector wherePrimaryParticleEndsInIceCubeCoordinate()
Get the point location where the particle run starts. Represented by the IceCube coordinate


getPrimaryParticleDirectionInEarthCenterCoordinate

public J3UnitVector getPrimaryParticleDirectionInEarthCenterCoordinate()
Get of propagating particle direction represented by Earth center coordinate


getPrimaryParticleDirectionInIceCubeCoordinate

public J3UnitVector getPrimaryParticleDirectionInIceCubeCoordinate()
Get of propagating particle direction represented by IceCube coordinate


setGeometryShift

public void setGeometryShift(J3Vector shift)
Set the geometrical shift in IceCube coordinate


getGeometryShift

public J3Vector getGeometryShift()
Get the geometrical shift in IceCube coordinate


definePropagatingParticle

public void definePropagatingParticle(int flavor,
                                      int doublet,
                                      double energy,
                                      J3Line axis)
Method to set primary energy, flavor, doublet for defining the input propagating particle, and its geomerty(for future use). If you do not call this method, the generator use the default values set by the constructor JulietEventGenerator().

        int flavor       :  flavor of the particle (c.f. Particle.java)
        int doublet      :  doublet of the particle (c.f. Particle.java)
        double energy    :  primary energy of the particle [GeV]
        J3Line axis      :  geometry of the particle trajectory. Must be represented
                            by the IceCubeCoordinate.


definePropagatingParticle

public void definePropagatingParticle(int flavor,
                                      int doublet,
                                      double energy)

definePropagationGeometry

public void definePropagationGeometry(double x_ice3,
                                      double y_ice3,
                                      double z_ice3,
                                      double nadirAngle_ice3,
                                      double azimuthAngle_ice3)
define the geometry of propagating particles
        double x_ice3  : x [cm] of a particle trajectory point in the IceCube coordinate
        double y_ice3  : y [cm] of a particle trajectory point in the IceCube coordinate
        double z_ice3  : z [cm] of a particle trajectory point in the IceCube coordinate
        double nadirAngle_ice3   : nadir angle [deg] define in the IceCube coodrinate
        double azimuthAngle_ice3 : nadir angle [deg] define in the IceCube coodrinate
       


definePropagationGeometry

public void definePropagationGeometry(double x_ice3,
                                      double y_ice3,
                                      double z_ice3,
                                      double nx,
                                      double ny,
                                      double nz)
define the geometry of propagating particles
        double x_ice3  : x [cm] of a particle trajectory point in the IceCube coordinate
        double y_ice3  : y [cm] of a particle trajectory point in the IceCube coordinate
        double z_ice3  : z [cm] of a particle trajectory point in the IceCube coordinate
        double nx,ny,nz : unit direction vector represented by the IceCube coordinate
       


definePropagationGeometry

public void definePropagationGeometry(J3Line particleAxisIce3)
define the geometry of propagating particles
        J3Line particleAxisIce3 : The primary particle trajectory. Should be
                                  defined by the IceCubeCoordinate.
       


configurePropagationGeometry

public void configurePropagationGeometry()
Configure the particle progation geometry.
        1. Setup the trajectory axis (J3Line) in the Earth center coordinate
        2. Calculate the point where the primary particle enters the earth
        3. Calculate the start location where the MC propgation run begines.
           It depnds on the propagationFlag setup by the constructor.
           when 1, the location is equal to the earth entrance point.
           when 2, it is IceCubeCoordinate.elevation away from the ice3 coordinate origin.
           when 3, it is equal to the original R0 of J3Line.
           You can change this location by calling the method 
           setStartLocationAlongTheAxis() if necessary
       


runSingleEvent

public void runSingleEvent()
Method to run a single event with a monocromatic primary energy given by the constructor.


moveParticleAxis

public void moveParticleAxis(double depth)
move the propagating axis by given slant depth [g/cm^2]


getListedEvents

public int getListedEvents(java.io.DataOutputStream out)
                    throws java.io.IOException
Method to acquire all the listed variables: the cascade particles, their energies, and their locations which occured along the track. Returns number of the interactions.

Throws:
java.io.IOException

getParticleIterator

public java.util.ListIterator getParticleIterator()
Return particle hit iterator which allows an external object to access each Particle stored in this object


getTrackParticleIterator

public java.util.ListIterator getTrackParticleIterator()

getLocationIce3Iterator

public java.util.ListIterator getLocationIce3Iterator()
Return location hit iterator which allows an external object to access each location stored in this object


getTrackLocationIce3Iterator

public java.util.ListIterator getTrackLocationIce3Iterator()

runEventOnMatrix

public void runEventOnMatrix(int numberOfEvent,
                             java.io.DataOutputStream out)
                      throws java.io.IOException
Method to run multiple events (numberOfEvent) with various primary energies from logE = Particle.getLogEnergyMinimum() all the way up to 10^12 GeV. The results are stored in the matrix form and will be handled by EventMatrix.class in the event package.

Throws:
java.io.IOException

setNeutrinoInteractionWeight

public static void setNeutrinoInteractionWeight(int weight)
Change the Neutrino interaction weight in the InteractionBase


getNeutrinoInteractionWeight

public static int getNeutrinoInteractionWeight()
Get the present neutrino interaction weight in the InteractionBase