Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:59:30

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 //  GEANT 4 class header file
0031 //
0032 //  GFlashSamplingShowerParameterisation
0033 //
0034 //  Class description:
0035 //
0036 //  GFlash concrete sampling shower parameterisation
0037 
0038 // Author: Joanna Weng - 02.2004
0039 //---------------------------------------------------------------
0040 #ifndef GFlashSamplingShowerParameterisation_h
0041 #define GFlashSamplingShowerParameterisation_h 1
0042 
0043 #include "globals.hh"
0044 #include "GFlashSamplingShowerTuning.hh"
0045 #include "GVFlashShowerParameterisation.hh"
0046 
0047 class G4Material;
0048 
0049 class GFlashSamplingShowerParameterisation
0050   : public GVFlashShowerParameterisation
0051 {
0052   public:
0053 
0054     GFlashSamplingShowerParameterisation(G4Material* aMat1, G4Material* aMat2,
0055                                          G4double d1, G4double d2,
0056     /// \param aMat1 passive material, \param dd1 - passive layer thickness
0057     /// \param aMat2 active material,  \param dd2 - acive layer thickness
0058 
0059     GFlashSamplingShowerTuning * aPar = 0);
0060     ~GFlashSamplingShowerParameterisation();
0061 
0062     void ComputeRadialParameters(G4double y, G4double Tau);
0063     void GenerateLongitudinalProfile(G4double Energy); 
0064     void ComputeZAX0EFFetc();
0065 
0066     G4double IntegrateEneLongitudinal(G4double LongitudinalStep);
0067     G4double IntegrateNspLongitudinal(G4double LongitudinalStep);
0068     G4double ComputeTau(G4double LongitudinalPosition);
0069     void SetMaterial(G4Material *mat1, G4Material *mat2);
0070     G4double GeneratePhi();
0071     G4double GenerateRadius(G4int ispot, G4double Energy,
0072     G4double LongitudinalPosition);
0073     G4double GenerateExponential(G4double Energy);
0074 
0075     inline G4double GetAveR99() {return (3.5 * Rmeff);}
0076     inline G4double GetAveR90() {return (1.5 * Rmeff);} //ok
0077     //
0078     inline G4double GetAveTmx() {return (X0eff*std::exp(AveLogTmax));}
0079     inline G4double GetAveT99() {return (X0eff*AveLogTmax/(AveLogAlpha-1.00));}
0080     inline G4double GetAveT90() {return (2.5* X0eff* std::exp( AveLogTmax));}
0081     // 
0082     inline G4double GetNspot()  {return NSpot;}
0083     inline G4double GetX0()     {return X0eff;}  
0084     inline G4double GetEc()     {return Eceff;} 
0085     inline G4double GetRm()     {return Rmeff;} 
0086 
0087     G4double ApplySampling(const G4double DEne, const G4double Energy);
0088 
0089   private:
0090 
0091     // medium related quantities
0092     //
0093     G4Material *material1, *material2 ;
0094     G4double  density1, A1, Z1, X01, Ec1, Rm1, d1;
0095     G4double  density2, A2, Z2, X02, Ec2, Rm2, d2;
0096     G4double  Aeff, Rhoeff, X0eff, Eceff, Rmeff, Fs, ehat, Zeff;
0097 
0098     // Resolution
0099     //
0100     G4double ConstantResolution; 
0101     G4double NoiseResolution;   
0102     G4double SamplingResolution;
0103      
0104     // parametrization parameters
0105     //
0106     GFlashSamplingShowerTuning * thePar;
0107 
0108     // Cashed parameters:  
0109     // Longitudinal Coefficients for a homogenious calo
0110     //
0111     G4double ParAveT1, ParAveT2;
0112     G4double ParAveA1,ParAveA2, ParAveA3;
0113     G4double ParSigLogT1,ParSigLogT2;
0114     G4double ParSigLogA1,ParSigLogA2;
0115     G4double ParRho1,ParRho2;
0116 
0117     //Cashed parameters:  
0118     // Longitudinal Coefficients for a sampling calo
0119     //
0120     G4double ParsAveT1, ParsAveT2;
0121     G4double ParsAveA1,ParsAveA2;
0122     G4double ParsSigLogT1,ParsSigLogT2;
0123     G4double ParsSigLogA1,ParsSigLogA2;
0124     G4double ParsRho1,ParsRho2;
0125     void ComputeLongitudinalParameters(G4double y);
0126     void GenerateEnergyProfile(G4double y);
0127     void GenerateNSpotProfile(G4double y);
0128 
0129     // Radial Coefficients homo
0130     //
0131     G4double ParRC1,ParRC2,ParRC3,ParRC4;
0132     G4double ParWC1,ParWC2,ParWC3;
0133     G4double ParWC4,ParWC5,ParWC6;
0134     G4double ParRT1,ParRT2,ParRT3,ParRT4;
0135     G4double ParRT5,ParRT6;
0136 
0137     // Radial Coefficients sampling
0138     //
0139     G4double ParsRC1,ParsRC2;
0140     G4double ParsWC1,ParsWC2;   
0141     G4double ParsRT1,ParsRT2;
0142 
0143     // Spot multiplicity Coefficients
0144     //
0145     G4double ParsSpotT1,ParsSpotT2,ParsSpotA1, ParsSpotA2;
0146     G4double ParsSpotN1,ParsSpotN2;
0147 
0148     // PARAMETRISATION variables (Energy & position dependent)
0149     // Longitudinal 
0150     // homogeneous
0151     //
0152     G4double AveLogAlphah,AveLogTmaxh;
0153     G4double SigmaLogAlphah,SigmaLogTmaxh;
0154     G4double Rhoh;
0155     G4double Alphah,Tmaxh,Betah;  
0156 
0157     // PARAMETRISATION variables (Energy & position dependent)
0158     // Longitudinal 
0159     // sampling
0160     //
0161     G4double AveLogAlpha,AveLogTmax;
0162     G4double SigmaLogAlpha,SigmaLogTmax;
0163     G4double Rho;
0164     G4double Alpha,Tmax,Beta;  
0165 
0166     // Multiplicity
0167     //
0168     G4double NSpot,AlphaNSpot,TNSpot,BetaNSpot;
0169 
0170     //Radial
0171     //
0172     G4double RadiusCore, WeightCore,RadiusTail; 
0173 };
0174 
0175 #endif