#include #include #include #include #include #include #include #include using namespace RAT; using namespace CLHEP; using namespace std; PanelT10::PanelT10( const std::string& prefix, const G4ThreeVector& position, const G4ThreeVector& zAxis, const G4ThreeVector& xAxis, G4Material* panelMaterial, G4VisAttributes* visAttributes ) : PanelBase( prefix, position, zAxis, xAxis, panelMaterial, visAttributes ) { SetPMTList(); SetCutList(); } void PanelT10::ConstructPanel() { // Construct the Panel Envelope, for T10 it is a equilateral triangle double fPanelRadius = 2.0 * fPMTc + 2.0 * fPMTb - cos( twopi / 6.0 * rad ) * fPMTb; double z[] = { fPanelDepth, fPanelHeight }; double rInner[] = { 0, 0 }; double rOuter[] = { fPanelRadius, fPanelRadius }; G4VSolid* panelSolid = new G4Polyhedra( fPrefix + "_t10_solid", 0.0, twopi, 3, 2, z, rInner, rOuter ); fPanelLogical = new G4LogicalVolume( panelSolid, fPanelMaterial, fPrefix + "_t10_logic" ); fPanelLogical->SetVisAttributes( fVisAttributes ); fPMTRotation = 0.0; } void PanelT10::SetPMTList() { fPMTs.clear(); fPMTs.push_back( PanelPMT( G4ThreeVector( 0.0, 0.0, 0.0 ) ) ); fPMTs.push_back( PanelPMT( G4ThreeVector( fPMTb + fPMTc, fPMTRadius, 0.0 ) ) ); fPMTs.push_back( PanelPMT( G4ThreeVector( 0.0, 2.0 * fPMTRadius, 0.0 ) ) ); fPMTs.push_back( PanelPMT( G4ThreeVector( -fPMTb - fPMTc, fPMTRadius, 0.0 ) ) ); fPMTs.push_back( PanelPMT( G4ThreeVector( -fPMTb - fPMTc, -fPMTRadius, 0.0 ) ) ); fPMTs.push_back( PanelPMT( G4ThreeVector( 0.0, -2.0 * fPMTRadius, 0.0 ) ) ); fPMTs.push_back( PanelPMT( G4ThreeVector( fPMTb + fPMTc, -fPMTRadius, 0.0 ) ) ); fPMTs.push_back( PanelPMT( G4ThreeVector( 2.0 * fPMTb + 2.0 * fPMTc, 0.0, 0.0 ) ) ); fPMTs.push_back( PanelPMT( G4ThreeVector( -fPMTb - fPMTc, 3.0 * fPMTRadius, 0.0 ) ) ); fPMTs.push_back( PanelPMT( G4ThreeVector( -fPMTb - fPMTc, -3.0 * fPMTRadius, 0.0 ) ) ); } void PanelT10::SetCutList() { fEdgeCoords.clear(); fEdgeCoords.push_back( G4ThreeVector( 3.0 * fPMTb + 3.0 * fPMTc, -1.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( 3.0 * fPMTb + 3.0 * fPMTc, 1.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( 2.0 * fPMTb + 2.0 * fPMTc, -2.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( 0.0, -4.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( -1.0 * fPMTb - 1.0 * fPMTc, -5.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( -2.0 * fPMTb - 2.0 * fPMTc, -4.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( -2.0 * fPMTb - 2.0 * fPMTc, -2.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( -2.0 * fPMTb - 2.0 * fPMTc, 2.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( -2.0 * fPMTb - 2.0 * fPMTc, 4.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( -1.0 * fPMTb - 1.0 * fPMTc, 5.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( 0.0, 4.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( 2.0 * fPMTb + 2.0 * fPMTc, 2.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( -2.0 * fPMTb - 2.0 * fPMTc, 0.0, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( 1.0 * fPMTb + 1.0 * fPMTc, 3.0 * fPMTRadius, 0.0 ) ); fEdgeCoords.push_back( G4ThreeVector( 1.0 * fPMTb + 1.0 * fPMTc, -3.0 * fPMTRadius, 0.0 ) ); }