diff --git a/geant4/LEMuSR/include/LEMuSRMUONIUMScatt.hh b/geant4/LEMuSR/include/LEMuSRMUONIUMScatt.hh index 2f3b7ff..59e5033 100644 --- a/geant4/LEMuSR/include/LEMuSRMUONIUMScatt.hh +++ b/geant4/LEMuSR/include/LEMuSRMUONIUMScatt.hh @@ -51,6 +51,8 @@ #include "G4ProcessVector.hh" #include "G4ProcessManager.hh" +#include "G4EventManager.hh" + //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... /*! @@ -111,8 +113,6 @@ class LEMuSRMUONIUMScatt : public G4VDiscreteProcess G4ThreeVector polar; G4ThreeVector RotateSpin(const G4Step&, G4ThreeVector, G4double); - - void PrepareSecondary(const G4Track&); G4Track* aSecondary; diff --git a/geant4/LEMuSR/src/LEMuSRAtRestSpinRotation.cc b/geant4/LEMuSR/src/LEMuSRAtRestSpinRotation.cc index e9ed93a..932575c 100644 --- a/geant4/LEMuSR/src/LEMuSRAtRestSpinRotation.cc +++ b/geant4/LEMuSR/src/LEMuSRAtRestSpinRotation.cc @@ -238,7 +238,7 @@ void LEMuSRAtRestSpinRotation::RotateSpin( const G4Step& aStep, G4ThreeVector B, - //! Return the gyromagnetic ratio + // Return the gyromagnetic ratio /*! * This method call the event manager to get the tracking manager and then the current track in order to get the particle name. According to the name of the particle it returns the gyromagnetic ratio. */ diff --git a/geant4/LEMuSR/src/LEMuSRMUONIUMScatt.cc b/geant4/LEMuSR/src/LEMuSRMUONIUMScatt.cc index 6730243..77efe80 100644 --- a/geant4/LEMuSR/src/LEMuSRMUONIUMScatt.cc +++ b/geant4/LEMuSR/src/LEMuSRMUONIUMScatt.cc @@ -74,7 +74,7 @@ G4VParticleChange* LEMuSRMUONIUMScatt::PostStepDoIt( fParticleChange.ProposeProperTime(itime); fParticleChange.ProposeTrackStatus(trackData.GetTrackStatus()) ; - /*! * - Verify the condition of applying the process.*/ + /*! * - Verify the condition of applying the process: if the Mu is in a material different than vacuum and carbon foil, then stop it directly.*/ if( CheckCondition(aStep)) { fParticleChange.ProposePosition(trackData.GetStep()->GetPreStepPoint()->GetPosition()); @@ -84,7 +84,7 @@ G4VParticleChange* LEMuSRMUONIUMScatt::PostStepDoIt( else {;} - /*! *- Rotate the spin if there is a magnetic field.*/ + /*! *- If the Mu is in flight, then rotate the spin if there is a magnetic field.*/ polar = RotateSpinIfMag(trackData, aStep); fParticleChange.ProposePolarization(polar); @@ -132,7 +132,7 @@ G4double LEMuSRMUONIUMScatt:: GetMeanFreePath(const G4Track& , /*! * Not used. */ -void LEMuSRMUONIUMScatt::GetDatas( const G4Step* aStep) +void LEMuSRMUONIUMScatt::GetDatas( const G4Step* ) {;} //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... @@ -235,9 +235,10 @@ G4ThreeVector LEMuSRMUONIUMScatt::RotateSpin( const G4Step& aStep, G4ThreeVector G4double gamma; q= aStep.GetTrack()->GetDefinition()->GetPDGCharge(); a= 1.165922e-3; + // Muon's value.. not used. just for comparison in debugging. fqz = 8.5062e+7*rad/(s*kilogauss); - gamma = aStep.GetTrack()->GetDefinition()->GetGyromagneticRatio()*rad; + gamma = 0.5*((1.*eplus)/(0.1056584*GeV/(c_light*c_light))-(1.*eplus)/(0.51099906*MeV/(c_light*c_light))); // G4cout<< fqz*(s*tesla)<