BEC信道极化现象
以消除概率=0.5 的二进制消除信道 BEC 为例,信道的错误概率上限巴氏参数可通过以下确定的递归计算得到:
Python实现程序如下:
import osimport numpy as npimport matplotlib.pyplot as pltdef main(): index = 10; n = np.power(2, range(1, index+1)) W = np.zeros((n[9]+1,n[9]+1)); W = W.astype(便宜美国vpsnp.float64) W[1][1] = 0.5; for i in n : for j in range( 1,int(i / 2)+1): W[i, 2 * j – 1] = W[int(i / 2), j] * W[int(i / 2), j] #^ 2; W[i, 2 * j] = 2 * W[int(i / 2), j] – W[int(i / 2), j]*W[int(i / 2), j] # ^ 2; plt.scatter(range(1, 1024), W[1024,1:1024], s = 5,label=’b.’); plt.axis([0, 1024, 0 ,1]); plt.xlabel(‘Channel index’); plt.ylabel(‘Symmetric capacity’); plt.show();if __name__ == ‘__main__’: main()
运行结果: