Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarifying the definition of spectral ratio in mt_deconvolve #35

Open
ebeauce opened this issue Jul 5, 2021 · 0 comments
Open

Clarifying the definition of spectral ratio in mt_deconvolve #35

ebeauce opened this issue Jul 5, 2021 · 0 comments

Comments

@ebeauce
Copy link

ebeauce commented Jul 5, 2021

Hi,

Thank you for providing this great library that really helps study earthquake source properties. While you state clearly in the doc string of mtspec that the "spectrum" is the PSD, the definition of "spectral_ratio" returned by the mt_deconvolve function is not stated, which can lead to quite bad mistakes in analyses.

The word "spectrum" is a confusing word as people freely use it to talk about different physical quantities. The documentation says that "spectral_ratio" is the ratio of the two spectra, and says that "spectrum_a" and "spectrum_b" are the spectra of the time series a and b, respectively. However, a simple test can show that spectrum_a/spectrum_b does not give spectral_ratio, instead it is equal to the square root of that: sqrt(spectrum_a/spectrum_b). I believe that this is the desired behavior for spectral_ratio, as what we want is the ratio between the Fourier transform of the two source terms, and not the ratio between the PSD of the two source terms. But this is in complete contradiction with the definition of "spectrum" used for "spectrum_a" and "spectrum_b", and given in the rest of the library.

I suggest to explicitly say in the docstring of mt_deconvolve that "spectrum_a" and "spectrum_b" are PSDs, whereas "spectral_ratio" is the ratio of the two moduli of the Fourier transforms (or anything that would clarify this).

Thanks!

Eric

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant