Skip to content

Integration of the electric field in Geant4 #397

Description

@hervasa2

Full integration of SSD and geant4 could include the use of the electric field calculated by SSD. Particle propagation in Geant4 can then occur in the presence of this field.
Field dependent spectrum effects (i.e. shift of single escape peak) could thus be simulated.
This would also require switching to G4EmStandardPhysics_option4

RegisterPhysics(pl, move!(G4EmStandardPhysics(verbose))) # EM physics

which should then also include doppler broadening effects (not captured by StandardPhysics). We would need some speed tests for this change.

I see two possible ways of passing the field to Geant4.

  1. Following the guidance in this thread a non-uniform electric field can be created in Geant4 in the following manner.
fFieldMessenger(nullptr)
{
// fEMfield = new G4UniformElectricField(G4ThreeVector(0.0,-1.0kilovolt/cm,0.0));
G4double zOffset = 0.0 * mm;
fEMfield = new PurgMagTabulatedEField3D(“PurgMag3D.TABLE”, zOffset);
fEquation = new G4EqMagElectricField(fEMfield);

fFieldManager = GetGlobalFieldManager();

UpdateIntegrator();
fFieldMessenger = new F02FieldMessenger(this);
}
  • PurgMag3D.TABLE is just a text file with a field vector in each row: x y z Ex Ey Ez
  • A /field/getField function needs to be defined to interpolate at any point, this can just be ported from the current methods in SSD
  1. Create virtual volumes (given by grid size) of uniform electric field and use
fEMfield = new G4UniformElectricField(G4ThreeVector(0.0,100000.0*kilovolt/cm,0.0));
fEquation = new G4EqMagElectricField(fEMfield)

Metadata

Metadata

Labels

enhancementImprovement of existing featuresgeant4Anything related to the Geant4 supporthelp wantedExtra attention is needed

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions