Conversion of standardized ReadMe file for
file /./ftp/cats/J/MNRAS/439/354 into FORTRAN code for reading data files line by line.
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-Jun-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/MNRAS/439/354 Sources around Tycho's Supernova 1572 (Bedin+, 2014)
*================================================================================
*Improved Hubble Space Telescope proper motions for Tycho-G and other stars in
*the remnant of Tycho's Supernova 1572.
* Bedin L.R., Ruiz-Lapuente P., Gonzalez Hernandez J.I., Canal R.,
* Filippenko A.V., Mendez J.
* <Mon. Not. R. Astron. Soc., 439, 354-371 (2014)>
* =2014MNRAS.439..354B
C=============================================================================
C Internal variables
integer*4 i__
c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
C Declarations for 'catalog.dat' ! Our catalogue for the sources in common with
those in P04 (related to Ruiz-Lapuente et al.,
2004Natur.431.1069R) (table 2 of the paper)
integer*4 nr__
parameter (nr__=1148) ! Number of records
character*137 ar__ ! Full-size record
C J2000 position composed of: RAh RAm RAs DE- DEd DEm DEs (Epoch=2011.858)
real*8 RAdeg ! (deg) Right Ascension J2000, Epoch=2011.858
real*8 DEdeg ! (deg) Declination J2000, Epoch=2011.858
C ---------------------------------- ! (position vector(s) in degrees)
integer*4 ID ! [1/1148] Sequential number
real*8 Xpos ! (pix) X position
real*8 Ypos ! (pix) Y position
integer*4 RAh ! (h) Right ascension (J2000, Ep=2011.858)
integer*4 RAm ! (min) Right ascension (J2000, Ep=2011.858)
real*4 RAs ! (s) Right ascension (J2000, Ep=2011.858)
character*1 DE_ ! Declination sign (J2000)
integer*4 DEd ! (deg) Declination (J2000, Ep=2011.858)
integer*4 DEm ! (arcmin) Declination (J2000, Ep=2011.858)
real*4 DEs ! (arcsec) Declination (J2000, Ep=2011.858)
real*8 pmRA ! (mas/yr) ?=99.990 Proper motion along RA (pmRA*cosDE)
real*4 e_pmRA ! (mas/yr) ?=99.990 rms uncertainty on pmRA
real*8 RAo ! (mas) ?=99.990 Correction to be applied to our
* reference-frame RA at epoch 2011.858 (1)
real*4 e_RAo ! (mas) ?=99.990 rms uncertainty on RAo
real*8 pmDE ! (mas/yr) ?=99.990 Proper motion along DE
real*4 e_pmDE ! (mas/yr) ?=99.990 rms uncertainty on pmDE
real*4 DEo ! (mas) ?=99.990 Correction to be applied to our
* reference-frame DE at epoch 2011.858
real*4 e_DEo ! (mas) ?=99.990 rms uncertainty on DEo (1)
integer*4 ef ! [1/4] Number of epochs used
integer*4 Nu ! [0/72] number of neighbouring stars used
* to derive the boresight corrections
character*3 Star ! P04 name (<[RCM2004] Tycho AN> in Simbad)
*Note (1): Note that in fitting the data, we let the positions at the reference
* epoch float freely; consequently, DEo and RAo indicate the corrections to be
* applied to our reference-frame positions at epoch 2011.858.
c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
C Declarations for 'table3.dat' ! Data for the 24 stars with mV<=22mag, located
within 42 arcsec from the Xray centroid of
Tycho's SNR
integer*4 nr__1
parameter (nr__1=24) ! Number of records
character*112 ar__1 ! Full-size record
character*2 Star_1 ! P04 name <[RCM2004] Tycho AN> in Simbad
real*4 Bmag ! (mag) ?=- B magnitude
real*4 e_Bmag ! (mag) ? rms uncertainty on Bmag
real*4 Vmag ! (mag) ?=- V magnitude
real*4 e_Vmag ! (mag) ? rms uncertainty on Vmag
real*4 Rmag ! (mag) ?=- R magnitude
real*4 e_Rmag ! (mag) ? rms uncertainty on Rmag
real*4 pmb ! (mas/yr) Proper motion perpendicular to the
* Galactic plane
real*4 e_pmb ! (mas/yr) rms uncertainty on pmb
character*2 l_Dist ! [~>=< ] Limit flag on Dist
real*4 Dist ! (kpc) Distance
real*4 e_Dist ! (kpc) ? rms uncertainty on Dist
character*1 n_Dist ! [-/] - for interval, / for second value
character*1 l_Dist2 ! [~] Limit flag on Dist2
real*4 Dist2 ! (kpc) ? Upper value of distance when interval or
* second distance value
real*4 RV ! (km/s) ?=- Radial velocity
real*4 e_RV ! (km/s) ? rms uncertainty on RV
character*2 l_VRA ! [~>=< ] Limit flag on VRA
real*4 VRA ! (km/s) Tangential velocity component along RA
real*4 e_VRA ! (km/s) ? rms uncertainty on VRA
character*1 n_VRA ! [-/] - for interval, / for second value
character*1 l_VRA2 ! [~] Limit flag on VRA2
integer*4 VRA2 ! (km/s) ? Upper value of VRA when interval or
* second VRA value
character*2 l_VDE ! [~>=< ] Limit flag on VDE
real*4 VDE ! (km/s) Tangential velocity component along DE
real*4 e_VDE ! (km/s) ? rms uncertainty on VDE
character*1 n_VDE ! [-/] - for interval, / for second value
character*1 l_VDE2 ! [~] Limit flag on VDE2
integer*4 VDE2 ! (km/s) ? Upper value of VDE when interval or
* second VDE value
C=============================================================================
C Loading file 'catalog.dat' ! Our catalogue for the sources in common with
* those in P04 (related to Ruiz-Lapuente et al.,
* 2004Natur.431.1069R) (table 2 of the paper)
C Format for file interpretation
1 format(
+ I4,1X,F9.3,1X,F9.3,1X,I2,1X,I2,1X,F6.3,1X,A1,I2,1X,I2,1X,F5.2,
+ 1X,F8.3,3X,F6.3,2X,F7.3,3X,F6.3,2X,F7.3,3X,F6.3,3X,F6.3,3X,
+ F6.3,1X,I1,1X,I2,7X,A3)
C Effective file loading
open(unit=1,status='old',file=
+'catalog.dat')
write(6,*) '....Loading file: catalog.dat'
do i__=1,1148
read(1,'(A137)')ar__
read(ar__,1)
+ ID,Xpos,Ypos,RAh,RAm,RAs,DE_,DEd,DEm,DEs,pmRA,e_pmRA,RAo,
+ e_RAo,pmDE,e_pmDE,DEo,e_DEo,ef,Nu,Star
RAdeg = rNULL__
DEdeg = rNULL__
c Derive coordinates RAdeg and DEdeg from input data
c (RAdeg and DEdeg are set to rNULL__ when unknown)
if(RAh .GT. -180) RAdeg=RAh*15.
if(RAm .GT. -180) RAdeg=RAdeg+RAm/4.
if(RAs .GT. -180) RAdeg=RAdeg+RAs/240.
if(DEd .GE. 0) DEdeg=DEd
if(DEm .GE. 0) DEdeg=DEdeg+DEm/60.
if(DEs .GE. 0) DEdeg=DEdeg+DEs/3600.
if(DE_.EQ.'-'.AND.DEdeg.GE.0) DEdeg=-DEdeg
c ..............Just test output...........
write(6,1)
+ ID,Xpos,Ypos,RAh,RAm,RAs,DE_,DEd,DEm,DEs,pmRA,e_pmRA,RAo,
+ e_RAo,pmDE,e_pmDE,DEo,e_DEo,ef,Nu,Star
write(6,'(6H Pos: 2F8.4)') RAdeg,DEdeg
c .......End.of.Just test output...........
end do
close(1)
C=============================================================================
C Loading file 'table3.dat' ! Data for the 24 stars with mV<=22mag, located
* within 42 arcsec from the Xray centroid of
* Tycho's SNR
C Format for file interpretation
2 format(
+ A2,1X,F5.2,1X,F4.2,1X,F5.2,1X,F4.2,1X,F5.2,1X,F4.2,1X,F5.2,1X,
+ F4.2,1X,A2,F5.2,1X,F3.1,A1,A1,F4.1,1X,F5.1,1X,F4.1,1X,A2,F6.1,
+ 1X,F3.1,A1,A1,I4,1X,A2,F5.1,1X,F4.2,A1,A1,I3)
C Effective file loading
open(unit=1,status='old',file=
+'table3.dat')
write(6,*) '....Loading file: table3.dat'
do i__=1,24
read(1,'(A112)')ar__1
read(ar__1,2)
+ Star_1,Bmag,e_Bmag,Vmag,e_Vmag,Rmag,e_Rmag,pmb,e_pmb,l_Dist,
+ Dist,e_Dist,n_Dist,l_Dist2,Dist2,RV,e_RV,l_VRA,VRA,e_VRA,
+ n_VRA,l_VRA2,VRA2,l_VDE,VDE,e_VDE,n_VDE,l_VDE2,VDE2
if (idig(ar__1(4:8)).EQ.0) Bmag = rNULL__
if(ar__1(10:13) .EQ. '') e_Bmag = rNULL__
if (idig(ar__1(15:19)).EQ.0) Vmag = rNULL__
if(ar__1(21:24) .EQ. '') e_Vmag = rNULL__
if (idig(ar__1(26:30)).EQ.0) Rmag = rNULL__
if(ar__1(32:35) .EQ. '') e_Rmag = rNULL__
if(ar__1(56:58) .EQ. '') e_Dist = rNULL__
if(ar__1(61:64) .EQ. '') Dist2 = rNULL__
if (idig(ar__1(66:70)).EQ.0) RV = rNULL__
if(ar__1(72:75) .EQ. '') e_RV = rNULL__
if(ar__1(86:88) .EQ. '') e_VRA = rNULL__
if(ar__1(91:94) .EQ. '') VRA2 = iNULL__
if(ar__1(104:107) .EQ. '') e_VDE = rNULL__
if(ar__1(110:112) .EQ. '') VDE2 = iNULL__
c ..............Just test output...........
write(6,2)
+ Star_1,Bmag,e_Bmag,Vmag,e_Vmag,Rmag,e_Rmag,pmb,e_pmb,l_Dist,
+ Dist,e_Dist,n_Dist,l_Dist2,Dist2,RV,e_RV,l_VRA,VRA,e_VRA,
+ n_VRA,l_VRA2,VRA2,l_VDE,VDE,e_VDE,n_VDE,l_VDE2,VDE2
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