# Resolução da DFT e adição de zeros

Neste notebook avaliaremos aspectos de resolução da DFT e da adição de zeros (zero padding).

Notamos que um sinal com $N$ amostras, amostrado a uma taxa $F_s$ {Hz] possuirá um vetor de frequências

\begin{equation}
f_{Hz}^{(k)} = \left\{\frac{0F_{s}}{N}, \ \frac{1F_{s}}{N}, \  \frac{2F_{s}}{N}, \ ... \ \frac{(N-1)F_{s}}{N}\right\}
\end{equation}


```python
# importar as bibliotecas necessárias
import numpy as np # arrays
import matplotlib.pyplot as plt # plots
plt.rcParams.update({'font.size': 14})
import IPython.display as ipd # to play signals
import sounddevice as sd
import soundfile as sf
```

## Vamos criar uma resposta ao impulso ideal

Esta é a resposta ao impulso de um sistema massa-mola (1DOF)

\begin{equation}
h(t) = \frac{A}{\omega_d} \mathrm{e}^{-\zeta \omega_n t} \mathrm{sin}(\omega_d t)
\end{equation}
com $\zeta$ sendo o amortecimento, $\omega_n = 2 \pi f_1$ e $\omega_d = \omega_n\sqrt{1-\zeta^2}$, que possui TF, dada por

\begin{equation}
H(\mathrm{j}\omega) = \frac{A}{\omega_n^2 - \omega^2+ \mathrm{j}2\zeta\omega_n\omega} 
\end{equation}


```python
# Define the sampling rate fs = 100 Hz and total record time T = 5 seconds
Fs=100
T=5 
# time vector
time = np.arange(0, T, 1/Fs) # Ts = 0.01 [s]

# Sinal puro (Fenômeno) - original - h(t) de um S1GL (massa-mola)
A=200
zeta=0.3
wn=2*np.pi*10
wd=np.sqrt(1-zeta**2)*wn
# Impulse response
ht=(A/wd)*np.exp(-zeta*wn*time)*np.sin(wd*time)
# FRF teorica
freq = np.arange(0, Fs, 0.1)

Hw=A/(wn**2 - (2*np.pi*freq)**2+ 1j*2*zeta*wn*(2*np.pi*freq));


plt.figure(figsize=(12,4))
plt.subplot(1,2,1)
plt.title(r'$h(t)$ - (fenômeno original)')
plt.plot(time, ht, '-b', linewidth = 2)
plt.grid(linestyle = '--', which='both')
plt.xlabel('Tempo [s]')
plt.ylabel('Amplitude [-]')
plt.xlim((0, time[-1]))

plt.subplot(1,2,2)
plt.title(r'$|H(j\omega)|$ - (fenômeno original)')
plt.plot(freq, 20*np.log10(np.abs(Hw)), '-b', linewidth = 2)
plt.grid(linestyle = '--', which='both')
plt.xlabel('Frequência [Hz]')
plt.ylabel('Magnitude [dB]')
plt.xlim((0, Fs))
plt.ylim((-80, -20))
plt.tight_layout()
plt.show()
```

## Adicionamos ruído a resposta ao impulso (fenômeno ideal)

Tipicamente, é isso que acontece em uma medição. Ela sempre estará contaminada por ruído em algum grau. O ruído vai ter característica de ruído branco (distribuição normal com média zero e uma variância).


```python
noise = np.random.normal(loc = 0, scale = 0.01, size = len(time))
ht_med = ht+noise
```


```python
plt.figure()
plt.title(r'$h(t)$ - (fenômeno original vs. medido)')
plt.plot(time, ht, '-b', linewidth = 2, label = 'Fenômeno original')
plt.plot(time, ht_med, '-r', linewidth = 1, label = 'Fenômeno medido')
plt.legend(loc = 'upper right')
plt.grid(linestyle = '--', which='both')
plt.xlabel('Tempo [s]')
plt.ylabel('Amplitude [-]')
plt.xlim((0, time[-1]));
```

## Agora podemos investigar a FFT e sua resolução para alguns casos

### 1. Resolução original

"If n is not given, the length of the input along the axis specified by axis is used."

Se n não for dado, to comprimento da entrada (ao longo do eixo especificado) é usado - Em outras palavras, o espectro tem o mesmo número de pontos que o sinal no domínio do tempo.


```python
N = len(ht) # Número de pontos da FFT
Hw_med = np.fft.fft(ht_med)
freq_vec = np.linspace(0, (N-1)*Fs/N, N)
print("Vetor de frequência: {:.2f}, {:.2f}, {:.2f}, ... {:.2f}".format(freq_vec[0], freq_vec[1], freq_vec[2], freq_vec[-1]))
print("Resolução do espectro: {:.2f} [Hz]".format(freq_vec[1]-freq_vec[0]))


plt.figure(figsize=(10,6))
plt.title(r'$|H(j\omega)|$')
plt.plot(freq, 20*np.log10(np.abs(Hw)), '-b', linewidth = 2, label = 'Fenômeno original')
plt.plot(freq_vec, 20*np.log10(np.abs(Hw_med)/Fs), '-r', linewidth = 1, label = 'Fenômeno medido')
plt.legend(loc = 'lower left')
plt.axvline(Fs/2, color='grey',linestyle = '--', linewidth = 4, alpha = 0.4)
plt.grid(linestyle = '--', which='both')
plt.xlabel('Frequência [Hz]')
plt.ylabel('Magnitude [dB]')
plt.xlim((0, Fs))
plt.ylim((-80, -20))
plt.tight_layout()
#plt.savefig('dft_mag_par.pdf')
plt.show()
```

## Cheque o teorema de Parseval


```python
# Domínio do tempo
Et = np.sum(ht_med**2)
# Domínio da frequência
Ef = np.sum(np.abs(Hw_med)**2)

print("A energia no domínio do tempo é {:.2f}".format(Et))
print("A energia no domínio da frequência é {:.2f}".format(Ef/N))
```

    A energia no domínio do tempo é 13.55
    A energia no domínio da frequência é 13.55


### 2. Sinal truncado

Agora vamos truncar $h(t)$. Note que o ruído tende a dominar a resposta ao impulso a partir de $0.4$ [s]

"If n is smaller than the length of the input, the input is cropped."

Se n for menor que que o comprimento do sinal, o sinal será truncado. É indiferente fazer:

a. Truncar o sinal no tempo:
- ht_med_trunc = ht_med[time<=0.4]
- Hw_med_trunc = np.fft.fft(ht_med_trunc)

b. Passar Nt como o segundo argumento da FFT
- Hw_med_trunc = np.fft.fft(ht_med, Nt)


```python
ht_med_trunc = ht_med[time<=0.4]

Nt = len(time[time<=0.4]) # Número de pontos da FFT
# Hw_med_trunc = np.fft.fft(ht_med_trunc) # Tente esta linha depois
Hw_med_trunc = np.fft.fft(ht_med, Nt)
freq_vec_t = np.linspace(0, (Nt-1)*Fs/Nt, Nt)
print("O número de pontos na DFT é {}".format(Nt))
print("Vetor de frequência: {:.2f}, {:.2f}, {:.2f}, ... {:.2f}".format(freq_vec_t[0], freq_vec_t[1],
    freq_vec_t[2], freq_vec_t[-1]))
print("Resolução do espectro: {:.2f} [Hz]".format(freq_vec_t[1]-freq_vec_t[0]))


plt.figure(figsize=(10,6))
plt.title(r'$|H(j\omega)|$ - (fenômeno original)')
plt.plot(freq, 20*np.log10(np.abs(Hw)), '-b', linewidth = 2, label = 'Fenômeno original')
plt.plot(freq_vec_t, 20*np.log10(np.abs(Hw_med_trunc)/Fs), '-r', linewidth = 1, label = 'Fenômeno medido truncado')
plt.legend(loc = 'lower left')
plt.axvline(Fs/2, color='grey',linestyle = '--', linewidth = 4, alpha = 0.4)
plt.grid(linestyle = '--', which='both')
plt.xlabel('Frequência [Hz]')
plt.ylabel('Magnitude [dB]')
plt.xlim((0, Fs/2)) # Extenda até Fs se desejar
plt.ylim((-80, -20))
plt.tight_layout()
plt.show()
```

### 3. Sinal truncado e com zeros no final.

Agora vamos truncar $h(t)$ e adicionar zeros no final. Note que a resolução do espectro no caso anterior diminuiu (maior $\Delta f$).

"If n is larger, the input is padded with zeros."

Se n for maior que que o comprimento do sinal, o sinal será completado com zeros. É indiferente fazer:

a. Truncar o sinal no tempo:
- ht_med_trunc = ht_med[time<=0.4]
- Nt = len(time[time<=0.4]) 
- ht_med_zp = np.concatenate((ht_med_trunc, np.zeros(N-Nt)))
- Hw_med_zp = np.fft.fft(ht_med_zp) # Tente esta linha depois

b. Passar Nt como o segundo argumento da FFT
- Hw_med_zp = np.fft.fft(ht_med_trunc, N)


```python
ht_med_trunc = ht_med[time<=0.4]
Nt = len(time[time<=0.4]) 

ht_med_zp = np.concatenate((ht_med_trunc, np.zeros(N-Nt)))

#Hw_med_zp = np.fft.fft(ht_med_zp) # Tente esta linha depois
Hw_med_zp = np.fft.fft(ht_med_trunc, N)

freq_vec_zp = np.linspace(0, (N-1)*Fs/N, N)
print("O número de pontos na DFT é {}".format(len(ht_med_zp)))
print("Vetor de frequência: {:.2f}, {:.2f}, {:.2f}, ... {:.2f}".format(freq_vec_zp[0], freq_vec_zp[1],
    freq_vec_zp[2], freq_vec_zp[-1]))
print("Resolução do espectro: {:.2f} [Hz]".format(freq_vec_zp[1]-freq_vec_zp[0]))


plt.figure(figsize=(10,6))
plt.title(r'$|H(j\omega)|$ - (fenômeno original)')
plt.plot(freq, 20*np.log10(np.abs(Hw)), '-b', linewidth = 2, label = 'Fenômeno original')
plt.plot(freq_vec_zp, 20*np.log10(np.abs(Hw_med_zp)/Fs), '-r', linewidth = 1, label = 'Fenômeno med. trunc. comp. zeros')
plt.legend(loc = 'lower left')
plt.axvline(Fs/2, color='grey',linestyle = '--', linewidth = 4, alpha = 0.4)
plt.grid(linestyle = '--', which='both')
plt.xlabel('Frequência [Hz]')
plt.ylabel('Magnitude [dB]')
plt.xlim((0, Fs/2)) # Extenda até Fs se desejar
plt.ylim((-80, -20))
plt.tight_layout()
plt.show()
```

## Trabalhando na IFFT

Vamos tratar rapidamente da transformada inversa e recuperar $h(t)$, a partir do espectro do sinal truncado e completado com zeros.


```python
ht_rec = np.fft.ifft(Hw_med_zp) # ifft
N_rec = len(ht_rec) # Número de amostras
t_mrec = (N_rec-1)/Fs # tempo máximo da ifft
time_rec = np.linspace(0, t_mrec, N_rec) # vetor temporal recuperado da ifft

plt.figure()
plt.title(r'$h(t)$ - (fenômeno original vs. IFFT do medido)')
plt.plot(time, ht, '-b', linewidth = 2, label = 'Fenômeno original')
plt.plot(time_rec, ht_rec, '-r', linewidth = 1, label = 'Fenômeno med. trunc. comp. zeros')
plt.legend(loc = 'upper right')
plt.grid(linestyle = '--', which='both')
plt.xlabel('Tempo [s]')
plt.ylabel('Amplitude [-]')
plt.xlim((0, time[-1]));
```

### Inspecione ht_rec

Você vai notar que:

1. O sinal recuperado da IFFT tem uma pequena parte imaginária
2. Você precisa do espectro de $0$ a $F_s$ pra operar a IFFT corretamente.


```python
ht_rec
```




    array([-1.31132980e-02-1.17683641e-17j,  1.56959697e+00+1.99285033e-17j,
            2.13357231e+00-5.46229728e-17j,  1.85113899e+00-4.88498131e-18j,
            1.06820611e+00-4.61120258e-17j,  1.98120119e-01-6.11798383e-18j,
           -4.78505416e-01-1.01804867e-17j, -7.91131898e-01-6.08427302e-18j,
           -7.24098739e-01-1.25559123e-17j, -4.93910808e-01+1.72125087e-17j,
           -1.32704465e-01-2.86079657e-17j,  1.35637166e-01+1.20231820e-17j,
            2.76690411e-01+1.97785491e-17j,  2.95206460e-01+2.44084806e-17j,
            2.02346788e-01-4.89000670e-18j,  7.19680486e-02+1.40362100e-17j,
           -2.26187658e-02+3.60721981e-17j, -9.15255500e-02+3.29928923e-18j,
           -1.17728629e-01-1.42474272e-17j, -8.90958560e-02+3.10673846e-17j,
           -6.63669849e-02-1.38476497e-17j,  1.08737487e-02-3.44088395e-17j,
            4.10848395e-02+6.28770210e-17j,  1.67814858e-02-8.17560688e-18j,
            2.27334309e-02-5.36159096e-17j,  1.33162996e-02+1.80890186e-17j,
            3.74385851e-04-2.27768346e-17j, -2.15409295e-02+3.53391134e-17j,
           -1.72967383e-02+5.21207735e-17j, -1.13996031e-02+5.29818087e-17j,
           -1.35199385e-02-1.39161500e-17j,  1.50149986e-03+5.21023465e-18j,
            9.12087023e-03+8.87078273e-18j,  7.95219739e-04+5.94773069e-18j,
            9.04785179e-03-2.94302101e-17j,  3.30061332e-03+5.12852942e-18j,
           -3.53646761e-03+4.37775093e-18j,  1.09633824e-02-1.38374022e-17j,
           -1.60729782e-04-2.27345293e-17j,  6.31880965e-03-6.46046418e-18j,
           -5.61484240e-03-6.46272429e-18j, -7.56516003e-18-1.83749122e-17j,
            4.08553566e-17-3.68559056e-17j, -1.82583428e-17+6.24486024e-18j,
            3.35206595e-17+8.40763483e-18j, -1.88587252e-17-2.89926379e-18j,
           -5.79546276e-17-2.98434143e-17j, -1.08190408e-17+4.96960086e-18j,
           -1.25896501e-17-6.11476647e-18j, -1.49106554e-18-9.92818376e-18j,
            2.88161769e-17+7.96589131e-18j,  4.07791942e-18+3.56987630e-17j,
            1.01910213e-16-5.53172811e-17j, -4.40581505e-17-4.39485653e-17j,
            3.55951258e-17+3.04973817e-17j,  1.87163541e-17+2.95058533e-18j,
           -9.65959177e-18+2.83841105e-17j, -9.31656225e-18-3.45002176e-17j,
           -1.83245071e-18-9.51735005e-18j, -4.27776378e-17-4.88094961e-18j,
           -2.22613471e-17-2.09692180e-17j, -3.38095603e-17+1.08559595e-17j,
           -7.46894396e-18-4.44822306e-17j, -3.52029539e-17-2.17423740e-17j,
            1.66221545e-17+5.93896478e-17j, -1.96727285e-17-1.76348465e-17j,
            7.33143811e-18+2.22431124e-17j, -5.33127515e-18-9.98554725e-18j,
           -3.01124828e-17+2.40831593e-18j, -9.32144189e-18+4.61400012e-17j,
           -1.09809125e-17+2.85650948e-17j, -1.13707199e-17+2.02535640e-17j,
            2.23989949e-17+4.52872920e-18j,  1.37197862e-17-7.99815414e-18j,
           -6.29709303e-18-4.90238756e-18j, -1.66796250e-17+7.07040514e-18j,
            5.96560982e-17+8.09962525e-18j,  4.99764017e-18-4.72525360e-17j,
           -1.45794778e-17+2.85225747e-17j,  3.06316147e-17-4.32257231e-17j,
            3.09545678e-18-4.65858864e-18j, -2.35056896e-17-4.10247489e-17j,
           -1.07140814e-17-9.84314478e-17j, -7.75068813e-17-7.43542699e-18j,
           -2.30513252e-17+1.09051638e-17j,  4.59827561e-18+3.22289065e-17j,
            1.65299928e-17-3.17367709e-17j,  1.11714071e-17+5.58277295e-18j,
            3.36504771e-17+1.41275231e-17j, -4.67123227e-18-2.69097723e-17j,
           -2.37003436e-17+5.21243902e-17j, -1.84093460e-17-1.46042687e-17j,
           -5.92017233e-18+1.56967264e-17j,  5.24886940e-19+2.22789245e-17j,
           -1.63699644e-17-2.21584655e-17j,  1.83087651e-17+9.58540129e-18j,
            4.91371792e-18-3.33508873e-17j,  8.31986121e-18-1.22609639e-17j,
            1.75778094e-17-2.40311292e-17j,  1.20591088e-17+1.54980838e-17j,
           -1.99972739e-17-1.20733909e-17j, -2.18369662e-16-8.57117196e-17j,
            1.08290384e-16-6.16137416e-17j,  9.52584472e-18+5.77512487e-17j,
           -8.19437290e-17+4.08077208e-17j, -1.00070411e-17+6.54863410e-18j,
            2.36766897e-18+8.70145305e-18j, -5.59903765e-17+8.44475160e-18j,
            8.75795994e-18-1.27988814e-17j,  3.06844216e-18-4.56147158e-18j,
           -9.72973431e-18-6.00300911e-18j,  1.90572750e-17-1.24709948e-17j,
            1.37168287e-17-1.66605566e-17j, -1.88070300e-18-5.03402739e-17j,
            3.80153376e-17-3.89407015e-17j, -3.17009072e-18-3.92600229e-17j,
            7.89081266e-18-1.02893513e-17j, -4.99378010e-17+3.50663243e-18j,
           -1.90060405e-17+4.04414637e-18j, -2.73745707e-17+6.25516616e-18j,
            7.52579198e-18+9.95826180e-18j, -2.52803035e-17-2.21023195e-17j,
           -4.22220589e-18-9.70366092e-18j,  3.01857127e-17+8.35608318e-18j,
            3.03744870e-18-7.95950177e-18j,  5.92779329e-18+2.01899303e-18j,
            4.11166147e-17+1.11050497e-17j, -5.78508559e-17-2.99379529e-17j,
           -3.52498976e-17-8.45401630e-18j, -1.47233890e-17+9.34243931e-18j,
           -1.79090412e-17+9.95975492e-18j, -1.09233966e-17+5.06592966e-18j,
            1.83524026e-17-4.28598853e-17j, -2.77875684e-17+2.81916401e-17j,
           -2.43203834e-17-1.24549078e-17j, -7.28540544e-19+1.87953999e-17j,
            2.98344799e-19-3.39592658e-18j,  1.10901245e-18+1.33090396e-17j,
            4.19794338e-17-3.25933304e-17j, -6.08319649e-18-6.60761441e-18j,
            1.26356141e-18+6.02444484e-19j, -6.76415288e-18+8.89853803e-18j,
           -2.99491088e-17+3.54559026e-17j, -1.98909367e-17-3.96176439e-17j,
            4.01292543e-17+1.84573975e-17j, -1.53610221e-17+4.54968592e-18j,
           -4.13836671e-18-1.03590628e-17j,  4.36088383e-17-7.75545022e-18j,
            9.09515317e-18+1.68049196e-17j, -1.44715993e-17+2.02351159e-17j,
            3.64686331e-18-7.28433695e-18j,  9.75664525e-18-5.32046241e-18j,
           -7.34947937e-17-4.45205233e-17j,  3.15576667e-17-4.51644084e-17j,
           -2.73647413e-17-4.26116131e-18j,  6.74035159e-18+1.14325244e-17j,
            5.98649665e-18-1.06425396e-17j, -2.22824412e-17-4.15310723e-17j,
            1.09182665e-17+4.47905826e-18j,  1.17566970e-17-3.99659543e-17j,
            7.04831945e-18-1.21643967e-17j,  2.77258131e-17-2.59172584e-17j,
           -7.01922235e-17-2.73256121e-18j,  4.67689708e-18-2.30327684e-17j,
            2.57802156e-17+7.61563030e-20j, -3.35458338e-18-7.58356790e-18j,
           -1.25535437e-17+2.00518790e-17j, -1.49217230e-17+1.78015531e-17j,
           -3.20693097e-18+1.56085053e-17j,  3.67069045e-17+2.25644929e-17j,
            3.86069267e-17+1.15646196e-17j, -1.30801627e-17+4.53695540e-17j,
            5.00692134e-17-3.24987795e-19j, -5.03024294e-19-9.24086367e-18j,
            6.20505503e-18-5.41326602e-19j, -2.76364249e-17-5.47995529e-18j,
            4.96336408e-17-7.76648797e-18j, -9.86172900e-17+5.85609492e-17j,
           -4.17193862e-17-3.31837657e-17j,  1.44452463e-17-5.48509588e-18j,
           -3.72549728e-18-1.82543981e-17j,  6.27928341e-17-2.55755885e-17j,
            3.20874193e-17+7.36500057e-17j,  2.52935121e-17-8.03977189e-18j,
            4.91019261e-18-4.43265858e-17j, -2.09126778e-17+3.10250812e-17j,
            5.63706277e-17+5.32110824e-18j,  3.17824052e-17+5.84347817e-17j,
            2.51873732e-17-5.05608236e-17j,  2.40247056e-17-2.81780169e-17j,
           -4.02079849e-18+6.45395020e-18j, -6.21365133e-18-1.87955679e-17j,
           -1.35704087e-17+1.28761546e-17j,  2.29054738e-17+2.46478862e-18j,
            1.49251861e-17+2.23085057e-17j,  5.14575343e-18-2.02522850e-17j,
           -2.81853907e-17-1.38255223e-17j, -2.01367755e-17+1.59685756e-17j,
           -3.51462302e-18-2.68710735e-17j, -2.62135925e-17+2.24695640e-17j,
            5.97089671e-18-1.32696656e-17j,  9.26539106e-17+8.74904443e-19j,
            1.29029367e-16-2.40829288e-17j,  2.53752724e-17+3.66051613e-17j,
            3.97580888e-17-5.70919498e-17j,  1.23917477e-17+1.22567083e-18j,
           -5.68825284e-17-1.22979168e-17j,  1.33921553e-17-2.71573399e-17j,
            4.24535935e-18-2.39702851e-17j,  3.45824135e-17+3.32057436e-18j,
           -1.18415180e-18+5.13004099e-18j, -1.13923550e-17+4.55617121e-18j,
            4.55466286e-18+1.29435046e-17j, -2.17660503e-17+6.84981965e-18j,
            4.53671222e-17-1.47989903e-18j,  1.09015174e-17+8.47775996e-19j,
            1.17574782e-17+3.65082980e-18j, -6.23647779e-18-5.98555367e-18j,
           -1.83179216e-17-7.79340769e-18j,  4.45349748e-17+8.08222022e-18j,
            1.51553356e-18-7.47704258e-18j, -4.60651340e-18-1.10989316e-17j,
           -4.14491811e-17+2.50221193e-17j, -1.26879701e-18-4.62634677e-17j,
            8.01024465e-18-4.15478267e-17j,  3.04395933e-18-2.51322021e-17j,
           -1.28801613e-17-3.86753957e-17j, -1.56790721e-17+1.91072614e-17j,
           -1.77447636e-17-4.66490752e-17j,  3.13408429e-17+5.79168916e-17j,
            2.59206521e-18+1.32327036e-17j,  7.51450469e-18+1.32970353e-17j,
            2.89923401e-17+6.91980966e-18j,  2.50145262e-17+3.12648746e-18j,
           -1.83360239e-18-2.05429361e-17j, -9.81625049e-18+5.93699472e-18j,
           -1.96432926e-17-1.14707407e-18j, -1.47976809e-17-5.12079245e-17j,
            9.51015754e-18-3.55180991e-19j,  4.47281081e-17+1.45013024e-18j,
           -1.16521709e-17+1.00951724e-18j, -3.77468911e-18+3.92584811e-17j,
            1.05349861e-17+2.98322952e-17j, -1.66639183e-17-5.36941548e-18j,
           -1.21763710e-17+2.69308108e-17j, -5.84339769e-18-8.03691332e-18j,
            1.43555245e-17+9.80634955e-18j,  1.02339942e-17-7.86472792e-18j,
           -4.94262175e-17-2.42096699e-17j,  9.32031704e-18-2.11875910e-17j,
            2.00306255e-18-1.57505072e-18j,  1.24548212e-17+4.39758835e-18j,
            8.74301590e-17+3.00308221e-18j,  1.31221087e-16+2.82535695e-17j,
           -3.53455816e-17+1.77473227e-18j,  2.89253748e-17+6.55685736e-18j,
           -2.01172641e-17-1.21408742e-17j,  8.97663963e-18-1.97818596e-17j,
            2.83460366e-17-2.86788472e-17j,  3.56104117e-17-7.50670223e-18j,
            3.16561966e-18-2.76152516e-17j, -1.83956972e-17-2.45992918e-17j,
            6.20449599e-18-3.86434472e-17j, -1.47826461e-17-8.72679158e-19j,
           -4.23394002e-17-2.96435947e-18j, -4.56899795e-19+1.39823307e-17j,
            1.80428589e-17-4.16168704e-18j, -8.12567344e-18+5.49111827e-17j,
           -1.44180421e-17-1.96132806e-17j, -1.21022877e-17+2.09510242e-17j,
           -1.16757158e-18-1.86661396e-17j, -8.88920602e-18+2.38425937e-17j,
           -5.51021469e-19-7.06977952e-18j, -2.90685340e-17-1.78213934e-18j,
           -1.89170645e-17+1.72624756e-17j,  1.62301976e-17-1.20549703e-17j,
           -1.38602358e-17+8.39941261e-18j, -3.94374256e-18+3.77981394e-17j,
            9.69857083e-18+7.61852948e-17j,  2.31585578e-17-1.54352064e-18j,
            5.25475525e-18+2.13549487e-18j,  1.54341297e-17+3.88840945e-17j,
            9.64247194e-21-4.08827175e-17j, -7.14026557e-18+1.21478150e-17j,
            2.22456227e-17+2.80014702e-17j, -3.37059077e-17+1.20631371e-17j,
           -1.38414852e-17+8.87208595e-18j,  9.20441644e-17-1.21531569e-17j,
           -1.57212542e-17+2.97165157e-17j, -3.10421465e-18-5.75767416e-17j,
            2.64052377e-17+1.44464697e-17j, -8.33221481e-18-1.96887711e-17j,
           -3.07405918e-17+1.15108313e-17j,  4.32174223e-17+3.44821646e-17j,
            4.97594337e-18+6.32020145e-18j,  2.76658655e-17+2.16680756e-17j,
           -1.07749466e-17+2.32442754e-17j, -2.41373068e-17+1.74510960e-17j,
           -3.69848475e-17+2.12112298e-17j, -9.43857962e-18-3.94862139e-17j,
           -5.52680750e-18+1.51679583e-17j,  7.78763459e-17-4.04242568e-17j,
            9.83443081e-17+4.27405178e-17j,  8.83115653e-17-3.02182853e-17j,
            1.70853301e-17+5.10306580e-17j, -2.66026024e-17+6.38806598e-18j,
           -1.41717452e-17+1.47327352e-17j,  7.18729730e-17+6.25438337e-18j,
           -4.24535935e-18-2.39702851e-17j, -3.45824135e-17+3.32057436e-18j,
            1.18415180e-18-1.25617504e-17j, -2.81849971e-18+2.74103578e-17j,
           -1.87655176e-17-1.72776831e-17j, -6.65565914e-18+8.06849584e-18j,
           -2.73455801e-18+6.87303180e-18j,  1.04147647e-17+1.45711409e-18j,
            1.57760528e-17-5.93451320e-18j, -2.57379453e-17+1.26921675e-17j,
            4.31869173e-17-1.29558028e-17j, -5.45512430e-18+9.06814996e-18j,
           -8.62096092e-18-1.51701351e-18j,  2.81432415e-17+1.11321808e-17j,
            5.74363927e-17-3.98569398e-17j,  5.70968911e-18+1.92471548e-17j,
           -4.45753097e-18+5.03481483e-17j,  1.87164120e-17+1.15239988e-17j,
           -2.66296108e-18-4.45039479e-18j, -2.51771352e-17-6.44717441e-17j,
            3.19556184e-17+2.03244444e-18j,  4.18629389e-18-1.40578375e-17j,
           -2.14797600e-18-1.55746440e-17j,  7.08492809e-18-4.14030280e-17j,
            5.20252908e-18+8.32678167e-18j,  2.43348872e-17-1.66300384e-17j,
            2.84789550e-17-5.30910107e-18j,  1.62555440e-17-2.29946553e-17j,
           -1.54397549e-17+1.10849264e-17j,  7.24816437e-18-7.71789334e-18j,
            1.29857365e-17+1.56074088e-18j, -3.07392980e-17+1.67310392e-17j,
            8.54354640e-18+9.85541293e-18j, -7.41893788e-19+2.03585585e-17j,
           -7.05990343e-17+3.15005437e-17j, -1.43276807e-17+1.49552952e-18j,
            6.42762326e-17+6.06415849e-18j, -1.16793124e-17+8.57360025e-18j,
            1.21250300e-17-1.76804713e-18j, -1.81127180e-17+1.04309961e-18j,
           -7.75572916e-18+3.53363116e-17j,  2.53028126e-17+2.30051386e-17j,
           -6.78064484e-18+1.21931074e-17j,  4.97533525e-18-1.46538738e-17j,
           -1.60734600e-17+4.95478962e-17j, -1.40681156e-17+3.23684158e-17j,
            1.92182118e-17+2.86034985e-18j,  2.77070934e-18+1.72319540e-17j,
           -1.05221424e-18+1.34635374e-17j,  3.31686217e-17-9.10400876e-18j,
            1.02412892e-17-5.15659630e-17j,  3.97623586e-17+8.93882920e-18j,
           -1.88369592e-17+1.92218328e-17j, -4.29352887e-17-7.71110859e-18j,
           -4.88998162e-19-3.34554876e-17j, -7.31052569e-18+6.00776329e-17j,
            1.13470453e-17-3.14184665e-18j,  5.23045235e-19-6.97556079e-18j,
            2.99374125e-17-1.79233425e-17j, -1.34079266e-17+5.15857099e-18j,
           -5.72139211e-18-1.90144861e-17j,  3.52605626e-18-1.16882159e-17j,
           -1.15508520e-18+1.94160230e-17j, -1.87952925e-17-1.10132098e-17j,
            2.41607871e-17+1.02676482e-17j, -8.06435921e-18+2.55258775e-17j,
           -4.00723210e-17-1.05247394e-17j, -1.08580332e-17-1.70303576e-17j,
            6.02579537e-17-4.61838597e-17j, -5.38736425e-17+6.76038650e-17j,
            4.66103203e-17-3.23480559e-17j,  2.38586751e-21-3.46767925e-17j,
           -2.55542130e-17+1.74263460e-17j, -6.92912687e-19+1.70250995e-17j,
           -2.24125018e-18-2.11237966e-18j, -5.09090965e-17+1.06285546e-17j,
           -7.73921559e-19+2.04694285e-17j, -1.58995509e-17+3.14930325e-17j,
           -2.45834425e-17+8.47235432e-18j, -7.56794469e-18-1.13126746e-17j,
            1.21570690e-17+1.43316918e-18j,  1.39345407e-17+1.29648187e-17j,
            2.63772776e-17+2.28799902e-17j, -3.17099733e-18+8.26904155e-18j,
           -9.52305721e-18+3.18701605e-18j, -6.18254301e-18+8.00208465e-18j,
           -1.49687998e-17-4.32882826e-17j,  2.68933330e-17-1.66837372e-17j,
           -4.46329949e-18-1.13692690e-17j, -1.29494661e-17-3.89169794e-18j,
           -1.18623867e-18+3.20797444e-17j, -3.42849445e-17+2.01149556e-17j,
            5.78641921e-18+2.63843543e-17j, -2.36377689e-16+8.92343348e-17j,
            1.19083291e-16+4.65088662e-17j, -9.52584472e-18-5.03713591e-17j,
           -3.17431088e-17-2.60157258e-17j,  1.00070411e-17-1.53196227e-17j,
            5.44757499e-17-8.00440860e-18j, -5.76964612e-17+6.25060555e-17j,
           -8.75795994e-18-1.27988814e-17j, -3.06844216e-18-4.56147158e-18j,
           -4.48112040e-18-4.40774128e-18j, -4.84642028e-18-3.59345194e-17j,
            1.47048808e-17-3.53382777e-17j, -2.65410064e-17+4.22951485e-17j,
           -9.59362819e-18-2.54253755e-17j, -1.10407640e-17+7.05768827e-18j,
           -1.67725969e-17+1.19777225e-17j,  1.99809505e-19-2.67145552e-17j,
            1.90060405e-17+2.59124032e-17j, -8.15256609e-18-2.23707536e-17j,
            1.37904901e-17-3.06409931e-18j, -2.80104016e-17+3.65342668e-17j,
           -2.88322147e-18+8.17575359e-17j, -2.84093559e-17+4.25791764e-17j,
           -1.90246603e-17+1.22912619e-17j,  2.95399091e-18+1.78870148e-17j,
           -1.52484182e-17-4.52944100e-19j,  9.88922120e-18+1.23778527e-17j,
           -2.05359598e-18+2.31666492e-18j,  4.75859905e-17-3.72286223e-17j,
            3.69818650e-18-1.77632704e-17j, -5.95199341e-18-1.98508706e-18j,
           -5.02972634e-18+1.23037215e-17j, -2.70574490e-17-2.27813839e-17j,
           -3.42993923e-17-6.69428718e-18j, -8.59733286e-18-3.13224356e-17j,
           -1.27328427e-17-2.49237626e-18j, -2.88536929e-18+3.07903099e-17j,
           -2.50207771e-17-4.69649278e-17j,  8.74773175e-18-1.02149477e-17j,
            6.73004436e-18-1.95189433e-19j, -3.72203669e-17-1.47930328e-17j,
            5.02680235e-17+3.08820955e-17j, -5.90898809e-17+2.81646679e-17j,
           -3.47114874e-17-3.77871586e-17j, -3.21358239e-18+1.08188328e-17j,
           -9.43832889e-18+6.70406497e-18j,  1.28365091e-17-2.61691515e-18j,
           -1.70391681e-17+3.27052676e-17j,  1.68666720e-17+1.38048078e-17j,
           -1.76934507e-17-1.74852929e-17j,  1.66830357e-17-3.39196635e-17j,
            3.73404254e-17+1.08191730e-16j, -5.02168644e-17-3.01636600e-17j,
            3.67627840e-17+3.89254519e-18j, -4.24423348e-17+1.33590068e-18j,
            3.60955811e-18-1.20858604e-17j, -1.05462579e-17-2.64177826e-17j,
           -7.94797393e-18+2.01846453e-17j,  5.33065080e-18+9.84268266e-18j,
           -1.85205575e-17+7.32759775e-18j, -1.86275512e-17+1.51427020e-17j,
           -2.18827000e-19+4.30700416e-17j, -3.23128328e-17-2.35118130e-17j,
            3.96602440e-17+1.04778993e-17j,  6.86293257e-18+1.18586045e-17j,
           -3.32345339e-17-4.56700714e-17j,  4.03901530e-18-4.55718323e-18j,
           -4.64612242e-17+2.04623659e-17j, -3.65727996e-17-1.33200512e-17j,
           -8.65001210e-18+1.23552046e-17j, -2.24577284e-17+2.55382124e-17j,
           -2.26412834e-18-1.00851662e-17j, -3.05194913e-17+2.08347638e-17j,
            4.79791932e-17+2.05638378e-17j, -1.79550444e-17+7.49231230e-18j,
           -6.77879367e-18+5.11683046e-17j,  3.59738403e-17-1.12362209e-17j,
            9.11461833e-18+1.37130677e-19j, -3.35433351e-17-4.57823676e-17j,
            3.16592986e-18-1.61149116e-19j,  1.92463581e-17+3.25121545e-17j,
           -2.80235143e-17-8.24339048e-17j, -7.84751830e-17+8.44216917e-18j,
           -1.66532449e-17+1.20433253e-17j, -4.39922187e-17-4.17371103e-19j,
           -1.83774589e-17-4.61792972e-17j, -4.74939743e-17-2.14428898e-17j,
            2.68828388e-17-6.25558081e-18j,  1.86660137e-17+4.64246585e-18j,
           -1.61795889e-17-4.93380064e-18j,  4.39611281e-20+4.55960447e-17j,
            9.12409672e-19+3.62846145e-17j, -2.04972111e-17-5.78506605e-18j,
           -1.88504163e-18+1.70572407e-17j,  9.41634605e-18-1.11781186e-17j,
            9.92167603e-18+3.81048097e-17j, -1.21585792e-17-4.05304921e-17j,
            3.25652359e-18+6.54655757e-17j,  7.84171339e-17+3.63384440e-17j])



c8665ffd0c3877818a4e5c985b94b499088f84b2
ipynb
Jupyter Notebook
Aula 44 - DFT resolucao e zero padding/.ipynb_checkpoints/DFT - resolucao e zero padding-checkpoint.ipynb
RicardoGMSilveira/codes_proc_de_sinais
e6a44d6322f95be3ac288c6f1bc4f7cfeb481ac0
CC0-1.0
2020-10-01T20:59:33.000Z
2021-07-27T22:46:58.000Z
Aula 44 - DFT resolucao e zero padding/.ipynb_checkpoints/DFT - resolucao e zero padding-checkpoint.ipynb
RicardoGMSilveira/codes_proc_de_sinais
e6a44d6322f95be3ac288c6f1bc4f7cfeb481ac0
CC0-1.0
Aula 44 - DFT resolucao e zero padding/.ipynb_checkpoints/DFT - resolucao e zero padding-checkpoint.ipynb
RicardoGMSilveira/codes_proc_de_sinais
e6a44d6322f95be3ac288c6f1bc4f7cfeb481ac0
CC0-1.0
2020-10-15T12:08:22.000Z
2021-04-12T12:26:53.000Z
Qwen/Qwen-72B
1. YES
2. YES