73 buildAsymmetryTable(true),
74 useAsymmetryTable(true),
78 theAsymmetryTable(NULL)
91 if (theAsymmetryTable) {
93 delete theAsymmetryTable;
102 isInitialised =
true;
109 else if(10 == mType) selectedModel = emModel;
120 G4cout <<
" Total cross sections has a good parametrisation"
121 <<
" from 10 KeV to (100/Z) GeV"
122 <<
"\n Sampling according " << selectedModel->
GetName() <<
" model"
130 if(ss ==
"Klein-Nishina") mType = 0;
131 if(ss ==
"Polarized-Compton") mType = 10;
149 if (theAsymmetryTable && useAsymmetryTable) {
166 if (!VolumeIsPolarized || mfp ==
DBL_MAX)
return mfp;
171 G4cout <<
" Polarization " << GammaPolarization <<
G4endl;
172 G4cout <<
" MaterialPol. " << ElectronPolarization <<
G4endl;
184 asymmetry = aVector->
GetValue(GammaEnergy, isOutRange);
186 G4cout <<
" MaterialIndex " << midx <<
" is out of range \n";
195 G4double pol=ElectronPolarization*GammaDirection0;
197 G4double polProduct = GammaPolarization.
p3() * pol;
198 mfp *= 1. / ( 1. + polProduct * asymmetry );
201 G4cout <<
" MeanFreePath: " << mfp / mm <<
" mm " <<
G4endl;
219 if (theAsymmetryTable && useAsymmetryTable) {
236 if (!VolumeIsPolarized || mfp ==
DBL_MAX)
return mfp;
241 G4cout <<
" Polarization " << GammaPolarization <<
G4endl;
242 G4cout <<
" MaterialPol. " << ElectronPolarization <<
G4endl;
254 asymmetry = aVector->
GetValue(GammaEnergy, isOutRange);
256 G4cout <<
" MaterialIndex " << midx <<
" is out of range \n";
265 G4double pol=ElectronPolarization*GammaDirection0;
267 G4double polProduct = GammaPolarization.
p3() * pol;
268 mfp *= 1. / ( 1. + polProduct * asymmetry );
271 G4cout <<
" MeanFreePath: " << mfp / mm <<
" mm " <<
G4endl;
285 if(buildAsymmetryTable)
296 if(buildAsymmetryTable)
309 for(
size_t i=0; i<numOfCouples; ++i) {
310 if (!theAsymmetryTable)
break;
311 if (theAsymmetryTable->
GetFlag(i)) {
362 lAsymmetry=sigma2/sigma0-1.;
G4double condition(const G4ErrorSymMatrix &m)
CLHEP::Hep3Vector G4ThreeVector
G4DLLIMPORT std::ostream G4cout
const G4ThreeVector & GetMomentumDirection() const
G4double GetKineticEnergy() const
static G4Electron * Electron()
static void SetPhysicsVector(G4PhysicsTable *physTable, size_t idx, G4PhysicsVector *vec)
static G4PhysicsTable * PreparePhysicsTable(G4PhysicsTable *physTable)
G4bool GetFlag(size_t i) const
G4double GetValue(G4double theEnergy, G4bool &isOutRange)
virtual G4double GetLowEdgeEnergy(size_t binNumber) const
void PutValue(size_t index, G4double theValue)
bool IsPolarized(G4LogicalVolume *lVol) const
static G4PolarizationManager * GetInstance()
const G4ThreeVector & GetVolumePolarization(G4LogicalVolume *lVol) const
void SetTargetPolarization(const G4ThreeVector &pTarget)
void SetBeamPolarization(const G4ThreeVector &pBeam)
virtual ~G4PolarizedCompton()
G4double ComputeAsymmetry(G4double energy, const G4MaterialCutsCouple *couple, const G4ParticleDefinition &particle, G4double cut, G4double &tAsymmetry)
virtual G4double PostStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
void SetModel(const G4String &name)
virtual void PreparePhysicsTable(const G4ParticleDefinition &)
virtual void BuildPhysicsTable(const G4ParticleDefinition &)
void BuildAsymmetryTable(const G4ParticleDefinition &part)
G4PolarizedCompton(const G4String &processName="pol-compt", G4ProcessType type=fElectromagnetic)
virtual void InitialiseProcess(const G4ParticleDefinition *)
virtual G4double GetMeanFreePath(const G4Track &aTrack, G4double previousStepSize, G4ForceCondition *condition)
const G4MaterialCutsCouple * GetMaterialCutsCouple(G4int i) const
size_t GetTableSize() const
static G4ProductionCutsTable * GetProductionCutsTable()
G4VPhysicalVolume * GetVolume() const
G4Material * GetMaterial() const
const G4DynamicParticle * GetDynamicParticle() const
const G4ThreeVector & GetPolarization() const
void SetHighEnergyLimit(G4double)
void SetLowEnergyLimit(G4double)
G4double CrossSection(const G4MaterialCutsCouple *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
const G4String & GetName() const
G4double GetMeanFreePath(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
G4PhysicsVector * LambdaPhysicsVector(const G4MaterialCutsCouple *)
void AddEmModel(G4int, G4VEmModel *, const G4Region *region=0)
void SetBuildTableFlag(G4bool val)
void SetMinKinEnergy(G4double e)
G4double PostStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
void SetLambdaBinning(G4int nbins)
void SetSecondaryParticle(const G4ParticleDefinition *p)
void BuildPhysicsTable(const G4ParticleDefinition &)
G4double MaxKinEnergy() const
G4double MinKinEnergy() const
void PreparePhysicsTable(const G4ParticleDefinition &)
G4int LambdaBinning() const
void SetMaxKinEnergy(G4double e)
size_t CurrentMaterialCutsCoupleIndex() const
G4LogicalVolume * GetLogicalVolume() const
const G4String & GetName() const
void SetProcessSubType(G4int)