74 : fSolidWorld(0), fLogicWorld(0), fPhysiWorld(0),
75 fSolidTarget(0), fLogicTarget(0), fPhysiTarget(0),
76 fSolidDegrader(0), fLogicDegrader(0), fPhysiDegrader(0),
77 fSolidCaptureMgnt(0), fLogicCaptureMgnt(0), fPhysiCaptureMgnt(0),
78 fSolidTransferMgnt(0), fLogicTransferMgnt(0), fPhysiTransferMgnt(0),
79 fWorldMaterial(0), fTargetMaterial(0), fDegraderMaterial(0)
84 fTargetRadius = 0.4*
cm;
85 fTargetThickness = 16.0*
cm;
89 fDegraderRadius = 30.0*
cm;
90 fDegraderThickness = 0.1*
cm;
92 fCaptureMgntRadius = 0.6*
m;
93 fCaptureMgntLength = 4.0*
m;
98 fTransferMgntRadius = 0.3*
m;
99 fTransferMgntLength = 15.0*
m;
103 fDegraderPos = -fTransferMgntLength/2. + fDegraderThickness/2.;
113 delete fDetectorMessenger;
129 void F04DetectorConstruction::DefineMaterials()
135 fWorldMaterial = fMaterials->
GetMaterial(
"G4_AIR");
136 fDegraderMaterial = fMaterials->
GetMaterial(
"G4_Pb");
144 fSolidWorld =
new G4Tubs(
"World",
161 fSolidCaptureMgnt =
new G4Tubs(
"CaptureMgnt",
181 fSolidTransferMgnt =
new G4Tubs(
"TransferMgnt",
234 fSolidTarget =
new G4Tubs(
"Target",
270 fSolidDegrader =
new G4Tubs(
"Degrader",
299 if (pttoMaterial != fWorldMaterial) {
300 if ( pttoMaterial ) {
301 fWorldMaterial = pttoMaterial;
303 G4cout <<
"\n--> WARNING from SetWorldMaterial : "
304 << materialChoice <<
" not found" <<
G4endl;
316 if (pttoMaterial != fTargetMaterial) {
317 if ( pttoMaterial ) {
318 fTargetMaterial = pttoMaterial;
320 G4cout <<
"\n--> WARNING from SetTargetMaterial : "
321 << materialChoice <<
" not found" <<
G4endl;
334 if (pttoMaterial != fDegraderMaterial) {
335 if ( pttoMaterial ) {
336 fDegraderMaterial = pttoMaterial;
338 G4cout <<
"\n--> WARNING from SetDegraderMaterial : "
339 << materialChoice <<
" not found" <<
G4endl;
362 fCaptureMgntRadius = val;
369 fCaptureMgntLength = val;
376 fCaptureMgntB1 = val;
383 fCaptureMgntB2 = val;
390 fTransferMgntRadius = val;
397 fTransferMgntLength = val;
404 fTransferMgntB = val;
411 fTransferMgntPos = val;
425 fTargetThickness = val;
446 fDegraderRadius = val;
453 fDegraderThickness = val;
478 focusSolenoid -> SetHalf(
true);
492 if (fields->size()>0) {
493 FieldList::iterator i;
494 for (i=fields->begin(); i!=fields->end(); ++i)
495 { (*i)->Construct(fPhysiWorld); }
504 if (fields->size()>0) {
505 FieldList::iterator i;
506 for (i=fields->begin(); i!=fields->end(); ++i)
507 { (*i)->UpdateWorld(fPhysiWorld); }
517 if (!fPhysiWorld)
return;
546 unsigned int place = 0;
548 while (place < rotation.size()) {
552 G4String current=rotation.substr(place+1);
553 angle = strtod(current.c_str(),&
p) *
deg;
555 if (!p || (*p !=
',' && *p !=
'\0')) {
556 G4cerr <<
"Invalid rotation specification: " <<
557 rotation.c_str() <<
G4endl;
564 switch(rotation.substr(place,1).c_str()[0]) {
575 G4cerr <<
" Invalid rotation specification: "
580 rot = thisRotation * rot;
581 place = rotation.find(
',',place);
582 if (place > rotation.size())
break;
void SetMaxStep(G4double stp)
SetMaxStep(G4double) sets the max. step size.
void SetTargetAngle(G4int)
void SetCaptureMgntB2(G4double)
G4Material * FindOrBuildMaterial(const G4String &name, G4bool isotopes=true, G4bool warning=false)
G4Material * GetWorldMaterial()
G4double GetDegraderPos()
void UpdateMaterialList(G4VPhysicalVolume *currentWorld=0)
G4double GetCaptureMgntRadius()
void SetTransferMgntLength(G4double)
Definition of the F04Materials class.
G4double GetDegraderRadius()
CLHEP::Hep3Vector G4ThreeVector
CLHEP::HepRotation G4RotationMatrix
G4VPhysicalVolume * ConstructDetector()
Definition of the F04GlobalField class.
void SetDegraderPos(G4double)
virtual ~F04DetectorConstruction()
G4String strip(G4int strip_Type=trailing, char c=' ')
G4Material * GetTargetMaterial()
void SetTargetThickness(G4double)
void SetDegraderMaterial(G4String)
void SetCaptureMgntLength(G4double)
F04DetectorConstruction()
void SetTargetMaterial(G4String)
G4double GetCaptureMgntB2()
G4double GetCaptureMgntLength()
G4Material * GetMaterial(G4String)
static G4NistManager * Instance()
void SetColor(G4String c)
SetColor(G4String) sets the color.
HepRotation inverse() const
void SetDegraderRadius(G4double)
G4double GetDegraderThickness()
static G4PhysicalVolumeStore * GetInstance()
static G4RegionStore * GetInstance()
static F04GlobalField * GetObject()
Definition of the F04DetectorConstruction class.
virtual G4VPhysicalVolume * Construct()
void SetWorldSizeZ(G4double)
G4GLOB_DLL std::ostream G4cout
G4double GetTransferMgntRadius()
std::vector< F04ElementField * > FieldList
void SetWorldMaterial(G4String)
G4double GetTargetRadius()
Definition of the F04DetectorMessenger class.
void SetCaptureMgntRadius(G4double)
void PhysicsHasBeenModified()
Definition of the F04FocusSolenoid class.
void SetDegraderThickness(G4double)
static G4LogicalVolumeStore * GetInstance()
static G4SolidStore * GetInstance()
void SetTargetPos(G4double)
G4double GetTransferMgntLength()
static G4GeometryManager * GetInstance()
void SetTransferMgntRadius(G4double)
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
G4double GetTransferMgntB()
static G4RunManager * GetRunManager()
G4Material * GetDegraderMaterial()
static F04Materials * GetInstance()
Definition of the F04SimpleSolenoid class.
void OpenGeometry(G4VPhysicalVolume *vol=0)
void SetTransferMgntB(G4double)
G4double GetCaptureMgntB1()
virtual void ConstructSDandField()
static G4RotationMatrix StringToRotationMatrix(G4String rotation)
G4double GetTargetThickness()
void SetTargetRadius(G4double)
void SetCaptureMgntB1(G4double)
G4double GetTransferMgntPos()
void SetWorldSizeR(G4double)
FieldList * GetFields()
Return the list of Element Fields.
G4GLOB_DLL std::ostream G4cerr
void SetTransferMgntPos(G4double)