Changeset 2434 for trunk/external-alma


Ignore:
Timestamp:
03/15/12 13:32:20 (12 years ago)
Author:
Takeshi Nakazato
Message:

New Development: No

JIRA Issue: Yes CAS-3345

Ready for Test: Yes

Interface Changes: No

What Interface Changed: Please list interface changes

Test Programs: import T100H/V data

Put in Release Notes: No

Module(s): Module Names change impacts.

Description: Describe your changes here...

POLNO is properly handled for T100H/V data while IFNO keeps array number.

Location:
trunk/external-alma/atnf/PKSIO
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/external-alma/atnf/PKSIO/NRODataset.cc

    r2289 r2434  
    827827  return vlsr ;
    828828}
     829
     830uInt NRODataset::getPolNo( int i )
     831{
     832  int idx = getIndex( i ) ;
     833//   cout << "HORN[" << idx << "]=" << HORN[idx]
     834//        << ", RX[" << idx << "]=" << RX[idx] << endl ;
     835  return polNoFromRX( RX[idx].c_str() ) ;
     836}
     837
     838uInt NRODataset::polNoFromRX( const char *rx )
     839{
     840  uInt polno = 0 ;
     841  // 2012/03/15 TN
     842  // T100H/V is multi-polarization receiver which is installed
     843  // on NRO 45m telescope. Here, POLNO is assigned as follows:
     844  //
     845  //    POLNO=0: T100H
     846  //          1: T100V
     847  //
     848  // For other receivers, POLNO is always 0.
     849  if ( strncmp( rx, "T100V", 5 ) == 0 )
     850    polno = 1 ;
     851  return polno ;
     852}
  • trunk/external-alma/atnf/PKSIO/NRODataset.h

    r2289 r2434  
    200200  virtual vector<double> getFrequencies( int i ) ;
    201201  virtual uInt getArrayId( string type ) ;
     202  virtual uInt getPolNo( int irow ) ;
    202203
    203204 protected:
     
    238239  virtual double toLSR( double v, double t, double x, double y ) ;
    239240
     241  // POLNO from RX
     242  uInt polNoFromRX( const char *rx ) ;
     243
    240244  // Type of file record
    241245  string LOFIL ;
  • trunk/external-alma/atnf/PKSIO/NROFITSDataset.cc

    r2203 r2434  
    734734//   for ( int i = 0 ; i < ARYNM ; i++ ) {
    735735//     if ( i == 0 ) {
    736 //       //cout << "HORN    " ;
     736//       cout << "HORN    " ;
    737737//     }
    738738//     else if ( ( i % 5 ) == 0 ) {
    739 //       //cout << endl << "        " ;
    740 //     }
    741 //     //cout << "\'" << HORN[i] << "\' " ;
     739//       cout << endl << "        " ;
     740//     }
     741//     cout << "\'" << HORN[i] << "\' " ;
    742742//   }
    743 //   //cout << endl ;
     743//   cout << endl ;
    744744  //
    745745  if ( readColumn( POLTP, "POLTP" ) != 0 ) {
     
    27422742}
    27432743
     2744uInt NROFITSDataset::getPolNo( int irow )
     2745{
     2746  char rx[9] ;
     2747  readTable( rx, "RX", 8, irow ) ;
     2748  rx[8] = '\0' ;
     2749  //cout << rx << endl ;
     2750  return polNoFromRX( rx ) ;
     2751}
     2752
    27442753// double NROFITSDataset::toLSR( double v, double t, double x, double y )
    27452754// {
  • trunk/external-alma/atnf/PKSIO/NROFITSDataset.h

    r2156 r2434  
    9797  virtual double getStartIntTime( int i ) ;
    9898  virtual double getScanTime( int i ) ;
     99  virtual uInt getPolNo( int irow ) ;
    99100
    100101 protected:
  • trunk/external-alma/atnf/PKSIO/NROReader.cc

    r2289 r2434  
    582582
    583583  // polno
    584   polno = 0 ;
     584  polno = dataset_->getPolNo( irow ) ;
    585585  //cout << "polno = " << polno << endl ;
    586586
Note: See TracChangeset for help on using the changeset viewer.