0

Can someone explain me these lines of python code, and the role of each line ?

thank you in advance.

X_f = abs(sf.fft(x))
l = np.size(x)
fr = (Fs/2)*np.linspace(0.1, l/2)
xl_m = (2/l)*abs(X_f[0:np.size(fr)]);
  • Can I suggest you add what you already know, and what you're confused/unsure about? Is there some part of the syntax you don't understand, or is it the math you don't understand? – joanis Mar 10 '21 at 13:24
  • Yes, the mathematical part I did not understand well. – Chamseddine Mar 10 '21 at 14:01
  • Then maybe this question would be more suitable for https://math.stackexchange.com/? – joanis Mar 10 '21 at 16:49
  • I have no idea if this question is relevant, but I found it searching "fft stackexchange", and it pointed me to math.SE: https://math.stackexchange.com/q/1915097/524164 Searching for "fft" or "spectral analysis" yield a lot of hits on math.SE. – joanis Mar 10 '21 at 16:51

0 Answers0