EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
RungeKuttaRequest.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file RungeKuttaRequest.h
1 
2 #ifndef _RUNGE_KUTTA_REQUEST_H
3 #define _RUNGE_KUTTA_REQUEST_H
4 
5 class RungeKutta {
6  friend class RungeKuttaRequest;
7  friend class TrKalmanNode;
8  friend class TrKalmanFilter;
9 
10  private:
11  // 2-d, 4-th or 5-th order;
12  int _order;
13 
14  // Will be set to '1' only if all the necessary m_i are Ok;
15  //int initialization_flag;
16 
17  // Actual usage of these pointers depends on required number of
18  // slices in Z (which is 2,3,6 for Runge-Kutta 2-d,4-th & 5-th
19  // order, respectively); the whole idea is that Runge-Kutta
20  // tracking requires field knowledge on a predefined set of
21  // XY-planes; once a grid is calculated there interpolation
22  // goes noticeably faster; mgrid usage is also required in
23  // general (even if official HRC map used), since it allows
24  // to fix used cells easily and thus guarantee continuity
25  // for F-matrix calculation procedure;
26  MgridSlice *m1, *m2, *m3, *m4, *m5, *m6;
27 } ;
28 
29 // It turns out to be fairly inconvenient to shuffle several parameters
30 // around; so split off code part which does not know anything about
31 // Kalman filter, HERMES, etc and pass this frame as a general "request"
32 // to perform Runge-Kutta step; remaining parameters to
33 // serve_runge_kutta_request() are really the ones which differ when
34 // calculating derivatives;
36  friend class TrKalmanNode;
37 
38  private:
39  int kk(MgridSlice *slice, double z, double x[4], double k[4]);
40  int serveRequest(double in[], double _q, double out[], int _repetition_flag);
41 
42  // Starting Z coordinate; step in Z; frame pointer to magnetic field slices;
43  // these parameters are set by perform_runge_kutta_step() and do not change;
44  double z0, h;
46 
47  // No sense to change self cell and cube during derivative calculation;
49  // Q/|p|; both parameters are set by serve_runge_kutta_request() and do
50  // not change between numerous calls to kk() routine;
51  double q;
52 } ;
53 
54 #endif