Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

MomentDist

Distance Between Moment Tensors


Description

Calculate the distance between moment tensors based on quaternions.

Usage

MomentDist(E1, E2)

Arguments

E1

Moment tensor

E2

Moment tensor

Details

Moment tensors should be right handed.

Value

angle in degrees

Author(s)

Jonathan M. Lees<jonathan.lees@unc.edu>

References

Tape and Tape, 2012

See Also

forcerighthand, testrightHAND

Examples

Mtens = c(-0.412, 0.084, 0.328 ,0.398, -1.239, 1.058)
M1 = matrix(c(Mtens[1], Mtens[4], Mtens[5], Mtens[4], Mtens[2],
Mtens[6], Mtens[5],Mtens[6], Mtens[3]), ncol=3, nrow=3, byrow=TRUE)



Mtens = c(5.054, -2.235, -2.819, -0.476, 5.420, 5.594)
M2 = matrix(c(Mtens[1], Mtens[4], Mtens[5], Mtens[4], Mtens[2],
Mtens[6], Mtens[5],Mtens[6], Mtens[3]), ncol=3, nrow=3, byrow=TRUE)

E1 = eigen(M1)

###  make sure these are a right handed system,
###   ie x1 cross x2 = x3


E2 = eigen(M2)

###  make sure these are a right handed system,
###   ie x1 cross x2 = x3
testrightHAND(E1$vectors) 
testrightHAND(E2$vectors) 

E1$vectors = forcerighthand(E1$vectors)

E2$vectors = forcerighthand(E2$vectors)


testrightHAND(E1$vectors) 
testrightHAND(E2$vectors) 

MomentDist(E1, E2)

RFOC

Graphics for Spherical Distributions and Earthquake Focal Mechanisms

v3.4-6
GPL (>= 2)
Authors
Jonathan M. Lees [aut, cre], Keehoon Kim [ctb]
Initial release
2018-01-17

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.