///////////////////////////////////////////////////////////////////////////////
//
// Simulates optical Rayleigh scattering. This class simulates
// Rayleigh scattering. It should be used in preference to the Geant4
// G4OpRayleigh class as it will calculate mean free paths for all
// materials not just water.
//
// Author: P G Jones
//
// REVISION HISTORY:
// 2014-01-08 : P G Jones - New file.
// 12-05-2015 : I Coulter - Remove use of the "SNOMAN style" RS_SCALE_FACTOR
// This already exists in SNOMANOpRayleigh, isn't
// used in general use and causes confusion.
//
//////////////////////////////////////////////////////////////////////////////
#ifndef __RAT_OpRayleigh_hh__
#define __RAT_OpRayleigh_hh__
#include
#include
class G4PhysicsTable;
class G4MaterialPropertiesTable;
namespace RAT
{
class OpRayleigh : public G4VDiscreteProcess
{
public:
// Construct the class
//
// processName: optional, defaults to OpRayleigh
// type: optional, defaults to fOptical
OpRayleigh( const G4String& processName = "OpRayleigh",
G4ProcessType type = fOptical );
// Deletes the physics table
~OpRayleigh();
// Returns true if this code is applicable to the particle type
//
// particleType: definition of the particle type
// returns true if the particle type is an optical photon
G4bool IsApplicable( const G4ParticleDefinition& particleType ) { return ( &particleType == G4OpticalPhoton::OpticalPhoton() ); }
// Returns the mean free path for the track in mm.
//
// previousStepSize and condition are unused
G4double GetMeanFreePath( const G4Track& track,
G4double previousStepSize,
G4ForceCondition* condition );
// Invoke scattering to the track
//
// returns a particle change description
G4VParticleChange* PostStepDoIt( const G4Track& track,
const G4Step& step );
private:
// Builds the physics table, i.e. a table of mean free paths
void BuildThePhysicsTable();
G4PhysicsTable* fPhysicsTable; // The physics table used
};
} //::RAT
#endif