Description Usage Arguments Details Value Examples
This function produces unit vectors for use in programs such as varsim
where a unit vecotr is required to define variogram directions in gridded
data.
1 | unit_vector(azm = 0, dip = 0)
|
azm |
Azimuth in degrees clockwise from north looking down z-axis. |
dip |
Dip in degrees from horizontal, negative down. |
I have validated this function against the examples given in the GSLIB book (2nd ed.) on p.48. All except the last example in the book work. The examples are reproduced here as part of the function docs. I am not sure why this doesn't work for the last example.
For now this function appears robust 2D (azimuth-only) directions and vertical dip.
Numeric unit vector of length three.
1 2 3 4 5 6 7 | unit_vector(90) # Aligned along x-axis.
unit_vector(0) # Aligned along the y-axis.
unit_vector(0,-90) # Aligned along the z-axis.
unit_vector(45) # Horizontal at 45 degrees from y.
unit_vector(135) # Horizontal at 135° from y.
# This one doesn't reproduce the resultin the GSLIB book.
unit_vector(225, -45) # Dipping at -45°, 225° clockwise from y.
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.