*-- Author : R. Henderson
SUBROUTINE FPLINT
C
C--- Routine finds all interections between any two planes (defined by
C--- clusters)from different wire orientations within the same
C--- supermodule
C---
C
C---
*KEEP,FPPRAM.
C
C--- MAXSEG is maximum number of segments per supermodule
C--- MAXCON is maximum number of amibiguous segments associatable with
C--- one segment
C--- LIMSTO is maximum number of 2 cluster planes intersections to be
C--- stored per supermodule
C--- MSEGLM is maximum number of clusters that can be found before
C--- connectivity considered
C--- MAXCLU is maximum number of clusters that can be found after
C--- forming non-connected set MUST BE 50 IF RUN WITH OLD RCW
C--- (cluster = 3/4 digits found in a straight line in one
C--- 4-wire orientation)
C
C---
*KEND.
C---
*KEEP,FPLGEO.
C---
C---
*KEND.
C---
*KEEP,FPCLUS.
C---
*KEND.
C---
*KEEP,FPH1WRK.
C-- *KEEP,FPCSEG.
C---
C---
C-- *KEEP,FPDIGI.
C---
C-- *KEEP,FPDGI.
C---
C-- *KEEP,FPSTID.
C---
C-- *interface to real data
C---.
*KEND.
C--
C
C
C
C---
C
C--- define front and back of planar supermodule (f/b,sm).
C
C
C--- define inner and outter radii squared
C
C
C--- Loop over supermodules
C
C
C--- Set counter for supermodule
C
C
C--- Loop over plane combinations in sm
C
C
C--- Loop on all tracks in this plane
C
C
C--- remove all combinations with nothing in
C
C
C--- Combination of planes
C
C
C--- Loop on all tracks in this plane
C
C
C--- remove all combinations with nothing in
C
C
C--- find cos of angle between track planes
C
C
C--- Set up inverse matrix for finding point on line
C
C
C--- set up vector of plane definition constants
C
C
C--- find coefficient of point on line of intersection
C
C
C--- now we have line of intersection as
C line = cpint + lambda * ( tpnorm1 vec tpnorm2 )
C
C--- calculate vector to line ponint
C
C
C--- Calculate direction vector of intersection
C
C
C--- solve for beginning and end of supermodule
C
C
C
C--- remove those segments not in sensitive volume
C
C---
C---
C---
C---
C
C--- Store line segment for later analysis and plot
C
C
C--- protect overwriting and store good primative segments
C
CALL ERRLOG(211,'W:FPLINT: NSMLS(ISM) >= LIMSTO')
C---
C---
C
C--- calculate and store beginning and end points
C
C
C--- record segment contributing track/planes
C--- smls(4,1 = it1*10 + ip1 smls(4,2 = it2*10 + ip2
C
C
C--- End of loops
C
C
C--- find if segments are coincident
C
C--- Primary (3 clusters)
C
CALL FPFSEG(NSMLS)
C
C--- Secondary (2 clusters + >=1 digit)
C
CALL FPFSSG(NSMLS)
C
C--- Tertiary (2 clusters ONLY)
C
CALL FPFTSG(NSMLS)
C---
*