-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathElectricFieldSetup.hh
71 lines (46 loc) · 1.48 KB
/
ElectricFieldSetup.hh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#ifndef ElectricFieldSetup_h
#define ElectricFieldSetup_h 1
#include "G4ElectricField.hh"
#include "G4UniformElectricField.hh"
class G4FieldManager;
class G4ChordFinder;
class G4EquationOfMotion;
class G4Mag_EqRhs;
class G4EqMagElectricField;
class G4MagIntegratorStepper;
class G4MagInt_Driver;
class FieldMessenger;
/// A class for control of the Electric Field of the detector.
///
/// The field for this case is uniform.
/// It is simply a 'setup' class that creates the field and necessary
/// other parts
class ElectricFieldSetup
{
public:
ElectricFieldSetup(G4ThreeVector); // The value of the field
ElectricFieldSetup(); // A zero field
virtual ~ElectricFieldSetup();
void SetStepperType( G4int i) { fStepperType = i ; }
void SetStepper();
void SetMinStep(G4double s) { fMinStep = s ; }
void UpdateField();
void SetFieldValue(G4ThreeVector fieldVector);
void SetFieldValue(G4double fieldValue);
G4ThreeVector GetConstantFieldValue();
protected:
// Find the global Field Manager
G4FieldManager* GetGlobalFieldManager();
private:
G4FieldManager* fFieldManager;
G4ChordFinder* fChordFinder;
G4EqMagElectricField* fEquation;
G4ElectricField* fEMfield;
G4ThreeVector fElFieldValue;
G4MagIntegratorStepper* fStepper;
G4MagInt_Driver* fIntgrDriver;
G4int fStepperType;
G4double fMinStep;
FieldMessenger* fFieldMessenger;
};
#endif