Print

Print


Commit in lcsim/src/org/lcsim/contrib/uiowa/MuonFinder on MAIN
MuonFinder.java+4-21.8 -> 1.9
fix bug to find last extrapolated point in Hcal

lcsim/src/org/lcsim/contrib/uiowa/MuonFinder
MuonFinder.java 1.8 -> 1.9
diff -u -r1.8 -r1.9
--- MuonFinder.java	13 Oct 2008 16:50:49 -0000	1.8
+++ MuonFinder.java	13 Oct 2008 19:19:02 -0000	1.9
@@ -193,6 +193,7 @@
                         if(lastLayerBarrel != lastLayerEndcap) {System.out.println("ERROR : number of layer different");}
                         int endingLayer = lastLayerBarrel;
                         boolean isBarrel = true;
+                        boolean hasLastPoint = true;
                         for(int i=0 ; i < 20 ;i++){ 
                             endingLayer = endingLayer - 1;
                             IDDecoder tid = null;
@@ -224,7 +225,8 @@
                             }
                             if(tpoint == null) {
                                 if(_debug) System.out.println("Null extrapolated track point");
-                                continue;
+                                hasLastPoint = false;
+                                break;
                             } 
                             if(isBarrel){tid = event.getDetector().getDecoder("HcalBarrHits");}
                             else {tid = event.getDetector().getDecoder("HcalEndcapHits");}
@@ -250,7 +252,7 @@
                             }
                             if(count > 0 && count < 3) isolated++;
                         }
-
+                        if(!hasLastPoint) continue;
                     } else {
                         if(_debug) System.out.println("Error: Has both mipcluster and extrapolation but no tangent");
                         continue;
CVSspam 0.2.8