Development and performance improvement of a novel zero cross-correlation code for SAC-OCDMA systems

In order to improve the performance of the Spectral Amplitude Coding-Optical Code Division Multiple Access (SAC-OCDMA) system, a zero cross-correlation (ZCC) code named double weight multi-diagonal (DW-MD) is proposed with constant weight (CW) or variable weight (VW). Mathematical results illustrate that it is feasible to reduce the number of filters without sacrificing system performance by using the CW DW-MD code instead of the multi-diagonal (MD) code. And for theVWDW-MD code, the supportable number of users for lower codeweightWL (3) at bit error rate (BER) of 10 (voice) is 43, medium code weight WM (4) at BER of 10 −9 (data) is 29, and higher codeweightWH (5) at BER of 10 (video) is 32. Finally, the analysis about the position of chips “1” is given, and the simulation setups show that the CW DW-MD code outperforms the MD code when Gaussian optical filter is used.


Introduction
Optical Code Division Multiple Access (OCDMA) is an attractive technology in the optical network due to the properties of asynchronous access to the entire channel and great capacity in bursty traffic [1]. In particular, Spectral Amplitude Coding-Optical Code Division Multiple Access (SAC-OCDMA) techniques stand out because of the ability to eliminate multiple-access interference (MAI) [2][3][4]. And with light-emitting diodes (LEDs) as the light source, the SAC-OCDMA network is inexpensive and simple [5,6]. The performance of the SAC-OCDMA system depends to a large extent on the choice of coding scheme, and many Spectral-Amplitude-Coding (SAC) codes have been reported, such as modified quadratic congruence (MQC) codes [3], double weight (DW) code family [7,8], Khazani-Syed (KS) code [9], Random Diagonal (RD) code [10], Multi-Service (MS) code [11], Enhanced multi-diagonal (EMD) code [12], Zhang finite-difference (ZFD) code [13] and a code based on construction of parity check matrix of Low density parity check (LDPC) codes [14].
In addition to these codes designed with constant code weight (CW), the variable weight (VW) codes are also reported. And with the property of higher code weight representing better performance, they can be utilized to support multimediaservice(e.g., voice,video, anddatatransmission) and provide different quality of service (QoS) for the various requirements in SAC-OCDMA network [15]. Some of them are VW KS code [9], VW RD code [10], VW MS code [16] and a VW code based on enhanced and modified DW codes [17].
All of the above CW and VW codes cannot avoid the impact of phase-induced intensity noise (PIIN). Thus, some zero cross-correlation (ZCC) codes along with the spectral direct detection (SDD) [18] technique has been reported to eliminate the PIIN for the SAC-OCDMA system. Such as ZCC code [19], Multi-Diagonal (MD) code based on the orthogonal matrix [20], new ZCC code with satisfactory code lengths [21], VW ZCC Code [22] and Zero Cross Correlation Code (ZCCC) with CW and VW [23].
There are also some two dimensional spectral/spatial codes have been proposed in order to improve the system capacity. Such as Two Dimensional-Single Weight Zero Cross Correlation (2D-SWZCC) code [24], two-dimensional hybrid ZCC/MD code [25], two-dimensional Fixed Right Shift (FRS) code [26] and two-dimensional Enhanced multi-diagonal (2D-EMD) Code [27]. Most of the two dimensional spectral/ spatial codes are usually constructed on the basis of onedimensional codes. Therefore, it is still very important to design one-dimensional SAC-OCDMA codes with excellent performance.
The code family for SAC-OCDMA system continues to grow, and the choice of an appropriate code with CW or VW is still an open issue. However, the position of chips "1" in the code sequences, one of the important factors affecting system performance, is not analyzed in the previous works. In this paper, a new ZCC code named double weight multidiagonal (DW-MD) code is constructed based on the DW codes and MD code. In order to reduce the number of filters used in the system and make the SAC systems more costeffective, the DW-MD code is designed with putting two chips "1" together compared to the MD code. And using the mapping technique, the DW-MD code with VW is given for supporting multimedia service. Furthermore, the effect of chips "1" position on system performance is qualitatively analyzed and evaluated by simulation in this paper.
This paper is organized as follows. In Section 2, construction of the DW-MD code with CW and VW are presented. In Section 3, mathematical and analysis results for evaluating the performance of the DW-MD code are given. Analysis of chips "1" position and simulation setup is given in section 4. Finally, conclusions are drawn in Section 5.
2 Construction of DW-MD code

Introduction of MD and DW codes
Construction of the DW-MD code is based on the DW codes and MD code.
As reported in [20], the MD code is constructed by using V alternating M-dimensional unit diagonal matrices and anti-tangle matrices (V is code weight and M is the number of users): The DW codes are designed with the property that chip "1" occurs in pairs [7,8]. Therefore, when the DW codes are used in SAC-OCDMA systems, the number of filters can be reduced by almost half. The principle of reducing the number of filters is shown in Figure 1. Here, the one filter with a bandwidth of 2Δf (central wavelength of f c = (f 1 + f 2 )/ 2) can be used to replace the two filters with a bandwidth of Δ f(central wavelength of f 1 and f 2 , respectively).

Construction of DW-MD code with constant weight
Construction steps of the DW-MD with CW code are as follows.
Step 1: Defining the code weight W and the number of users N, where W and N are positive integer numbers. And the code length L is given as L = N × W.
Step 2: Constructing a sequence of matrices S w (w = 1, 2, 3 …, w max ) with only elements "1" and "0" according to W and N, and the S w (i, j) (i = 1, 2, 3 … , N) represents the element of the ith row and the jth column of each matrix respectively.
(a) When W is an odd number, the value of w max is (W + 1)/2. S 1 is a matrix with N × N dimensions, and S w (w = 2, 3, … , w max ) are matrices of power N × 2 N, the position of elements "1" in Sw is determined by for j i S w odd number,w≠1 (i, j) 1, for j 2i − 1, 2i S w even number (i, j) 1, where, i is varied from one to N, and (b) When W is the even number, the value of w max is W/2. S w (w = 1, 2, 3 … , w max ) are matrices of N × 2 N, the position of elements "1" in S w is determined by Step 3: The total combination of the S w (w = 1, 2, 3 … , w max ) in matrices (3) or (5) represents the DW-MD code as a matrix of power N × L.
For example, to construct a DW-MD code with W = 3 and N = 3 according to the previous steps. Therefore, L = N × W = 9, W is an odd number and w max = 2. For i = 1, 2, 3, the matrices S w (w = 1, 2) can be expressed as: and the DW-MD code will be: The DW-MD code concentrates on the advantages of MD and DW codes. On the one hand, MAI can be fully eliminated and the PIIN can be suppressed due to the property of ZCC (same as MD code). On the other hand, the number of filters and the complexity of the system can be reduced because the two chips "1" are adjacent (same as DW code). Besides, the DW-MD code can be generated easily and efficiently with any code weight and the number of users.

Construction of DW-MD code with variable weight
Construction of DW-MD code with VW for supporting multimedia service with different QoS in SAC-OCDMA network is described here. It consists of several CW DW-MD code matrices by using the mapping technique and each code weight can be chosen independently to satisfy the required service quality. The VW code with J number of service classes is described as where, N j is the number of users of the jth CW code matrix whose code weight is W j , and W 1 > W 2 > ⋯ > W J . Thus, the total number of users N v is expressed as X. Li et al.: Development of SAC-OCDMA systems and the code length L v is given as As shown in Figure 2, the VW DW-MD code for supporting QoS differentiation is designed. The weights of 5, 3, and 2 are chosen for representing higher, medium and lower class, respectively. There is a total of 10 subscribers (four users with higher class, three users with medium class and three users with lower class), and the total length of VW DW-MD code is 41 from the Eq. (10).

System setup
The schematic diagram of the SAC-OCDMA system with the CW DW-MD code is shown in Figure 3. The system consists of the transmitter and receiver. At the transmitter, the optical bandpass filters are used to encode the optical spectra of the three users according to the DW-MD code sequence. After being modulated with the given data by the Mach-Zehnder Modulators (MZMs), three branches of encoded optical spectra are multiplexed by the Combiner and then sent to the receiver through the Single Mode Fiber (SMF). Finally, direct detection technique is used. The divided optical signals are decoded by using the filters with unique central wavelengths respectively and retrieved by means of photo-diode and Low Pass Filter (LPF). It is noted that not all the "1" s must be detected in the SDD technique for the CW system, and the number of detected "1" s can be determined according to the actual situation.
As shown in Figure 4, the system setup for VW DW-MD code is similar to the CW code and the filters at the encoder and decoder are determined by the VW code sequence. However, all the "1" s should be used in the SDD technique so as to ensure that the code weight of each class remains unequal. Here, the lower code weight (i.e., W = 1) is associated with low service demand represented as class 1, and the higher code weight is assigned to class 3 owning high QoS.

Derivation of BER formula
In the following analysis, Gaussian approximation is used to evaluate the performance of the CW and VW DW-MD code. And the SAC-OCDMA system performance is characterized by referring to BER. Because the DW-MD codes have the ZCC property and there are no spectra overlapping among different users, only the effects of both shot and thermal noise are considered and the PIIN is ignored. Consequently, the total variance of noise for the system can be written as where, e is the electron's charge, I is the average photocurrent at the receiving photo-diode, B is noise-equivalent electrical bandwidth of the receiver, K b is Boltzmann's constant, T n is receiver noise temperature and R L is receiver load resistor. In order to evaluate the SAC-OCDMA system performance accurately, it is assumed that: Moreover, power spectral density (PSD) of received optical signals at the photo-diode can be written as where, P sr represents the effective power at the receiver, N is the active users, L is the DW-MD code length, d n is the data bit of the nth user that is ''1'' or ''0'', rec(i) in Eq. (13) is explained as and u(v) is the unit step function expressed as Let C n (i) be the ith element of nth CW DW-MD code sequence and according to the correlation properties, the SDD technique for the DW-MD code can be represented as From the Eqs. (13) and (16), the PSD at the photodetector of the lth receiver during one period can be written as: and then  The photocurrent I can be found as where, R is the responsivity of the photo-detectors given by R = μe/(hvc), μ is the quantum efficiency, h is Planck's constant, and v c is the central frequency of the original broad-band optical pulse. Substituting Eq. (19) in Eq. (12), it can be obtained that Noting that the probability of sending bit "1" at any time for each user is 1/2, Eq. (17) becomes Thus, for users with code weight W, the average Signal to Noise Ratio (SNR) can be calculated as Using Gaussian approximation, the BER can be expressed as And for VW DW-MD code, the Eq. (16) can be expressed as By the similar derivation to CW DW-MD code, the average SNR j for VW DW-MD code with code weight W j can be calculated as Using Gaussian approximation, the BER j can be also expressed:

Mathematical results and discussion
The parameters used in the numerical analysis are listed in Table 1. Comparison of the number of filters used at the encoder/decoder between the CW DW-MD and MD codes is given in Figure 5. For the same number of users and code weight, fewer filters are used with the DW-MD   code due to the property that chip '1' occurs in pairs, and half number of filters can be reduced when the code weight is an even number (e.g., W = 4). It is noted that the same number of filters (two filters per encoder) are required for the DW-MD code with W = 4 and W = 3, but both filters are double bandwidth for W = 4 while only one for W = 3. As shown in Figure 6, the performance of DW-MD code (W = 4), MD code (W = 4) [20], KS code (W = 6) [10] and MS code (W = 4 and N B = 3) [12] are investigated as log of BER against the total number of active users operating at P sr of −10 dBm. Due to the same ZCC and no PIIN, the DW-MD code and MD code have almost the same BER performance and are superior to other codes. This further indicates that it is feasible to reduce the number of filters without sacrificing system performance by using the DW-MD code instead of the MD code. Figure 7 illustrates the variations of the BER against the number of users (each weight of VW DW-MD code). For supporting multimedia service, the lower code weight W L , medium code weight W M , and higher code weight W H are set as 3, 4 and 5, respectively. The Supportable number of users for W L at BER of 10 −3 (voice) is 43, W M at BER of 10 −9 (data) is 29, and W H at BER of 10 −12 (video) is 32. Figure 8 depicts BER versus the number of users (each weight) for VW code by varying the W L or W H and keeping another code weight fixed. The combinations of two code weights (W L , W H ) are taken as (3,4), (3,5) and (4,5). On one hand, increasing the W H from four to five and keeping the W L fixed at three leads to the worse BER for W L users and better performance for W H users. On the other hand, the    BER for W L users and W H users decreased and increased respectively when the W H is fixed at five and W L increases from three to four Eq. (11) indicates whether it is to increase W L or W H , the total code length L v should be increased. And it is obvious that the BER performance becomes worse for the fixed code weight (W L or W H ) as the increase of L v according to the Eq. (26).
In Figure 9, BER is plotted against the number of simultaneous users with the number of lower code weight users (N L ) being 10, 20, and 30, respectively. As the N L increases, both the W L and W H users have a better BER performance. Thus, the higher the proportion of users with W L , the better the system performance. This is because increasing the N L can decrease the total code length L v and provide a lower BER for the whole system according to the Eqs. (11) and (26).

Analysis of interference between two
adjacent "1"s The above mathematical analysis and discussion are based on the assumption that there is no interference between two adjacent chips "1". However, filters used at the encoder/decoder in SAC-OCDMA systems are not ideal filters in real scenario, and there is indeed interference between the two adjacent wavelength channels. Take the Gaussian Optical Filter commonly used in SAC-OCDMA systems as an example, and its theoretical model is shown in Figure 10 (theoretical model of ideal filter can be obtained from Figure 1). According to Figure 10 where the interference is represented as ΔS, it can be concluded that the construction with two discrete "1" (MD code) has more interference than two adjacent "1"s (DW-MD) (4ΔS for the former and 2ΔS for the latter when the code weight is 2). If there is only one chip "1" needed at the decoder in the SDD technique, the filter with a bandwidth of Δf and the central wavelength of f c can be the optimal choice.

Simulation setup
The simulation setup for the CW DW-MD code is shown in Figure 11. There are five users in the SAC-OCDMA system, and the data rate is set as 1.25 Gbps. The a.u. value of Bias Generator (d.c. source.) is set as one. The spectral width is set as 0.8 nm for each chip and the mapping of DW-MD code (W = 4) and wavelength for each user is given in Table 2.
At the transmitter, the LED is utilized as a broadband light source whose parameters are set as the wavelength of 1550 nm and bandwidth of 3.75 THz (30 nm), WDM Demux and Mux are used for encoding the optical spectra, a pseudo-random bit sequence (PRBS) generator and a non-return-zero (NRZ) pulse generator are used to generate the data signal for each user, and the Mach-Zehnder Modulator is utilized as external intensity modulator. According to ITU-T G.652 standard, the 20 km standard single mode optical fiber (SMF) with the dispersion of 16.75 ps/nm/km and attenuation of 0.2 dB/km is chosen to connect the transmitter and receiver.   And at the receiver, the SDD technique is applied to detect signals. The Gaussian Optical Filter with the bandwidth of 0.8 nm is utilized to filter the unique wavelength chips for each user, and the photo-detector with dark current value being 5 nA and 0.75 GHz. Low Pass Bessel Filter is applied for recovering the original electrical signal. It is noted that the channel bandwidth of WDM Demux and Mux are set as 1.6 nm (represent two "1" s with the bandwidth of 0.8 nm) for reducing the number of filters at the encoder. And the wavelength of Gaussian Optical Filter is set as the center of two adjacent wavelengths for mitigating interference from other users.
The simulation setup for MD code is shown in Figure 12, and all the parameters are the same as that shown in Figure 11 except for the encoder and decoder corresponding to the code sequence. The mapping of MD code (W = 4) and wavelength for each user is given in Table 3.

Simulation with Gaussian Optical Filter
Performance of the system with the DW-MD and the MD codes is characterized in terms of the BER and eye pattern. As shown in Figure 13, eye patterns of one user using (a) DW-MD and (b) MD code clearly depict that the DW-MD code gives a more open eye and a better BER. Furthermore, Table 4 lists the BER values of the five users in the simulation systems using the DW-MD and MD codes, and the BER values of the two codes differ by 8∼14 orders of magnitude. This is because the DW-MD code can reduce the interference by the structure of two adjacent "1" s (analysis of the Figure 10).
In order to further analyze the performance of DW-MD and MD codes, the fiber length between the transmitter and receiver is changed from 10 to 50 km. And the BER of the two codes versus fiber length is observed at two different data rates (622 Mbps and 1.25 Gbps). Figure 14 shows that BER increases with increasing SMF length, which can be attributed to the increasing attenuation and dispersion of SMF.
Moreover, it is observed that the performance advantages of DW-MD code are obvious. In the range of 10-40 km, the SAC-OCDMA system with DW-MD code transmitted at higher rate (1.25 Gbps) performs better than that with MD code transmitted at lower rate (622 Mbps). And for lengths of up to 40 km, the  proposed DW-MD has the ability to provide nominal performance for an acceptable BER of 10-9 at 1.25 Gbps of data.

Simulation with rectangle optical filter
In the next simulation, the Rectangle Optical Filters are utilized to replace the Gaussian Optical Filters at the encoder and decoder and other settings and parameters remain unchanged. The BER values of the five users in the SAC-OCDMA systems using the DW-MD and MD codes are given in Table 5, and the BER difference between two corresponding users does not exceed two orders of magnitude. Furthermore, as a sample, the eye diagrams for one user using DW-MD code and MD code are shown in Figure 15 (a) and (b), respectively. Obviously, the two users have a very close eye quality. This is because when using the Rectangle Optical Filters, there is no interference between adjacent filter channels and the effect of chips "1" position on system performance does not exist (theoretical model of ideal Rectangle Optical Filter is shown in Figure 1).
From the above analysis, it can be easy to conclude that the DW-MD and MD codes have a similar performance when the ideal Rectangle Optical Filters are utilized, which indirectly reveal that the effect of chips "1" position on system performance cannot be ignored when the non-ideal optical filter (e.g., Gaussian Optical Filter) is used at the encoder/decoder in the real scenario.

Conclusions
A new ZCC code named DW-MD code has been developed to reduce the number of filters used in the SAC-OCDMA system with the feature of two adjacent chips "1". And the DW-MD code with variable weight is also constructed to support multimedia in SAC-OCDMA system by associating several different CW code matrices and using the mapping technique. The VW DW-MD code can be chosen independently for each code weight to satisfy the required service quality. Theoretical analysis shows that the DW-MD code can be used instead of the MD code to reduce the number of filters without sacrificing system performance under the ideal conditions. Here, one filter with a larger bandwidth (doubled) can be used instead of using two filters (represent two distinct chips '1'). The ability of VW DW-MD code to support multimedia service is also verified, and results indicate that the users with lower code weight W L , medium code weight W M , and higher code weight W H have the higher BER, medium BER and lower BER, respectively. In terms of changing the W L or W H and keeping another code weight fixed, increasing W L or W H results in an increase in the total code length L v , and the performance for the fixed code weight (W H or W L ) deteriorates. In addition, the number of lower code weight users (N L ) with different values (i.e., 10, 20 and 30) are set for the VW code with the combination of (3,5). It is shown that increasing the N L decreases the total code length and provides better performance for both the W L and W H . Finally, the performance comparison of the MD code and proposed CW code is given through qualitative analysis and simulation setups. The proposed code provides a significant performance improvement compared with the MD code when the Gaussian Optical Filters are used. In summary, the overall results demonstrate that the DW-MD code can be a code candidate that makes the SAC-OCDMA system more costeffective, and the VW DW-MD code is suitable for supporting multimedia service in optical networks.