////////////////////////////////////////////////////////////////////////
/// \class RAT::TorusPMTConstructor
///
/// \brief Constructs a torus shape PMT
///
/// \author Phil Jones
/// \author Aksel Hallin -- contact person
/// \author Christopher Jackson -- contact person
///
/// REVISION HISTORY:\n
/// 03/12 : P.Jones - First Revision, new file. \n
///
/// \details Extends PMTConstructor to produce a torus shaped PMT.
///
////////////////////////////////////////////////////////////////////////
#ifndef __RAT_TorusPMTConstructor__
#define __RAT_TorusPMTConstructor__
#include
#include
#include
#include
namespace RAT
{
class TorusPMTConstructor : public PMTConstructor
{
public:
/// Constructor for the class, needs parameters and a name
TorusPMTConstructor( const std::string &prefix, ///< Prefix string
const PMTConstructorParams ¶ms ///< Parameters that define the pmt
);
virtual ~TorusPMTConstructor() {}
/// Construct the G4LogicalVolume that is a RAT PMT
void ConstructLogical();
/// Returns the Max height above the pmt equator of the bucket
double GetMaxHeight();
/// Returns the Max depth below the pmt equator of the bucket (note returns a -ive number)
double GetMaxDepth();
/// Returns the Max radius
double GetHexRadius();
protected:
/// Calculate the parameters that make the torus shape
void CalcInnerParams( GLG4TorusStack* body,///< The body solid
std::vector& innerZEdge,///< Inner Z edge co-ords
std::vector& innerRhoEdge,///< Inner rho edge coords
int& pcMirrorTopIndex, ///< Index in array that corresponds to photocathode mirror overlap top
int& pcMirrorBottomIndex, ///< Index in array that corresponds to photocathode mirror overlap bottom
double& zLowestDynode );///< The Lowest dynode position
double fMaxRadius; ///< Derived maximum radius of the PMT
private:
///To prevent usage
TorusPMTConstructor();
};
} //::RAT
#endif