Changeset 2256 for trunk/external-alma


Ignore:
Timestamp:
08/01/11 11:35:44 (13 years ago)
Author:
Takeshi Nakazato
Message:

New Development: No

JIRA Issue: Yes CAS-1913

Ready for Test: Yes

Interface Changes: No

What Interface Changed: Please list interface changes

Test Programs: List test programs

Put in Release Notes: Yes/No

Module(s): Module Names change impacts.

Description: Describe your changes here...

Tracking error (encoder-pointingDirection) is taken into account.


File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/external-alma/asdm2ASAP/ASDMReader.cc

    r2255 r2256  
    18801880vector< vector<double> > ASDMReader::pointingDir( PointingRow *row )
    18811881{
    1882   vector< vector<Angle> > aDir = row->getTarget() ;
     1882  vector< vector<Angle> > aTar = row->getTarget() ;
    18831883  vector< vector<Angle> > aOff = row->getOffset() ;
    1884   unsigned int n = aDir.size() ;
     1884  vector< vector<Angle> > aDir = row->getPointingDirection() ;
     1885  vector< vector<Angle> > aEnc = row->getEncoder() ;
     1886  unsigned int n = aTar.size() ;
    18851887  vector< vector<double> > dir( n ) ;
    1886   double factor = 1.0 / cos( aDir[0][1].get() ) ;
     1888  double factor = 1.0 / cos( aTar[0][1].get() ) ;
    18871889  for ( unsigned int i = 0 ; i < n ; i++ ) {
    18881890    dir[i].resize( 2 ) ;
    18891891    /**
    1890      * This is approximate way to add offset
     1892     * This is approximate way to add offset taking tracking error
     1893     * into account
    18911894     *
    18921895     * az = dir[0][0] = target[0][0] + offset[0][0] / cos(el)
     1896     *                 + encorder[0][0] - direction[0][0]
    18931897     * el = dir[0][1] = target[0][1] + offset[0][1]
     1898     *                 + encorder[0][1] - direction[0][1]
    18941899     **/
    1895     dir[i][0] = aDir[i][0].get() + factor * aOff[i][0].get() ;
    1896     dir[i][1] = aDir[i][1].get() + aOff[i][1].get() ;
     1900    dir[i][0] = aTar[i][0].get() + factor * aOff[i][0].get() ;
     1901               + aEnc[i][0].get() - aDir[i][0].get() ;
     1902    dir[i][1] = aTar[i][1].get() + aOff[i][1].get() ;
     1903               + aEnc[i][1].get() - aDir[i][1].get() ;
    18971904  }
    18981905  return dir ;
Note: See TracChangeset for help on using the changeset viewer.