Welcome to the Harris Geospatial product documentation center. Here you will find reference guides, help documents, and product libraries.


  >  Docs Center  >  Libraries  >  Mankoff  >  LONXLATE

LONXLATE

LONXLATE

Name


LONXLATE

Purpose


  This function translates an array (or atomic element) of
  longitudes from one grid to another. A grid is either Eastern or
  Western longitude, and from 0 to 360 or -180 to 180

Category


  Mapping

Calling Sequence


  Result = LONXLATE( Longitudes, /from_xxx, /to_xxx )

Inputs


  Longitudes: An array (or a atomic element (scalar)) of
  longitudes. These must be valid regarding the /FROM_xxx grid
  system.

Keyword Parameters


  FROM_180E: A keyword specifying that the longitude(s) range
  between -180 and 180, and increase to the East.
  FROM_180W: A keyword specifying that the longitude(s) range
  between -180 and 180, and increase to the West.
  FROM_360E: A keyword specifying that the longitude(s) range
  between 0 and 360, and increase to the East.
  FROM_360W: A keyword specifying that the longitude(s) range
  between 0 and 360, and increase to the West.
  TO_180E: A keyword specifying that the output longitude(s) range
  should be between -180 and 180, and increase to the East.
  TO_180W: A keyword specifying that the output longitude(s) range
  should be between -180 and 180, and increase to the West.
  TO_360E: A keyword specifying that the output longitude(s) range
  should be between 0 and 360, and increase to the East.
  TO_360W: A keyword specifying that the output longitude(s) range
  should be between 0 and 360, and increase to the West.

Outputs


  This function returns the input longitude array, translated from
  the grid specified by the /FROM_xxx keyword, onto the grid
  specified by the /TO_xxx keyword.

Side Effects


  None that I know of yet... Email me if you find any.

Restrictions


  The input array must be valid on the grid specified by the
  /FROM_xxx keyword. No error checking is done. Use CIRRANGE and/or
  RANGECIR before calling this to fix your lons for you (they are in
  the astronomy library)

Procedure


  * read the code
  * Most of the work is done in the /to_180e section. All other
  /TO_xxx keywords use that chunk of code, pass in the /FROM_xxx
  keyword, and then do only a little bit of work to translate from
  /to_180e to the actual requested /TO_xxx.

Example


  lon_0 = [ -135, -45, 45, 135 ]
  lon_1 = lonxlate( lon_0, /from_180e, /to_180w )
  lon_2 = lonxlate( lon_1, /from_180w, /to_360e )

Modification History


  Written by: Ken Mankoff (mankoff@lasp.colorado.edu), 2002-04-03
2002-05-22; KDM; Added documentation.



© 2018 Harris Geospatial Solutions, Inc. |  Legal
My Account    |    Store    |    Contact Us