You are on page 1of 6

# Sample time series data

N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)
plt.plot(t, x)
plt.show()

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
# Sample time series data
N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)
# Calculate the amplitude (magnitute) for FFT
mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

plt.plot(t, x)
plt.show()
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

plt.plot(t, x)
plt.show()

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
# Sample time series data
N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)
# Calculate the amplitude (magnitute) for FFT
mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

# Sample time series data


N = 1000
t = np.linspace(0, 10, N)
x = np.concatenate(
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

plt.plot(t, x)
plt.show()
[np.random.normal(0.7, 0.05, int(N/4)),
np.random.normal(1.5, 0.05, int(N/4)),
np.random.normal(0.6, 0.05, int(N/4)),
np.random.normal(1.3, 0.05, int(N/4))])

# Calculate the FFT for the input signal


X = np.fft.fft(x)

# Calculate the amplitude (magnitute) for FFT


mag = np.sqrt(X.real**2 + X.imag**2)

# Calculate log amplitude


log_mag = np.log(mag)

plt.plot(t, x)
plt.show()

plt.plot(t, x)
plt.show()

You might also like