Message: Re: simultaneous B and E fields Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Re: simultaneous B and E fields 

Keywords: magnetic field, electric field
Forum: Fields: Magnetic and Otherwise
Re: Question simultaneous B and E fields (Abigail Bickley)
Re: Feedback Re: simultaneous B and E fields (Gumplinger Peter)
Re: Question Re: simultaneous B and E fields (Abigail Bickley)
Re: Warning Re: simultaneous B and E fields (Gumplinger Peter)
Date: 19 Jul, 2007
From: Abigail Bickley <bickley@nscl.msu.edu>

Thank you for your suggestion. Following the example provided by advanced/microbeam/ I was able to create a new class that inherits from G4ElectroMagneticField and have confirmed that it does simultaneously apply an E and B field to the same geometrical volume. However, I have encountered one problem for which I have a followup question. If I apply the E&B field to the whole detector in my DetectorConstruction as follows everything works fine. I see the curvature of charged particle tracks and e- drift in the field gradient.

      Field = new TPCEMField();
      pEquation = new G4EqMagElectricField(Field);
      pStepper = new G4ClassicalRK4 (pEquation);
      pFieldMgr = G4TransportationManager::GetTransportationManager()->GetFieldManager();
      pIntgrDriver = new G4MagInt_Driver(0.000001*mm,pStepper,pStepper->GetNumberOfVariables() );
      pChordFinder = new G4ChordFinder(pIntgrDriver);
      pFieldMgr->SetChordFinder( pChordFinder );
      pFieldMgr->GetChordFinder()->SetDeltaChord(1e-5*m);
      pFieldMgr->SetDetectorField(Field);

But, I would rather apply it only to a localized volume. You mentioned that this should not be done with a global field manager so instead I changed the code to the following as shown in field03. However, now I find that the field is not being applied anywhere (ie no curved tracks and no e- drift). What am I doing wrong?

      Field = new TPCEMField();
      pEquation = new G4EqMagElectricField(Field);
      pStepper = new G4ClassicalRK4 (pEquation);
      pFieldMgr = new G4FieldManager();
      pIntgrDriver = new G4MagInt_Driver(0.000001*mm,pStepper,pStepper->GetNumberOfVariables() );
      pChordFinder = new G4ChordFinder(pIntgrDriver);
      pFieldMgr->SetChordFinder( pChordFinder );
      pFieldMgr->GetChordFinder()->SetDeltaChord(1e-5*m);
      detector_log->SetFieldManager(pFieldMgr, true);

Thank you for your help.

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 Feedback: Re: simultaneous B and E fields   (Peter Gumplinger - 20 Jul, 2007)
(_ Warning: Re: simultaneous B and E fields   (Gumplinger Peter - 17 Sep, 2009)
 Add Message Add Message
to: "Re: simultaneous B and E fields"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]