File indexing completed on 2025-08-05 08:17:50
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013 #ifndef G4DETECTORS_PHG4OUTERHCALFIELD_H
0014 #define G4DETECTORS_PHG4OUTERHCALFIELD_H
0015
0016 #include <Geant4/G4MagneticField.hh>
0017 #include <Geant4/G4Types.hh> // for G4double, G4int
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031 class PHG4OuterHcalField : public G4MagneticField
0032 {
0033 public:
0034 PHG4OuterHcalField() = delete;
0035
0036 PHG4OuterHcalField(bool isInIron, G4int steelPlates,
0037 G4double scintiGap, G4double tiltAngle);
0038
0039 ~PHG4OuterHcalField() override {}
0040
0041 void
0042 GetFieldValue(const double Point[4], double *Bfield) const override;
0043
0044 bool
0045 is_is_in_iron() const
0046 {
0047 return is_in_iron;
0048 }
0049
0050 void
0051 set_is_in_iron(bool isInIron)
0052 {
0053 is_in_iron = isInIron;
0054 }
0055
0056 G4int
0057 get_steel_plates() const
0058 {
0059 return n_steel_plates;
0060 }
0061
0062 void
0063 set_steel_plates(G4int steelPlates)
0064 {
0065 n_steel_plates = steelPlates;
0066 }
0067
0068 double
0069 get_relative_permeability_absorber() const
0070 {
0071 return relative_permeability_absorber;
0072 }
0073
0074 void
0075 set_relative_permeability_absorber(double relativePermeabilityAbsorber)
0076 {
0077 relative_permeability_absorber = relativePermeabilityAbsorber;
0078 }
0079
0080 double
0081 get_relative_permeability_gap() const
0082 {
0083 return relative_permeability_gap;
0084 }
0085
0086 void
0087 set_relative_permeability_gap(double relativePermeabilityGap)
0088 {
0089 relative_permeability_gap = relativePermeabilityGap;
0090 }
0091
0092 G4double
0093 get_scinti_gap() const
0094 {
0095 return scinti_gap;
0096 }
0097
0098 void
0099 set_scinti_gap(G4double scintiGap)
0100 {
0101 scinti_gap = scintiGap;
0102 }
0103
0104 G4double
0105 get_tilt_angle() const
0106 {
0107 return tilt_angle;
0108 }
0109
0110 void
0111 set_tilt_angle(G4double tiltAngle)
0112 {
0113 tilt_angle = tiltAngle;
0114 }
0115
0116 private:
0117 double relative_permeability_absorber = 1514.;
0118
0119 double relative_permeability_gap = 1;
0120
0121 bool is_in_iron;
0122 G4int n_steel_plates;
0123 G4double scinti_gap;
0124 G4double tilt_angle;
0125 };
0126
0127 #endif