NAME

     lmascii2usp - Convert a Landmark ascii horizon
                   to a USP record.


SYNTAX

     lmascii2usp [ -N filename -O filename -P filename
                   -ol origin_iline -ox origin_xline
                   -dl delta_iline -dx delta_xline
                   -nl n_iline -nx n_xline -emask emask -I -h ]



DESCRIPTION

     lmascii2usp reads points from an ascii horizon file exported
     from  Landmark and casts them onto a map grid in USP format.
     The USP grid (record) will  be  aligned  with  the  in-line,
     cross-line  grid  present in the horizon file. Each trace of
     the USP file is coincident with an in-line of  the  Landmark
     grid.

     lmascii2usp requires in-line, cross-line origins, sizes, and
     deltas.  If these are unknown, -I can be used on the command
     line to interrogate the ascii file for these parameters  for
     use in a subsequent run.

     Command line arguments allow the user to extend or  truncate
     the  in-line and cross-line ranges of the output, as well as
     redefine the value of an embedded mask - the value placed in
     the output grid where the horizon is undefined.


OPTIONS

     -N filename [default: stdin]
          Enter the name of the ascii file from Landmark  immedi-
          ately  after  typing  -N.  This file should include the
          relative path name if the file resides in  a  different
          directory.

     -O filename [default: stdout]
          Enter the output dataset name or file immediately after
          typing  -O.  This file should include the relative path
          name if the file resides in a different  directory.  -O
          is  ignored  when  -I  is used to interrogate the input
          file for in-line and cross-line limits and deltas.

     -P filename [default: none]
          Enter a name for an optional  output  pick  file.  This
          file  is  used to record input samples used in map gen-
          eration. It can be usefull for QC or  to  capture  only
          the  values  used  when in-lines and/or cross-lines are
          limitted by command line arguments. The  pick  file  is
          the same format as the input Landmark file.


     -ol origin_iline [default: origin_iline=1]
          Enter the first in-line to be  in  the  output  record.
          (in-lines are coincident with usp traces)

     -ox origin_xline [default: origin_xline=1]
          Enter the first cross-line to be in the output  record.
          (cross-lines are coincident with usp samples)

     -dl delta_iline [default: delta_iline=1]
          Enter the numbering increment for in-lines in the  out-
          put  grid.  This  is used to convert in-line numbers in
          the ascii file to trace indices in the output. Negative
          numbers are allowed.

     -dx delta_xline [default: delta_xline=1]
          Enter the numbering increment for  cross-lines  in  the
          output grid. This is used to convert cross-line numbers
          in the ascii file to  sample  indices  in  the  output.
          Negative numbers are allowed.

     -nl n_iline [default: n_iline=100]
          Enter the number of in-lines in the output  grid.  This
          can  more  or less than the number of in-lines actually
          present in the input file.

     -nx n_xline [default: n_xline=100]
          Enter the number of cross-lines  in  the  output  grid.
          This  can  more  or less than the number of cross-lines
          actually present in the input file.

USP grid and assign values as follows:
     Origins, deltas, and numbers are used to calculate indices in the

           itrc = (iline_in-origin_iline)/delta_iline + 1
           ismp = (xline_in-origin_xline)/delta_xline + 1

           if (itrc.ge.1 .and. itrc.le.n_iline .and.
               ismp.ge.1 .and. ismp.le.n_xline) then
             usp_grid(ismp,itrc) = zdata_in
           endif

     -emask emask [default: emask=-1e+37]
          Enter the value to use for samples where  there  is  no
          input point.

     -I [default: FALSE]
          Use -I to interrogate the input file  for  in-line  and
          cross-line ranges, increments, and sizes.

     -h or -?
          Print online help to the terminal.


EXAMPLE

         lmascii2usp -Nlm_map.dat -Omap.usp \
            -ol605 -ox201 -dl1 -dx-2 -nl200 -nx101 \
            -emask-99999

     This will create a UPS record with 200 traces of 101 samples
     using  data  from in-lines 605 to 804 by 1 and cross-lines 1
     to 201 by 2.


BUGS

     None known


AUTHORS

     M.J. O'Brien - Allied Geophysics Inc.



COPYRIGHTS

     Copyright  2001,  Allied  Geophysics,   Inc.    All   Rights
     Reserved.

     Portions of this application are also protected as follows:

     copyright 2001, Amoco Production Company
               All Rights Reserved
          an affiliate of BP America Inc.




























Man(1) output converted with man2html