16

Basics The amplitude of an IQ signal is just the vector magnitude, $\sqrt{I^2 + Q^2}$. The power of an IQ signal is the squared magnitude, $I^2 + Q^2$. When you see a logarithmic (dB) meter, it is usually measuring the log of the power, i.e. $10 \log_{10}(I^2 + Q^2)$. (This can also be calculated as $20 \log_{10}$ of the amplitude, but unless you already ...


8

Creating the Frequency Vector The arrangement of the output of fft() depends on whether you use an odd or even number of points for your fft. I think this post nicely summarises how the frequencies are arranged. Have a look at it. Since you are using an even number of points, the Nyquist frequency, $F_N = F_s/2$, is present in the output of your fft, and ...


7

if the two audio signals are totally uncorrelated, the the squares of the two crossfade gains should add to 1. so, to prevent that dip, your crossfade function will look more like $\sqrt{\frac{1}{2}(1+t)}$ and $\sqrt{\frac{1}{2}(1-t)}$ rather than $\frac{1}{2}(1+t)$ and $\frac{1}{2}(1-t)$ for $-1 \le t \le +1$. note, for constant power crossfades, at the ...


7

An exponentially decaying envelope $a\exp(-b x)$ is a good choice, and is used for example in vintage Yamaha FM synthesizers. It has the favorable property that over any constant length time interval, by the end of the interval the envelope has decayed to a constant fraction of what it was at the beginning of the interval. Damped oscillation (with some ...


6

Your code is bit unclear, especially generation of your signal. Python allows for vectorized operations so it is good to use it. What's more, it is good to clearly specify the sampling frequency of your signal and use it then. Also please remember to normalize your FFT by length of your signal (in this particular case) and multiply by 2 (half of spectrum is ...


5

The correct way to group multiple bins together is to multiply each complex fft bin output by its complex conjugate (which gives the bin power) then add all the bin powers together and divide by the number of bins in the group. If you want to display in db (which is the conventional approach) then take 10*log10() of the result. Negative db values are normal ...


5

That depends to a very large degree on the type & sensitivity on the headset, the gain of the amplifier and the frequency. I don't think there is a reasonable rule of thumb, this will be all over the place.


5

Without an artificial ear and calibrated SPL meter your not going to obtain a valid measurement (even then the SPL will vary per earphone fitting). With earphones and a multimeter, you can only really ballpark the measurement e.g. output a full scale tone, and measure the voltage at the terminals (should be OK to do this by parallel output of the playback ...


5

Both amplitude and frequency modulated radio signals nowadays use quadrature modulation and demodulation as a mean to transfer and receive radio signals. This question is ill-defined – a signal doesn't use quadrature modulation/demodulation, transmitters/receivers do. So, your question is, if we try to "rescue" it, is Do modern FM receivers/...


4

Suppose that we have a continuous-time periodic signal $\displaystyle s(t) = a_0 + \sum_{n=1}^N a_n \cos(n\omega_0 t + \theta_n)$. What does this mean? Do we have a trace of $s(t)$ on some recorder chart and the trace looks periodic? If we did, the question to be solved would be trivial since we could simply measure the maximum and minimum values of $s(t)$...


4

Generally, the frequency estimation problem decouples from the amplitude + phase estimation problem. As I said in the comments, you could just do: $$ \hat{A} = \left|\sum_{n=0}^{N-1} x_n e^{-j 2\pi\hat{f} n} \right| $$ where $\hat{f}$ is your frequency estimate. Regarding your issues: because the number of points isn't high enough to hit the right ...


4

The usual way to estimate the amplitude of a particular frequency is to use the Goertzel algorithm. There is a good write-up by Rick Lyons here. Even though Rick's writeup is about single tone detection, it can be applied when multiple tones are present, too.


4

Not really, as the transform is real. However, one could interpret the sign as a poor man's phase, being "quantized" or restricted to values $0$ or $\pi$. In other words, $1 = 1.e^{0.\imath}$ and $-1 = 1.e^{\pi.\imath}$. [EDIT] There are some instances where people use the sign of DCT or (real) wavelet coefficients, for subpixel image registration or ...


4

A DCT is equivalent to a DFT of real data that is doubled and mirrored, thus rendering it symmetric. The DFT of any symmetric real signal has a phase of zero (its all cosines, no antisymmetric sine components).


4

Know that each bin in the FFT is the value for the exponential $e^{j\omega t}$, not sine or cosine. So for the OP's case $5sin(2\pi 3 x-2)$ in terms of exponentials (see Euler's identity) this is: $$\frac{5}{2j}e^{j(6\pi x -2)} - \frac{5}{2j}e^{-j(6\pi x -2)}$$ Each is a DFT bin with that magnitude and phase given by the exponentials above, as long as ...


3

In $2^{2n}$-QAM with a square constellation, there are $4$ "corner" points and $4(2^n-2)$ "edge" points, and $(2^n-2)^2$ "interior" points. The conditional symbol error probabilities given that each type of point is transmitted, are $$\begin{align} P_e(\text{corner}) &= 2Q(x) - Q^2(x)\\ P_e(\text{edge}) &= 3Q(x) - 2Q^2(x)\\ P_e(\text{interior}) &...


3

This is a continuation of the (music-dsp) thread started by Element Green titled: "Algorithms for finding seamless loops in audio" As far as I know, it is not published anywhere, although I have recently been informed that a similarly-themed paper by Marco Fink, Martin Holters, and Udo Zölzer has been presented at the 2016 DAFx conference, which is a while ...


3

Maybe you have a look at Goertzels Algorithm.


3

As people in the other answer have been asking for a code snippet (and as I don't have enough reputation to comment on answers), here's the other answer implemented in C# (which should be easy enough to convert to other languages) /* returns a float array with two indexes representing the volumes of the left (index 0) and right (index 1) channels when t is -...


3

The antenna does not do Fourier analysis and has no idea that there is a carrier signal and an upper sideband and lower sideband. Whatever the signal applied to the antenna via electrical wiring or coax cable or transmission line, the flow of current in the antenna causes an electromagnetic wave (coupled time-varying electrical and magnetic fields) to be ...


3

Regarding your Edit #2: It is not true that phase estimation requires that frequency be at a bin center. However if a frequency estimate requires interpolation between FFT result bins, so does any phase estimation at that frequency estimate. Using a Sinc interpolation kernel on the complex FFT results, plus successive approximation for the magnitude peak,...


3

Try adding a gain of 16 before your low pass filter, or equivalently using a low pass filter with a passband gain of 16 instead of 1.


3

That's correct, $0.4053$ is the approximate magnitude of the frequency response of linear interpolation at the Nyquist frequency. With the definition: $$\operatorname{sinc}(x) = \frac{\sin(\pi x)}{\pi x}$$ the exact value is: $$\operatorname{sinc}^2\left(\frac{1}{2}\right)= \left(\frac{\sin\left(\frac{\pi}{2}\right)}{\frac{\pi}{2}}\right)^2 = \left(\frac{...


3

There is no issue of frequency resolution in a typical modulation and demodulation scheme. (unless you want to implement some frequency/signal detectors) Putting two message signals in adjacent channels requires that their spectrums do not overlap. In your case you should be able to specify the associated bandwidths of those two slowly changing analogue ...


3

I'm wondering how can i get the frequency and the amplitude from a 16 bits sample That makes no sense. A single sample is just a number. A number doesn't have a frequency. The number itself is the amplitude.


3

To extract only the carrier with a band-pass filter, the filter pass-band has to be narrower than the modulating frequencies, or else some of the envelope modulation will "leak" through the filter. Also note that a very narrow filter has a long settling time, so you will need a long enough test signal.


3

To a first approximation, a plucked string has an exponential decay, so your envelope will look like $$x(t) = a \exp -bt.$$ The physical explanation for this is simple: when you pluck the string, you put a certain amount of energy into the system. Over time, energy is lost. At any given time, the amount of energy lost is proportional to the amount of energy ...


3

First, 0.3dB is generally considered small potatoes in signal processing. Second, the documentation for scipy.signal.decimate states that it uses an 8th-order Chebychev filter by default (without specifying the ripple, dangit!). Chebychev filters have some ripple in the passband; if the bulk of your signal's energy is falling into the troughs of the ripple,...


3

Below is the analytic result for both the actual max value of $0.901243$ and the maximum value found by the OP of $0.898464$ The reason you are not getting the predicted maximum is your samples of the sine wave are not located exactly at the peak. This is clear if you zoom in on the plot and compare the two peak locations for the number of samples given (as ...


2

Consider your carrier signal as $E_c\cos W_{ct}$ and your message signal is $E_m \cos W_{mt}$. The double side band plus carrier signal is, $ E_c\cos(W_{ct})+(E_c\cos(W_{ct})E_m\cos(W_{mt})) $ $ E_c\cos(W_{ct})+\frac{1}{2}(E_cE_m[\cos(W_{ct}+W_{mt})+\cos(W_{ct}-W_{mt})]) $ $ Ec*Cos(W_{ct})+\frac{1}{2}E_cE_m\cos(W_{ct}+W_{mt})+\frac{1}{2}*Ec*Em*Cos(W_{ct}...


Only top voted, non community-wiki answers of a minimum length are eligible