77 theAsymmetryTable(NULL),
78 theTransverseAsymmetryTable(NULL)
89 if (theAsymmetryTable) {
91 delete theAsymmetryTable;
93 if (theTransverseAsymmetryTable) {
95 delete theTransverseAsymmetryTable;
104 isInitialised =
true;
132 if (theAsymmetryTable) {
144 if (!volumeIsPolarized || mfp ==
DBL_MAX)
return mfp;
155 G4cout <<
" Polarization " << positronPolarization <<
G4endl;
156 G4cout <<
" MaterialPol. " << electronPolarization <<
G4endl;
164 G4double lAsymmetry = (*theAsymmetryTable)(idx)->
165 GetValue(positronEnergy, isOutRange);
166 G4double tAsymmetry = (*theTransverseAsymmetryTable)(idx)->
167 GetValue(positronEnergy, isOutRange);
169 G4double polZZ = positronPolarization.
z()*
170 electronPolarization*positronDirection0;
171 G4double polXX = positronPolarization.
x()*
173 G4double polYY = positronPolarization.
y()*
176 G4double impact = 1. + polZZ*lAsymmetry + (polXX + polYY)*tAsymmetry;
181 G4cout <<
" MeanFreePath: " << mfp / mm <<
" mm " <<
G4endl;
182 G4cout <<
" Asymmetry: " << lAsymmetry <<
", " << tAsymmetry <<
G4endl;
183 G4cout <<
" PolProduct: " << polXX <<
", " << polYY <<
", " << polZZ <<
G4endl;
199 if (theAsymmetryTable) {
211 if (!volumeIsPolarized || mfp ==
DBL_MAX)
return mfp;
222 G4cout <<
" Polarization " << positronPolarization <<
G4endl;
223 G4cout <<
" MaterialPol. " << electronPolarization <<
G4endl;
231 G4double lAsymmetry = (*theAsymmetryTable)(idx)->
232 GetValue(positronEnergy, isOutRange);
233 G4double tAsymmetry = (*theTransverseAsymmetryTable)(idx)->
234 GetValue(positronEnergy, isOutRange);
236 G4double polZZ = positronPolarization.
z()*
237 electronPolarization*positronDirection0;
238 G4double polXX = positronPolarization.
x()*
240 G4double polYY = positronPolarization.
y()*
243 G4double impact = 1. + polZZ*lAsymmetry + (polXX + polYY)*tAsymmetry;
248 G4cout <<
" MeanFreePath: " << mfp / mm <<
" mm " <<
G4endl;
249 G4cout <<
" Asymmetry: " << lAsymmetry <<
", " << tAsymmetry <<
G4endl;
250 G4cout <<
" PolProduct: " << polXX <<
", " << polYY <<
", " << polZZ <<
G4endl;
278 G4cout<<
" annih-numOfCouples="<<numOfCouples<<
"\n";
279 for(
size_t i=0; i<numOfCouples; ++i) {
280 G4cout<<
"annih- "<<i<<
"/"<<numOfCouples<<
"\n";
281 if (!theAsymmetryTable)
break;
283 if (theAsymmetryTable->
GetFlag(i)) {
284 G4cout<<
" building pol-annih ... \n";
340 lAsymmetry=sigma2/sigma0-1.;
341 tAsymmetry=sigma3/sigma0-1.;
353 G4cout <<
" Polarized model for annihilation into 2 photons"
375 G4ThreeVector direction (sinTeta*std::cos(phi), sinTeta*std::sin(phi), cosTeta);
377 direction, electron_mass_c2) );
379 -direction, electron_mass_c2) );
G4double condition(const G4ErrorSymMatrix &m)
CLHEP::Hep3Vector G4ThreeVector
G4DLLIMPORT std::ostream G4cout
const G4ThreeVector & GetMomentumDirection() const
G4double GetKineticEnergy() const
void InitializeForPostStep(const G4Track &)
void AddSecondary(G4DynamicParticle *aParticle)
static void SetPhysicsVector(G4PhysicsTable *physTable, size_t idx, G4PhysicsVector *vec)
static G4PhysicsTable * PreparePhysicsTable(G4PhysicsTable *physTable)
G4bool GetFlag(size_t i) const
virtual G4double GetLowEdgeEnergy(size_t binNumber) const
void PutValue(size_t index, G4double theValue)
static G4ThreeVector GetParticleFrameY(const G4ThreeVector &)
static G4ThreeVector GetParticleFrameX(const G4ThreeVector &)
bool IsPolarized(G4LogicalVolume *lVol) const
static G4PolarizationManager * GetInstance()
const G4ThreeVector & GetVolumePolarization(G4LogicalVolume *lVol) const
void SetTargetPolarization(const G4ThreeVector &pTarget)
void SetBeamPolarization(const G4ThreeVector &pBeam)
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)
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 &)
void PreparePhysicsTable(const G4ParticleDefinition &)
void SetStartFromNullFlag(G4bool val)
G4ParticleChangeForGamma fParticleChange
G4int LambdaBinning() const
void SetMaxKinEnergy(G4double e)
size_t CurrentMaterialCutsCoupleIndex() const
void ProposeTrackStatus(G4TrackStatus status)
void SetNumberOfSecondaries(G4int totSecondaries)
G4LogicalVolume * GetLogicalVolume() const
const G4String & GetName() const
void SetProcessSubType(G4int)
G4eplusPolarizedAnnihilation(const G4String &name="pol-annihil")
virtual void PreparePhysicsTable(const G4ParticleDefinition &)
virtual ~G4eplusPolarizedAnnihilation()
virtual G4VParticleChange * AtRestDoIt(const G4Track &track, const G4Step &stepData)
virtual void BuildPhysicsTable(const G4ParticleDefinition &)
G4double GetMeanFreePath(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
G4double PostStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
virtual void InitialiseProcess(const G4ParticleDefinition *)
void BuildAsymmetryTable(const G4ParticleDefinition &part)
G4double ComputeAsymmetry(G4double energy, const G4MaterialCutsCouple *couple, const G4ParticleDefinition &particle, G4double cut, G4double &tasm)