--------------------------------------------------------------------------
                 usng Documentation 10/29/02
 --------------------------------------------------------------------------
 
 usng - Converts Geodetic Latitude, Longitude or UTM
        to U.S. National Grid or vice versa.
 
        *  NOTE - For more information about the 'U.S. National Grid' system
                  see file' usng_sys.doc'


 Author:
 -------
 EMail = Craig.Larrimore@noaa.gov -> ngs.infocenter@noaa.gov



 Changes:
 --------
  Ver 1.1 = Original
  Ver 2.0 = Added Southern Hemisphere capability


 To execute with prompts:
 ------------------------
  usng


 You will prompted for:
 ----------------------
  1. Direction of conversion
  2. Input Datum
  3. Input coordinates
  4. Other information as needed.

  NOTE - You will have the option of saving output to a file.
         The output file is always called 'usng.out'
         and you will be asked 'Okay to Delete'
         if it already exists.




 To see COMMAND LINE USAGE INFO Type:
 -------------------
  usng CMD


 To see FILE USAGE INFO Type:
 ----------------------------
  usng FILE



 To use COMMAND LINE to convert Lat/Lon to USNG:
 -----------------------------------------------
  Type: usng GP2US N385322.08 W0770206.86 83
 
        where:
              usng       =  Program name
              GP2US      =  Convert from GeodeticPosition to USNG
              N385322.08 = Latitude deg-min-sec
             W0770206.86 = Longitude deg-min-sec
                      83 = Datum (either 83 or 27)
 
        Note:
             Latitude and Longitude may be 0, 1, or 2 decimal places.
             Valid examples:
             ---------------
             N380059.99 W0770059.99
             N380059.9  W0770059.9
             N380059    W0770059


 To use COMMAND LINE to convert USNG to Lat/Lon:
 -----------------------------------------------
  Type: usng US2GP 18SUJ2348306479 83
 
        where:
              usng            =  Program name
              US2GP           =  Convert from USNG to GeodeticPosition
              18SUJ2348306479 =  USNG
                           83 = Datum (either 83 or 27)

        Note:
             USNG may to 15 char, 13 char, or 11 char.
             Valid examples:
             ---------------
             18SUJ2348306479
             18SUJ23480647
             18SUJ234064

 


 To use COMMAND LINE to convert UTM to USNG:
 -----------------------------------------------
  Type: usng UTM2US 18 323483.2 4306479.5 83 A10
 
        where:
              usng       =  Program name
              UTM2US     =  Convert from UTM to USNG
                    18   = UTM Zone
              323483.2   = UTM East
             4306479.5   = UTM North
                      83 = Datum (either 83 or 27)
                     A10 = UTM Accuracy
                               A1 means good to 1 meter
                               A10 means good to 10 meters
                               A100 means good to 10 meters
    
        Note: UTM East comes before North


 To use COMMAND LINE to convert USNG to UTM
 -----------------------------------------------
  Type: usng US2GP 18SUJ2348306479 83
 
        where:
              usng            =  Program name
              US2UTM          =  Convert from USNG to UTM
              18SUJ2348306479 =  USNG
                           83 = Datum (either 83 or 27)

        Note:
             USNG may to 15 char, 13 char, or 11 char.
             Valid examples:
             ---------------
             18SUJ2348306479
             18SUJ23480647
             18SUJ234064

 

  To use a FILE to convert Lat/Lon to USNG:
  -----------------------------------------
    1. Type: usng GP2US FILE=myfile
             where:
                   GP2US   = convert to USNG
                   FILE=   = required text.
                   myfile  = Your input filename.

    2. Your input file should consist of delimited records
       with 5 fields per record, using '|' as the delimiter.

    3. The 1st and 2nd fields will be ignored.
       (You may leave them empty or put something in them)

    4. The LAT, LON, DATUM must reside in the 3rd, 4th, and 5th fields

    5. Here are examples of valid input file records:
       ----------------------------------------------
       ZZ0263|BENCH MARK 283|N384517.33|W0773322.44|83
       ZZ3551|JONES MUN TANK|N441622.35263|W1203344.26353|83
       ||N423000|W1203000|83


  To use a FILE to convert USNG to Lat/Lon
  -----------------------------------------
    1. Type: usng US2GP FILE=myfile
             where:
                   US2GP   = convert to GeodeticPosition
                   FILE=   = required text.
                   myfile  = Your input filename.

    2. Your input file should consist of delimited records
       with 4 fields per record, using '|' as the delimiter.

    3. The 1st and 2nd fields will be ignored.
       (You may leave them empty or put something in them)

    4. The USNG, DATUM must reside in the 3rd, and 4th fields.

    5. Here are examples of valid input file records:
       ----------------------------------------------
       ZZ0263|BENCH MARK 283|18SUJ2348306479|83
       ZZ3551|JONES MUN TANK|18SUJ23480647|83
       ||18SUJ234064|83



  To use a FILE to convert UTM to USNG:
  -----------------------------------------
    1. Type: usng UTM2US FILE=myfile
             where:
                   UTM2US  = Convert UTM to USNG
                   FILE=   = required text.
                   myfile  = Your input filename.

    2. Your input file should consist of delimited records
       with 7 fields per record, using '|' as the delimiter.

    3. The 1st and 2nd fields will be ignored.
       (You may leave them empty or put something in them)

    4. The ZONE, EAST, NORTH, DATUM, ACCURACY must reside in the 
       3rd, 4th, 5th, 6th and 7th fields.

    5. Here are examples of valid input file records:
       ----------------------------------------------
       ZZ0263|BENCH MARK 283|18|323483.2|4306479.5|83|A10
       ZZ3551|JONES MUN TANK|18|323483.2|4306479.5|83|A10
       ||18|323483.2|4306479.5|83|A10


  To use a FILE to convert USNG to UTM
  -----------------------------------------
    1. Type: usng US2GP FILE=myfile
             where:
                   US2UTM  = Convert USNG to UTM
                   FILE=   = required text.
                   myfile  = Your input filename.

    2. Your input file should consist of delimited records
       with 4 fields per record, using '|' as the delimiter.

    3. The 1st and 2nd fields will be ignored.
       (You may leave them empty or put something in them)

    4. The USNG, DATUM must reside in the 3rd, and 4th fields.

    5. Here are examples of valid input file records:
       ----------------------------------------------
       ZZ0263|BENCH MARK 283|18SUJ2348306479|83
       ZZ3551|JONES MUN TANK|18SUJ23480647|83
       ||18SUJ234064|83



  Southern Hemisphere
  -------------------
    For input Lat, Lon precede the Latitude with 'S' instead on 'N'.
    For input UTM, precede the North with '-'
    Examples:
        ||S141723|W1703949|83
        ||02|536200.0|-8420200.0|83|A100
        ||2LNK362202|83

  Eastern Hemisphere
  -------------------
  This program only recognizes West longitude.
  You should convert any input East longitudes to West.
  If East Lon = E1444105 then West Lon = 359 59 60 - 144 41 05 = W2151855



 OUTPUT:
 -------
 Output goes to the screen.

 If you ran via Input FILE then output will also go
 to a file called 'usng.out'.