|
SoDaRadio-5.0.3-master:8901fb5
|
In several places we have a real valued signal x(t) that needs to be converted to an analytic signal g(t) such that real(g(t)) == x(t) and imag(g(t)) = shift_by_90degrees(x(t));. More...
#include <HilbertTransformer.hxx>
Public Member Functions | |
| HilbertTransformer (unsigned int inout_buffer_length, unsigned int filter_length=256) | |
| constructor – build a Hilbert Transformer More... | |
| unsigned int | applyIQ (std::complex< float > *inbuf, std::complex< float > *outbuf, float gain=1.0) |
| Perform a hilbert transform on the QUADRATURE signal in the input buffer. More... | |
| unsigned int | apply (std::complex< float > *inbuf, std::complex< float > *outbuf, bool pos_sided=true, float gain=1.0) |
| Perform a hilbert transform on the INPHASE signal in the input buffer. More... | |
| unsigned int | apply (float *inbuf, std::complex< float > *outbuf, bool pos_sided=true, float gain=1.0) |
| Perform a hilbert transform on the signal in the floating point input buffer. More... | |
| std::ostream & | dump (std::ostream &os) |
Public Member Functions inherited from SoDa::SoDaBase | |
| SoDaBase (const std::string &oname) | |
| The constructor – pass a name for the object. More... | |
| std::string & | getObjName () |
| get the name of this object More... | |
| SoDaBase * | findSoDaObject (const std::string &oname) |
| find a SoDa Object by name. More... | |
| double | getTime () |
| Get a time stamp in nS resolution that monotonically increases and that is very inexpensive (typically < 100nS). More... | |
Private Attributes | |
| unsigned int | M |
| these are the salient dimensions for this Overlap/Save widget (for terminology, see Lyons pages 719ff More... | |
| unsigned int | Q |
| the filter length More... | |
| unsigned int | N |
| the total length of the transform N > (M + Q-1) More... | |
| std::complex< float > * | fft_I_input |
| std::complex< float > * | fft_Q_input |
| std::complex< float > * | fft_I_output |
| std::complex< float > * | fft_Q_output |
| std::complex< float > * | ifft_I_input |
| std::complex< float > * | ifft_Q_input |
| std::complex< float > * | ifft_I_output |
| std::complex< float > * | ifft_Q_output |
| fftwf_plan | forward_I_plan |
| fftwf_plan | forward_Q_plan |
| fftwf_plan | backward_I_plan |
| fftwf_plan | backward_Q_plan |
| std::complex< float > * | HTu_filter |
| The DFT image of the hilbert transform – upper sideband. More... | |
| std::complex< float > * | HTl_filter |
| The DFT image of the hilbert transform – lower sideband. More... | |
| std::complex< float > * | Pass_U_filter |
| The DFT image of a Q/2 delay transform – used in USB. More... | |
| std::complex< float > * | Pass_L_filter |
| The DFT image of a Q/2 delay transform – used in LSB. More... | |
| float | passthrough_gain |
| the gain of the direct passthrough path. More... | |
| float | H_transform_gain |
| the gain of the Hilbert Transform path More... | |
In several places we have a real valued signal x(t) that needs to be converted to an analytic signal g(t) such that real(g(t)) == x(t) and imag(g(t)) = shift_by_90degrees(x(t));.
HilbertTransformer provides the apply functions to convert x(t) as a float or complex<float>. Hilbert Transformer also provides a function (applyIQ) to convert a complex x(t) into g(t) such that real(g(t)) = real(x(t + tau)) and imag(g(t)) = shift_by_90deg(imag(x(t + tau)))
Definition at line 54 of file HilbertTransformer.hxx.
| SoDa::HilbertTransformer::HilbertTransformer | ( | unsigned int | inout_buffer_length, |
| unsigned int | filter_length = 256 |
||
| ) |
constructor – build a Hilbert Transformer
| inout_buffer_length | the length of the input and output buffers |
| filter_length | the minimum length of the hilbert transform impulse response |
Definition at line 52 of file HilbertTransformer.cxx.
References backward_I_plan, backward_Q_plan, fft_I_input, fft_I_output, fft_Q_input, fft_Q_output, forward_I_plan, forward_Q_plan, H_transform_gain, HTl_filter, HTu_filter, ifft_I_input, ifft_I_output, ifft_Q_input, ifft_Q_output, M, N, Pass_L_filter, Pass_U_filter, passthrough_gain, and Q.
| unsigned int SoDa::HilbertTransformer::apply | ( | std::complex< float > * | inbuf, |
| std::complex< float > * | outbuf, | ||
| bool | pos_sided = true, |
||
| float | gain = 1.0 |
||
| ) |
Perform a hilbert transform on the INPHASE signal in the input buffer.
It is assumed that the QUADRATURE signal is zero, if not, the result is broken.
| inbuf | complex input buffer of I (real) and Q (imag) samples |
| outbuf | complex output buffer real is input.real delayed, and imag is Hilbert(input.real) |
| pos_sided | if true, swap I and Q outputs |
| gain | factor to apply to output buffer. |
Definition at line 205 of file HilbertTransformer.cxx.
References backward_I_plan, backward_Q_plan, dbgctr, fft_I_input, fft_I_output, forward_I_plan, H_transform_gain, HTl_filter, HTu_filter, ifft_I_input, ifft_I_output, ifft_Q_input, ifft_Q_output, M, N, Pass_L_filter, Pass_U_filter, passthrough_gain, and Q.
Referenced by apply(), doPMTest(), doSSBTest(), dumpTest(), and SoDa::BaseBandTX::modulateAM().
| unsigned int SoDa::HilbertTransformer::apply | ( | float * | inbuf, |
| std::complex< float > * | outbuf, | ||
| bool | pos_sided = true, |
||
| float | gain = 1.0 |
||
| ) |
Perform a hilbert transform on the signal in the floating point input buffer.
| inbuf | input buffer of real (float) samples |
| outbuf | complex output buffer real is input delayed, and imag is Hilbert(input) |
| pos_sided | if true, swap I and Q outputs |
| gain | factor to apply to output buffer. |
Definition at line 259 of file HilbertTransformer.cxx.
| unsigned int SoDa::HilbertTransformer::applyIQ | ( | std::complex< float > * | inbuf, |
| std::complex< float > * | outbuf, | ||
| float | gain = 1.0 |
||
| ) |
Perform a hilbert transform on the QUADRATURE signal in the input buffer.
Pass the Inphase signal through a delay filter that matches the hilbert transform
| inbuf | complex input buffer of I (real) and Q (imag) samples |
| outbuf | complex output buffer real is input.real delayed, and imag is Hilbert(input.imag) |
| gain | factor to apply to output buffer. |
Definition at line 284 of file HilbertTransformer.cxx.
References backward_I_plan, backward_Q_plan, dbgctr, fft_I_input, fft_I_output, fft_Q_input, fft_Q_output, forward_I_plan, forward_Q_plan, H_transform_gain, HTu_filter, ifft_I_input, ifft_I_output, ifft_Q_input, ifft_Q_output, M, N, Pass_U_filter, passthrough_gain, and Q.
Referenced by SoDa::BaseBandRX::demodulateSSB(), doSSBTest(), and dumpTest().
| std::ostream & SoDa::HilbertTransformer::dump | ( | std::ostream & | os | ) |
Definition at line 337 of file HilbertTransformer.cxx.
References HTl_filter, HTu_filter, N, Pass_L_filter, and Pass_U_filter.
|
private |
Definition at line 115 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
Definition at line 115 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
Definition at line 108 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
Definition at line 109 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
Definition at line 108 of file HilbertTransformer.hxx.
Referenced by applyIQ(), and HilbertTransformer().
|
private |
Definition at line 109 of file HilbertTransformer.hxx.
Referenced by applyIQ(), and HilbertTransformer().
|
private |
Definition at line 115 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
Definition at line 115 of file HilbertTransformer.hxx.
Referenced by applyIQ(), and HilbertTransformer().
|
private |
the gain of the Hilbert Transform path
Definition at line 123 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
The DFT image of the hilbert transform – lower sideband.
Definition at line 118 of file HilbertTransformer.hxx.
Referenced by apply(), dump(), and HilbertTransformer().
|
private |
The DFT image of the hilbert transform – upper sideband.
Definition at line 117 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), dump(), and HilbertTransformer().
|
private |
Definition at line 110 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
Definition at line 111 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
Definition at line 110 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
Definition at line 111 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
these are the salient dimensions for this Overlap/Save widget (for terminology, see Lyons pages 719ff
the input buffer length;
Definition at line 103 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
the total length of the transform N > (M + Q-1)
Definition at line 105 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), dump(), and HilbertTransformer().
|
private |
The DFT image of a Q/2 delay transform – used in LSB.
Definition at line 120 of file HilbertTransformer.hxx.
Referenced by apply(), dump(), and HilbertTransformer().
|
private |
The DFT image of a Q/2 delay transform – used in USB.
Definition at line 119 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), dump(), and HilbertTransformer().
|
private |
the gain of the direct passthrough path.
Definition at line 122 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
|
private |
the filter length
Definition at line 104 of file HilbertTransformer.hxx.
Referenced by apply(), applyIQ(), and HilbertTransformer().
1.8.13