7 #include "Geometry/GeometryCore.h" 24 _description =
"Cartesian segmentation in the local XY-plane with strip along the Y direction";
26 std::cout <<
"######### gar::geo::seg::SegmentationStripXAlg() " <<
std::endl ;
37 _description =
"Cartesian segmentation in the local XY-plane with strip along the Y direction";
39 std::cout <<
"######### gar::geo::seg::SegmentationStripXAlg() " <<
std::endl ;
78 std::array<double, 3> cellPosition;
85 cellPosition[0] = ( cellIndexX + 0.5 ) *
_stripSizeX;
104 double localX = localPosition[0];
105 double localY = localPosition[1];
153 TVector3 stripEnd1(0., 0., 0.);
154 TVector3 stripEnd2(0., 0., 0.);
158 stripEnd1.SetX(local[0]);
159 stripEnd2.SetX(local[0]);
160 stripEnd1.SetZ(local[2]);
161 stripEnd2.SetZ(local[2]);
163 return std::make_pair(stripEnd1, stripEnd2);
178 return std::make_pair(time1, time2);
189 if(
std::abs(pos) > stripLength / 2. ) pos = (pos > 0) ? stripLength / 2. : -stripLength / 2.;
191 std::array<double, 3> newlocal = {local[0],
pos, local[2]};
static constexpr double cm
const BitFieldCoder * _decoder
bool isTile(const gar::raw::CellID_t &cID) const override
std::array< double, 3 > GetPosition(const gar::geo::GeometryCore &geo, const gar::raw::CellID_t &cID) const override
std::pair< float, float > CalculateLightPropagation(const gar::geo::GeometryCore &geo, const std::array< double, 3 > &local, const gar::raw::CellID_t &cID) const override
void set(long64 &bitfield, size_t index, ulong64 value) const
double _stripSizeX
the strip size in X
void reconfigure(fhicl::ParameterSet const &pset) override
void PrintParameters() const override
double _layer_dim_X
layer dimension in X
Description of geometry of one entire detector.
double _layer_dim_Y
layer dimension in Y
std::string _layerId
the field name used for layer
std::string _xId
the field name used for X
std::string _yId
the field name used for Y
double getStripLength(const gar::geo::GeometryCore &geo, const std::array< double, 3 > &local, const gar::raw::CellID_t &cID) const override
Helper class for decoding and encoding a bit field of 64bits for convenient declaration.
T get(std::string const &key) const
std::array< double, 3 > ReconstructStripHitPosition(const gar::geo::GeometryCore &geo, const std::array< double, 3 > &local, const float &xlocal, const gar::raw::CellID_t &cID) const override
std::string _sliceId
the field name used for slice
gar::raw::CellID_t GetCellID(const gar::geo::GeometryCore &geo, const unsigned int &det_id, const unsigned int &stave, const unsigned int &module, const unsigned int &layer, const unsigned int &slice, const std::array< double, 3 > &localPosition) const override
determine the cell ID based on the position
double _frac
fraction of tiles to remove at the edge
General GArSoft Utilities.
long64 get(long64 bitfield, size_t index) const
static constexpr double mm
unsigned int _nLayers
number of layers
std::pair< TVector3, TVector3 > getStripEnds(const gar::geo::GeometryCore &geo, const std::array< double, 3 > &local, const gar::raw::CellID_t &cID) const override
void decode(std::any const &a, Hep2Vector &result)
std::string _encoding
the encoding string
SegmentationStripXAlg(fhicl::ParameterSet const &pset)
Default constructor used by derived classes passing the encoding string.
LArSoft geometry interface.
QTextStream & endl(QTextStream &s)
void Initialize(const gar::geo::GeometryCore &geo) override
bool isBarrel(const gar::raw::CellID_t &cID) const override