CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
FieldBuilder.h
Go to the documentation of this file.
1 #ifndef SimG4Core_FieldBuilder_H
2 #define SimG4Core_FieldBuilder_H
3 
5 // #include "SimG4Core/Geometry/interface/G4LogicalVolumeToDDLogicalPartMap.h"
6 #include <memory>
7 
8 // class DDLogicalPart;
9 class MagneticField;
10 
11 class G4FieldManager;
12 class G4ChordFinder;
13 class G4Mag_UsualEqRhs;
14 class G4PropagatorInField;
15 class G4LogicalVolume;
16 
17 namespace sim {
18  class Field;
19  class FieldBuilder {
20  public:
22  //~FieldBuilder();
23 
24  /*
25  void readFieldParameters(DDLogicalPart theLogicalPart,
26  const std::string& keywordField);
27  */
28  void build(G4FieldManager* fM = 0,
29  G4PropagatorInField* fP = 0) ;
30 
31  /*
32  void configure(const std::string& keywordField,
33  G4FieldManager * fM = 0,
34  G4PropagatorInField * fP = 0);
35  */
36  void configureForVolume( const std::string& volName,
37  edm::ParameterSet& volPSet,
38  G4FieldManager * fM = 0,
39  G4PropagatorInField * fP = 0);
40  G4LogicalVolume * fieldTopVolume();
41  void setStepperAndChordFinder (G4FieldManager * fM, int val);
42 
43  private:
44  void configureFieldManager(G4FieldManager * fM);
45  void configurePropagatorInField(G4PropagatorInField * fP);
46  private:
47  std::auto_ptr<Field> theField;
48  G4Mag_UsualEqRhs *theFieldEquation;
49  G4LogicalVolume *theTopVolume;
51 
54  double fieldValue;
56  double minStep;
57  double dChord;
58  double dOneStep;
59  double dIntersection;
61  double maxLoopCount;
64  double delta;
66  };
67 }
68 
69 #endif
G4ChordFinder * fChordFinder
Definition: FieldBuilder.h:50
std::string fieldType
Definition: FieldBuilder.h:53
void build(G4FieldManager *fM=0, G4PropagatorInField *fP=0)
Definition: FieldBuilder.cc:47
G4ChordFinder * fChordFinderMonopole
Definition: FieldBuilder.h:50
Definition: sim.h:19
void configureForVolume(const std::string &volName, edm::ParameterSet &volPSet, G4FieldManager *fM=0, G4PropagatorInField *fP=0)
Definition: FieldBuilder.cc:97
G4LogicalVolume * theTopVolume
Definition: FieldBuilder.h:49
void setStepperAndChordFinder(G4FieldManager *fM, int val)
double dIntersectionAndOneStep
Definition: FieldBuilder.h:60
FieldBuilder(const MagneticField *, const edm::ParameterSet &)
Definition: FieldBuilder.cc:33
void configureFieldManager(G4FieldManager *fM)
std::auto_ptr< Field > theField
Definition: FieldBuilder.h:47
std::string keywordField
Definition: FieldBuilder.h:52
G4LogicalVolume * fieldTopVolume()
G4Mag_UsualEqRhs * theFieldEquation
Definition: FieldBuilder.h:48
edm::ParameterSet thePSet
Definition: FieldBuilder.h:65
std::string stepper
Definition: FieldBuilder.h:55
void configurePropagatorInField(G4PropagatorInField *fP)