Commit in lcsim/src/org/lcsim/fit/helicaltrack on MAIN | |||
StereoHitMaker.java | +18 | -8 | 1.10 -> 1.11 |
relax _eps cut for module coplanarity
diff -u -r1.10 -r1.11 --- StereoHitMaker.java 19 Jan 2011 20:44:05 -0000 1.10 +++ StereoHitMaker.java 19 Mar 2012 22:25:29 -0000 1.11 @@ -22,10 +22,10 @@
* @version 1.0 */ public class StereoHitMaker {
-
+ boolean debug=true;
private double _tolerance; private double _maxsep;
- private double _eps = 1.0e-6;
+ private double _eps = 1.0e-4;
/** * Creates a new instance of StereoHitMaker with default parameters:
@@ -183,17 +183,23 @@
* @return */ private boolean CheckCross(HelicalTrackStrip strip1, HelicalTrackStrip strip2) {
-
+ if(debug) + System.out.println("in CheckCross...");
// Check that the strips have the same BarrelEndcap Flag if (strip1.BarrelEndcapFlag() != strip2.BarrelEndcapFlag()) return false;
-
+ if(debug) + System.out.println("in CheckCross...pass BarrelEndcapFlag");
// Check that the sensors planes are parallel to each other
+ if(debug) + System.out.println("Strip1 : "+strip1.w().toString()+"; Strip2 "+strip2.w().toString());
if (VecOp.cross(strip1.w(), strip2.w()).magnitude() > _eps) return false;
-
+ if(debug) + System.out.println("in CheckCross...planes are parallel");
// Check that the strips aren't colinear double salpha = VecOp.dot(strip1.v(), strip2.u()); if (Math.abs(salpha) < _eps) return false;
-
+ if(debug) + System.out.println("in CheckCross...strips aren't colinear");
// Locate the center of the hit strips and the difference in these positions Hep3Vector p1 = VecOp.add(strip1.origin(), VecOp.mult(strip1.umeas(), strip1.u())); Hep3Vector p2 = VecOp.add(strip2.origin(), VecOp.mult(strip2.umeas(), strip2.u()));
@@ -202,7 +208,8 @@
// Check that the sensor separation meets requirements double separation = Math.abs(VecOp.dot(dp, strip1.w())); if (separation > _maxsep) return false;
-
+ if(debug) + System.out.println("in CheckCross...strips pass maxsep test");
// Check if we can form a cross within tolerances double mytolerance = _tolerance; if (Math.abs(salpha) > 0.99) mytolerance = 0.01; //strips are almost perp...don't allow much tolerance
@@ -210,10 +217,13 @@
double vtol = Math.abs(separation * mytolerance / salpha); if (v1 > strip1.vmax() + vtol) return false; if (v1 < strip1.vmin() - vtol) return false;
+ if(debug) + System.out.println("in CheckCross...strip1 within tolerence");
double v2 = VecOp.dot(dp, strip1.u()) / salpha; if (v2 > strip2.vmax() + vtol) return false; if (v2 < strip2.vmin() - vtol) return false;
-
+ if(debug) + System.out.println("in CheckCross...strip2 within tolerence");
// Passed all tests - OK to make stereo hit from this strip pair return true; }
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