Hall-D Software  alpha
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DEventProcessor_bcal_calib Class Reference

#include <DEventProcessor_bcal_calib.h>

+ Inheritance diagram for DEventProcessor_bcal_calib:

Public Types

enum  track_type { kWireBased, kTimeBased }
 
enum  state_vector { state_x, state_y, state_tx, state_ty }
 

Public Member Functions

 DEventProcessor_bcal_calib ()
 
 ~DEventProcessor_bcal_calib ()
 
const char * className (void)
 

Private Member Functions

jerror_t init (void)
 Called once at program start. More...
 
jerror_t brun (jana::JEventLoop *eventLoop, int32_t runnumber)
 Called everytime a new run number is detected. More...
 
jerror_t evnt (jana::JEventLoop *eventLoop, uint64_t eventnumber)
 Called every event. More...
 
jerror_t erun (void)
 Called everytime run number changes, provided brun has been called. More...
 
jerror_t fini (void)
 Called after last event of last event source has been processed. More...
 
jerror_t GuessForStateVector (const cdc_track_t &track, DMatrix4x1 &S)
 
jerror_t DoFilter (DMatrix4x1 &S, vector< const DCDCTrackHit * > &hits)
 
jerror_t KalmanFilter (DMatrix4x1 &S, DMatrix4x4 &C, vector< const DCDCTrackHit * > &hits, deque< trajectory_t > &trajectory, double &chi2, unsigned int &ndof, bool timebased=false)
 
jerror_t SetReferenceTrajectory (double z, DMatrix4x1 &S, deque< trajectory_t > &trajectory, const DCDCTrackHit *last_cdc)
 
jerror_t FindSegments (vector< const DCDCTrackHit * > &hits, vector< cdc_segment_t > &segments, vector< bool > &used_hits)
 
jerror_t LinkSegments (vector< cdc_segment_t > &axial_segments, vector< bool > &used_axial, vector< const DCDCTrackHit * > &axial_hits, vector< const DCDCTrackHit * > &stereo_hits, vector< cdc_track_t > &LinkedSegments)
 
bool MatchCDCHit (const DVector3 &vhat, const DVector3 &pos0, const DCDCTrackHit *hit)
 
void PlotLines (deque< trajectory_t > &traj)
 
bool MatchToBCAL (vector< const DBCALShower * > &bcalshowers, DMatrix4x1 &S)
 
unsigned int locate (vector< double > &xx, double x)
 
double cdc_variance (double t)
 
double cdc_drift_distance (double t)
 
double FindDoca (double z, const DMatrix4x1 &S, const DVector3 &vhat, const DVector3 &origin)
 
double GetDriftDistance (double t)
 
double GetDriftVariance (double t)
 

Private Attributes

pthread_mutex_t mutex
 
TH1F * Hcdc_prob
 
TH1F * Hcdcmatch
 
TH1F * Hcdcmatch_stereo
 
TH2F * Hbcalmatchxy
 
double mT0
 
DMatrix4x1 Zero4x1
 
DMatrix4x4 Zero4x4
 
double mOuterTime
 
double mOuterZ
 
vector< double > cdc_drift_table
 
double CDC_RES_PAR1
 
double CDC_RES_PAR2
 
bool DEBUG_HISTS
 
bool DEBUG_PLOT_LINES
 

Detailed Description

Definition at line 68 of file DEventProcessor_bcal_calib.h.

Member Enumeration Documentation

Enumerator
state_x 
state_y 
state_tx 
state_ty 

Definition at line 78 of file DEventProcessor_bcal_calib.h.

Enumerator
kWireBased 
kTimeBased 

Definition at line 74 of file DEventProcessor_bcal_calib.h.

Constructor & Destructor Documentation

DEventProcessor_bcal_calib::DEventProcessor_bcal_calib ( )

Definition at line 71 of file DEventProcessor_bcal_calib.cc.

DEventProcessor_bcal_calib::~DEventProcessor_bcal_calib ( )

Definition at line 79 of file DEventProcessor_bcal_calib.cc.

Member Function Documentation

jerror_t DEventProcessor_bcal_calib::brun ( jana::JEventLoop *  eventLoop,
int32_t  runnumber 
)
private

Called everytime a new run number is detected.

Definition at line 125 of file DEventProcessor_bcal_calib.cc.

References cdc_drift_table, and dapp.

double DEventProcessor_bcal_calib::cdc_drift_distance ( double  t)
private

Definition at line 55 of file DEventProcessor_bcal_calib.cc.

References cdc_drift_table, xstream::base64::index(), and locate().

double DEventProcessor_bcal_calib::cdc_variance ( double  t)
inlineprivate

Definition at line 150 of file DEventProcessor_bcal_calib.h.

References CDC_RES_PAR1, CDC_RES_PAR2, and sigma.

const char* DEventProcessor_bcal_calib::className ( void  )
inline

Definition at line 72 of file DEventProcessor_bcal_calib.h.

jerror_t DEventProcessor_bcal_calib::DoFilter ( DMatrix4x1 S,
vector< const DCDCTrackHit * > &  hits 
)
private

Definition at line 243 of file DEventProcessor_bcal_calib.cc.

References C0, and S.

jerror_t DEventProcessor_bcal_calib::erun ( void  )
private

Called everytime run number changes, provided brun has been called.

Definition at line 155 of file DEventProcessor_bcal_calib.cc.

jerror_t DEventProcessor_bcal_calib::evnt ( jana::JEventLoop *  eventLoop,
uint64_t  eventnumber 
)
private

Called every event.

Definition at line 174 of file DEventProcessor_bcal_calib.cc.

References cdc_hit_cmp(), and S.

double DEventProcessor_bcal_calib::FindDoca ( double  z,
const DMatrix4x1 S,
const DVector3 vhat,
const DVector3 origin 
)
private

Definition at line 820 of file DEventProcessor_bcal_calib.cc.

References S.

jerror_t DEventProcessor_bcal_calib::FindSegments ( vector< const DCDCTrackHit * > &  hits,
vector< cdc_segment_t > &  segments,
vector< bool > &  used_hits 
)
private
jerror_t DEventProcessor_bcal_calib::fini ( void  )
private

Called after last event of last event source has been processed.

Definition at line 165 of file DEventProcessor_bcal_calib.cc.

double DEventProcessor_bcal_calib::GetDriftDistance ( double  t)
private
double DEventProcessor_bcal_calib::GetDriftVariance ( double  t)
private
jerror_t DEventProcessor_bcal_calib::GuessForStateVector ( const cdc_track_t track,
DMatrix4x1 S 
)
private
jerror_t DEventProcessor_bcal_calib::init ( void  )
private

Called once at program start.

Definition at line 87 of file DEventProcessor_bcal_calib.cc.

jerror_t DEventProcessor_bcal_calib::KalmanFilter ( DMatrix4x1 S,
DMatrix4x4 C,
vector< const DCDCTrackHit * > &  hits,
deque< trajectory_t > &  trajectory,
double &  chi2,
unsigned int &  ndof,
bool  timebased = false 
)
private

compute initial doca^2 to first wire

Definition at line 402 of file DEventProcessor_bcal_calib.cc.

References H, I, DCoordinateSystem::origin, S, DMatrix4x4::Transpose(), tx, and DCoordinateSystem::udir.

jerror_t DEventProcessor_bcal_calib::LinkSegments ( vector< cdc_segment_t > &  axial_segments,
vector< bool > &  used_axial,
vector< const DCDCTrackHit * > &  axial_hits,
vector< const DCDCTrackHit * > &  stereo_hits,
vector< cdc_track_t > &  LinkedSegments 
)
private
unsigned int DEventProcessor_bcal_calib::locate ( vector< double > &  xx,
double  x 
)
private

Definition at line 32 of file DEventProcessor_bcal_calib.cc.

bool DEventProcessor_bcal_calib::MatchCDCHit ( const DVector3 vhat,
const DVector3 pos0,
const DCDCTrackHit hit 
)
private
bool DEventProcessor_bcal_calib::MatchToBCAL ( vector< const DBCALShower * > &  bcalshowers,
DMatrix4x1 S 
)
private

Definition at line 922 of file DEventProcessor_bcal_calib.cc.

References bcal_match_t::dir, bcal_match_t::match, S, sqrt(), temp, x, and y.

void DEventProcessor_bcal_calib::PlotLines ( deque< trajectory_t > &  traj)
private

Definition at line 847 of file DEventProcessor_bcal_calib.cc.

References c1, and S.

jerror_t DEventProcessor_bcal_calib::SetReferenceTrajectory ( double  z,
DMatrix4x1 S,
deque< trajectory_t > &  trajectory,
const DCDCTrackHit last_cdc 
)
private

Member Data Documentation

vector<double> DEventProcessor_bcal_calib::cdc_drift_table
private

Definition at line 140 of file DEventProcessor_bcal_calib.h.

double DEventProcessor_bcal_calib::CDC_RES_PAR1
private

Definition at line 143 of file DEventProcessor_bcal_calib.h.

Referenced by cdc_variance().

double DEventProcessor_bcal_calib::CDC_RES_PAR2
private

Definition at line 143 of file DEventProcessor_bcal_calib.h.

Referenced by cdc_variance().

bool DEventProcessor_bcal_calib::DEBUG_HISTS
private

Definition at line 145 of file DEventProcessor_bcal_calib.h.

bool DEventProcessor_bcal_calib::DEBUG_PLOT_LINES
private

Definition at line 145 of file DEventProcessor_bcal_calib.h.

TH2F* DEventProcessor_bcal_calib::Hbcalmatchxy
private

Definition at line 130 of file DEventProcessor_bcal_calib.h.

TH1F* DEventProcessor_bcal_calib::Hcdc_prob
private

Definition at line 129 of file DEventProcessor_bcal_calib.h.

TH1F * DEventProcessor_bcal_calib::Hcdcmatch
private

Definition at line 129 of file DEventProcessor_bcal_calib.h.

TH1F * DEventProcessor_bcal_calib::Hcdcmatch_stereo
private

Definition at line 129 of file DEventProcessor_bcal_calib.h.

double DEventProcessor_bcal_calib::mOuterTime
private

Definition at line 137 of file DEventProcessor_bcal_calib.h.

double DEventProcessor_bcal_calib::mOuterZ
private

Definition at line 137 of file DEventProcessor_bcal_calib.h.

double DEventProcessor_bcal_calib::mT0
private

Definition at line 132 of file DEventProcessor_bcal_calib.h.

pthread_mutex_t DEventProcessor_bcal_calib::mutex
private

Definition at line 127 of file DEventProcessor_bcal_calib.h.

DMatrix4x1 DEventProcessor_bcal_calib::Zero4x1
private

Definition at line 134 of file DEventProcessor_bcal_calib.h.

DMatrix4x4 DEventProcessor_bcal_calib::Zero4x4
private

Definition at line 135 of file DEventProcessor_bcal_calib.h.


The documentation for this class was generated from the following files: