1
C @(#)cfaint.for 19.1 (ES0-DMD) 02/25/03 13:25:31
2
C===========================================================================
3
C Copyright (C) 1995 European Southern Observatory (ESO)
5
C This program is free software; you can redistribute it and/or
6
C modify it under the terms of the GNU General Public License as
7
C published by the Free Software Foundation; either version 2 of
8
C the License, or (at your option) any later version.
10
C This program is distributed in the hope that it will be useful,
11
C but WITHOUT ANY WARRANTY; without even the implied warranty of
12
C MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
C GNU General Public License for more details.
15
C You should have received a copy of the GNU General Public
16
C License along with this program; if not, write to the Free
17
C Software Foundation, Inc., 675 Massachusetss Ave, Cambridge,
20
C Corresponding concerning ESO-MIDAS should be addressed as follows:
21
C Internet e-mail: midas@eso.org
22
C Postal address: European Southern Observatory
23
C Data Management Division
24
C Karl-Schwarzschild-Strasse 2
25
C D 85748 Garching bei Muenchen
27
C===========================================================================
29
C+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
32
C subroutine CFAINT version 1.2 870729
33
C A. Kruszewski ESO Garching
37
C classifies unsaturated objects into stars, galaxies and image defects
43
C PMTR real*4 array array holding classifiers
44
C BRGT logical array array indicating saturated objects
45
C M integer*4 number of objects
46
C STPR real*4 array one-dimensional point spread function
48
C TRSH real*4 detection treshold above the sky
53
C ICLS integer*4 array array holding the classification
54
C coded: 0-defect or not classified,
55
C 1-star, 2-galaxy. for each object
56
C the first element gives a seed value,
57
C the second gives a current value.
58
C FAIL logical fail flag
59
C-----------------------------------------------------------------------
60
SUBROUTINE CFAINT(PMTR,BRGT,ICLS,M,STPR,TRSH,FAIL)
63
INCLUDE 'MID_REL_INCL:INVENT.INC/NOLIST'
67
INTEGER ICLS(2,MAXCNT)
75
REAL PCLA(0:13,MAXCNT)
79
C sets seed samples of stars and galaxies
81
CALL STSEED(PMTR,BRGT,ICLS,M,TRSH,FAIL)
87
C corrects radius parameters for distortions due to
88
C finite sizes of objects
90
CALL RADCOR(PMTR,PCLA,M,STPR,TRSH)
92
C transforms parameters in order to make them more independend
93
C and to assure similar ranges of variability
95
CALL TRSFRM(PMTR,PCLA,M)
97
C performs classification
101
DO 10 KZ6901 = 1,100000000
102
IF ( .NOT. (.NOT.DONE.AND.ITER.LE.20)) GO TO 20
103
CALL CLASFY(PCLA,BRGT,ICLS,M,ITER,DONE)
107
C seed classification is coded in ICLS(1,*)
108
C final classification is coded in ICLS(2,*)
109
C 0-defect or unclassified, 1-star, 2-galaxy