CDS.headStuff2
FORTRAN Generation
Conversion of standardized ReadMe file for
catalog 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 2024-Apr-26 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/464/641 Double stars CCD photometry and astrometry. III (Lampens+, 2007) *================================================================================ *Multicolour CCD measurements of visual double and multiple stars. III. * Lampens P., Strigachev A., Duval D. * <Astron. Astrophys. 464, 641 (2007)> * =2007A&A...464..641L C============================================================================= C Internal variables integer*4 i__ c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - C Declarations for 'table4.dat' ! Astrometry of the observed stars integer*4 nr__ parameter (nr__=138) ! Number of records character*94 ar__ ! Full-size record character*12 Name (nr__) ! Identifier of the star character*1 n_Name (nr__) ! [*] * denotes two epochs for the same target character*3 m_Name (nr__) ! Double star component real*8 Epoch (nr__) ! (yr) Epoch in Besselian year integer*4 Nfr (nr__) ! Number of frames real*4 rho (nr__) ! (arcsec) ?=- Angular separation real*4 e_rho (nr__) ! (arcsec) ?=- Standard error of angular separation real*4 theta (nr__) ! (deg) ?=- Position angle real*4 e_theta (nr__) ! (deg) ?=- Standard error of position angle character*3 Tel (nr__) ! Telescope (1) character*34 Remark (nr__) ! Remark *Note (1): Telescope as follows: * 2 = 2-m telescope at NAO Rozhen * 0.6 = 60-cm telescope at AO Belogradchik c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - C Declarations for 'table5.dat' ! Differential photometry of the observed stars integer*4 nr__1 parameter (nr__1=124) ! Number of records character*83 ar__1 ! Full-size record character*12 Name_1 (nr__1) ! Identifier of the star character*1 n_Name_1 (nr__1) ! [*] * denotes two epochs for the same target character*3 m_Name_1 (nr__1) ! Double star component real*8 HJD (nr__1) ! (d) Heliocentric Julian Date real*4 DVmag (nr__1) ! (mag) Magnitude V difference of the components real*4 e_DVmag (nr__1) ! (mag) Standard error of magnitude difference real*4 D_B_V (nr__1) ! (mag) ?=- B-V colour difference of the components real*4 e_D_B_V (nr__1) ! (mag) ?=- Standard error of colour difference real*4 D_V_R (nr__1) ! (mag) ?=- V-R colour difference of the components character*1 u_D_V_R (nr__1) ! [)] Uncertainty flag on DV-DR real*4 e_D_V_R (nr__1) ! (mag) ?=- Standard error of colour difference character*1 u_e_D_V_R (nr__1) ! [)] Uncertainty flag on e_DV-DR real*4 D_V_I (nr__1) ! (mag) ?=- V-I colour difference of the components real*4 e_D_V_I (nr__1) ! (mag) ?=- Standard error of colour difference c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - C Declarations for 'table6.dat' ! Relative position compared to the Hipparcos/CCDM data integer*4 nr__2 parameter (nr__2=63) ! Number of records character*90 ar__2 ! Full-size record character*12 Name_2 (nr__2) ! Identifier of the star character*1 n_Name_2 (nr__2) ! [*] * denotes two epochs for the same target character*3 m_Name_2 (nr__2) ! Double star component integer*4 Nfr_1 (nr__2) ! Number of frames real*8 Epoch_1 (nr__2) ! (yr) Epoch in Bessel year (1) real*4 rho_1 (nr__2) ! (arcsec) Angular separation real*4 theta_1 (nr__2) ! (deg) Position angle real*4 Drho (nr__2) ! (arcsec) Comparison with Hipparcos/CCDM * angular separation real*8 Dtheta (nr__2) ! (deg) Comparison with Hipparcos/CCDM position angle real*4 Dpos (nr__2) ! (arcsec) Comparison with Hipparcos/CCDM * relative position character*24 Code (nr__2) ! Remarks concerning the system (2) *Note (1): Epoch: 1991.25 from Hipparcos else epoch from CCDM *Note (2): Codes as follows: * L = optical * M = motion * O = orbital * S = stable * * = 180{deg} converted * ** = alternative Hipparcos solution * Pap II = Lampens & Strigachev, 2004, Cat. <J/A+A/422/1023> C============================================================================= C Loading file 'table4.dat' ! Astrometry of the observed stars C Format for file interpretation 1 format( + A12,1X,A1,A3,1X,F9.4,1X,I2,1X,F6.3,1X,F5.3,1X,F6.2,1X,F4.2,1X, + A3,1X,A34) C Effective file loading open(unit=1,status='old',file= +'table4.dat') write(6,*) '....Loading file: table4.dat' do i__=1,138 read(1,'(A94)')ar__ read(ar__,1) + Name(i__),n_Name(i__),m_Name(i__),Epoch(i__),Nfr(i__), + rho(i__),e_rho(i__),theta(i__),e_theta(i__),Tel(i__), + Remark(i__) if (idig(ar__(32:37)).EQ.0) rho(i__) = rNULL__ if (idig(ar__(39:43)).EQ.0) e_rho(i__) = rNULL__ if (idig(ar__(45:50)).EQ.0) theta(i__) = rNULL__ if (idig(ar__(52:55)).EQ.0) e_theta(i__) = rNULL__ c ..............Just test output........... write(6,1) + Name(i__),n_Name(i__),m_Name(i__),Epoch(i__),Nfr(i__), + rho(i__),e_rho(i__),theta(i__),e_theta(i__),Tel(i__), + Remark(i__) c .......End.of.Just test output........... end do close(1) C============================================================================= C Loading file 'table5.dat' ! Differential photometry of the observed stars C Format for file interpretation 2 format( + A12,1X,A1,A3,1X,F12.4,1X,F5.3,1X,F5.3,1X,F6.3,1X,F5.3,1X,F6.3, + A1,1X,F5.3,A1,1X,F6.3,1X,F5.3) C Effective file loading open(unit=1,status='old',file= +'table5.dat') write(6,*) '....Loading file: table5.dat' do i__=1,124 read(1,'(A83)')ar__1 read(ar__1,2) + Name_1(i__),n_Name_1(i__),m_Name_1(i__),HJD(i__),DVmag(i__), + e_DVmag(i__),D_B_V(i__),e_D_B_V(i__),D_V_R(i__),u_D_V_R(i__), + e_D_V_R(i__),u_e_D_V_R(i__),D_V_I(i__),e_D_V_I(i__) if (idig(ar__1(44:49)).EQ.0) D_B_V(i__) = rNULL__ if (idig(ar__1(51:55)).EQ.0) e_D_B_V(i__) = rNULL__ if (idig(ar__1(57:62)).EQ.0) D_V_R(i__) = rNULL__ if (idig(ar__1(65:69)).EQ.0) e_D_V_R(i__) = rNULL__ if (idig(ar__1(72:77)).EQ.0) D_V_I(i__) = rNULL__ if (idig(ar__1(79:83)).EQ.0) e_D_V_I(i__) = rNULL__ c ..............Just test output........... write(6,2) + Name_1(i__),n_Name_1(i__),m_Name_1(i__),HJD(i__),DVmag(i__), + e_DVmag(i__),D_B_V(i__),e_D_B_V(i__),D_V_R(i__),u_D_V_R(i__), + e_D_V_R(i__),u_e_D_V_R(i__),D_V_I(i__),e_D_V_I(i__) c .......End.of.Just test output........... end do close(1) C============================================================================= C Loading file 'table6.dat' ! Relative position compared to the * Hipparcos/CCDM data C Format for file interpretation 3 format( + A12,1X,A1,A3,1X,I2,1X,F7.2,1X,F6.3,1X,F6.2,1X,F6.3,1X,F8.3,1X, + F6.3,1X,A24) C Effective file loading open(unit=1,status='old',file= +'table6.dat') write(6,*) '....Loading file: table6.dat' do i__=1,63 read(1,'(A90)')ar__2 read(ar__2,3) + Name_2(i__),n_Name_2(i__),m_Name_2(i__),Nfr_1(i__), + Epoch_1(i__),rho_1(i__),theta_1(i__),Drho(i__),Dtheta(i__), + Dpos(i__),Code(i__) c ..............Just test output........... write(6,3) + Name_2(i__),n_Name_2(i__),m_Name_2(i__),Nfr_1(i__), + Epoch_1(i__),rho_1(i__),theta_1(i__),Drho(i__),Dtheta(i__), + Dpos(i__),Code(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