Commit in hps-java/src/main/java/org/lcsim/hps/recon/tracking on MAIN | |||
SvtTrackExtrapolator.java | +22 | -9 | 1.7 -> 1.8 |
Adding constructor with track params and being consistent with coord frame
diff -u -r1.7 -r1.8 --- SvtTrackExtrapolator.java 22 Dec 2012 20:38:15 -0000 1.7 +++ SvtTrackExtrapolator.java 11 Oct 2013 02:23:59 -0000 1.8 @@ -3,23 +3,31 @@
//--- org.lcsim ---// import hep.physics.vec.BasicHep3Vector; import hep.physics.vec.Hep3Vector;
+
import org.lcsim.event.Track;
+import org.lcsim.fit.helicaltrack.HelicalTrackFit;
public class SvtTrackExtrapolator { boolean isTrackSet = false;
- TrackUtils trackUtils;
+ TrackUtils trackUtils = new TrackUtils();
public static final double ECAL_FACE = 1524; // mm
- public static final double DIPOLE_EDGE = 914; // mm
+ public static final double DIPOLE_EDGE = 457.2 + 457.2; // 452.2 + 462.2; //914; // mm + public static final double DIPOLE_EDGELOW = 0.; //452.2 - 462.2; // mm
public static final double HARP_POSITION = -674.062; // mm /** * */ public SvtTrackExtrapolator(){
- isTrackSet = false; - trackUtils = new TrackUtils();
+ } + + /** + * + */ + public SvtTrackExtrapolator(double[] pars){ + setTrack(pars);
} /**
@@ -27,7 +35,7 @@
*/ public void setTrack(Track track){ trackUtils.setTrack(track);
- isTrackSet = true;
+ isTrackSet = true;
} /**
@@ -35,9 +43,10 @@
*/ public void setTrack(double[] pars){ trackUtils.setTrack(pars);
- isTrackSet = true;
+ isTrackSet = true;
}
+
/** * */
@@ -62,10 +71,14 @@
if(z >= DIPOLE_EDGE){ trackPosition = trackUtils.extrapolateHelixToXPlane(DIPOLE_EDGE); dz = z - DIPOLE_EDGE;
- } else if(z <= 0){ - trackPosition = trackUtils.extrapolateHelixToXPlane(0);
+ } else if(z <= DIPOLE_EDGELOW){ + trackPosition = trackUtils.extrapolateHelixToXPlane(DIPOLE_EDGELOW);
dz = z - trackPosition.x();
- } else return trackUtils.extrapolateHelixToXPlane(z);
+ } else { + Hep3Vector detVecTracking = trackUtils.extrapolateHelixToXPlane(z); + //System.out.printf("detVec %s\n", detVecTracking.toString()); + return new BasicHep3Vector(detVecTracking.y(),detVecTracking.z(),detVecTracking.x()); + }
// Get the track azimuthal angle double phi = trackUtils.getPhi(trackPosition);
Use REPLY-ALL to reply to list
To unsubscribe from the LCD-CVS list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=LCD-CVS&A=1