| 314 |
do i=1,5 |
do i=1,5 |
| 315 |
AL_GUESS(i)=AL(i) |
AL_GUESS(i)=AL(i) |
| 316 |
enddo |
enddo |
| 317 |
|
c print*,'## guess: ',al |
| 318 |
|
|
| 319 |
do i=1,5 |
do i=1,5 |
| 320 |
AL(i)=dble(AL_STORE(i,icand)) |
AL(i)=dble(AL_STORE(i,icand)) |
| 568 |
xPAM_B = 0. |
xPAM_B = 0. |
| 569 |
yPAM_B = 0. |
yPAM_B = 0. |
| 570 |
zPAM_B = 0. |
zPAM_B = 0. |
| 571 |
|
c print*,'## xyz_PAM: ',icx,icy,sensor,PFAx,PFAy,angx,angy |
| 572 |
* ----------------- |
* ----------------- |
| 573 |
* CLUSTER X |
* CLUSTER X |
| 574 |
* ----------------- |
* ----------------- |
| 687 |
|
|
| 688 |
endif |
endif |
| 689 |
|
|
| 690 |
|
c print*,'## stripx,stripy ',stripx,stripy |
| 691 |
|
|
| 692 |
c=========================================================== |
c=========================================================== |
| 693 |
C COUPLE |
C COUPLE |
| 694 |
C=========================================================== |
C=========================================================== |
| 890 |
|
|
| 891 |
endif |
endif |
| 892 |
|
|
| 893 |
|
|
| 894 |
|
c print*,'## xPAM,yPAM,zPAM ',xPAM,yPAM,zPAM |
| 895 |
|
c print*,'## xPAM_A,yPAM_A,zPAM_A ',xPAM_A,yPAM_A,zPAM_A |
| 896 |
|
c print*,'## xPAM_B,yPAM_B,zPAM_B ',xPAM_B,yPAM_B,zPAM_B |
| 897 |
|
|
| 898 |
100 continue |
100 continue |
| 899 |
end |
end |
| 900 |
|
|
| 2872 |
endif |
endif |
| 2873 |
11882 continue |
11882 continue |
| 2874 |
enddo !end loop on cluster inside couples |
enddo !end loop on cluster inside couples |
| 2875 |
*----- single clusters ----------------------------------------------- |
*----- single clusters ----------------------------------------------- |
| 2876 |
|
c print*,'## ncls(',ip,') ',ncls(ip) |
| 2877 |
do ic=1,ncls(ip) !loop on single clusters |
do ic=1,ncls(ip) !loop on single clusters |
| 2878 |
icl=cls(ip,ic) |
icl=cls(ip,ic) |
| 2879 |
|
c print*,'## ic ',ic,' ist ',ist |
| 2880 |
c if(cl_used(icl).eq.1.or. !if the cluster is already used |
c if(cl_used(icl).eq.1.or. !if the cluster is already used |
| 2881 |
if(cl_used(icl).ne.0.or. !if the cluster is already used !(3) |
if(cl_used(icl).ne.0.or. !if the cluster is already used !(3) |
| 2882 |
$ LADDER(icl).ne.nldt.or. !or the ladder number does not match |
$ LADDER(icl).ne.nldt.or. !or the ladder number does not match |
| 2896 |
distance = distance_to(XP,YP) |
distance = distance_to(XP,YP) |
| 2897 |
distance = distance / RCHI2_STORE(ibest)!<<< MS |
distance = distance / RCHI2_STORE(ibest)!<<< MS |
| 2898 |
if(DEBUG)print*,'( cl-s ',icl |
if(DEBUG)print*,'( cl-s ',icl |
| 2899 |
$ ,' ) normalized distance ',distance |
$ ,' ) normalized distance ',distance,'<',distmin,' ?' |
| 2900 |
if(distance.lt.distmin)then |
if(distance.lt.distmin)then |
| 2901 |
|
if(DEBUG)print*,'YES' |
| 2902 |
xmm_A = xPAM_A |
xmm_A = xPAM_A |
| 2903 |
ymm_A = yPAM_A |
ymm_A = yPAM_A |
| 2904 |
zmm_A = zPAM_A |
zmm_A = zPAM_A |
| 2920 |
endif |
endif |
| 2921 |
18882 continue |
18882 continue |
| 2922 |
enddo !end loop on single clusters |
enddo !end loop on single clusters |
| 2923 |
|
c print*,'## distmin ', distmin,' clinc ',clinc |
| 2924 |
if(distmin.le.clinc)then |
if(distmin.le.clinc)then |
| 2925 |
|
|
| 2926 |
CLS_STORE(nplanes-ip+1,ibest)=iclm !<<<< |
CLS_STORE(nplanes-ip+1,ibest)=iclm !<<<< |