Definition of the Target. More...
#include <MollerTarget.hh>
Definition of the Target.
Definition at line 48 of file MollerTarget.hh.
MollerTarget::MollerTarget | ( | ) |
Definition at line 24 of file MollerTarget.cc.
References MollerMaterial::DefineMaterials(), fTargetLength, MollerMaterial::GetMaterial(), MollerTargetMessenger::MollerTargetMessenger(), pMaterial, ScatteringChamberWindowRadius, ScatteringChamberWindowThickness, Target_Material, TargetCell_Logical, TargetCell_Material, TargetCell_Physical, targetCellBackInnerRadiusMax, targetCellBackOuterRadiusMax, targetCellBackRadiusMin, targetCellDeltaPhi, targetCellEntranceWindowThickness, targetCellExitWindowNippleRadius, targetCellExitWindowNippleThickness, targetCellExitWindowThickness, targetCellFrontInnerRadiusMax, targetCellFrontOuterRadiusMax, targetCellFrontRadiusMin, targetCellInnerLength, targetCellOuterLength, targetCellStartingPhi, targetCellWallThickness, TargetContainer_Logical, TargetContainer_Material, TargetContainer_Physical, TargetEntranceWindow_Logical, TargetEntranceWindow_Material, TargetEntranceWindow_Physical, TargetExitWindow_Logical, TargetExitWindow_Material, TargetExitWindow_Physical, TargetExitWindowNipple_Logical, TargetExitWindowNipple_Material, TargetExitWindowNipple_Physical, TargetMaterial_Logical, TargetMaterial_Physical, targetMessenger, and targetZPos.
00025 { 00026 G4cout << G4endl << "###### Calling MollerTarget::MollerTarget() " << G4endl << G4endl; 00027 00028 //myUserInfo = myUI; 00029 00030 TargetContainer_Logical = NULL; 00031 TargetContainer_Physical = NULL; 00032 TargetContainer_Material = NULL; 00033 00034 TargetCell_Logical = NULL; 00035 TargetCell_Physical = NULL; 00036 TargetCell_Material = NULL; 00037 00038 TargetEntranceWindow_Logical = NULL; 00039 TargetEntranceWindow_Physical = NULL; 00040 TargetEntranceWindow_Material = NULL; 00041 00042 TargetExitWindow_Logical = NULL; 00043 TargetExitWindow_Physical = NULL; 00044 TargetExitWindow_Material = NULL; 00045 00046 TargetExitWindowNipple_Logical = NULL; 00047 TargetExitWindowNipple_Physical = NULL; 00048 TargetExitWindowNipple_Material = NULL; 00049 00050 TargetMaterial_Logical = NULL; 00051 TargetMaterial_Physical = NULL; 00052 Target_Material = NULL; 00053 00054 00055 // definition of a mil = inch/1000 00056 static const G4double mil = 0.001*2.54*cm; 00057 static const G4double inch = 2.54*cm; 00058 00059 pMaterial = new MollerMaterial(); 00060 pMaterial->DefineMaterials(); 00061 00062 TargetContainer_Material = pMaterial->GetMaterial("Vacuum"); 00063 TargetCell_Material = pMaterial->GetMaterial("Aluminum"); 00064 TargetEntranceWindow_Material = pMaterial->GetMaterial("Aluminum"); 00065 TargetExitWindow_Material = pMaterial->GetMaterial("Aluminum"); 00066 TargetExitWindowNipple_Material = pMaterial->GetMaterial("Aluminum"); 00067 Target_Material = pMaterial->GetMaterial("H2Liquid"); 00068 00069 // define target geometry values 00070 00071 targetCellEntranceWindowThickness = 5*mil;; 00072 targetCellExitWindowThickness = 20*mil; 00073 targetCellExitWindowNippleThickness = 5*mil; 00074 targetCellWallThickness = 10.0*mil; 00075 00076 targetCellExitWindowNippleRadius = 0.5*0.622*inch; 00077 00078 targetCellInnerLength = 34.346*cm; 00079 targetCellOuterLength = targetCellInnerLength 00080 + targetCellEntranceWindowThickness 00081 + targetCellExitWindowThickness; // Full length of Target 00082 00083 targetCellFrontRadiusMin = 0.0*cm; 00084 targetCellFrontOuterRadiusMax = 0.5*2.730*inch; 00085 targetCellFrontInnerRadiusMax = targetCellFrontOuterRadiusMax - targetCellWallThickness; 00086 00087 targetCellBackRadiusMin = targetCellExitWindowNippleRadius; //0.0*cm; 00088 targetCellBackOuterRadiusMax = 0.5*7.5*inch; 00089 targetCellBackInnerRadiusMax = targetCellBackOuterRadiusMax - targetCellWallThickness; 00090 00091 targetCellStartingPhi = 0.0*deg; 00092 targetCellDeltaPhi = 360*deg; 00093 00094 targetZPos = 0.0*cm; 00095 //targetZPos = myUserInfo->TargetCenterPositionZ; //-650.0*cm; 00096 00097 ScatteringChamberWindowRadius = 0.5*23.5*inch; 00098 ScatteringChamberWindowThickness = 35*mil; 00099 00100 //myUserInfo->TargetLength = targetCellInnerLength; 00101 //myUserInfo->TargetEntranceWindowThickness = targetCellEntranceWindowThickness; 00102 //myUserInfo->TargetExitWindowThickness = targetCellExitWindowThickness; 00103 targetMessenger = new MollerTargetMessenger(this); 00104 00105 fTargetLength = 150.0*cm; 00106 00107 }
MollerTarget::~MollerTarget | ( | ) |
Definition at line 110 of file MollerTarget.cc.
References pMaterial, and targetMessenger.
00111 { 00112 delete pMaterial; 00113 delete targetMessenger; 00114 }
void MollerTarget::ConstructComponent | ( | G4VPhysicalVolume * | MotherVolume | ) |
Definition at line 118 of file MollerTarget.cc.
References fTargetLength, target_logic, Target_Material, target_phys, targetCellEntranceWindowThickness, targetCellExitWindowThickness, TargetEntranceWindow_Logical, TargetEntranceWindow_Material, TargetEntranceWindow_Physical, TargetExitWindow_Logical, TargetExitWindow_Material, TargetExitWindow_Physical, and targetZPos.
00119 { 00120 G4cout << G4endl << "###### Calling MollerTarget::ConstructComponent() " << G4endl << G4endl; 00121 00122 //------Target-----// 00123 G4double inner_rad = 0.0*cm; 00124 G4double start_angle = 0.0*deg; 00125 G4double end_angle = 360.0*deg; 00126 00127 G4double outer_rad_targ = 4.0*cm; 00128 G4double half_len_targ = fTargetLength/2; 00129 00130 G4cout<< "target half-length = "<<half_len_targ/cm<<G4endl; 00131 00132 G4Tubs* target_solid = new G4Tubs("tubeTarget", inner_rad, outer_rad_targ, 00133 half_len_targ, start_angle, end_angle); 00134 00135 G4LogicalVolume* target_logic = new G4LogicalVolume(target_solid, Target_Material, "logicTarget"); 00136 00137 G4VPhysicalVolume* target_phys = new G4PVPlacement(0, 00138 G4ThreeVector(0, 0, targetZPos), 00139 "Target", 00140 target_logic, 00141 MotherVolume, 00142 false, 00143 0); 00144 00145 G4VisAttributes* targetVisAtt= new G4VisAttributes(G4Colour(1.0,1.0,0.0)); 00146 targetVisAtt->SetVisibility(true); 00147 target_logic->SetVisAttributes(targetVisAtt); 00148 00149 // define target entrance window (front, upstream) 00150 G4Tubs* TargetEntranceWindow_Solid = new G4Tubs("TargetEntranceWindow_Sol", 00151 inner_rad, outer_rad_targ, 00152 0.5*targetCellEntranceWindowThickness, 00153 start_angle, end_angle); 00154 00155 TargetEntranceWindow_Logical = new G4LogicalVolume(TargetEntranceWindow_Solid, 00156 TargetEntranceWindow_Material, 00157 "MollerTargetEntranceWindow_Log", 00158 0,0,0); 00159 00160 TargetEntranceWindow_Physical = new G4PVPlacement(0, 00161 G4ThreeVector(0, 0, targetZPos-(half_len_targ+0.5*targetCellEntranceWindowThickness)),// positionTargetEntranceWindow, 00162 "MollerTargetEntranceWindow", 00163 TargetEntranceWindow_Logical, 00164 MotherVolume, 00165 false, 00166 0); 00167 00168 // define target exit window (back, downstream) 00169 G4Tubs* TargetExitWindow_Solid = new G4Tubs("TargetExitWindow_Sol", 00170 inner_rad, outer_rad_targ, 00171 0.5*targetCellExitWindowThickness, 00172 start_angle, end_angle); 00173 00174 TargetExitWindow_Logical = new G4LogicalVolume(TargetExitWindow_Solid, 00175 TargetExitWindow_Material, 00176 "MollerTargetExitWindow_Log", 00177 0,0,0); 00178 00179 TargetExitWindow_Physical = new G4PVPlacement(0, 00180 G4ThreeVector(0, 0, targetZPos+(half_len_targ+0.5*targetCellExitWindowThickness)),// positionTargetEntranceWindow, 00181 "MollerTargetExiteWindow", 00182 TargetExitWindow_Logical, 00183 MotherVolume, 00184 false, 00185 0); 00186 00187 G4Colour blue ( 0/255., 0/255., 255/255.); 00188 G4VisAttributes* targetWindowVisAtt= new G4VisAttributes(blue); 00189 targetWindowVisAtt->SetVisibility(true); 00190 TargetEntranceWindow_Logical->SetVisAttributes(targetWindowVisAtt); 00191 TargetExitWindow_Logical->SetVisAttributes(targetWindowVisAtt); 00192 00193 00194 G4cout << G4endl << "###### Leaving MollerTarget::ConstructComponent() " << G4endl << G4endl; 00195 00196 } // end of MollerTarget::ConstructComponent()
void MollerTarget::DestroyComponent | ( | ) |
Definition at line 290 of file MollerTarget.cc.
G4String MollerTarget::GetTargetCellMaterial | ( | ) |
G4double MollerTarget::GetTargetCenterPositionInZ | ( | ) |
Definition at line 306 of file MollerTarget.cc.
References targetZPos.
00307 { 00308 G4cout << G4endl << "###### Calling MollerTarget::GetTargetCenterPositionInZ() " << G4endl << G4endl; 00309 return targetZPos; 00310 }
G4String MollerTarget::GetTargetEntranceMaterial | ( | ) |
G4String MollerTarget::GetTargetExitWindowMaterial | ( | ) |
G4String MollerTarget::GetTargetExitWindowNippleMaterial | ( | ) |
G4double MollerTarget::GetTargetLength | ( | ) | [inline] |
Definition at line 61 of file MollerTarget.hh.
References fTargetLength.
00061 {return fTargetLength;};
G4LogicalVolume* MollerTarget::getTargetLogicalVolume | ( | ) | [inline] |
Definition at line 78 of file MollerTarget.hh.
References TargetMaterial_Logical.
00078 {return TargetMaterial_Logical;}
G4String MollerTarget::GetTargetMaterial | ( | ) |
G4VPhysicalVolume* MollerTarget::getTargetPhysicalVolume | ( | ) | [inline] |
Definition at line 79 of file MollerTarget.hh.
References TargetMaterial_Physical.
00079 {return TargetMaterial_Physical;}
void MollerTarget::SetTargetCellMaterial | ( | G4String | materialName | ) |
Definition at line 218 of file MollerTarget.cc.
References TargetCell_Logical.
Referenced by MollerTargetMessenger::SetNewValue().
00219 { 00220 // search the material by its name 00221 G4Material* pttoMaterial = G4Material::GetMaterial(materialName); 00222 if (pttoMaterial) 00223 { 00224 G4cout << "==== Changing Target Cell Material: Looking up Material " << G4endl; 00225 TargetCell_Logical->SetMaterial(pttoMaterial); 00226 G4cout << "==== Changing Target Cell Material: Now the Target Cell is made of " << materialName << G4endl; 00227 } 00228 else { 00229 G4cerr << "==== ERROR: Changing Target Cell Material failed" << G4endl; 00230 } 00231 00232 }
void MollerTarget::SetTargetCenterPositionInZ | ( | G4double | zPos | ) |
Definition at line 296 of file MollerTarget.cc.
References TargetContainer_Physical, and targetZPos.
Referenced by MollerTargetMessenger::SetNewValue().
00297 { 00298 G4cout << G4endl << "###### Calling MollerTarget::SetTargetCenterPositionInZ() " << G4endl << G4endl; 00299 00300 targetZPos = zPos; 00301 //myUserInfo->TargetCenterPositionZ = zPos; 00302 //TargetCell_Physical->SetTranslation(G4ThreeVector(0.,0., zPos)); 00303 TargetContainer_Physical->SetTranslation(G4ThreeVector(0.,0., zPos)); 00304 }
void MollerTarget::SetTargetEntranceWindowMaterial | ( | G4String | materialName | ) |
Definition at line 236 of file MollerTarget.cc.
References TargetEntranceWindow_Logical.
00237 { 00238 // search the material by its name 00239 G4Material* pttoMaterial = G4Material::GetMaterial(materialName); 00240 if (pttoMaterial) 00241 { 00242 G4cout << "==== Changing Target Entrance Window Material: Looking up Material " << G4endl; 00243 TargetEntranceWindow_Logical->SetMaterial(pttoMaterial); 00244 G4cout << "==== Changing Target Entrance Window Material: Now the Target Entrance Window is made of " << materialName << G4endl; 00245 } 00246 else { 00247 G4cerr << "==== ERROR: Changing Target Entrance Window Material failed" << G4endl; 00248 } 00249 00250 }
void MollerTarget::SetTargetExitWindowMaterial | ( | G4String | materialName | ) |
Definition at line 254 of file MollerTarget.cc.
References TargetExitWindow_Logical.
00255 { 00256 // search the material by its name 00257 G4Material* pttoMaterial = G4Material::GetMaterial(materialName); 00258 if (pttoMaterial) 00259 { 00260 G4cout << "==== Changing Target Exit Window Material: Looking up Material " << G4endl; 00261 TargetExitWindow_Logical->SetMaterial(pttoMaterial); 00262 G4cout << "==== Changing Target Exit Window Material: Now the Target Exit Window is made of " << materialName << G4endl; 00263 } 00264 else { 00265 G4cerr << "==== ERROR: Changing Target Exit Window Material failed" << G4endl; 00266 } 00267 00268 }
void MollerTarget::SetTargetExitWindowNippleMaterial | ( | G4String | materialName | ) |
Definition at line 272 of file MollerTarget.cc.
References TargetExitWindowNipple_Logical.
00273 { 00274 // search the material by its name 00275 G4Material* pttoMaterial = G4Material::GetMaterial(materialName); 00276 if (pttoMaterial) 00277 { 00278 G4cout << "==== Changing Target Exit Window Nipple Material: Looking up Material " << G4endl; 00279 TargetExitWindowNipple_Logical->SetMaterial(pttoMaterial); 00280 G4cout << "==== Changing Target Exit Window Nipple Material: Now the Target Exit Window Nipple is made of " << materialName << G4endl; 00281 } 00282 else { 00283 G4cerr << "==== ERROR: Changing Target Exit Window Nipple Material failed" << G4endl; 00284 } 00285 00286 }
void MollerTarget::SetTargetLength | ( | G4double | length | ) |
Definition at line 312 of file MollerTarget.cc.
References fTargetLength.
Referenced by MollerTargetMessenger::SetNewValue().
00313 { 00314 G4cout << G4endl << "###### Calling MollerTarget::SetTargetLength() " << G4endl << G4endl; 00315 fTargetLength = length; 00316 }
void MollerTarget::SetTargetMaterial | ( | G4String | materialName | ) |
Definition at line 200 of file MollerTarget.cc.
References TargetMaterial_Logical.
Referenced by MollerTargetMessenger::SetNewValue().
00201 { 00202 // search the material by its name 00203 G4Material* pttoMaterial = G4Material::GetMaterial(materialName); 00204 if (pttoMaterial) 00205 { 00206 G4cout << "==== Changing Target Material: Looking up Material " << G4endl; 00207 TargetMaterial_Logical->SetMaterial(pttoMaterial); 00208 G4cout << "==== Changing Target Material: Now the Target is made of " << materialName << G4endl; 00209 } 00210 else { 00211 G4cerr << "==== ERROR: Changing Target Material failed" << G4endl; 00212 } 00213 00214 }
G4double MollerTarget::fTargetLength [private] |
Definition at line 137 of file MollerTarget.hh.
Referenced by ConstructComponent(), GetTargetLength(), MollerTarget(), and SetTargetLength().
MollerMaterial* MollerTarget::pMaterial [private] |
Definition at line 83 of file MollerTarget.hh.
Referenced by MollerTarget(), and ~MollerTarget().
G4LogicalVolume* MollerTarget::ScatteringChamberWindow_Logical [private] |
Definition at line 101 of file MollerTarget.hh.
G4VPhysicalVolume* MollerTarget::ScatteringChamberWindow_Physical [private] |
Definition at line 102 of file MollerTarget.hh.
G4double MollerTarget::ScatteringChamberWindowRadius [private] |
Definition at line 130 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::ScatteringChamberWindowThickness [private] |
Definition at line 131 of file MollerTarget.hh.
Referenced by MollerTarget().
G4LogicalVolume* MollerTarget::target_logic [private] |
Definition at line 142 of file MollerTarget.hh.
Referenced by ConstructComponent().
G4Material* MollerTarget::Target_Material [private] |
Definition at line 106 of file MollerTarget.hh.
Referenced by ConstructComponent(), and MollerTarget().
G4VPhysicalVolume* MollerTarget::target_phys [private] |
Definition at line 143 of file MollerTarget.hh.
Referenced by ConstructComponent().
G4LogicalVolume* MollerTarget::TargetCell_Logical [private] |
Definition at line 85 of file MollerTarget.hh.
Referenced by MollerTarget(), and SetTargetCellMaterial().
G4Material* MollerTarget::TargetCell_Material [private] |
Definition at line 87 of file MollerTarget.hh.
Referenced by MollerTarget().
G4VPhysicalVolume* MollerTarget::TargetCell_Physical [private] |
Definition at line 86 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellBackInnerRadiusMax [private] |
Definition at line 125 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellBackOuterRadiusMax [private] |
Definition at line 126 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellBackRadiusMin [private] |
Definition at line 124 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellDeltaPhi [private] |
Definition at line 134 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellEntranceWindowThickness [private] |
Definition at line 112 of file MollerTarget.hh.
Referenced by ConstructComponent(), and MollerTarget().
G4double MollerTarget::targetCellExitWindowNippleRadius [private] |
Definition at line 128 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellExitWindowNippleThickness [private] |
Definition at line 114 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellExitWindowThickness [private] |
Definition at line 113 of file MollerTarget.hh.
Referenced by ConstructComponent(), and MollerTarget().
G4double MollerTarget::targetCellFrontInnerRadiusMax [private] |
Definition at line 121 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellFrontOuterRadiusMax [private] |
Definition at line 122 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellFrontRadiusMin [private] |
Definition at line 120 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellInnerLength [private] |
Definition at line 117 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellOuterLength [private] |
Definition at line 118 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellStartingPhi [private] |
Definition at line 133 of file MollerTarget.hh.
Referenced by MollerTarget().
G4double MollerTarget::targetCellWallThickness [private] |
Definition at line 115 of file MollerTarget.hh.
Referenced by MollerTarget().
G4LogicalVolume* MollerTarget::TargetContainer_Logical [private] |
Definition at line 108 of file MollerTarget.hh.
Referenced by MollerTarget().
G4Material* MollerTarget::TargetContainer_Material [private] |
Definition at line 110 of file MollerTarget.hh.
Referenced by MollerTarget().
G4VPhysicalVolume* MollerTarget::TargetContainer_Physical [private] |
Definition at line 109 of file MollerTarget.hh.
Referenced by MollerTarget(), and SetTargetCenterPositionInZ().
G4LogicalVolume* MollerTarget::TargetEntranceWindow_Logical [private] |
Definition at line 89 of file MollerTarget.hh.
Referenced by ConstructComponent(), MollerTarget(), and SetTargetEntranceWindowMaterial().
G4Material* MollerTarget::TargetEntranceWindow_Material [private] |
Definition at line 91 of file MollerTarget.hh.
Referenced by ConstructComponent(), and MollerTarget().
G4VPhysicalVolume* MollerTarget::TargetEntranceWindow_Physical [private] |
Definition at line 90 of file MollerTarget.hh.
Referenced by ConstructComponent(), and MollerTarget().
G4LogicalVolume* MollerTarget::TargetExitWindow_Logical [private] |
Definition at line 93 of file MollerTarget.hh.
Referenced by ConstructComponent(), MollerTarget(), and SetTargetExitWindowMaterial().
G4Material* MollerTarget::TargetExitWindow_Material [private] |
Definition at line 95 of file MollerTarget.hh.
Referenced by ConstructComponent(), and MollerTarget().
G4VPhysicalVolume* MollerTarget::TargetExitWindow_Physical [private] |
Definition at line 94 of file MollerTarget.hh.
Referenced by ConstructComponent(), and MollerTarget().
G4LogicalVolume* MollerTarget::TargetExitWindowNipple_Logical [private] |
Definition at line 97 of file MollerTarget.hh.
Referenced by MollerTarget(), and SetTargetExitWindowNippleMaterial().
G4Material* MollerTarget::TargetExitWindowNipple_Material [private] |
Definition at line 99 of file MollerTarget.hh.
Referenced by MollerTarget().
G4VPhysicalVolume* MollerTarget::TargetExitWindowNipple_Physical [private] |
Definition at line 98 of file MollerTarget.hh.
Referenced by MollerTarget().
G4LogicalVolume* MollerTarget::TargetMaterial_Logical [private] |
Definition at line 104 of file MollerTarget.hh.
Referenced by getTargetLogicalVolume(), MollerTarget(), and SetTargetMaterial().
G4VPhysicalVolume* MollerTarget::TargetMaterial_Physical [private] |
Definition at line 105 of file MollerTarget.hh.
Referenced by getTargetPhysicalVolume(), and MollerTarget().
Definition at line 139 of file MollerTarget.hh.
Referenced by MollerTarget(), and ~MollerTarget().
G4double MollerTarget::targetZPos [private] |
Definition at line 135 of file MollerTarget.hh.
Referenced by ConstructComponent(), GetTargetCenterPositionInZ(), MollerTarget(), and SetTargetCenterPositionInZ().