Conversion of standardized ReadMe file for
file /./ftp/cats/I/305 into FORTRAN code for loading all data files into arrays.
Note that special values are assigned to unknown or unspecified
numbers (also called NULL numbers);
when necessary, the coordinate components making up the right ascension
and declination are converted into floating-point numbers
representing these angles in degrees.
program load_ReadMe
C=============================================================================
C F77-compliant program generated by readme2f_1.81 (2015-09-23), on 2026-Sep-10
C=============================================================================
* This code was generated from the ReadMe file documenting a catalogue
* according to the "Standard for Documentation of Astronomical Catalogues"
* currently in use by the Astronomical Data Centers (CDS, ADC, A&A)
* (see full documentation at URL http://vizier.u-strasbg.fr/doc/catstd.htx)
* Please report problems or questions to
C=============================================================================
implicit none
* Unspecified or NULL values, generally corresponding to blank columns,
* are assigned one of the following special values:
* rNULL__ for unknown or NULL floating-point values
* iNULL__ for unknown or NULL integer values
real*4 rNULL__
integer*4 iNULL__
parameter (rNULL__=--2147483648.) ! NULL real number
parameter (iNULL__=(-2147483647-1)) ! NULL int number
integer idig ! testing NULL number
C=============================================================================
Cat. I/305 The Guide Star Catalog, Version 2.3.2 (GSC2.3) (STScI, 2006)
*================================================================================
*The Guide Star Catalogue, Version 2.3.2
* Lasker B., Lattanzi M.G., McLean B.J., et al.
* <Astron. J. 136, 735 (2008)>
* =2008AJ....136..735L
C=============================================================================
C Internal variables
integer*4 i__
c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
C Declarations for 'out.sam' ! Sample records of GSC2.3.2 (near 0+0)
integer*4 nr__
parameter (nr__=100) ! Number of records
character*205 ar__ ! Full-size record
C J2000 position composed of: RAdeg DEdeg
character*10 GSC2_3 (nr__) ! [NS0-9A-Z] Identification of the object (1)
real*8 RAdeg (nr__) ! (deg) ? Right Ascension (J2000), at "Epoch"
real*8 DEdeg (nr__) ! (deg) ? Declination in (J2000), at "Epoch"
character*10 GSC1 (nr__) ! Identification in GSC Version 1 (Cat. I/254)
character*8 HTM6 (nr__) ! [NS0-3] HTM-6 designation as in GSC2.2 (1)
real*4 e_RAdeg (nr__) ! (arcsec) Mean error on RAdeg (2)
real*4 e_DEdeg (nr__) ! (arcsec) Mean error on DEdeg (2)
real*8 Epoch (nr__) ! (yr) Epoch of the position
real*4 Fmag (nr__) ! (mag) ? Magnitude in F photographic band (red)
real*4 e_Fmag (nr__) ! (mag) ? Mean error on Fmag
integer*4 n_Fmag (nr__) ! ? Coded emulsion / bandpass / filter (2)
real*4 jmag (nr__) ! (mag) ? Magnitude in Bj photographic band (blue)
real*4 e_jmag (nr__) ! (mag) ? Mean error on jmag
integer*4 n_jmag (nr__) ! ? Coded emulsion / bandpass / filter (2)
real*4 Vmag (nr__) ! (mag) ? Magnitude in V photographic band (green)
real*4 e_Vmag (nr__) ! (mag) ? Mean error on Vmag
integer*4 n_Vmag (nr__) ! ? Coded emulsion / bandpass / filter (2)
real*4 Nmag (nr__) ! (mag) ? Magnitude in N photographic band (0.8{mu}m)
real*4 e_Nmag (nr__) ! (mag) ? Mean error on Nmag
integer*4 n_Nmag (nr__) ! ? Coded emulsion / bandpass / filter (2)
real*4 Umag (nr__) ! (mag) ? Magnitude in U band (Johnson)
real*4 e_Umag (nr__) ! (mag) ? Mean error on Umag
integer*4 n_Umag (nr__) ! ? Coded emulsion / bandpass / filter (2)
real*4 Bmag (nr__) ! (mag) ? Magnitude in B band (Johnson blue)
real*4 e_Bmag (nr__) ! (mag) ? Mean error on Bmag
integer*4 n_Bmag (nr__) ! ? Coded emulsion / bandpass / filter (2)
integer*4 Class (nr__) ! [0,5] Object class (3)
integer*8 Status (nr__) ! Source status flag (4)
character*1 M (nr__) ! [M] 'M' for multiple object (5)
real*8 a (nr__) ! (pix) ? Semi-major axis of fitting ellipse
real*4 e (nr__) ! ? Eccentricity of fitting ellipse
real*4 aPA (nr__) ! (deg) ? Position angle (N->E) of fitting ellipse
*Note (1): The GSC2.3 identification differs from GSC2.2.
* Is is made of 10 characters, the first four representing the level-6
* HTM (Hierarchical Triangular Mesh) coded in base 36 (0..9 and A..Z),
* and the last 6 represent a zero-filled sequence number assigned to
* each source upon initial detection.
*
* The Hierarchical Triangular Mesh (HTM) is a recursive spatial indexing
* scheme dividing the unit sphere into spherical triangles, the number
* of triangles at level n being 8x4^n^ (see details about HTM at
* http://www.sdss.jhu.edu/htm/). The level-6 HTM varies from N000 to
* NCN3 and S000 to SCN3, i.e. 16384*2 different regions.
*
* The designation of the corresponding GSC2.2 object, if existing,
* is made by replacing the 4 first digits of the GSC2.3 identifier
* by the 8 HTM6 digits, and removing the leading zeroes of the number
* made by digits 5-10 of the GSC2.3 identifier.
*Note (2): coded emulsion / bandpass / filter:
* ----------------------------------------------------------------------
* bcode Name Emulsion/Filter
* ----------------------------------------------------------------------
* 0 Jpg IIIaJ+GG395 (SERC-J/EJ)
* 1 V IIaD+W12 (Pal Quick-V)
* 2 - HST FGS
* 3 B (Johnson)
* 4 V (Johnson)
* 5 Fpg IIIaF+RG630 (ESO-R)
* 6 V495 IIaD+GG495 (Pal QV/AAO XV)
* 7 O 103aO+no filter (POSS-I Blue)
* 8 E 103aE+red plexi (POSS-I Red)
* 9 Fpg IIIaF+RG630
* 10 - IIaD+GG495+yellow objective (GPO Astrograph)
* 11 - 103aO+blue objective (Black Birch Astrograph)
* 12 - 103aO+blue objective Black Birch Astrograph, GSC cal.)
* 13 - 103aG+GG495+yellow objective (Black Birch Astrograph)
* 14 - 103aG+GG495+yellow objective (Black Birch Astrograph, GSC)
* 16 Vpg IIIaJ+GG49
* 18 Jpg IIIaJ+GG385 (POSS-II Blue)
* 19 U (Johnson)
* 20 R (Johnson)
* 21 I (Johnson)
* 22 U (Cape)
* 23 R (Kron)
* 24 I (Kron)
* 35 Fpg IIIaF+RG610 (POSS-II Red)
* 36 Fpg IIIaF+OG590 (SERC-ER/SR, AAO-R/GR)
* 37 Npg IVN+RG9 (POSS-II IR)
* 38 Npg IVN+RG715 (SERC-IR)
* 39 Jpg IIaO+GG385 (ESO-B)
* 41 BT TYCHO-B
* 42 VT TYCHO-V
* 43 - IRAS 12micron
* 44 - IRAS 25 micron
* 45 - IRAS 60 micron
* 46 - IRAS 100 micron
* 47 J (2MASS)
* 48 H (2MASS)
* 49 K (2MASS)
* 50 u' (SDSS)
* 51 g' (SDSS)
* 52 r' (SDSS)
* 53 i' (SDSS)
* 54 z' (SDSS)
* ----------------------------------------------------------------------
*Note (3): the object class is defined as:
* 0=star 1=Galaxy, 2=Blend
* 3=Non-star 4=unclassified 5=Defect
* In the version 2.3.2, only values 0 and 3 are present.
*Note (4): the status code is a 10-digit field encoding the properties
* of the catalog object. This flag is 99999900 for a Tycho object.
* ----------------------------------------------------------------------
* ........xx Number of plates on which the object appeared.
* .......x.. Centroid type associated with the exported position, as:
* 0 = barycenter 4 = multicircular
* 1 = circular gaussian 5 = multielliptical
* 2 = elliptical gaussian 6 = FPA + circular
* 3 = FPA-applied barycenter 7 = FPA + elliptical
* (FPA = Fractional Pixel Allocation)
* ......x... Quality of exported J magnitude, as:
* 0 = not present 1 = fit 2 = extrapolated
* .....x.... Quality of exported F magnitude, as:
* 0 = not present 1 = fit 2 = extrapolated
* ....x..... Quality of exported V magnitude, as:
* 0 = not present 1 = fit 2 = extrapolated
* ...x...... Classification unanimity
* 0 = mixed vote 2 = unanimous defect
* 1 = unanimous vote
* ..x....... Classification voters
* 0 = several 15um scan 2 = several 25um scan
* 1 = one 15um scan 3 = one 25um scan
* .x........ Processing status
* 0 = complete processing on all plates
* 1 = object too big (>256^2^ pix) on at least one plate
* x......... Deblending
* 0 = single object on all plates
* 1 = child (deblended) object on at least one plate.
* ----------------------------------------------------------------------
*Note (5): this flag concerns only the Tycho stars (Status=99999900)
C=============================================================================
C Loading file 'out.sam' ! Sample records of GSC2.3.2 (near 0+0)
C Format for file interpretation
1 format(
+ A10,1X,F10.6,1X,F10.6,1X,A10,1X,A8,1X,F4.2,1X,F4.2,1X,F8.3,1X,
+ F5.2,1X,F4.2,1X,I2,1X,F5.2,1X,F4.2,1X,I2,1X,F5.2,1X,F4.2,1X,
+ I2,1X,F5.2,1X,F4.2,1X,I2,1X,F4.2,1X,F4.2,1X,I2,1X,F5.2,1X,
+ F4.2,1X,I2,1X,I1,1X,I10,1X,A1,F8.2,1X,F4.2,1X,F5.1)
C Effective file loading
open(unit=1,status='old',file=
+'out.sam')
write(6,*) '....Loading file: out.sam'
do i__=1,100
read(1,'(A205)')ar__
read(ar__,1)
+ GSC2_3(i__),RAdeg(i__),DEdeg(i__),GSC1(i__),HTM6(i__),
+ e_RAdeg(i__),e_DEdeg(i__),Epoch(i__),Fmag(i__),e_Fmag(i__),
+ n_Fmag(i__),jmag(i__),e_jmag(i__),n_jmag(i__),Vmag(i__),
+ e_Vmag(i__),n_Vmag(i__),Nmag(i__),e_Nmag(i__),n_Nmag(i__),
+ Umag(i__),e_Umag(i__),n_Umag(i__),Bmag(i__),e_Bmag(i__),
+ n_Bmag(i__),Class(i__),Status(i__),M(i__),a(i__),e(i__),
+ aPA(i__)
if(ar__(12:21) .EQ. '') RAdeg(i__) = rNULL__
if(ar__(23:32) .EQ. '') DEdeg(i__) = rNULL__
if(ar__(73:77) .EQ. '') Fmag(i__) = rNULL__
if(ar__(79:82) .EQ. '') e_Fmag(i__) = rNULL__
if(ar__(84:85) .EQ. '') n_Fmag(i__) = iNULL__
if(ar__(87:91) .EQ. '') jmag(i__) = rNULL__
if(ar__(93:96) .EQ. '') e_jmag(i__) = rNULL__
if(ar__(98:99) .EQ. '') n_jmag(i__) = iNULL__
if(ar__(101:105) .EQ. '') Vmag(i__) = rNULL__
if(ar__(107:110) .EQ. '') e_Vmag(i__) = rNULL__
if(ar__(112:113) .EQ. '') n_Vmag(i__) = iNULL__
if(ar__(115:119) .EQ. '') Nmag(i__) = rNULL__
if(ar__(121:124) .EQ. '') e_Nmag(i__) = rNULL__
if(ar__(126:127) .EQ. '') n_Nmag(i__) = iNULL__
if(ar__(129:132) .EQ. '') Umag(i__) = rNULL__
if(ar__(134:137) .EQ. '') e_Umag(i__) = rNULL__
if(ar__(139:140) .EQ. '') n_Umag(i__) = iNULL__
if(ar__(142:146) .EQ. '') Bmag(i__) = rNULL__
if(ar__(148:151) .EQ. '') e_Bmag(i__) = rNULL__
if(ar__(153:154) .EQ. '') n_Bmag(i__) = iNULL__
if(ar__(170:177) .EQ. '') a(i__) = rNULL__
if(ar__(179:182) .EQ. '') e(i__) = rNULL__
if(ar__(184:188) .EQ. '') aPA(i__) = rNULL__
c ..............Just test output...........
write(6,1)
+ GSC2_3(i__),RAdeg(i__),DEdeg(i__),GSC1(i__),HTM6(i__),
+ e_RAdeg(i__),e_DEdeg(i__),Epoch(i__),Fmag(i__),e_Fmag(i__),
+ n_Fmag(i__),jmag(i__),e_jmag(i__),n_jmag(i__),Vmag(i__),
+ e_Vmag(i__),n_Vmag(i__),Nmag(i__),e_Nmag(i__),n_Nmag(i__),
+ Umag(i__),e_Umag(i__),n_Umag(i__),Bmag(i__),e_Bmag(i__),
+ n_Bmag(i__),Class(i__),Status(i__),M(i__),a(i__),e(i__),
+ aPA(i__)
c .......End.of.Just test output...........
end do
close(1)
C=============================================================================
stop
end