import numpy as np
import matplotlib.pyplot as plt
from numpy import pi
from numpy import sin
from numpy import cos
from numpy import r_
fH = 1800
fL=1200
j=0
k=0
input = np.random.random_integers(0,1,7)
print input
l=len(input)
if (l%2!=0):
e=(l-1)/2
o=(l/2)+1
else:
e=(l/2)
o=(l/2)
t = np.arange(0,l+1)
even=np.zeros(e)
odd=np.zeros(o)
for i in range(0,l):
if i%2==0:
odd[j]=input[i]
j=j+1
else:
even[k]=input[i]
k=k+1
print odd
print even
#fig_size = plt.rcParams["figure.figsize"]
#print "Current size:", fig_size
#fig_size[0] = 10
#fig_size[1] = 10
x=np.array(odd)
y=np.array(even)
plt.plot(t,x)
plt.plot(t,y)
I want to implement MSK modulation using python using this EXOR logic as mentioned in figure. Kindly help me out 同样,当我运行上面的代码时,我得到x abd y必须具有相同的第一维并且偶数和奇数位的图不起作用的错误。