Commit in hps-java/src/main/java/org/lcsim/hps on MAIN | |||
event/BeamlineConstants.java | +4 | -4 | 1.1 -> 1.2 |
monitoring/svt/TrackingReconstructionPlots.java | +2 | -2 | 1.17 -> 1.18 |
recon/tracking/TrackUtils.java | +9 | -9 | 1.31 -> 1.32 |
recon/vertexing/TwoTrackVertexer.java | +8 | -8 | 1.8 -> 1.9 |
users/mgraham/ElwinsTrackingRecon.java | +17 | -17 | 1.2 -> 1.3 |
/ExamplePlotter.java | +1 | -1 | 1.3 -> 1.4 |
/TrackExtrapolationAnalysis.java | +7 | -7 | 1.7 -> 1.8 |
/TwoTrackAnalysis.java | +18 | -18 | 1.3 -> 1.4 |
users/phansson/TrigRateDriver.java | +1 | -1 | 1.7 -> 1.8 |
/TwoTrackAnlysis.java | +4 | -4 | 1.24 -> 1.25 |
+71 | -71 |
Renaming constants.
diff -u -r1.1 -r1.2 --- BeamlineConstants.java 11 Oct 2013 23:14:28 -0000 1.1 +++ BeamlineConstants.java 15 Oct 2013 00:57:24 -0000 1.2 @@ -4,9 +4,9 @@
private BeamlineConstants() {}
- public static final double ECAL_FACE = 1524; // 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 static final double ECAL_FACE_TESTRUN = 1524; // mm + public static final double DIPOLE_EDGE_TESTRUN = 457.2 + 457.2; // 452.2 + 462.2; //914; // mm + public static final double DIPOLE_EDGELOW_TESTRUN = 0.; //452.2 - 462.2; // mm + public static final double HARP_POSITION_TESTRUN = -674.062; // mm
}
diff -u -r1.17 -r1.18 --- TrackingReconstructionPlots.java 14 Oct 2013 22:58:03 -0000 1.17 +++ TrackingReconstructionPlots.java 15 Oct 2013 00:57:24 -0000 1.18 @@ -730,8 +730,8 @@
Hep3Vector posAtEcal = TrackUtils.getTrackPositionAtEcal(trk);
- aida.histogram1D("X (mm) @ Z=-60cm").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION)[0]); //this is y in the tracker frame - aida.histogram1D("Y (mm) @ Z=-60cm").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION)[1]); //this is z in the tracker frame
+ aida.histogram1D("X (mm) @ Z=-60cm").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[0]); //this is y in the tracker frame + aida.histogram1D("Y (mm) @ Z=-60cm").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[1]); //this is z in the tracker frame
//double sECAL = HelixUtils.PathToXPlane(ht, zEcal, 3000, 1).get(0); aida.histogram1D("X (mm) @ Z=-150cm").fill(slt.getYZAtX(zAtColl)[0]); aida.histogram1D("Y (mm) @ Z=-150cm").fill(slt.getYZAtX(zAtColl)[1]);
diff -u -r1.31 -r1.32 --- TrackUtils.java 15 Oct 2013 00:33:53 -0000 1.31 +++ TrackUtils.java 15 Oct 2013 00:57:24 -0000 1.32 @@ -40,7 +40,7 @@
* Re-use as much of HelixUtils as possible. * * @author Omar Moreno <[log in to unmask]>
- * @version $Id: TrackUtils.java,v 1.31 2013/10/15 00:33:53 phansson Exp $
+ * @version $Id: TrackUtils.java,v 1.32 2013/10/15 00:57:24 phansson Exp $
* TODO: Switch to tracking/LCsim coordinates for the extrapolation output! */
@@ -175,7 +175,7 @@
* @return position at HARP */ public static Hep3Vector getTrackPositionAtHarp(Track track){
- return extrapolateTrack(track, BeamlineConstants.HARP_POSITION);
+ return extrapolateTrack(track, BeamlineConstants.HARP_POSITION_TESTRUN);
} /**
@@ -184,7 +184,7 @@
* @return position at ECAL */ public static Hep3Vector getTrackPositionAtEcal(Track track){
- return extrapolateTrack(track, BeamlineConstants.ECAL_FACE);
+ return extrapolateTrack(track, BeamlineConstants.ECAL_FACE_TESTRUN);
} /**
@@ -197,11 +197,11 @@
Hep3Vector trackPosition = null; double dz = 0;
- if(z >= BeamlineConstants.DIPOLE_EDGE){ - trackPosition = extrapolateHelixToXPlane(track, BeamlineConstants.DIPOLE_EDGE); - dz = z - BeamlineConstants.DIPOLE_EDGE; - } else if(z <= BeamlineConstants.DIPOLE_EDGELOW){ - trackPosition = extrapolateHelixToXPlane(track, BeamlineConstants.DIPOLE_EDGELOW);
+ if(z >= BeamlineConstants.DIPOLE_EDGE_TESTRUN){ + trackPosition = extrapolateHelixToXPlane(track, BeamlineConstants.DIPOLE_EDGE_TESTRUN); + dz = z - BeamlineConstants.DIPOLE_EDGE_TESTRUN; + } else if(z <= BeamlineConstants.DIPOLE_EDGELOW_TESTRUN){ + trackPosition = extrapolateHelixToXPlane(track, BeamlineConstants.DIPOLE_EDGELOW_TESTRUN);
dz = z - trackPosition.x(); } else { Hep3Vector detVecTracking = extrapolateHelixToXPlane(track,z);
@@ -661,7 +661,7 @@
Hep3Vector org = HPSTransformations.transformVectorToTracking(mcp.getOrigin()); Hep3Vector p = HPSTransformations.transformVectorToTracking(mcp.getMomentum()); // Move to x=0 if needed
- double targetX = BeamlineConstants.DIPOLE_EDGELOW;
+ double targetX = BeamlineConstants.DIPOLE_EDGELOW_TESTRUN;
if(org.x() < targetX) { double dydx = p.y()/p.x(); double dzdx = p.z()/p.x();
diff -u -r1.8 -r1.9 --- TwoTrackVertexer.java 15 Oct 2013 00:33:54 -0000 1.8 +++ TwoTrackVertexer.java 15 Oct 2013 00:57:24 -0000 1.9 @@ -55,9 +55,9 @@
public Hep3Vector getVertex() { assert isValid(); Hep3Vector A1 = this.getPosition(trk1, 0);
- Hep3Vector A2 = this.getPosition(trk1, BeamlineConstants.HARP_POSITION);
+ Hep3Vector A2 = this.getPosition(trk1, BeamlineConstants.HARP_POSITION_TESTRUN);
Hep3Vector B1 = this.getPosition(trk2, 0);
- Hep3Vector B2 = this.getPosition(trk2, BeamlineConstants.HARP_POSITION);
+ Hep3Vector B2 = this.getPosition(trk2, BeamlineConstants.HARP_POSITION_TESTRUN);
return getVertexPosition(VecOp.mult(HPSTransformations.getMatrix(), A1), VecOp.mult(HPSTransformations.getMatrix(), A2), VecOp.mult(HPSTransformations.getMatrix(), B1), VecOp.mult(HPSTransformations.getMatrix(), B2)); }
@@ -71,8 +71,8 @@
HPSTrack hpstrk2 = new HPSTrack(htf2); boolean debug = false;
- Hep3Vector posAtConv1 = hpstrk1.getPositionAtZMap(100.0, BeamlineConstants.HARP_POSITION, 5.0)[0]; - Hep3Vector posAtConv2 = hpstrk2.getPositionAtZMap(100.0, BeamlineConstants.HARP_POSITION, 5.0)[0];
+ Hep3Vector posAtConv1 = hpstrk1.getPositionAtZMap(100.0, BeamlineConstants.HARP_POSITION_TESTRUN, 5.0)[0]; + Hep3Vector posAtConv2 = hpstrk2.getPositionAtZMap(100.0, BeamlineConstants.HARP_POSITION_TESTRUN, 5.0)[0];
StraightLineTrack slt1_conv = converter.Convert((Helix)hpstrk1.getTrajectory()); StraightLineTrack slt2_conv = converter.Convert((Helix)hpstrk2.getTrajectory());
@@ -80,11 +80,11 @@
Hep3Vector A1 = new BasicHep3Vector(slt1_conv.x0(),slt1_conv.y0(),slt1_conv.z0()); Hep3Vector B1 = new BasicHep3Vector(slt2_conv.x0(),slt2_conv.y0(),slt2_conv.z0());
- double YZAtConv1[] = slt1_conv.getYZAtX(BeamlineConstants.HARP_POSITION); - double YZAtConv2[] = slt2_conv.getYZAtX(BeamlineConstants.HARP_POSITION);
+ double YZAtConv1[] = slt1_conv.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN); + double YZAtConv2[] = slt2_conv.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN);
- Hep3Vector A2 = new BasicHep3Vector(BeamlineConstants.HARP_POSITION,YZAtConv1[0],YZAtConv1[1]); - Hep3Vector B2 = new BasicHep3Vector(BeamlineConstants.HARP_POSITION,YZAtConv2[0],YZAtConv2[1]);
+ Hep3Vector A2 = new BasicHep3Vector(BeamlineConstants.HARP_POSITION_TESTRUN,YZAtConv1[0],YZAtConv1[1]); + Hep3Vector B2 = new BasicHep3Vector(BeamlineConstants.HARP_POSITION_TESTRUN,YZAtConv2[0],YZAtConv2[1]);
diff -u -r1.2 -r1.3 --- ElwinsTrackingRecon.java 14 Oct 2013 22:03:09 -0000 1.2 +++ ElwinsTrackingRecon.java 15 Oct 2013 00:57:24 -0000 1.3 @@ -633,9 +633,9 @@
StraightLineTrack slt2 = converter2.Convert(ht2); HPSTrack hpstrack1 = new HPSTrack(ht1);
- Hep3Vector[] trkatconver1 = hpstrack1.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1);
+ Hep3Vector[] trkatconver1 = hpstrack1.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1);
HPSTrack hpstrack2 = new HPSTrack(ht2);
- Hep3Vector[] trkatconver2 = hpstrack2.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1);
+ Hep3Vector[] trkatconver2 = hpstrack2.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1);
@@ -724,8 +724,8 @@
- double X1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION)[0]; - double Y1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION)[1];
+ double X1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[0]; + double Y1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[1];
// boolean Y1top = false; // boolean X1plus = false;
@@ -753,8 +753,8 @@
// if (11 < X1 && X1 < 29) { // 24 < X1 && X1 < 36 +-6 // X1plus = true; // }
- double X2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION)[0]; - double Y2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION)[1];
+ double X2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[0]; + double Y2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[1];
// boolean Y2top = false; //for data // boolean X2plus = false;
@@ -894,7 +894,7 @@
// System.out.println("y'1 = " + my1); // System.out.println("y'2 = " + my2); double zi = (b2 - b1) / (m1 - m2);
- double zr = Math.abs(zi - BeamlineConstants.HARP_POSITION);
+ double zr = Math.abs(zi - BeamlineConstants.HARP_POSITION_TESTRUN);
double zs = 2 * zr / 100; // System.out.println("Closest Possible Z to Tracker"); // System.out.println(zi);
@@ -902,7 +902,7 @@
List<double[]> Trk1 = new ArrayList<double[]>(); for (int i = 0; i < 100; i++) {
- double z = BeamlineConstants.HARP_POSITION - zr + (zs * i);
+ double z = BeamlineConstants.HARP_POSITION_TESTRUN - zr + (zs * i);
double[] posvec = new double[3]; Hep3Vector[] trk1atz = hpstrack1.getPositionAtZMap(100, z, 1); posvec[0] = trk1atz[0].x();
@@ -980,7 +980,7 @@
List<double[]> Trk2 = new ArrayList<double[]>(); for (int i = 0; i < 100; i++) {
- double z = BeamlineConstants.HARP_POSITION - zr + (zs * i);
+ double z = BeamlineConstants.HARP_POSITION_TESTRUN - zr + (zs * i);
double[] posvec2 = new double[3]; Hep3Vector[] trk2atz = hpstrack2.getPositionAtZMap(100, z, 1); posvec2[0] = trk2atz[0].x();
@@ -1123,8 +1123,8 @@
// double distancex = Math.sqrt(Math.pow(postrk2[0] - postrk1[0], 2)); // double distancey = Math.sqrt(Math.pow(postrk2[1] - postrk1[1], 2)); aida.histogram1D("Distance btwn Trks @ Solution").fill(distance);
- double tt1 = (BeamlineConstants.HARP_POSITION - zbar) / dd[2]; //target - double tt2 = (BeamlineConstants.HARP_POSITION - zbar2) / d22[2]; //target
+ double tt1 = (BeamlineConstants.HARP_POSITION_TESTRUN - zbar) / dd[2]; //target + double tt2 = (BeamlineConstants.HARP_POSITION_TESTRUN - zbar2) / d22[2]; //target
double postrk1att[]; postrk1att = new double[3]; //target postrk1att[0] = xbar + (tt1) * dd[0];
@@ -1389,11 +1389,11 @@
HPSTrack hpstrack1 = new HPSTrack(ht1);
- Hep3Vector[] trkatconver1 = hpstrack1.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1);
+ Hep3Vector[] trkatconver1 = hpstrack1.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1);
HPSTrack hpstrack2 = new HPSTrack(ht2);
- Hep3Vector[] trkatconver2 = hpstrack2.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1);
+ Hep3Vector[] trkatconver2 = hpstrack2.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1);
HPSTrack hpstrack3 = new HPSTrack(ht3);
- Hep3Vector[] trkatconver3 = hpstrack3.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1);
+ Hep3Vector[] trkatconver3 = hpstrack3.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1);
double Etrk1sq = (Math.pow(trkatconver1[1].x(), 2) + Math.pow(trkatconver1[1].y(), 2) + Math.pow(trkatconver1[1].z(), 2)); double Etrk2sq = (Math.pow(trkatconver2[1].x(), 2) + Math.pow(trkatconver2[1].y(), 2) + Math.pow(trkatconver2[1].z(), 2));
@@ -1428,7 +1428,7 @@
StraightLineTrack slt = converter.Convert(ht); HPSTrack hpstrack = new HPSTrack(ht);
- Hep3Vector[] trkatconver = hpstrack.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1);
+ Hep3Vector[] trkatconver = hpstrack.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1);
aida.histogram1D("X (mm) @ Converter").fill(trkatconver[0].x()); // y tracker frame? aida.histogram1D("Y (mm) @ Converter").fill(trkatconver[0].y()); // z tracker frame?
@@ -1436,8 +1436,8 @@
// ExtendTrack extend = new ExtendTrack(); // extend.setTrack(stEle);
- aida.histogram1D("X (mm) @ Z=-60cm").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION)[0]); //this is y in the tracker frame - aida.histogram1D("Y (mm) @ Z=-60cm").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION)[1]); //this is z in the tracker frame
+ aida.histogram1D("X (mm) @ Z=-60cm").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[0]); //this is y in the tracker frame + aida.histogram1D("Y (mm) @ Z=-60cm").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[1]); //this is z in the tracker frame
aida.histogram1D("X (mm) @ Z=-150cm").fill(slt.getYZAtX(zAtColl)[0]); aida.histogram1D("Y (mm) @ Z=-150cm").fill(slt.getYZAtX(zAtColl)[1]);
diff -u -r1.3 -r1.4 --- ExamplePlotter.java 14 Oct 2013 22:03:09 -0000 1.3 +++ ExamplePlotter.java 15 Oct 2013 00:57:24 -0000 1.4 @@ -84,7 +84,7 @@
HelixConverter converter = new HelixConverter(0); StraightLineTrack slt = converter.Convert(ht); HPSTrack hpstrack = new HPSTrack(ht);
- Hep3Vector[] trkatconver = hpstrack.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1);
+ Hep3Vector[] trkatconver = hpstrack.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1);
aida.histogram1D("X (mm) @ Converter").fill(trkatconver[0].x()); // y tracker frame? aida.histogram1D("Y (mm) @ Converter").fill(trkatconver[0].y()); // z tracker frame?
diff -u -r1.7 -r1.8 --- TrackExtrapolationAnalysis.java 14 Oct 2013 22:58:03 -0000 1.7 +++ TrackExtrapolationAnalysis.java 15 Oct 2013 00:57:24 -0000 1.8 @@ -90,7 +90,7 @@
StraightLineTrack slt = converter.Convert(ht); Hep3Vector posAtEcal = TrackUtils.getTrackPositionAtEcal(trk);
- Hep3Vector extendAtConverter = TrackUtils.extrapolateTrack(trk,BeamlineConstants.HARP_POSITION);
+ Hep3Vector extendAtConverter = TrackUtils.extrapolateTrack(trk,BeamlineConstants.HARP_POSITION_TESTRUN);
int isTop = -1;
@@ -104,7 +104,7 @@
HPSTrack hpstrk=null; hpstrk = new HPSTrack(ht); // Hep3Vector posAtConv = hpstrk.getPositionAtZ(zAtConverter, -101, -100, 0.1);
- Hep3Vector posAtConv = hpstrk.getPositionAtZMap(100,BeamlineConstants.HARP_POSITION , 5.0)[0];
+ Hep3Vector posAtConv = hpstrk.getPositionAtZMap(100,BeamlineConstants.HARP_POSITION_TESTRUN , 5.0)[0];
double useThisx=posAtConv.x(); double useThisy=posAtConv.y();
@@ -125,15 +125,15 @@
aida.histogram1D("Negative Y (mm) @ Converter").fill(useThisy); } // Hep3Vector posAtConvShort = hpstrk.getPositionAtZ(zAtConverter, -0.1, 0, 0.01);
- Hep3Vector posAtConvShort = hpstrk.getPositionAtZMap(0,BeamlineConstants.HARP_POSITION, 5.0)[0];
+ Hep3Vector posAtConvShort = hpstrk.getPositionAtZMap(0,BeamlineConstants.HARP_POSITION_TESTRUN, 5.0)[0];
aida.histogram2D("Extrapolated X: short vs long fringe").fill(posAtConvShort.x(), posAtConv.x()); aida.histogram2D("Extrapolated Y: short vs long fringe").fill(posAtConvShort.y(), posAtConv.y());
- aida.histogram2D("Extrapolated X: HPS vs SLT").fill(posAtConv.x(), slt.getYZAtX(BeamlineConstants.HARP_POSITION)[0]); - aida.histogram2D("Extrapolated Y: HPS vs SLT").fill(posAtConv.y(), slt.getYZAtX(BeamlineConstants.HARP_POSITION)[1]);
+ aida.histogram2D("Extrapolated X: HPS vs SLT").fill(posAtConv.x(), slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[0]); + aida.histogram2D("Extrapolated Y: HPS vs SLT").fill(posAtConv.y(), slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[1]);
- aida.histogram2D("Extrapolated X: Extend vs SLT").fill(extendAtConverter.y(), slt.getYZAtX(BeamlineConstants.HARP_POSITION)[0]); - aida.histogram2D("Extrapolated Y: Extend vs SLT").fill(extendAtConverter.z(), slt.getYZAtX(BeamlineConstants.HARP_POSITION)[1]);
+ aida.histogram2D("Extrapolated X: Extend vs SLT").fill(extendAtConverter.y(), slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[0]); + aida.histogram2D("Extrapolated Y: Extend vs SLT").fill(extendAtConverter.z(), slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[1]);
List<HPSEcalCluster> clusters = event.get(HPSEcalCluster.class, ecalCollectionName); HPSEcalCluster clust = findClosestCluster(posAtEcal, clusters);
diff -u -r1.3 -r1.4 --- TwoTrackAnalysis.java 14 Oct 2013 22:03:09 -0000 1.3 +++ TwoTrackAnalysis.java 15 Oct 2013 00:57:24 -0000 1.4 @@ -275,12 +275,12 @@
HelixConverter converter = new HelixConverter(0); StraightLineTrack slt = converter.Convert(ht); HPSTrack hpstrack = new HPSTrack(ht);
- Hep3Vector[] trkatconver = hpstrack.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1);
+ Hep3Vector[] trkatconver = hpstrack.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1);
aida.histogram1D("X (mm) @ Converter using Map").fill(trkatconver[0].x()); // y tracker frame? aida.histogram1D("Y (mm) @ Converter using Map").fill(trkatconver[0].y()); // z tracker frame? if (slt != null) {
- aida.histogram1D("X (mm) @ Converter using SLT").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION)[0]); // y tracker frame? - aida.histogram1D("Y (mm) @ Converter using SLT").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION)[1]); // z tracker frame?
+ aida.histogram1D("X (mm) @ Converter using SLT").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[0]); // y tracker frame? + aida.histogram1D("Y (mm) @ Converter using SLT").fill(slt.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[1]); // z tracker frame?
} }
@@ -326,13 +326,13 @@
HPSTrack hpstrack2 = new HPSTrack(ht2); Hep3Vector[] trkatconver2 = {new BasicHep3Vector(), new BasicHep3Vector(0, 0, 0)};; if (isMC) {
- double[] t1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION); - double[] t2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION); - trkatconver1[0] = new BasicHep3Vector(t1[0], t1[1], BeamlineConstants.HARP_POSITION); - trkatconver2[0] = new BasicHep3Vector(t2[0], t2[1], BeamlineConstants.HARP_POSITION);
+ double[] t1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN); + double[] t2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN); + trkatconver1[0] = new BasicHep3Vector(t1[0], t1[1], BeamlineConstants.HARP_POSITION_TESTRUN); + trkatconver2[0] = new BasicHep3Vector(t2[0], t2[1], BeamlineConstants.HARP_POSITION_TESTRUN);
} else {
- trkatconver1 = hpstrack1.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1); - trkatconver2 = hpstrack2.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION, 1);
+ trkatconver1 = hpstrack1.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1); + trkatconver2 = hpstrack2.getPositionAtZMap(100, BeamlineConstants.HARP_POSITION_TESTRUN, 1);
} List<TrackerHit> hitsOnTrack1 = trk1.getTrackerHits(); int layer1;
@@ -420,8 +420,8 @@
double X1 = -99, Y1 = -99; if (slt1 != null) {
- X1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION)[0]; - Y1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION)[1];
+ X1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[0]; + Y1 = slt1.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[1];
} boolean X1cent = false;
@@ -436,8 +436,8 @@
double X2 = 99, Y2 = 99; if (slt2 != null) {
- X2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION)[0]; - Y2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION)[1];
+ X2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[0]; + Y2 = slt2.getYZAtX(BeamlineConstants.HARP_POSITION_TESTRUN)[1];
} boolean X2cent = false;
@@ -494,7 +494,7 @@
} double zi = (b2 - b1) / (m1 - m2);
- double zr = Math.abs(zi - BeamlineConstants.HARP_POSITION);
+ double zr = Math.abs(zi - BeamlineConstants.HARP_POSITION_TESTRUN);
double zs = 2 * zr / 100; // System.out.println("Closest Possible Z to Tracker"); // System.out.println(zi);
@@ -502,7 +502,7 @@
List<double[]> Trk1 = new ArrayList<double[]>(); for (int i = 0; i < 100; i++) {
- double z = BeamlineConstants.HARP_POSITION - zr + (zs * i);
+ double z = BeamlineConstants.HARP_POSITION_TESTRUN - zr + (zs * i);
double[] posvec = new double[3]; if (isMC) { posvec[0] = slt1.getYZAtX(z)[0];
@@ -585,7 +585,7 @@
List<double[]> Trk2 = new ArrayList<double[]>(); for (int i = 0; i < 100; i++) {
- double z = BeamlineConstants.HARP_POSITION - zr + (zs * i);
+ double z = BeamlineConstants.HARP_POSITION_TESTRUN - zr + (zs * i);
double[] posvec2 = new double[3]; if (isMC) {
@@ -773,8 +773,8 @@
aida.histogram1D("ZVertex with y cut").fill(C.get(2, 0)); aida.histogram1D("Distance btwn Trks with y cut").fill(distance); }
- double tt1 = (BeamlineConstants.HARP_POSITION - zbar) / dd[2]; //target - double tt2 = (BeamlineConstants.HARP_POSITION - zbar2) / d22[2]; //target
+ double tt1 = (BeamlineConstants.HARP_POSITION_TESTRUN - zbar) / dd[2]; //target + double tt2 = (BeamlineConstants.HARP_POSITION_TESTRUN - zbar2) / d22[2]; //target
double postrk1att[]; postrk1att = new double[3]; //target postrk1att[0] = xbar + (tt1) * dd[0];
diff -u -r1.7 -r1.8 --- TrigRateDriver.java 14 Oct 2013 22:03:10 -0000 1.7 +++ TrigRateDriver.java 15 Oct 2013 00:57:24 -0000 1.8 @@ -321,7 +321,7 @@
int iside = clusterPosIdx[1]>0 ? 0 : 1; int hitY = clusterPosIdx[1]>0 ? clusterPosIdx[1] : (-1*clusterPosIdx[1]);
- double hitTheta = Math.atan(clusterPosY/(clusterPosZ-BeamlineConstants.HARP_POSITION));
+ double hitTheta = Math.atan(clusterPosY/(clusterPosZ-BeamlineConstants.HARP_POSITION_TESTRUN));
//x-check if(hitTheta<0) { if(!"bottom".equals(side)) {
diff -u -r1.24 -r1.25 --- TwoTrackAnlysis.java 14 Oct 2013 22:58:04 -0000 1.24 +++ TwoTrackAnlysis.java 15 Oct 2013 00:57:24 -0000 1.25 @@ -60,7 +60,7 @@
private String triggerDecisionCollectionName = "TriggerBank"; private String MCParticleCollectionName = "MCParticle"; private String _stripClusterCollectionName = "StripClusterer_SiTrackerHitStrip1D";
- private double targetPosition = BeamlineConstants.HARP_POSITION;
+ private double targetPosition = BeamlineConstants.HARP_POSITION_TESTRUN;
private boolean _debug; private HitIdentifier _ID = new HitIdentifier(); private TwoTrackVertexer vertexer = new TwoTrackVertexer();
@@ -547,11 +547,11 @@
} //Track at converter
- Hep3Vector posAtConverter = TrackUtils.extrapolateTrack(trk1,BeamlineConstants.HARP_POSITION);
+ Hep3Vector posAtConverter = TrackUtils.extrapolateTrack(trk1,BeamlineConstants.HARP_POSITION_TESTRUN);
if(posAtConverter!=null) printWriter.format("%5.5f %5.5f ", posAtConverter.x(),posAtConverter.y()); //note rotation from JLab->tracking else printWriter.format("%5.5f %5.5f ", -9999999.9,-9999999.9); HPSTrack hpstrk1 = new HPSTrack(helix1);
- Hep3Vector posAtConverterFringe1 = hpstrk1.getPositionAtZMap(100., BeamlineConstants.HARP_POSITION, 5.0)[0];
+ Hep3Vector posAtConverterFringe1 = hpstrk1.getPositionAtZMap(100., BeamlineConstants.HARP_POSITION_TESTRUN, 5.0)[0];
if (posAtConverterFringe1!=null) printWriter.format("%5.5f %5.5f %5.5f ", posAtConverterFringe1.z(),posAtConverterFringe1.x(),posAtConverterFringe1.y()); //note rotation from JLab->tracking else printWriter.format("%5.5f %5.5f %5.5f ", -9999999.9,-9999999.9,-9999999.9);
@@ -562,7 +562,7 @@
Hep3Vector posAtNomTargetFringe1 = hpstrk1.getPositionAtZMap(100., 0.0, 5.0)[0]; if (posAtNomTargetFringe1!=null) printWriter.format("%5.5f %5.5f %5.5f ", posAtNomTargetFringe1.z(),posAtNomTargetFringe1.x(),posAtNomTargetFringe1.y()); //note rotation from JLab->tracking else printWriter.format("%5.5f %5.5f %5.5f ", -9999999.9,-9999999.9,-9999999.9);
- Hep3Vector posAtECal = TrackUtils.extrapolateTrack(trk1,BeamlineConstants.ECAL_FACE);
+ Hep3Vector posAtECal = TrackUtils.extrapolateTrack(trk1,BeamlineConstants.ECAL_FACE_TESTRUN);
if(posAtECal!=null && !Double.isNaN(posAtECal.x()) && !Double.isNaN(posAtECal.y())) { printWriter.format("%5.5f %5.5f ",posAtECal.x(),posAtECal.y()); //note rotation from JLab->tracking }
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