View source: R/soundbeam.TSD.R
soundbeam.TSD | R Documentation |
Calculates the midpoints (or edges along the beams, depending on 'rpos') of the voxels of a sonar or an echo sounder, relative to a global coordinate system (usually centered on the sea surface at the first vessel position, with y-axis pointing north and vertical z-axis). Only the heading is considered, as the pitch and roll of the vessel is compensated for by the sonar. If positions are wanted in the coodinate system of the vessel, set 'data' to c(list(psxv=0,psyv=0,pszv=0,rtxv=0,rtyv=0,rtzv=0,psze=0),data). If pitch and/or roll are not compensated for by the sonar, the function has to be altered. The funciton can treat multiple time steps, but not for systems with changing beam configuration between pings, for which the function needs to be run at each separate time step, inputting the beam configuration of one time step at the time (not matrices for variables such as the elevation angle of the direction of the beams 'dire').
soundbeam.TSD(
data,
t = 1,
ind = NULL,
cs = "g",
seabed = -12000,
rot = 1,
compensation = c("pitch", "roll"),
ideal = TRUE,
rpos = c("midp", "edge"),
drop.out = TRUE,
plot = FALSE,
...
)
data |
is the list of TSD inputs as returned from read.TSD (must contain "psxv", "psyv", "rtzv", "lenb", "numb", "sint", "psze", ("dira","dirl") or ("dire", "dirt"), "asps"). |
t |
is a single integer giving the time step to treat (in the range [1,number of pings]). |
cs |
is the coordinate system of the voxel midpoints or edges of the voxels. |
seabed |
is the z-coordinate of the sea bed, usually provided by echo sounder data. Soundbeams reflected from the sea bed or the surface are reflected at the incidence angle. |
rot |
is 1 if simple rotation using cosine and sine is to be used, and 2 if the function rotate() is to be used in the rotation. Times for the different methods (tested on MacBook Pro dual 2.8 GHz, 2010-02-09, with other applications running): |
compensation |
is a vector of string giving which rotation values that are compensated for in the sonar. Only c("pitch","roll") is available for the current version. Used in soundbeam.TSD. |
ideal |
is TRUE to represent the simple case where the speed of sound 'data$asps' is invariant of depth. |
rpos |
is a string of two possible values: "midpoint" which specifies that the positions alont the beams are to bo located at midpoints of voxels and "edge" which returns the edges of the voxels including the first edge on the surface of the sonar (length of output is lenb+1 in this case). Abbreviation are allowed. |
drop.out |
is TRUE if output should be stripped of dimensions of only one level. |
plot |
is TRUE if the plot produced by soundbeam() is to be shown (slows down the calculation). |
... |
allowing for argument passed to tjie function. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.