25 lines
309 B
Python
25 lines
309 B
Python
import numpy as np
|
|
import scipy as sp
|
|
import matplotlib.pyplot as plt
|
|
|
|
f_c = 1
|
|
f_m = f_c/4
|
|
|
|
omega_m = 2*np.pi*f_m
|
|
omega_c = 2*np.pi*f_c
|
|
|
|
T_c = f_c
|
|
|
|
t = np.arange(0,10,T_c/10)
|
|
m = np.cos(omega_m * t)
|
|
|
|
plt.plot(t, m)
|
|
plt.show()
|
|
|
|
D_p = np.pi
|
|
D_f = np.pi
|
|
|
|
S_p = np.cos(omega_c + D_p*m)
|
|
plt.plot(t,S_p)
|
|
plt.show()
|