CHAPTER 1. ABOUT SU
on the Internet, it began to be used by a much broader community. The package is used by
exploration geophysicists, earthquake seismologists, environmental engineers, software develop-
ers and others. It is used by scientiﬁc staﬀ in both small geotechnical companies and major
oil and gas companies, and by academics and government researchers, both as a seismic data
processing and software development environment.
1.1 What SU is
The SU package is free software, meaning that you may have unrestricted use of the codes for
both processing and software development, provided that you honor the license that appears
at the beginning of this manual and as the ﬁle LEGAL
STATEMENT in the current release
of the package. (This latter ﬁle takes precedence). The package is maintained and expanded
periodically, with each new release appearing at 3 to 6 month intervals, depending on changes
that accumulate in the oﬃcial version here at CWP. The package is distributed with the full
source code, so that users can alter and extend its capabilities. The philosophy behind the
package is to provide both a free processing and development environment in a proven structure
that can be maintained and expanded to suit the needs of a variety of users.
The package is not necessarily restricted to seismic processing tasks, however. A broad
suite of wave-related processing can be done with SU, making it a somewhat more general
package than the word “seismic” implies. SU is intended as an extension of the Unix operating
system, and therefore shares many characteristics of the Unix, including Unix ﬂexibility and
expandibility. The fundamental Unix philosophy is that all operating system commands are
programs run under that operating system. The idea is that individual tasks be identiﬁed, and
that small programs be written to do those tasks, and those tasks alone. The commands may
have options that permit variations on those tasks, but the fundamental idea is one-program,
one-task. Because Unix is a multi-tasking operating system, multiple processes may be strung
together in a cascade via “pipes” (|).
This decentralization has the advantage of minimizing overhead by not launching single
“monster” applications that try to do everything, as is seen in Microsoft applications, or in
some commercial seismic utilities, for example.
Unix has the added feature of supporting a variety of shell languages, making Unix, itself,
ameta-language. Seismic Unix beneﬁts from all of these attributes as well. In combination
with standard Unix programs, Seismic Unix programs may be used in shell scripts to extend
the functionality of the package.
Of course, it may be that no Unix or Seismic Unix program will fulﬁll a speciﬁc task. This
means that new code has to be written. The availability of a standard set of source code,
designed to be readable by human beings, can expedite the process of extending the package
through the addition of new source code.
1.2 What SU is not
The SU package is not a graphical user interface driven utility at this time, though there
are several possibilities including Java and TCL/TK scripts, which may be exploited for this
purpose in the future. Because most commercial seismic processing packages are GUI-based, it
is unavoidable that users will expect SU to be similar to these packages. However, this is not
afair comparison, for several reasons.
1.3. OBTAINING AND INSTALLING SU
As mentioned above, SU is an extension of the Unix operating system. Just as there are no
GUI driven Unix operating systems that give full access to all of the capabilities of Unix from
menus, it is not reasonable to expect full access to Seismic Unix through such an interface. At
most, any SU interface will give limited access to the capabilities of the package.
SU is not a replacement for commercial seismic packages. Commercial seismic software
packages are industrial-strength utilities designed for the express purpose of production-level
seismic processing. If you do commercial-level processing, and have dedicated, or plan to
dedicate funds to purchase one or more license of such commercial software, then it is unlikely
that you will be able to substitute SU for the commercial utility.
However, SU can be an important adjunct to any commercial package you use. Where
commercial packages are used for production work, SU often has found a place as a proto-
typing package. Also, if new code needs to be written, SU can provide a starting base for
new software applications. Indeed, the availability of seismic processing capability may encour-
age non-processors to experiment with processing, non-software-developers to experiment with
software development, and non-researchers to engage in research.
SU is not conﬁned to seismic applications. It may ﬁnd use, both in geophysical and more
general signal processing applications. It certainly can be useful for teaching students about
“wave related” signal processing and, particularly, Fourier transform properties. This can
include radar, non-seismic acoustics, and image processing, just to name a few.
Another thing that SU is not, at least in its current version, is a 3D package. However, it
is not, expressly a 2D package, either, as there are numerous ﬁltering and trace manipulation
tasks that are the same in 2D as in 3D. It is likely, however, that there will be 3D applications
in future releases of SU. A single 3D migration code appeared ﬁrst in Release 32, which will
hopefully set the stage for new developments.
1.3 Obtaining and Installing SU
Because the coding standards of SU stress portability, the package will install on any system
that is running some form of the Unix operating system, and has a decent version of “make”
and an ANSI C compiler. The programs GNU Make and GCC may be substituted for these
respective programs on most systems.
New releases of SU are issued at 3 to 6 month intervals, depending upon the accumulation
of changes in the home version at CWP. Old releases are not supported. However, if materials
appear to break between releases, please contact me (John Stockwell) by email so that we can
ﬁx the problem.
Instructions for obtaining and installing SU may be found in Appendix A of this manual.
Remarkably,asoftware packagecalled CYGWIN32, recently released bytheGNU project, provides enough
Unix-like functionality, so that SU may be ported to Windows NT, with no changes to the SU source code or
C# Excel - Excel Conversion & Rendering in C#.NET
Excel documents in .NET class applications independently, without using other external third-party dependencies like Adobe Acrobat. Excel to PDF Conversion. delete page from pdf acrobat; delete pdf pages in preview
Like the Unix operating system, Seismic Unix may be thought of as a language (or meta-
language). As with any language, a certain amount of vocabulary must be mastered before
useful operations may be performed. Because the SU contains many programs, there must
be a “dictionary” to permit the inevitable questions about vocabulary can be answered. It is
intended that this manual be the beginning of such a dictionary.
SU does not have “man pages,” in the same way that Unix does, but it does have equiv-
alent internal documentation mechanisms. There is a general level help utilities which give
an overview of what is available. For information about speciﬁc aspects of a particular code,
the majority of the programs contain a selfdoc—a self-documentation paragraph, which will
appear when the name of the program is typed on the commandline, with no options.
(In all of the examples that follow, the percent sign “%” indicates a Unix commandline
prompt, and is not typed as part of the command.)
The following tools provide internal documentation at various levels of detail for the main
programs, shell scripts, and library functions in the package:
• SUHELP - list the CWP/SU programs and shells
• SUNAME - get name line from self-docs and location of the source code
• The selfdoc - is an internaldocumentation utility whichexists inthemajority ofexecutable
mains and shell scripts. The selfdoc is seen by typing the name of the program or shell
script on the commandline with no arguments, and without redirection of input or output
via pipes | or Unix redirects > <, For non-executables (library routines) and for programs
without the selfdoc feature, there is a dummy selfdoc included which provides a database
of information about those items, as well,
• SUDOC - get DOC listing for code
• SUFIND - get info from self-docs
• GENDOCS - generate complete list of selfdocs in latex form
• suhelp.html - is an HTML global overview of SU programs by subject matter,
• SUKEYWORD – guide to SU keywords in segy.h
This chapter discusses each of these utilities, with the intent of showing the reader how to
get from the most general to the most speciﬁc information about SU programs.
CHAPTER 2. HELP FACILITIES
2.1 SUHELP - List the Executable Programs and Shell Scripts
For a general listing of the contents of SU, which includes each executable (that is, each main
program and shell script) in the package type:
CWP PROGRAMS: (no self-documentation)
PAR PROGRAMS: (programs with self-documentation)
press return key to continue
Please type suhelp or see Appendix B for the full text.
Another useful command sequence is:
% suhelp | lpr
which will the output from suhelp to the local print.
2.2 SUNAME - Lists the Name and Short Description of Every
Item in SU
Amore complete listing of the contents of the CWP/SU package may be obtained by typing
----- CWP Free Programs -----
* CTRLSTRIP - Strip non-graphic characters
* DOWNFORT - change Fortran programs to lower case, preserving strings
* FCAT - fast cat with 1 read per file
* ISATTY - pass on return from isatty(2)
* MAXINTS - Compute maximum and minimum sizes for integer types
* PAUSE - prompt and wait for user signal to continue
* T - time and date for non-military types
* UPFORT - change Fortran programs to upper case, preserving strings
2.3. THE SELFDOC - PROGRAM SELF-DOCUMENTATION
A2B - convert ascii floats to binary
B2A - convert binary floats to ascii
DZDV - determine depth derivative with respect to the velocity ",
FARITH - File ARITHmetic -- perform simple arithmetic with binary files
FTNSTRIP - convert a file of floats plus record delimiters created
H2B - convert 8 bit hexidecimal floats to binary
KAPERTURE - generate the k domain of a line scatterer for a seismic array
MAKEVEL - MAKE a VELocity function v(x,y,z)
MKPARFILE - convert ascii to par file format
PRPLOT - PRinter PLOT of 1-D arrays f(x1) from a 2-D function f(x1,x2)
RAYT2D - traveltime Tables calculated by 2D paraxial RAY tracing
RECAST - RECAST data type (convert from one data type to another)
REGRID3 - REwrite a [ni3][ni2][ni1] GRID to a [no3][no2][no1] 3-D grid
RESAMP - RESAMPle the 1st dimension of a 2-dimensional function f(x1,x2)
Please type: suhelp or see Appendix B for the full text.
2.3 The Selfdoc - Program Self-Documentation
There are no Unix man pages for SU. To some people that seems to be a surprise (even
a disappointment) as this would seem to be a standard Unix feature, which Seismic Unix
should emulate. The package does contain an equivalent mechanism called a selfdoc or self-
This is a paragraph that is written into every program, and arranged so that if the name
of the program is typed on the commandline of a Unix terminal window, with no options or
redirects to or from ﬁles, the paragraph is printed to standard error (the screen).
SUSTACK - stack adjacent traces having the same key header word
sustack <input >output [Optional parameters]
header key word to stack on
each sample is divided by the
normpow’th number of non-zero values
stacked (normpow=0 selects no division)
verbose = 1 echos information
Note: The offset field is set to zero on the output traces.
Sushw can be used afterwards if this is not acceptable.
The ﬁrst line indicates the name of the program sustack and a short description of what
the program does. This is the same line that appears for the listing of sustack in the suname
listing. The second line
CHAPTER 2. HELP FACILITIES
sustack <stdin >stdin [Optional parameters]
indicates how the program is to be typed on the commandline, with the words “stdin” and
“stdout” indicating that the input is from the standard input and standard output, respectively.
What this means in Unix terms is that the user could be inputting and outputting data via
diskﬁles or the Unix “redirect in” < and “redirect out” > symbols, or via pipes |.
The paragraphs labeled by “Required parameters:” and “Optional parameters” indicate
the commandline parameters which are required for the operation of the program, and those
which are optional. The default values of the Optional parameters are given via the equality
are the values that the program assumes for these parameters when data are supplied, with no
additional commandline arguments given. For example: “key=cdp” indicates that sustack will
stack over the common depth point gather number ﬁeld, “cdp.” (The shell script sukeyword
tells the choices of keyword that are available.)
2.4 SUDOC - List the Full Online Documentation of any Item
As has been alluded to in previous sections of this manual, there is a database of selfdocumen-
tation items that is available for each main program, shell script, and library function. This
database exists in the directory $CWPROOT/src/doc and is composed of all of the selfdocu-
mentation paragraphs of all of the items in SU.
Because not all all items with selfdocs are executable, an additional mechanism is nec-
essary to see the selfdoc for these items. For example, information about the Abel trans-
form routines, located in $CWPROOT/src/cwp/lib/abel.c (on the system at CWP, CWP-
ROOT=/usr/local/cwp) is obtained via
% sudoc abel
ABEL - Functions to compute the discrete ABEL transform:
abelalloc allocate and return a pointer to an Abel transformer
abelfree free an Abel transformer
abel compute the Abel transform
void *abelalloc (int n);
void abelfree (void *at);
void abel (void *at, float f, float g);
ns number of samples in the data to be transformed
f array of floats, the function being transformed
at pointer to Abel transformer returned by abelalloc(int n)
g array of floats, the transformed data returned by
Documents you may be interested
Documents you may be interested