diff --git a/examples/example_ber_estimation_10.py b/examples/example_ber_estimation_10.py index d5d4cc563f970d6fc235dc495ae8d328832f3195..aad32385ffede8eb42900635d9e8c2c582952895 100644 --- a/examples/example_ber_estimation_10.py +++ b/examples/example_ber_estimation_10.py @@ -77,12 +77,12 @@ for c in range(0, 0): ############################ E = amp(E = E, Pmean = 0) -print('1:', osnr( E = E)) + Ein = copy.deepcopy(E) plt.figure(1) # Get decision matrix Dec_x, Esx_re_ax, Esx_im_ax, Dec_y, Esy_re_ax, Esy_im_ax = get_decision_matrix(gp, Ein, [constpts_x, constpts_y], [symbols_x, symbols_y], filter_f0) -print('1:', osnr( E = E)) + # Plot decision matrix plt.figure(1) plt.subplot(2, 1, 1); h = plt.contourf(Esx_re_ax, Esx_im_ax, Dec_x, 32, cmap=plt.cm.jet ) @@ -93,6 +93,6 @@ plt.plot(np.real(E[0]['E'][1][int(gp.sps/2)::gp.sps]), np.imag(E[0]['E'][1][int( # Calculate BER ############################ BER = calc_BER (gp, E, [constpts_x, constpts_y], osnr( E = E), Dec_x, Dec_y, Esx_re_ax, Esx_im_ax, Esy_re_ax, Esy_im_ax, 10, filter_f0, [symbols_x, symbols_y]) -print('1:', osnr( E = E)) + print(BER) plt.show() \ No newline at end of file