79 G4double sint = std::sqrt((1.-cost)*(1.+cost));
89 parent_polarization.
setX(px);
90 parent_polarization.
setY(py);
91 parent_polarization.
setZ(pz);
96 if (decaytable !=
nullptr) {
106 return pParticleChangeForDecay;
122 G4double sint = std::sqrt((1.-cost)*(1.+cost));
132 parent_polarization.
setX(px);
133 parent_polarization.
setY(py);
134 parent_polarization.
setZ(pz);
139 GetLogicalVolume()->GetFieldManager();
140 if (fieldMgr ==
nullptr) {
145 if (fFieldPropagator) fieldMgr =
149 const G4Field* field =
nullptr;
152 if ( field !=
nullptr ) {
159 G4double fieldValue[6] ={ 0., 0., 0., 0., 0., 0.};
160 field -> GetFieldValue(point,fieldValue);
164 if (B.
mag2() > 0.) parent_polarization =
172 if ( decaytable !=
nullptr) {
182 return pParticleChangeForDecay;
195 G4double omega = -(q*s_omega)*(1.+a) * Bnorm;
197 G4double rotationangle = deltatime * omega;
207 G4double normspin = std::sqrt(Spin*Spin);
208 G4double normnewspin = std::sqrt(newSpin*newSpin);
217 G4cout <<
"Checked norms : " << normspin <<
" " << normnewspin <<
G4endl;
228 <<
": Decay of particles considering parent polarization \n"
229 <<
"kinematics of daughters are dertermined by DecayChannels \n";
CLHEP::Hep3Vector G4ThreeVector
G4double fRemainderLifeTime
G4DecayTable * GetDecayTable() const
std::vector< ExP01TrackerHit * > a
static constexpr double kilogauss
G4FieldManager * GetCurrentFieldManager()
G4double GetPDGCharge() const
virtual G4VParticleChange * AtRestDoIt(const G4Track &aTrack, const G4Step &aStep) override
virtual G4VParticleChange * PostStepDoIt(const G4Track &aTrack, const G4Step &aStep) override
G4ParticleDefinition * GetDefinition() const
virtual void ProcessDescription(std::ostream &outFile) const override
G4ParticleDefinition * GetDefinition() const
G4ParticleChangeForDecay fParticleChangeForDecay
G4ThreeVector Spin_Precession(const G4Step &aStep, G4ThreeVector B, G4double deltatime)
const G4ThreeVector & GetPosition() const
G4VDecayChannel * GetDecayChannel(G4int index) const
G4double GetGlobalTime() const
static constexpr double twopi
G4int GetVerboseLevel() const
G4Track * GetTrack() const
const G4String & GetProcessName() const
const G4Field * GetDetectorField() const
static constexpr double rad
G4StepPoint * GetPostStepPoint() const
virtual ~G4DecayWithSpin()
void SetPolarization(const G4ThreeVector &)
static G4TransportationManager * GetTransportationManager()
const G4ThreeVector & GetPolarization() const
void SetProcessSubType(G4int)
void ProposePolarization(G4double Px, G4double Py, G4double Pz)
G4GLOB_DLL std::ostream G4cout
G4PropagatorInField * GetPropagatorInField() const
G4TrackStatus GetTrackStatus() const
G4DecayWithSpin(const G4String &processName="DecayWithSpin")
virtual void Initialize(const G4Track &)
double B(double temperature)
const G4DynamicParticle * GetDynamicParticle() const
virtual G4VParticleChange * DecayIt(const G4Track &aTrack, const G4Step &aStep)
G4VPhysicalVolume * GetVolume() const