Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-31 09:21:47

0001 //
0002 // ********************************************************************
0003 // * License and Disclaimer                                           *
0004 // *                                                                  *
0005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
0006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
0007 // * conditions of the Geant4 Software License,  included in the file *
0008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
0009 // * include a list of copyright holders.                             *
0010 // *                                                                  *
0011 // * Neither the authors of this software system, nor their employing *
0012 // * institutes,nor the agencies providing financial support for this *
0013 // * work  make  any representation or  warranty, express or implied, *
0014 // * regarding  this  software system or assume any liability for its *
0015 // * use.  Please see the license in the file  LICENSE  and URL above *
0016 // * for the full disclaimer and the limitation of liability.         *
0017 // *                                                                  *
0018 // * This  code  implementation is the result of  the  scientific and *
0019 // * technical work of the GEANT4 collaboration.                      *
0020 // * By using,  copying,  modifying or  distributing the software (or *
0021 // * any work based  on the software)  you  agree  to acknowledge its *
0022 // * use  in  resulting  scientific  publications,  and indicate your *
0023 // * acceptance of all terms of the Geant4 Software license.          *
0024 // ********************************************************************
0025 //
0026 //
0027 
0028 // ********************************************************************
0029 //
0030 //  CaTS (Calorimetry and Tracking Simulation)
0031 //
0032 //  Authors : Hans Wenzel
0033 //            Soon Yung Jun
0034 //            (Fermi National Accelerator Laboratory)
0035 //
0036 // History
0037 //   October 18th, 2021 : first implementation
0038 //
0039 // ********************************************************************
0040 //
0041 /// \file RadiatorSD.hh
0042 /// \brief Definition of the CaTS::RadiatorSD class
0043 
0044 #pragma once
0045 
0046 #include "G4VSensitiveDetector.hh"
0047 #include "G4ScintillationTrackInformation.hh"
0048 #include <G4MaterialPropertyVector.hh>
0049 #include <G4String.hh>
0050 #include <G4Types.hh>
0051 class G4Step;
0052 class G4Material;
0053 class G4HCofThisEvent;
0054 class G4MaterialPropertiesTable;
0055 class G4PhysicsOrderedFreeVector;
0056 class G4PhysicsTable;
0057 class G4TouchableHistory;
0058 
0059 class RadiatorSD : public G4VSensitiveDetector
0060 {
0061  public:
0062   RadiatorSD(G4String name);
0063   virtual ~RadiatorSD() = default;
0064   // methods from base class
0065   void Initialize(G4HCofThisEvent* hitCollection) final;
0066   G4bool ProcessHits(G4Step* step, G4TouchableHistory* history) final;
0067   void EndOfEvent(G4HCofThisEvent* hitCollection) final;
0068 
0069  private:
0070   const G4Material* aMaterial;
0071   G4MaterialPropertiesTable* aMaterialPropertiesTable;
0072   //
0073   // properties related to Scintillation
0074   //
0075   G4MaterialPropertyVector* Fast_Intensity;
0076   G4MaterialPropertyVector* Slow_Intensity;
0077   G4double YieldRatio;        // slowerRatio,
0078   G4double FastTimeConstant;  // TimeConstant,
0079   G4double SlowTimeConstant;  // slowerTimeConstant,
0080   G4ScintillationType ScintillationType;
0081   //
0082   // properties related to Cerenkov
0083   //
0084   G4MaterialPropertyVector* Rindex;
0085   G4PhysicsOrderedFreeVector* CerenkovAngleIntegrals;
0086   const G4PhysicsTable* thePhysicsTable;
0087   G4double Pmin{ 0 };
0088   G4double Pmax{ 0 };
0089   G4double dp{ 0 };
0090   G4double nMax{ 0 };
0091   G4bool first{ true };
0092   G4bool verbose{ false };
0093   G4int tCphotons{ 0 };
0094   G4int tSphotons{ 0 };
0095 #ifdef WITH_G4OPTICKS
0096   //
0097   // info needed for generating Cerenkov photons on the GPU;
0098   //
0099   G4double maxCos{ 0.0 };
0100   G4double maxSin2{ 0.0 };
0101   G4double beta{ 0.0 };
0102   G4double beta1{ 0.0 };
0103   G4double beta2{ 0.0 };
0104   G4double BetaInverse{ 0.0 };
0105   G4double MeanNumberOfPhotons1{ 0.0 };
0106   G4double MeanNumberOfPhotons2{ 0.0 };
0107   G4int Sphotons{ 0 };  // number of scintillation photons this step
0108   G4int Cphotons{ 0 };  // number of Cerenkov photons this step
0109   const G4double ScintillationTime{ 0.0 };
0110   const G4int scntId{ 1 };
0111 #endif
0112 };