Conversion of standardized ReadMe file for
file /./ftp/cats/J/A_A/566/A50 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-Oct-08
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. J/A+A/566/A50 Classification of stellar spectra 644-681nm (Damiani+, 2014)
*================================================================================
*Gaia-ESO Survey: Empirical classification of VLT/Giraffe stellar spectra in the
*wavelength range 6440-6810{AA} in the gamma Vel cluster, and calibration of
*spectral indices.
* Damiani F., Prisinzano L., Micela, G., Randich S., Gilmore G., Drew J.E.,
* Jeffries R.D., Fremat Y., Alfaro E.J., Bensby T., Bragaglia A.,
* Flaccomio E., Lanzafame A.C., Pancino E., Recio-Blanco A., Sacco G.G.,
* Smiljanic R., Jackson R.J., de Laverny P., Morbidelli L., Worley C.C.,
* Hourihane A., Costado M.T., Jofre P., Lind K., Maiorca E.
* <Astron. Astrophys. 566, A50 (2014)>
* =2014A&A...566A..50D
C=============================================================================
C Internal variables
integer*4 i__
c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
C Declarations for 'table1.dat' ! Wavelength ranges for definition of spectral
indices
integer*4 nr__
parameter (nr__=13) ! Number of records
character*135 ar__ ! Full-size record
character*8 Index (nr__) ! Index name
character*1 n_Index (nr__) ! [a] Note on Index (1)
character*59 Arange (nr__) ! A wavelength range(s) of the numerator
character*1 n_Arange (nr__) ! [b] Note on Arange (1)
character*63 Brange (nr__) ! B wavelength range(s) of the denominator
*Note (1): Notes as follows:
* a = The alpha_w_ index must include a correction based on mu, see text
* b = The 6489-6492{AA} range is summed with the main range with relative
* weights 1:7
c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
C Declarations for 'table3.dat' ! Spectral indices for {gamma} Vel dataset
(for 1242 distinct stars)
integer*4 nr__1
parameter (nr__1=1802) ! Number of records
character*356 ar__1 ! Full-size record
integer*4 Nspec (nr__1) ! [1/1802] Sequential spectrum number
character*16 JName (nr__1) ! Star name from coordinates (HHMMSSss+DDMMSSs)
real*8 JD (nr__1) ! (d) Julian Date of observation
real*4 Vmag (nr__1) ! (mag) [12/19] Apparent Johnson V magnitude
real*4 V_Ic (nr__1) ! (mag) [0.2/5.0] Johnson-Cousins V-I color index
real*4 S_N (nr__1) ! Signal/noise ratio
real*8 mu1 (nr__1) ! Index {mu}_1_
real*8 e_mu1 (nr__1) ! ?=- Error on mu1
real*8 mu2 (nr__1) ! Index {mu}_2_
real*8 e_mu2 (nr__1) ! ?=- Error on mu2
real*4 mu3 (nr__1) ! Index {mu}_3_
real*8 e_mu3 (nr__1) ! ?=- Error on mu3
real*4 mu4 (nr__1) ! Index {mu}_4_
real*8 e_mu4 (nr__1) ! ?=- Error on mu4
real*8 mu5 (nr__1) ! Index {mu}_5_
real*8 e_mu5 (nr__1) ! ?=- Error on mu5
real*4 mu6 (nr__1) ! Index {mu}_6_
real*8 e_mu6 (nr__1) ! ?=- Error on mu6
real*8 mu7 (nr__1) ! Index {mu}_7_
real*8 e_mu7 (nr__1) ! ?=- Error on mu7
real*8 alphaw (nr__1) ! Index {alpha}_w_
real*8 e_alphaw (nr__1) ! Error on alphaw
real*8 alphac (nr__1) ! Index {alpha}_c_
real*8 e_alphac (nr__1) ! ?=- Error on alphac
real*8 betat (nr__1) ! Index {beta}_t_
real*8 e_betat (nr__1) ! ?=- Error on betat
real*4 betac (nr__1) ! Index {beta}_c_
real*8 e_betac (nr__1) ! ?=- Error on betac
real*4 zeta1 (nr__1) ! Index {zeta}_1_
real*8 e_zeta1 (nr__1) ! ?=- Error on zeta1
real*4 gamma1 (nr__1) ! Index {gamma}_1_
real*8 e_gamma1 (nr__1) ! ?=- Error on gamma1
real*8 mu (nr__1) ! Index {mu}=0.25({mu}_1_+{mu}_3_+{mu}_5_+{mu}_7_)
real*4 e_mu (nr__1) ! Error on mu
real*4 beta (nr__1) ! Index {beta}=1-{beta}_c_/{beta}_t_
real*8 e_beta (nr__1) ! ?=- Error on beta
real*4 gamma (nr__1) ! Index {gamma}={beta}+{gamma}_1_
real*8 e_gamma (nr__1) ! Error on gamma
real*8 tau (nr__1) ! Index {tau} = min({alpha}_w_,1)
* - {beta}_t_ - {zeta}_1_ + 3*{mu}
real*8 e_tau (nr__1) ! Error on tau
character*5 Notes (nr__1) ! [M SB2] Membership/binarity flags (1)
*Note (1): Membership/binarity flags:
* M = putative (candidate) member of the {gamma} Vel cluster
* SB2 = spectroscopic binary
C=============================================================================
C Loading file 'table1.dat' ! Wavelength ranges for definition of spectral
* indices
C Format for file interpretation
1 format(A8,1X,A1,1X,A59,A1,1X,A63)
C Effective file loading
open(unit=1,status='old',file=
+'table1.dat')
write(6,*) '....Loading file: table1.dat'
do i__=1,13
read(1,'(A135)')ar__
read(ar__,1)
+ Index(i__),n_Index(i__),Arange(i__),n_Arange(i__),Brange(i__)
c ..............Just test output...........
write(6,1)
+ Index(i__),n_Index(i__),Arange(i__),n_Arange(i__),Brange(i__)
c .......End.of.Just test output...........
end do
close(1)
C=============================================================================
C Loading file 'table3.dat' ! Spectral indices for {gamma} Vel dataset
* (for 1242 distinct stars)
C Format for file interpretation
2 format(
+ I4,1X,A16,1X,F11.3,1X,F5.2,1X,F4.2,1X,F5.1,1X,F9.5,1X,F9.6,1X,
+ F7.5,1X,F9.6,1X,F6.4,1X,F9.6,1X,F6.4,1X,F9.6,1X,F7.4,1X,F9.6,
+ 1X,F6.4,1X,F9.6,1X,F7.4,1X,F9.6,1X,F7.4,1X,F8.6,1X,F7.4,1X,
+ F9.6,1X,F7.4,1X,F9.6,1X,F6.4,1X,F9.6,1X,F6.4,1X,F9.6,1X,F6.4,
+ 1X,F9.6,1X,F7.4,1X,E8.2,1X,E10.3,1X,F9.6,1X,F6.4,1X,F8.6,1X,
+ F7.3,1X,F8.5,1X,A5)
C Effective file loading
open(unit=1,status='old',file=
+'table3.dat')
write(6,*) '....Loading file: table3.dat'
do i__=1,1802
read(1,'(A356)')ar__1
read(ar__1,2)
+ Nspec(i__),JName(i__),JD(i__),Vmag(i__),V_Ic(i__),S_N(i__),
+ mu1(i__),e_mu1(i__),mu2(i__),e_mu2(i__),mu3(i__),e_mu3(i__),
+ mu4(i__),e_mu4(i__),mu5(i__),e_mu5(i__),mu6(i__),e_mu6(i__),
+ mu7(i__),e_mu7(i__),alphaw(i__),e_alphaw(i__),alphac(i__),
+ e_alphac(i__),betat(i__),e_betat(i__),betac(i__),e_betac(i__),
+ zeta1(i__),e_zeta1(i__),gamma1(i__),e_gamma1(i__),mu(i__),
+ e_mu(i__),beta(i__),e_beta(i__),gamma(i__),e_gamma(i__),
+ tau(i__),e_tau(i__),Notes(i__)
if (idig(ar__1(62:70)).EQ.0) e_mu1(i__) = rNULL__
if (idig(ar__1(80:88)).EQ.0) e_mu2(i__) = rNULL__
if (idig(ar__1(97:105)).EQ.0) e_mu3(i__) = rNULL__
if (idig(ar__1(114:122)).EQ.0) e_mu4(i__) = rNULL__
if (idig(ar__1(132:140)).EQ.0) e_mu5(i__) = rNULL__
if (idig(ar__1(149:157)).EQ.0) e_mu6(i__) = rNULL__
if (idig(ar__1(167:175)).EQ.0) e_mu7(i__) = rNULL__
if (idig(ar__1(202:210)).EQ.0) e_alphac(i__) = rNULL__
if (idig(ar__1(220:228)).EQ.0) e_betat(i__) = rNULL__
if (idig(ar__1(237:245)).EQ.0) e_betac(i__) = rNULL__
if (idig(ar__1(254:262)).EQ.0) e_zeta1(i__) = rNULL__
if (idig(ar__1(271:279)).EQ.0) e_gamma1(i__) = rNULL__
if (idig(ar__1(309:317)).EQ.0) e_beta(i__) = rNULL__
c ..............Just test output...........
write(6,2)
+ Nspec(i__),JName(i__),JD(i__),Vmag(i__),V_Ic(i__),S_N(i__),
+ mu1(i__),e_mu1(i__),mu2(i__),e_mu2(i__),mu3(i__),e_mu3(i__),
+ mu4(i__),e_mu4(i__),mu5(i__),e_mu5(i__),mu6(i__),e_mu6(i__),
+ mu7(i__),e_mu7(i__),alphaw(i__),e_alphaw(i__),alphac(i__),
+ e_alphac(i__),betat(i__),e_betat(i__),betac(i__),e_betac(i__),
+ zeta1(i__),e_zeta1(i__),gamma1(i__),e_gamma1(i__),mu(i__),
+ e_mu(i__),beta(i__),e_beta(i__),gamma(i__),e_gamma(i__),
+ tau(i__),e_tau(i__),Notes(i__)
c .......End.of.Just test output...........
end do
close(1)
C=============================================================================
stop
end
C Locate position of first digit in string; or return 0
integer function idig(c)
character*(*) c
character*1 c1
integer lc,i
lc=len(c)
idig=0
do i=1,lc
if(c(i:i).ne.' ') go to 1
end do
1 if(i.gt.lc) return
c1=c(i:i)
if(c1.eq.'.'.or.c1.eq.'-'.or.c1.eq.'+') i=i+1
if(i.gt.lc) return
c1=c(i:i)
if(c1.ge.'0'.and.c1.le.'9') idig=i
return
end