Rvelslant {Rvelslant} | R Documentation |
The function Rvelslant
is the main function for analyzing
downhole seismic data and interpreting layered velocity models.
The travel time at depth z is given by the equation:
sum(n_i * h_i * s_i) = tt_z
for i = 1, 2, ..., N where h_i is layer thickness, s_i is the layer slowness (v = 1/s), and n_i is the number of transits of each layer (1 for all layers above the measurement depth z, 0 for all layers below). When refracted waves are considered, h_i is adjusted to be the length of the raypath in each layer according to Snell's law, then:
The slowness, s_i for i = 1, 2, ..., N, of each layer, is calculated by
A = sum(n_i * h_i * s_i)
and
s_i = (A'A)^(-1) * A' * tt_z
Two-point ray-tracing is calculated with the function path4sl
which is based on the FORTRAN subroutine path4sl
by:
David Boore <boore@usgs.gov>
U.S. Geological Survey
Mail Stop 977
345 Middlefield Road
Menlo Park, CA 94025 USA
Rvelslant(data, snell = TRUE, bot = NULL, auto = FALSE, cex = 1, nticks = NULL, grid = FALSE, depth = "v", profile = "slow")
data |
a list containing the following elements:
|
snell |
logical value for calculating the raypath according
to Snell's Law, defaults is TRUE. If snell == FALSE , then
the raypath is approximated by a slanted line and the inversion is
much faster. |
bot |
an optional array (length = n) of depth to layer interfaces for the starting model. If not provided, then the initial model is a single layer extending from the surface to the depth of the last measurement. |
auto |
logical value for if the depths to boundaries should be autopicked for initial model. Default is TRUE |
cex |
see par function in R package ‘graphics’. |
nticks |
approximate number of tick marks desired for depth-axis
on travel-time plots. See pretty function in R package
‘base’. |
grid |
logical value for plotting grid lines on travel-time plots. |
depth |
layout of plots. Value can be ‘v’ for vertical or ‘h’ for horizontal orientation of the depth-axis on travel-time plots. |
profile |
defaults to ‘slow’ for plotting the slowness profile with the travel-times and residuals. Any other value, i.e. ‘vel’ will plot the velocity profile instead. |
a list containing model info and original data. The specific elements of the list are:
A |
A = sum(n_i * h_i * s_i) |
s |
array containing the slowness of each layer (length = n). |
v |
array containing the velocity of each layer (length = n). |
n |
integer number of layers in the velocity model. |
k |
number of travel-time measurements. |
h |
array of thicknesses of each layer (length = n). |
bot |
array of depth to bottoms of each layer (length = n). |
tt |
array of observed travel-time arrivals (length = k). |
z |
array of depths of each travel-time measurement, in meters (length = k). |
hoffset |
horizontal offset at the surface from the borehole. |
N |
k by n matrix of transits. |
theta |
k by n matrix of angles of incidence when
snell == TRUE . Otherwise defaults to 0. |
LM.tt |
array of predicted travel-times (length = k). |
wt |
array of weights used in the regression (length = k). Defaults to 1 if sig is unspecified. Calculated as 1/sig^2 |
sig |
array of the standard deviation of the travel-time measurements normalized to the standard deviation of the best pick (length = k). |
se |
array of standard error of slowness for each layer (length = n). Used to calculate the upper and lower bounds in the velocity model. |
sigma.hat |
sqrt(sum(res^2*wt)/(k-n)) |
v.upper |
array of layer velocities corresponding to s_i - se_i (length = n). |
v.lower |
array of layer velocities corresponding to s_i + se_i (length = n). |
tt.slant |
array of observed travel-time measurements (length = k). |
snell |
logical value for if the Snell's Law raypaths should be used. If FALSE, then raypaths are assumed to be straight lines from source to receiver. |
Eric M. Thompson <eric.thompson@tufts.edu>
Boore, D. M. (2003) A compendium of p- and s-wave velocities from surface-to-borehole logging: Summary and reanalysis of previously published data and analysis of unpublished data U.S. Geological Survey Open-File Report 03-191.
Faraway, J. J. (2005) Linear Models with R Chapman & Hall/CRC.
# Load table of Dave Boore's downhole seismic data: data(tt.s) # S-wave arrivals # Select hole code 293: f <- tt.s$hole.code == 293 example <- tt.s[f, ] data <- list(tt.slant = example$tt.slant, hoffset = example$hoffset[1], z = example$z, sig = example$sig, hole.code = 293) # If Using the Windows GUI, it is best to uncheck the 'Buffered output' # option in the Misc pull-down menu. This will allow you to see the # outputs to the console as they occur rather than all at once at the # end. # The command to calculate the layered model is: mod1 <- Rvelslant(data) # The default is to use depth on the vertical axis. However, if you # prefer depth to be displayed on the horizontal axis, use: mod1 <- Rvelslant(data, depth = "h") ##################################################### # Notes: # You can select layer boundaries by clicking on the # travel-time or residual plots. You can remove a # boundary by left clicking on it in the velocity # profile plot. # Right-click anywhere once your have found a model # that you want to save. # -> In WINDOWS must select 'stop' after right-click # -> In MAC OS, can use ESC key instead if you don't # have a second mouse button. # The layered model depth to bottom, thickness, and # velocity will be printed to the terminal. # The default is to calculate the refracted ray path # according to Snell's law and iteratively update # the velocity mode. To override this, and do the # inversion assuming the raypaths are straight lines # from source to receiver, use: mod2 <- Rvelslant(data, snell = FALSE, ntick = 10, grid = TRUE) # To use the auto picker: mod3 <- Rvelslant(data, auto = TRUE) # To manually enter layer interfaces: mod4 <- Rvelslant(data, bot = c(6.2, 9.5, 14.5, 29.5, 47, 54.5, 74.5, 89.5)) # To view the profiles, type: velprofile(mod1) velprofile(mod2, col = "green") # If you have more than one model and you want to compare the profiles: velprofile(mod1, col = "black") velprofile(mod2, add = TRUE, col = "red") velprofile(mod3, add = TRUE, col = "blue") # To view the fit of travel-times and the residuals: par(mfrow = c(1, 2)) plotmod(mod1) plotresid(mod1) # To save the model to a file writemod(mod1, prefix = "hc293")