76 theAsymmetryTable(nullptr),
77 theTransverseAsymmetryTable(nullptr)
118 G4cout <<
"G4eplusPolarizedAnnihilation::MeanFreePath: " 127 const G4Track&
track,
143 std::max(nLength - previousStepSize/curLength, 0.0);
148 G4cout <<
"G4eplusPolarizedAnnihilation::PostStepGetPhysicalInteractionLength: " 170 if (volumeIsPolarized) {
175 const G4StokesVector positronPolarization = track.GetPolarization();
179 G4cout <<
"G4eplusPolarizedAnnihilation::ComputeSaturationFactor: " <<
G4endl;
181 G4cout <<
" Polarization " << positronPolarization <<
G4endl;
182 G4cout <<
" MaterialPol. " << electronPolarization <<
G4endl;
191 if(midx < theAsymmetryTable->size()) {
192 aVector = (*theAsymmetryTable)(midx);
194 if(midx < theTransverseAsymmetryTable->size()) {
195 bVector = (*theTransverseAsymmetryTable)(midx);
197 if(aVector && bVector) {
200 G4double polZZ = positronPolarization.
z()*
201 (electronPolarization*positronDirection0);
202 G4double polXX = positronPolarization.
x()*
204 G4double polYY = positronPolarization.
y()*
207 factor /= (1. + polZZ*lAsymmetry + (polXX + polYY)*tAsymmetry);
210 G4cout <<
" Asymmetry: " << lAsymmetry <<
", " << tAsymmetry <<
G4endl;
211 G4cout <<
" PolProduct: " << polXX <<
", " << polYY <<
", " << polZZ <<
G4endl;
216 ed <<
"Problem with asymmetry tables: material index " << midx
217 <<
" is out of range or tables are not filled";
218 G4Exception(
"G4eplusPolarizedAnnihilation::ComputeSaturationFactor",
"em0048",
234 if(masterProcess && masterProcess !=
this) { isMaster =
false; }
255 for(
size_t i=0; i<numOfCouples; ++i) {
313 lAsymmetry=sigma2/sigma0-1.;
314 tAsymmetry=sigma3/sigma0-1.;
323 G4cout <<
" Polarized model for annihilation into 2 photons" G4double condition(const G4ErrorSymMatrix &m)
void SetBeamPolarization(const G4ThreeVector &pBeam)
const G4VProcess * GetMasterProcess() const
static void SetPhysicsVector(G4PhysicsTable *physTable, size_t idx, G4PhysicsVector *vec)
G4double ComputeSaturationFactor(const G4Track &aTrack)
std::ostringstream G4ExceptionDescription
CLHEP::Hep3Vector G4ThreeVector
virtual void BuildPhysicsTable(const G4ParticleDefinition &)
static G4Material * GetMaterial(const G4String &name, G4bool warning=true)
const G4ThreeVector & GetVolumePolarization(G4LogicalVolume *lVol) const
static G4PolarizationManager * GetInstance()
G4double theNumberOfInteractionLengthLeft
G4int LambdaBinning() const
virtual void BuildPhysicsTable(const G4ParticleDefinition &)
virtual G4double PostStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
size_t CurrentMaterialCutsCoupleIndex() const
static G4PhysicsTable * PreparePhysicsTable(G4PhysicsTable *physTable)
G4double ComputeAsymmetry(G4double energy, const G4MaterialCutsCouple *couple, const G4ParticleDefinition &particle, G4double cut, G4double &tasm)
G4double GetLowEdgeEnergy(size_t binNumber) const
void SetEmModel(G4VEmModel *, G4int index=1)
G4double GetKineticEnergy() const
G4ThreeVector theTargetPolarization
bool IsPolarized(G4LogicalVolume *lVol) const
G4GLOB_DLL std::ostream G4cout
void SetTargetPolarization(const G4ThreeVector &pTarget)
const G4String & GetName() const
G4double CrossSection(const G4MaterialCutsCouple *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
G4double currentInteractionLength
void PutValue(size_t index, G4double theValue)
virtual G4double GetMeanFreePath(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
G4double Value(G4double theEnergy, size_t &lastidx) const
virtual G4double PostStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
G4PhysicsTable * theAsymmetryTable
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
virtual G4double GetMeanFreePath(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
const G4String & GetName() const
static G4ProductionCutsTable * GetProductionCutsTable()
G4PhysicsVector * LambdaPhysicsVector(const G4MaterialCutsCouple *)
const G4MaterialCutsCouple * GetMaterialCutsCouple(G4int i) const
static const G4double factor
const G4ThreeVector & GetMomentumDirection() const
G4PolarizedAnnihilationModel * emModel
static G4ThreeVector GetParticleFrameY(const G4ThreeVector &)
size_t GetTableSize() const
G4PhysicsTable * theTransverseAsymmetryTable
G4bool GetFlag(size_t i) const
void BuildAsymmetryTables(const G4ParticleDefinition &part)
G4LogicalVolume * GetLogicalVolume() const
static G4ThreeVector GetParticleFrameX(const G4ThreeVector &)
G4eplusPolarizedAnnihilation(const G4String &name="pol-annihil")
virtual ~G4eplusPolarizedAnnihilation()