--- DarthVader/TrackerLevel2/src/TrkLevel2.cpp 2006/11/08 16:42:28 1.16 +++ DarthVader/TrackerLevel2/src/TrkLevel2.cpp 2006/11/14 16:28:42 1.18 @@ -21,6 +21,42 @@ // // //-------------------------------------- +/** + * Evaluates the trajectory in the apparatus associated to the track. + * It integrates the equations of motion in the magnetic field. The magnetic field should be previously loaded ( by calling TrkLevel2::LoadField() ), otherwise an error message is returned. + * @param t pointer to an object of the class Trajectory, + * which z coordinates should be previously initialized by calling the proper constructor ( Trajectory::Trajectory(int n, float* zin) ). + * @return error flag. + */ +int Trajectory::DoTrack2(float* al){ + + double *dxout = new double[npoint]; + double *dyout = new double[npoint]; + double *dthxout = new double[npoint]; + double *dthyout = new double[npoint]; + double *dtlout = new double[npoint]; + double *dzin = new double[npoint]; + double dal[5]; + + int ifail = 0; + + for (int i=0; i<5; i++) dal[i] = (double)al[i]; + for (int i=0; i