#ifndef L1Algo_h #define L1Algo_h 1 #include using namespace std; #include "L1Field.h" #include "L1Station.h" #include "L1StsHit.h" #include "L1Triplet.h" #include "L1Branch.h" class L1Algo{ public: L1Station vStations[20] _fvecalignment; L1FieldRegion vtxFieldRegion _fvecalignment; L1FieldValue vtxFieldValue _fvecalignment; void CATrackFinder(); void CAFindTrack( int ista, const L1Triplet* ptrip, L1Branch& newtrack, unsigned char &new_L, float &new_chi2, L1Branch ¤ttrack, unsigned char &curr_L, float &curr_chi2 ); void Init( float geo[] ); //local copy of measurements arranged vs station/planes int NStations, fTrackingLevel, fGhostSuppression, bla3; double TRACK_CHI2_CUT; double CATime; double fMomentumCutOff; double bla; vector< float > vStsStrips, vStsStripsB; vector< L1StsHit > vStsHits; vector< unsigned char > vSFlag; // = iStation*4 + used*2 + used_by_duplets; vector< unsigned char > vSFlagB; vector< unsigned short int > vRecoHits; vector< L1Track > vTracks; vector vTriplets; int StsHitsStartIndex[20], StsHitsStopIndex[20]; int TripStartIndex[20], TripStopIndex[20]; } _fvecalignment; inline void L1Algo::Init( float geo[] ) { int ind=0; { L1FieldValue B[3]; fvec z[3]; for( int i=0; i<3; i++){ z[i] = geo[ind++]; B[i].x = geo[ind++]; B[i].y = geo[ind++]; B[i].z = geo[ind++]; cout<<"L1Algo Input Magnetic field:"<=0; i-- ){ L1Station &st = vStations[i]; fvec dz = st.z-z0; fvec By = vStations[i].fieldSlice.cy[0]; Sy += dz*sy + dz*dz*By/2.; sy += dz*By; st.Sy = Sy; z0 = st.z; } } cout<<"L1Algo initialized"<