#include "SabreDetector.h" #include /* Distances in meters, angles in radians. The channel arrays have four points, one for each corner. The corners are as follows, as if looking BACK along beam (i.e. from the target's pov): 0---------------------1 | | | | x | | <----- | | | | | | 3---------------------2 y (z is hence positive along beam direction) The channel numbers, also as looking back from target pov, are: >> rings are 0 -- 15 from inner to outer: 15 ------------------- 14 ------------------- 13 ------------------- . . . 2 ------------------- 1 ------------------- 0 ------------------- >> wedges are 0 -- 7 moving counterclockwise: 7 6 ... 1 0 | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | >> Note that the detector starts centered on the x-axis (central phi = 0) untilted, and then is rotated to wherever the frick it is supposed to go; phi = 90 is centered on y axis, pointing down towards the bottom of the scattering chamber -- gwm, Dec 2020; based on the og code from kgh */ SabreDetector::SabreDetector() : m_Router(0.1351), m_Rinner(0.0326), m_deltaPhi_flat(54.4*deg2rad), m_phiCentral(0.0), m_tilt(0.0), m_translation(0.,0.,0.) { m_YRot.SetAngle(m_tilt); m_ZRot.SetAngle(m_phiCentral); m_ringCoords_flat.resize(m_nRings); m_ringCoords_tilt.resize(m_nRings); m_wedgeCoords_flat.resize(m_nWedges); m_wedgeCoords_tilt.resize(m_nWedges); for(int i=0; i