EDepSimEMFieldSetup.hh
Go to the documentation of this file.
1 // ********************************************************************
2 // * License and Disclaimer *
3 // * *
4 // * The Geant4 software is copyright of the Copyright Holders of *
5 // * the Geant4 Collaboration. It is provided under the terms and *
6 // * conditions of the Geant4 Software License, included in the file *
7 // * LICENSE and available at http://cern.ch/geant4/license . These *
8 // * include a list of copyright holders. *
9 // * *
10 // * Neither the authors of this software system, nor their employing *
11 // * institutes,nor the agencies providing financial support for this *
12 // * work make any representation or warranty, express or implied, *
13 // * regarding this software system or assume any liability for its *
14 // * use. Please see the license in the file LICENSE and URL above *
15 // * for the full disclaimer and the limitation of liability. *
16 // * *
17 // * This code implementation is the result of the scientific and *
18 // * technical work of the GEANT4 collaboration. *
19 // * By using, copying, modifying or distributing the software (or *
20 // * any work based on the software) you agree to acknowledge its *
21 // * use in resulting scientific publications, and indicate your *
22 // * acceptance of all terms of the Geant4 Software license. *
23 // ********************************************************************
24 //
25 /// \file field/field02/include/EDepSimEMFieldSetup.hh
26 /// \brief Definition of the EDepSim::EMFieldSetup class
27 //
28 //
29 // $Id: EDepSim::EMFieldSetup.hh 76247 2013-11-08 11:18:52Z gcosmo $
30 //
31 // History:
32 // - 2017.03.15 C.McGrew adapted for EDepSim
33 //
34 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
35 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
36 
37 #ifndef EDepSimEMFieldSetup_h
38 #define EDepSimEMFieldSetup_h 1
39 
40 #include <G4ThreeVector.hh>
41 
42 class G4FieldManager;
43 class G4ChordFinder;
44 class G4ElectroMagneticField;
45 class G4EquationOfMotion;
46 class G4Mag_EqRhs;
47 class G4EqMagElectricField;
48 class G4MagIntegratorStepper;
49 class G4MagInt_Driver;
50 
51 namespace EDepSim {class EMFieldSetup;}
52 
53 /// A class for control of the Electric Field of the detector.
54 ///
55 /// The field for this case is uniform.
56 /// It is simply a 'setup' class that creates the field and necessary
57 /// other parts
59 {
60 public:
61  /// Create a new field. The first argument is a general EM field (for
62  /// example, G4UniformMagneticField, or G4UniformElectricField. The
63  /// second argument is the field manager to setup.
64  EMFieldSetup(G4ElectroMagneticField* field, G4FieldManager* m=0);
65 
66  /// Create a zero field for the field manager.
67  EMFieldSetup(G4FieldManager* m=0);
68 
69  virtual ~EMFieldSetup();
70 
71  void SetStepperType(G4int i) { fStepperType = i ; }
72 
73  void SetStepper();
74 
75  void SetMinStep(G4double s) { fMinStep = s ; }
76 
77 protected:
78 
79  // Find the global Field Manager
80 
81  G4FieldManager* GetGlobalFieldManager();
82 
83  void UpdateField();
84 
85 private:
86 
87  G4FieldManager* fFieldManager;
88 
89  G4ChordFinder* fChordFinder;
90 
91  G4EqMagElectricField* fEquation;
92 
93  G4ElectroMagneticField* fEMfield;
94 
95  G4MagIntegratorStepper* fStepper;
96  G4MagInt_Driver* fIntgrDriver;
97 
98  G4int fStepperType;
99 
100  G4double fMinStep;
101 };
102 #endif
G4EqMagElectricField * fEquation
EMFieldSetup(G4ElectroMagneticField *field, G4FieldManager *m=0)
G4ChordFinder * fChordFinder
void SetMinStep(G4double s)
Construct a module from components.
Definition: TG4HitSegment.h:10
G4FieldManager * fFieldManager
G4MagIntegratorStepper * fStepper
G4MagInt_Driver * fIntgrDriver
G4ElectroMagneticField * fEMfield
static QCString * s
Definition: config.cpp:1042
G4FieldManager * GetGlobalFieldManager()