NAME

     word_swap  - Trace header word transfer tool.  Allows  swap-
     ing  information between int*2, int*4, float, fake float etc
     without having to know all about the  format  of  the  trace
     headers.   Can  also do multiplication by a scalar and addi-
     tion of a bias.


SYNOPSIS

     word_swap [ -Nntap ] [ -Ootap ] [ -nsnstr ] [  -nenetr  ]  [
     -rsnrst  ] [ -renred ] [ -hw1word1 ] [ -hw2word2 ] [ -ampamp
     ] [ -biasbias ] [ -abs ] [ -V ] [ -?  or  -h or  -help ]


DESCRIPTION

     word_swap : will  map the contents of hw1 after  multiplica-
     tion  by  amp  and the addition of bias into hw2.  It is not
     necessary that the two header words be  of  the  same  type.
     For  instance  the  routine  will  gladly map floating point
     values into integer header words.  Of course it is up to the
     user  to  realize the potential loss of fidelity here.  Also
     if you are mapping from a floating point header  entry  into
     an  integer entry of length 2 be wary of numbers larger than
     32767 as they will become nonsense.

     word_swap gets both its data and its parameters from command
     line  arguments.  These arguments specify the input, output,
     the start and end traces, start and end records, the  header
     words  to be mapped and the multiplier and bias values to be
     used in the mapping as well as verbose printout, if desired.

  Command line arguments
     -N ntap  [default: stdin]
          Enter the input data set name or file immediately after
          typing -N unless the input is from a pipe in which case
          the -N entry must be omitted. This  input  file  should
          include the complete path name if the file resides in a
          different directory.  Example -N/b/vsp/dummy tells  the
          program to look for file 'dummy' in directory '/b/vsp'.

     -O otap  [default: stdout]
          Enter the output data  set  name  or  file  immediately
          after  typing -O. This output file is not required when
          piping the output to another process. The  output  data
          set also requires the full path name (see above).

     -ns nstr  [default: 1]
          Enter the start trace number.

     -ne netr  [default: last trace of record]
          Enter the end trace number.

     -rs nrst  [default: 1]
          Enter start record number.

     -re nred  [default: last record]
          Enter end record number.

     -hw1 word1  [default: none]
          Enter the header mnemonic from which the mapping  value
          is to be taken.

     -hw2 word2  [default: none]
          Enter the header mnemonic to which the mapped value  is
          to deposited.

     -amp amp  [default: 1.0]
          Enter the scalar multiplier to be used in the  mapping.
          The value retrieved from hw1 will be multiplied by this
          value prior to assignment to hw2.

     -bias bias  [default: 0.0]
          Enter the scalar bias to be used in the mapping.   This
          value  will be added to the result of hw1 * amp and the
          resulting value stored in hw2.

     -abs Enter the command line argument '-abs' to use the abso-
          lute  value  of hw1[] in the calculation.  In this case
          the absolute value of hw1 will be taken prior to multi-
          plication by -amp[] and/or addition of -bias[].

     -V   Enter the command line argument '-V' to get  additional
          printout.

     -? or -h or -help
          Enter the command line argument '-?'  or  -h  or  -help
          to  get  online help.  The program terminates after the
          help screen is printed.


BUGS

     unknown


SEE ALSO

      xyz2head(1) hdrswap(1)


AUTHOR

     [P.G.A. Garossino: X3932] .


COPYRIGHT

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






Man(1) output converted with man2html