PyREx

pyrex.Signal.filter_frequencies

Signal.filter_frequencies(freq_response, force_real=False)

Apply the given frequency response function to the signal, in-place.

For the given response function, multiplies the response into the frequency domain of the signal. If the filtered signal is forced to be real, the positive-frequency response is mirrored into the negative frequencies by complex conjugation.

Parameters
freq_responsefunction

Response function taking a frequency (or array of frequencies) and returning the corresponding complex gain(s).

force_realboolean, optional

If True, complex conjugation is used on the positive-frequency response to force the filtered signal to be real-valued. Otherwise the frequency response is left alone and any imaginary parts of the filtered signal are thrown out.

Warns
Raises a warning if the maximum value of the imaginary part of the
filtered signal was greater than 1e-5 times the maximum value of the
real part, indicating that there was significant signal lost when
discarding the imaginary part.

PyREx

A Python package for simulation of neutrinos and radio antennas in ice. Version 1.10.0

Navigation