27 |
#define NANGMAX 21 |
#define NANGMAX 21 |
28 |
#define NETAVALMAX 500 |
#define NETAVALMAX 500 |
29 |
|
|
30 |
|
#define NTRACKSMAX (NCLOYZ_MAX*NCLOXZ_MAX) |
31 |
|
|
32 |
#include <CalibTrk1Event.h> |
#include <CalibTrk1Event.h> |
33 |
#include <CalibTrk2Event.h> |
#include <CalibTrk2Event.h> |
39 |
#include <TTree.h> |
#include <TTree.h> |
40 |
|
|
41 |
|
|
42 |
|
|
43 |
#include <fstream> |
#include <fstream> |
44 |
#include <iostream> |
#include <iostream> |
45 |
/** |
/** |
182 |
float dedx_y[NTRKMAX][6]; |
float dedx_y[NTRKMAX][6]; |
183 |
int cltrx[NTRKMAX][6]; |
int cltrx[NTRKMAX][6]; |
184 |
int cltry[NTRKMAX][6]; |
int cltry[NTRKMAX][6]; |
185 |
|
int multmaxx[NTRKMAX][6]; |
186 |
|
int multmaxy[NTRKMAX][6]; |
187 |
|
float seedx[NTRKMAX][6]; |
188 |
|
float seedy[NTRKMAX][6]; |
189 |
|
float xpu[NTRKMAX][6]; |
190 |
|
float ypu[NTRKMAX][6]; |
191 |
// float bdl[NTRKMAX]; |
// float bdl[NTRKMAX]; |
192 |
|
|
193 |
void InitcTrkLevel2(){ |
void InitcTrkLevel2(){ |
239 |
ayv_nt[i][ii] = 0; |
ayv_nt[i][ii] = 0; |
240 |
dedx_x[i][ii] = 0; |
dedx_x[i][ii] = 0; |
241 |
dedx_y[i][ii] = 0; |
dedx_y[i][ii] = 0; |
242 |
|
multmaxx[i][ii] = 0; |
243 |
|
multmaxy[i][ii] = 0; |
244 |
|
seedx[i][ii] = 0; |
245 |
|
seedy[i][ii] = 0; |
246 |
|
xpu[i][ii] = 0; |
247 |
|
ypu[i][ii] = 0; |
248 |
} |
} |
249 |
} |
} |
250 |
} |
} |
378 |
|
|
379 |
|
|
380 |
}; |
}; |
381 |
|
|
382 |
|
// ================================================================== |
383 |
|
/** |
384 |
|
* \brief Struct to pass DELTAB parameters to F77 routines |
385 |
|
*/ |
386 |
|
struct cDeltaB { |
387 |
|
double delta0; |
388 |
|
double delta1; |
389 |
|
double dlt; |
390 |
|
}; |
391 |
|
|
392 |
// |
// |
393 |
/** |
/** |
394 |
* \Struct for the hough transform variables |
* \Struct for the hough transform variables |
457 |
}; |
}; |
458 |
|
|
459 |
/** |
/** |
460 |
|
* \Struct for track candidates after hough transform |
461 |
|
*/ |
462 |
|
struct cTrkCandidates { |
463 |
|
int ntracks; |
464 |
|
float al[NTRACKSMAX][5]; |
465 |
|
float xm[NTRACKSMAX][NPLANE]; |
466 |
|
float ym[NTRACKSMAX][NPLANE]; |
467 |
|
float zm[NTRACKSMAX][NPLANE]; |
468 |
|
float resx[NTRACKSMAX][NPLANE]; |
469 |
|
float resy[NTRACKSMAX][NPLANE]; |
470 |
|
float xv[NTRACKSMAX][NPLANE]; |
471 |
|
float yv[NTRACKSMAX][NPLANE]; |
472 |
|
float zv[NTRACKSMAX][NPLANE]; |
473 |
|
float axv[NTRACKSMAX][NPLANE]; |
474 |
|
float ayv[NTRACKSMAX][NPLANE]; |
475 |
|
float xgood[NTRACKSMAX][NPLANE]; |
476 |
|
float ygood[NTRACKSMAX][NPLANE]; |
477 |
|
int cp[NTRACKSMAX][NPLANE]; |
478 |
|
int cls[NTRACKSMAX][NPLANE]; |
479 |
|
int sensor[NTRACKSMAX][NPLANE]; |
480 |
|
int ladder[NTRACKSMAX][NPLANE]; |
481 |
|
float bx[NTRACKSMAX][NPLANE]; |
482 |
|
float by[NTRACKSMAX][NPLANE]; |
483 |
|
float chi2[NTRACKSMAX]; |
484 |
|
|
485 |
|
void Init(){ |
486 |
|
ntracks=0; |
487 |
|
for(int i=0; i<NTRACKSMAX; i++){ |
488 |
|
for(int ii=0; ii<5; ii++)al[i][ii]=0; |
489 |
|
chi2[i]=0; |
490 |
|
for(int ip=0; ip<NPLANE; ip++){ |
491 |
|
xm[i][ip]=0; |
492 |
|
ym[i][ip]=0; |
493 |
|
zm[i][ip]=0; |
494 |
|
resx[i][ip]=0; |
495 |
|
resy[i][ip]=0; |
496 |
|
xv[i][ip]=0; |
497 |
|
yv[i][ip]=0; |
498 |
|
zv[i][ip]=0; |
499 |
|
axv[i][ip]=0; |
500 |
|
ayv[i][ip]=0; |
501 |
|
xgood[i][ip]=0; |
502 |
|
ygood[i][ip]=0; |
503 |
|
cp[i][ip]=0; |
504 |
|
cls[i][ip]=0; |
505 |
|
sensor[i][ip]=0; |
506 |
|
ladder[i][ip]=0; |
507 |
|
bx[i][ip]=0; |
508 |
|
by[i][ip]=0; |
509 |
|
} |
510 |
|
} |
511 |
|
|
512 |
|
}; |
513 |
|
|
514 |
|
|
515 |
|
}; |
516 |
|
|
517 |
|
/** |
518 |
* \brief Struct to pass VA1-mask to F77 routines |
* \brief Struct to pass VA1-mask to F77 routines |
519 |
*/ |
*/ |
520 |
struct cTrkMask { |
struct cTrkMask { |
553 |
float eta4[NANGMAX][NETAVALMAX]; |
float eta4[NANGMAX][NETAVALMAX]; |
554 |
float feta4[NANGMAX][NLADDER][NVIEW][NETAVALMAX]; |
float feta4[NANGMAX][NLADDER][NVIEW][NETAVALMAX]; |
555 |
float fcorr[NANGMAX][NLADDER][NVIEW]; |
float fcorr[NANGMAX][NLADDER][NVIEW]; |
556 |
|
float e234ax[6];//F77: e2fax,e2tax,e3fax,e3tax,e4fax,e4tax |
557 |
|
float e234ay[6];//F77: e2fay,e2tay,e3fay,e3tay,e4fay,e4tay |
558 |
|
|
559 |
}; |
}; |
560 |
/** |
/** |
574 |
extern struct cPath path_; |
extern struct cPath path_; |
575 |
extern struct cDbg dbg_; |
extern struct cDbg dbg_; |
576 |
extern struct cTrkHough houghevent_; |
extern struct cTrkHough houghevent_; |
577 |
|
extern struct cTrkCandidates trackcandidates_; |
578 |
extern struct cMini2track track_; |
extern struct cMini2track track_; |
579 |
extern struct cTrkETA pfa_; |
extern struct cTrkETA pfa_; |
580 |
extern struct cTrkSW sw_; |
extern struct cTrkSW sw_; |
581 |
|
extern struct cDeltaB deltab_; |
582 |
|
|
583 |
void fillpedsigfromdefault_(); |
void fillpedsigfromdefault_(); |
584 |
int readmipparam_(); |
int readmipparam_(); |
592 |
void gufld_(float*, float*); |
void gufld_(float*, float*); |
593 |
void xyzpam_(int*,int*,int*,int*,int*,float*,float*,float*,float*); |
void xyzpam_(int*,int*,int*,int*,int*,float*,float*,float*,float*); |
594 |
float riseta_(int*,float*); |
float riseta_(int*,float*); |
595 |
|
void chisq_(int*, int*); |
596 |
|
|
597 |
} |
} |
598 |
|
|