Fortran 77 package CRT version 5.30

General description

Programming language, error messages, screen output, etc.
Unified memory management.
History files.

New in version 5.30

VRML (Virtual Reality Modeling Language). VRML97 examples: len-ray.wrl, 98-srf.wrl, 98-vp.wrl, 98-ray.wrl.

Compiling and linking programs of package CRT

Running programs of package CRT

It is recommended to run the programs from the history files. The history files may contain the information how to execute the programs, the data read from standard input (Fortran) or from the command line (Perl) and the data read from the SEP parameter files.
Data from standard input *:
Main input data of each program are read from the standard input (denoted by * in the table below), and mostly consist of a single line containing filenames and at most few numerical parameters.
Description of input data for CRT
Complete Ray Tracing.
Description of input data for RPPLOT
Plotting ray parameters using the output files of CRT.
Description of input data for CRT2D3D
Transforming 2-D system of rays to 3-D system of rays to be processed by program MTT which presently works only in 3-D.
Description of input data for MTT
Calculation of Multivalued Travel Times on 3-D grids of points, using the output of CRT.
Description of input data for MTTGRD
Converting multivalued travel times produced by program MTT into several singlevalued grids separated according to different ray histories.
Description of input data for CRTRAY
Conversion of output rays from CRT to formatted files.
Description of input data for CRTPTS
Conversion of output points from CRT to formatted files.
Description of input data for GREEN
Program to convert the unformatted output of program CRT into a formatted file containing the ray-theory elastodynamic Green function.
Description of input data for GREENSS
Program to read a formatted file containing the ray-theory elastodynamic Green function and to generate ray-theory time-domain synthetic seismograms (without attenuation) or frequency-domain response functions (including causal Futterman's attenuation).
Description of input data for INV1TT
Program to evaluate the derivatives of the travel time with respect to the model coefficients.
Description of input data for CRTCART
Converting the rays calculated by program CRT from curvilinear to Cartesian coordinates, which are required by 'mtt.for'.
Table of data files (the table is incomplete and should be revised in future)::
d
a
t
a

*




m
a
i
n

l
o
g


M
O
D
E
L
C
R
T
_
R
C
R
T
_
S
C
R
T
_
I
C
R
T
_
T
L
I
N


P
T
S


F
T
T


G
R
E
E
N
S
O
U
R
C
E
R
F



G
S
E


S
E
P


M
G
R
D

D
A
T
A

P
S



CRT in in out in out out out out in
in
RPPLOT in in in in in out
MTT in in in in in out
CRT2P in in
out
in
out
in
out
CRTRAY in in in out in
in
CRTPTS in in in in
in
out
out
GREEN in in in in
in
out in
GREENSS in in in out in
out
in
SS in out in out in out
SP in in in in out
INV1TT in in out in in in out
General descriptions of the data forms are available under the formal names of the data forms in the table header.
Information specific to individual programs is available under the active items 'in' and 'out' inside the table.
Input data files '*' are read from the standard input and are unique to each program '*.for'.
Input data files 'main' are unique to each program '*.for'. Their names often default to '*.dat' (with the exception of 'greenss.for').
Output log files 'log' are unique to each program '*.for' and their default names are often '*.out', where the program name stands for *.
'PS' are the output encapsulated PostScript files with figures, generated by means of calcops.for.

List of error messages

File list of package CRT

The Complete Ray Tracing consists of package MODEL and of the following FORTRAN77 source code and demo files:

(A) Documentation:
crt.htm
This file (main HTML file containing basic description and links the files of this package).
crtdoc.htm
General documentation to CRT. File containing a brief overview of the CRT package. The detailed description of input data, procedures, and other important topics is included within the individual FORTRAN77 source code files.
crtver.htm
List of the released versions.
crterr.htm
List of error messages with the links to their descriptions.
(B) Basic complete ray tracing program and subroutines:
These files together with the forward modelling model specification routines of files 'model.for', 'metric.for', 'srfc.for', 'parm.for', 'val.for', 'fit.for' form a consistent basic version of the complete ray tracing program.
crt.for
Main program. It reads the input data and then controls the complete ray tracing of the specified elementary waves.
crtin.for
Subroutines designed to open the data files for complete ray tracing and to read the input data sets CRT, MODEL, DCRT and INIT. Called e.g. by the main program 'crt.for'.
code.for
Subroutine file devoted to the codes for elementary waves. Contains the general description of the codes for elementary waves and subroutines designed to read the input data for the codes of elementary waves and to transform the used numerical code of the elementary wave under consideration into instructions specifying the behaviour of the wave at the initial points of rays and at all points of incidence of the rays at interfaces (see C.R.T.4).
code.inc
Include file with COMMON block for 'code.for'.
ray.for
Contains the subroutine designed to read the input data for complete ray tracing and to store them in the memory (see C.R.T.5.6), the list of the quantities computed along rays (see C.R.T.5.2), and the subroutine designed to continue the complete ray tracing of a ray from the given point (see C.R.T.5.7).
dcrt.inc
Include file with COMMON block with data controlling ray tracing. The data are read by 'ray.for' and are used by various ray tracing routines.
raycb.for
Subroutines for complete ray tracing within one complex block (see C.R.T.5.8).
raycb.inc
Include file with COMMON block for 'raycb.for'.
trans.for
Subroutine transforming the computed quantities across a curved interface (see C.R.T.5.9), and subroutine replacing the amplitudes by ones involving the appropriate conversion coefficients (see C.R.T.5.5.4).
coef.for
Subroutines computing the reflection/transmission coefficients (see C.R.T.5.9.7).
init.for
Subroutines designed to read the input data for the initial surface, and to define the initial values of the quantities for complete tracing of a ray with given take-off parameters (see C.R.T.6).
initd.inc
Include file with COMMON blocks for 'init.for', containing input data and related quantities.
initc.inc
Include file with COMMON block for 'init.for' and other routines, containing the quantities at the initial point of the ray being currently traced.
rpar.for
Subroutines controlling the take-off parameters of the rays. A user may introduce his own procedure of selection of the take-off parameters and his own two-point ray tracing algorithm by means of a modification of this subroutine file, or subsequently referred files 'rp2d.for' and 'rp3d.for' controlling the shooting algorithms.
rpard.inc
Include file with COMMON block for 'rpar.for', containing input data and related quantities.
rparc.inc
Include file with COMMON blocks for 'rpar.for' to record the ray histories and other related quantities.
rp2d.for
Subroutines controlling the one-parametric shooting algorithm determining the normalized take-off parameter of rays for 2-D two-point ray tracing.
rp2d.inc
Include file with COMMON block for 'rp2d.for'.
rp3d.for
rp3d.inc
Subroutines controlling the two-parametric shooting algorithm determining the normalized take-off parameters of rays for 3-D two-point ray tracing.
rp3dnul.for
Void subroutines replacing 'rp3d.for' to save RAM if only 2-D ray tracing is performed. Not very interesting.
writ.for
Subroutines creating the output of complete ray tracing (see C.R.T.5.5).
writ.inc
Include file with COMMON blocks for 'writ.for'.
scronum.for
Basic version of the subroutine file 'scro.for', writing the index of ray and the index of elementary wave to the screen. It uses the '+' ASA carriage control character in the first column to avoid line feed.
(C) The following subroutine files may be used to modify the basic version of the complete ray tracing program by means of additional screen output routines:
scronul.for
Dummy version of the subroutine file 'scro.for' containing screen output subroutines called by the subroutines of the package 'writ.for'.
scropc.for
Version of the subroutine file 'scro.for' for the IBM-compatible personal computers. It should also work on the VAX computers. The screen output consists of a simple graphic output (see the subroutine files 'plot*.for' below) and of writing the brief messages on the status of the currently computed ray to the console. This output controls the console by means of the ANSI escape sequences supported by MS-DOS ANSI.SYS driver on IBM-compatible personal computers. This console output is just an example, the subroutines SCRO1, SCRO2, SCRO3, SCRO4 and SCRO5 have to be modified by a user for the particular computer system. If no screen output is required, the executable statements of the subroutines SCRO1, SCRO2, SCRO3, SCRO4 and SCRO5 may simply be deleted (see 'scronul.for' above). Graphic output is accomplished by means of invocation of 'CalComp' subroutines PLOTS, PLOT, and NEWPEN. They may be already available on some computers for some FORTRAN77 compilers (e.g., PLOTS, PLOT, and NEWPEN are included in the Lahey FORTRAN77 compilers for PC's). Otherwise, 'scropc.for' may be linked with 'plotnul.for' to disable plotting, or with user's own interface routines to his particular graphic system (see files 'plot*.for' and 'calcomp.for').
scropc.inc
Include file with COMMON block for 'scropc.for'.
plotnul.for
Dummy version of the subroutine file 'plot*.for' containing the plot subroutines called by the subroutines of the package 'scropc.for', see also the section graphics of this guide.
calcomp.cfg
Configuration file to the 'calcomp.for' routines, disabling the interactive communication and other features of 'calcomp.for' not required by the 'scropc.for' routines. The 'calcomp.cfg' configuration file is active just if located in the current directory. Otherwise, the 'calcomp.for' routines run in an interactive way and may create another 'calcomp.cfg' configuration file. Refer to the MODEL package.
(D) Application routines and programs facilitating the processing of the results of complete ray tracing:
When using the complete ray tracing program composed of the subroutine files listed above, we determine and store various quantities along the ray and at the points of intersection of the ray with some selected surfaces. The following sets of routines may be utilized when processing the results of the complete ray tracing, including a kinematic inversion:
ap.for
Applications and processing of the results of complete ray tracing. Subroutines designed to read from the files the quantities describing the points of rays, and to evaluate many other quantities used in seismology and discussed in the chapter C.R.T.7. These subroutines may be included in user's application programs following the complete ray tracing program. Individual subroutines correspond to the individual sections of the chapter C.R.T.7, and may call many subroutines of the above files composing the complete ray tracing program.
apvar.for
Subroutines designed to evaluate the variations of the travel time with respect to the model coefficients.
pointc.inc
Include file with COMMON block /POINTC/ to store the quantities calculated at a point of a ray, used by 'ap.for' and other routines processing the results of the 'crt.for' program.
rpplot.for
Program plotting ray parameters using the output of program 'crt.for'.
rpplot.inc
rpsymb.for
crt2d3d.for
Program to transform 2-D system of rays to 3-D system of rays to be processed by program MTT, which present version works only in 3-D.
mtt.for
Interpolation within ray cells.
mtt.inc
mttgrd.for
Converting multivalued travel times produced by program MTT into several singlevalued grids corresponding to individual ray histories.
crt2p.for
Program to single out two-point rays in the unformatted output program CRT. Simple illustrative example how to use 'ap.for'.
crtout.for
Subroutines to facilitate conversion of the unformatted output of program CRT into formatted files.
ttsort.for
Subroutine to sort the quantities according to the receivers, and at each receiver according to the increasing travel time.
crtray.for
Program converting the unformatted output of program CRT into formatted files with rays suitable for plotting.
crtpts.for
Program converting the unformatted output of program CRT into formatted file with endpoints of rays.
green.for
Program to convert the unformatted output of program CRT into a formatted file containing the ray-theory elastodynamic Green function.
wan.for
Subroutines to compute quantities along a ray necessary for computation of the Green function by means of coupling ray-theory in weakly anisotropic models without interfaces. Called by 'green.for'.
greenss.for
Program to read a formatted file containing the ray-theory elastodynamic Green function and to generate ray-theory time-domain synthetic seismograms (without attenuation) or frequency-domain response functions (including causal Futterman's attenuation).
rm.for
Interface between program 'greenss.for' and package RMATRIX.
rmnul.for
File containing void versions of two subroutines called by program 'greenss.for'.
inv1tt.for
Program designed to evaluate the derivatives of the travel time with respect to the model coefficients.
crtcart.for
Program to convert the rays calculated by program CRT from curvilinear to Cartesian coordinates, which are required by 'mtt.for'.
(E) Demo files:
crt.h
Sample main input data for the CRT program in the form of a history file. This data file refers, among others, sample data file 'model.dat' of the MODEL specification package, which has therefore to be located in the current directory.
crt.dat
Additional input data file for the CRT program, with the numerical parameters for the complete ray tracing.
len-src.dat
Additional input data file for the CRT program, specifying the position of the point source.
code.dat
Data specifying only the refracted wave.
code2.dat
Additional input data file for the CRT program, specifying the codes of 3 elementary waves (2 reflected).
rpar.dat
Additional input data file for the CRT program, specifying the take-off parameters of the computed rays.
writ.dat
Additional input data file for the CRT program, with names of the output files. Whole two-point rays are stored in files corresponding to individual elementary waves and the points of intersection with given surfaces are stored in files corresponding to individual surfaces.
writall.dat
Alternative data file specifying the names of the output files. All whole rays are stored, not only two-point rays.
writsrf.dat
Alternative data file specifying the names of the output files. No whole rays are stored. The points of intersection with given surfaces are stored in files corresponding to individual surfaces.
writnul.dat
Alternative data file specifying the names of the output files. Nothing is written.
source.dat
Sample main input data for the GREENSS program to specify the point source (moment-tensor or single-force seismic source).
sourcex.dat
Data specifying the seismic moment tensor of an explosive source (extracted from examples in 'source.dat').
srpcrt.pl
Perl script to generate coordinates of the source and receiver points for given configuration parameters, perform two-point ray tracing, and convert unformatted output into a simple formatted file. It runs programs 'srp', 'crt' and 'crtpts'.
fcrt.pl
Perl script to compile the CRT package by means of predefined script 'f.pl' compiling and linking a single Fortran 77 source code file.
(F) Subdirectories with data files related to particular models:
len
Model with a lenticular inclusion. Examples for programs crt.for, rpplott.for, intf.for(MODEL), crtpts.for, mtt.for, mttgrd.for(MODEL) and grdps.for(MODEL).
VRML97 view of rays and interfaces
prem
PREM (Preliminary Reference Earth Model) specified in geographical spherical coordinates. Input data for the complete ray tracing in spherical coordinates. Example for program crt.for in spherical coordinates.
elf1
Homogeneous layers separated by dipping plane interfaces (model MI). Examples for programs srp.for(MODEL), crt.for and crtpts.for.
u2d
2-D model UNCONFORMITY (Cormier and Mellen 1984). Examples for programs crt.for, green.for, greenss.for, ss.for(FORMS), sp.for(FORMS) and also inv1tt.for.
rm
Model RM to test version GREENRM of program GREENSS against 2-D finite differences. 1-D model RM consists of a thin homogeneous low-velocity layer covering homogeneous halfspace.
qi
Anisotropic model QI for comparison of synthetic seismograms with package ANRAY.
98
A sample synthetic model created during the technical session of the SW3D consortium meeting in June 1998.
VRML97 view of interfaces
VRML97 view of P-wave velocities
VRML97 view of rays and interfaces
tc
Analytical plane-wave solutions in 1-D anisotropic "twisted crystal" model. Comparison with the results of package CRT and and with the exact solution.