#include <MMT_Road.h>
|  | 
|  | MMT_Road (const char sector, const int roadSize, const int UpX, const int DownX, const int UpUV, const int DownUV, const int xthr, const int uvthr, const int iroadx, const int iroadu=-1, const int iroadv=-1) | 
|  | 
|  | ~MMT_Road ()=default | 
|  | 
| void | addHits (std::vector< std::shared_ptr< MMT_Hit > > &hits) | 
|  | 
| double | avgSofX () const | 
|  | 
| double | avgSofUV (const int uv1, const int uv2) const | 
|  | 
| bool | checkCoincidences (const int bcwind) const | 
|  | 
| unsigned int | countHits () const | 
|  | 
| unsigned int | countRealHits () const | 
|  | 
| unsigned int | countUVHits (bool flag) const | 
|  | 
| unsigned int | countXHits (bool flag) const | 
|  | 
| bool | evaluateLowRes () const | 
|  | 
| bool | horizontalCheck () const | 
|  | 
| void | incrementAge (const int bcwind) | 
|  | 
| const std::vector< MMT_Hit > & | getHitVector () const | 
|  | 
| char | getSector () const | 
|  | 
| int | getXthreshold () const | 
|  | 
| int | getUVthreshold () const | 
|  | 
| int | iRoadx () const | 
|  | 
| int | iRoadu () const | 
|  | 
| int | iRoadv () const | 
|  | 
| bool | matureCheck (const int bcwind) const | 
|  | 
| double | mxl () const | 
|  | 
| void | reset () | 
|  | 
| bool | stereoCheck () const | 
|  | 
Definition at line 12 of file MMT_Road.h.
 
◆ MMT_Road()
      
        
          | MMT_Road::MMT_Road | ( | const char | sector, | 
        
          |  |  | const int | roadSize, | 
        
          |  |  | const int | UpX, | 
        
          |  |  | const int | DownX, | 
        
          |  |  | const int | UpUV, | 
        
          |  |  | const int | DownUV, | 
        
          |  |  | const int | xthr, | 
        
          |  |  | const int | uvthr, | 
        
          |  |  | const int | iroadx, | 
        
          |  |  | const int | iroadu = -1, | 
        
          |  |  | const int | iroadv = -1 | 
        
          |  | ) |  |  | 
      
 
 
◆ ~MMT_Road()
◆ addHits()
      
        
          | void MMT_Road::addHits | ( | std::vector< std::shared_ptr< MMT_Hit > > & | hits | ) |  | 
      
 
Definition at line 29 of file MMT_Road.cxx.
   30   for (
const auto &hit_i : 
hits) {
 
   31     if (
m_sector != hit_i->getSector()) 
continue;
 
   35       slow = hit_i->getShift() + 
m_slopeXlow * hit_i->getPitchOverZ();
 
   36       shigh = hit_i->getShift() + 
m_slopeXhigh * hit_i->getPitchOverZ();
 
   38     else if (hit_i->isU()) {
 
   39       slow = hit_i->getShift() + 
m_slopeUlow * hit_i->getPitchOverZ();
 
   40       shigh = hit_i->getShift() + 
m_slopeUhigh * hit_i->getPitchOverZ();
 
   42     else if (hit_i->isV()) {
 
   43       slow = hit_i->getShift() + 
m_slopeVlow * hit_i->getPitchOverZ();
 
   44       shigh = hit_i->getShift() + 
m_slopeVhigh * hit_i->getPitchOverZ();
 
   48     const double val = hit_i->getRZSlope();
 
   49     bool has_hit = (
val > 0.) ? (
val > slow && 
val < shigh) : (
val > shigh && 
val < slow);
 
   51     if (!has_hit) 
continue;
 
   54     const int bo = hit_i->getPlane();
 
   55     auto it = std::find_if(
m_road_hits.begin(), 
m_road_hits.end(), [&bo](
const auto &hit) { return (hit.getPlane() == bo); });
 
   58       if (!hit_i->isNoise() && 
it->isNoise()) {
 
   64     if (has_hit) 
continue;
 
 
 
 
◆ avgSofUV()
      
        
          | double MMT_Road::avgSofUV | ( | const int | uv1, | 
        
          |  |  | const int | uv2 | 
        
          |  | ) |  | const | 
      
 
Definition at line 82 of file MMT_Road.cxx.
   86     const int bo = hit.getPlane();
 
   87     if (bo == uv1 || bo == uv2) {
 
   88       sum += hit.getRZSlope();
 
 
 
 
◆ avgSofX()
      
        
          | double MMT_Road::avgSofX | ( |  | ) | const | 
      
 
 
◆ checkCoincidences()
  
  | 
        
          | bool MMT_Road::checkCoincidences | ( | const int | bcwind | ) | const |  | inline | 
 
 
◆ countHits()
  
  | 
        
          | unsigned int MMT_Road::countHits | ( |  | ) | const |  | inline | 
 
 
◆ countRealHits()
      
        
          | unsigned int MMT_Road::countRealHits | ( |  | ) | const | 
      
 
Definition at line 95 of file MMT_Road.cxx.
   97                        [&](
auto& hit) { return hit.isNoise()==false; });
 
 
 
 
◆ countUVHits()
      
        
          | unsigned int MMT_Road::countUVHits | ( | bool | flag | ) | const | 
      
 
Definition at line 100 of file MMT_Road.cxx.
  102                        [&](
auto& hit) { return (hit.isU() || hit.isV()) && hit.isNoise()==flag; });
 
 
 
 
◆ countXHits()
      
        
          | unsigned int MMT_Road::countXHits | ( | bool | flag | ) | const | 
      
 
Definition at line 105 of file MMT_Road.cxx.
  107                        [&](
auto& hit) { return hit.isX() && hit.isNoise()==flag; });
 
 
 
 
◆ evaluateLowRes()
      
        
          | bool MMT_Road::evaluateLowRes | ( |  | ) | const | 
      
 
Definition at line 110 of file MMT_Road.cxx.
  111   unsigned int nhits1 = 0, nhits2 = 0;
 
  113     nhits1 += hit.getPlane() < 4 && !hit.isNoise();
 
  114     nhits2 += hit.getPlane() > 3 && !hit.isNoise();
 
  116   return (nhits1 < 4 || nhits2 < 4);
 
 
 
 
◆ getHitVector()
  
  | 
        
          | const std::vector<MMT_Hit>& MMT_Road::getHitVector | ( |  | ) | const |  | inline | 
 
 
◆ getSector()
  
  | 
        
          | char MMT_Road::getSector | ( |  | ) | const |  | inline | 
 
 
◆ getUVthreshold()
  
  | 
        
          | int MMT_Road::getUVthreshold | ( |  | ) | const |  | inline | 
 
 
◆ getXthreshold()
  
  | 
        
          | int MMT_Road::getXthreshold | ( |  | ) | const |  | inline | 
 
 
◆ horizontalCheck()
      
        
          | bool MMT_Road::horizontalCheck | ( |  | ) | const | 
      
 
Definition at line 119 of file MMT_Road.cxx.
  120   int nx1 = 0, nx2 = 0;
 
  122     nx1 += hit.getPlane() >-1 && hit.getPlane() < 2;
 
  123     nx2 += hit.getPlane() > 5 && hit.getPlane() < 8;
 
  125     if (nx1 > 0 && nx2 > 0 && (nx1+nx2) >= 
m_xthr) 
return true;
 
 
 
 
◆ incrementAge()
      
        
          | void MMT_Road::incrementAge | ( | const int | bcwind | ) |  | 
      
 
Definition at line 130 of file MMT_Road.cxx.
  131   std::vector<unsigned int> old_ihits;
 
  132   for (
unsigned int j = 0; j < 
m_road_hits.size(); j++) {
 
  134     if (
m_road_hits[j].getAge() > (bcwind-1)) old_ihits.push_back(j);
 
 
 
 
◆ iRoadu()
  
  | 
        
          | int MMT_Road::iRoadu | ( |  | ) | const |  | inline | 
 
 
◆ iRoadv()
  
  | 
        
          | int MMT_Road::iRoadv | ( |  | ) | const |  | inline | 
 
 
◆ iRoadx()
  
  | 
        
          | int MMT_Road::iRoadx | ( |  | ) | const |  | inline | 
 
 
◆ matureCheck()
      
        
          | bool MMT_Road::matureCheck | ( | const int | bcwind | ) | const | 
      
 
Definition at line 139 of file MMT_Road.cxx.
  141     if (hit.getAge() == (bcwind - 1)) 
return true;
 
 
 
 
◆ mxl()
      
        
          | double MMT_Road::mxl | ( |  | ) | const | 
      
 
Definition at line 146 of file MMT_Road.cxx.
  147   std::vector<double> ys, zs;
 
  150       ys.push_back(hit.getR());
 
  151       zs.push_back(hit.getZ());
 
  156   double sum_sq_z = std::inner_product(zs.begin(), zs.end(), zs.begin(), 0.0);
 
  157   for (
unsigned int i = 0; 
i < ys.size(); 
i++) 
mxl += ys[
i]*( (zs[
i]-avg_z) / (sum_sq_z - zs.size()*
std::pow(avg_z,2)) );
 
 
 
 
◆ reset()
◆ stereoCheck()
      
        
          | bool MMT_Road::stereoCheck | ( |  | ) | const | 
      
 
 
◆ m_iroadu
◆ m_iroadv
◆ m_iroadx
◆ m_road_hits
  
  | 
        
          | std::vector<MMT_Hit> MMT_Road::m_road_hits |  | private | 
 
 
◆ m_sector
◆ m_slopeUhigh
  
  | 
        
          | double MMT_Road::m_slopeUhigh |  | private | 
 
 
◆ m_slopeUlow
  
  | 
        
          | double MMT_Road::m_slopeUlow |  | private | 
 
 
◆ m_slopeVhigh
  
  | 
        
          | double MMT_Road::m_slopeVhigh |  | private | 
 
 
◆ m_slopeVlow
  
  | 
        
          | double MMT_Road::m_slopeVlow |  | private | 
 
 
◆ m_slopeXhigh
  
  | 
        
          | double MMT_Road::m_slopeXhigh |  | private | 
 
 
◆ m_slopeXlow
  
  | 
        
          | double MMT_Road::m_slopeXlow |  | private | 
 
 
◆ m_uvthr
◆ m_xthr
The documentation for this class was generated from the following files: