Reduction of Complexity Design of SAC OCDMA Systems by Utilizing Diagonal Permutation Shift (DPS) Codes with Single Photodiode (SPD) Detection Technique

In this paper, a diagonal permutation code is presented for spectral amplitude coding optical code division multiple access (SAC-OCDMA) employing a single photodiode (SPD) detection technique. It is characterized by practical code length and ideal in-phase cross correlation (CC) that results in multiple access interference (MAI) suppression. A diagonal permutation shift (DPS) code can be constructed using both prime codes and some matrix operations. In addition, it can be easily implemented as it exists for prime numbers P, which limits the addressing probability of codes to P2. Fiber Bragg gratings (FBGs) are used for code encoding and decoding. Simulation analysis that calibrates with BER, Q-factor, and eye diagram proves that DPS code using SPD technique is able to maintain error free transmission compared to the complementary detection scheme (CDS) technique. It is reported that a reduction of fiber Bragg grating (FBG) sets by 41.6% was achieved for SPD over CDS techniques.


Introduction
Recently, SAC-OCDMA systems have gained a lot of attention among OCDMA systems as they are able to completely eliminate multiple access interference (MAI) by spectral coding [1]. As the number of users increases, the bit error rate (BER) also increases as the phase-induced intensity noise (PIIN) increases through the balanced detecting schemes [2]. Unfortunately, the presence of PIIN leads to limitation of the network capacity. Many families of codes have been proposed by researchers lately for SAC-OCDMA systems that have ideal in-phase cross correlation (CC) [3][4][5][6][7]. In [5], Abd et al. proposed a new code that is dynamic cyclic shift (DCS) code and compared it with other reported codes. It shows better performance. As in this code, the number of users is the same as the code length and the code length is short, so that will cause restriction in selecting the code. In order to achieve the cyclic shift property with minimum CC, the authors considered the dynamic part D > 7 to have a CC value less than 1. Tseng and Wu in [6] constructed a partitioned partial prime (PPP) code family that has many advantages such as flexible code length, lower value for in phase CC (IPCC), excellent orthogonality, and balanced code. In addition, by comparing PPP codes with other SAC-OCDMA codes [6], it can support a large number of users as well as higher transmission rate. However, the code construction is too complicated which makes it time-consuming. Fadhil et al. [7] proposed random diagonal (RD) code for OCDMA systems. They used both code and data segments in code structure which make the code constructions easy with short code length. However, when the number of users increases, the cross correlation increases, eventually degrading the system performance. Ahmed et al. proposed a new coding scheme for spectral amplitude coding (SAC) family, known as Sigma Shift Matrix (SSM). There are two techniques for constructing SSM, lower and upper shift [8]. H.Y. Ahmed and K.S. Nisar [2] constructed Diagonal Eigenvalue Unity (DEU) code with CC ≤ 1 and different sets of code sequences. However, the code construction is complicated which is considered one of its drawbacks. Fiber Bragg gratings (FBGs) are used for encoding and decoding each user in SAC-OCDMA systems. However, when the number of active users becomes large, the sizes of FBG will become impractical.
The SAC-OCDMA code system uses low price broadband incoherent sources such as amplified spontaneous emission (ASE) and light emitting diode (LED) [9]. These sources are harmonized with the SAC-OCDMA concept by nature while implementing commercially. An incoherent sources-based SAC-OCDMA system is simple and easy to implement with extremely low price and huge optical bandwidth features with bandwidth limitation constraints at high transmission rates due to their intensity noise restricted system performance [10]. The main issue with such sources is that it provides low data rates when long distance communication is involved with high inherent intensity noise [11].
The performance of SAC-OCDMA is limited by strong noise originating from other users trying to use the medium simultaneously for transmitting concurrent data streams using the same time and frequency, referred to as Multiple Access Interference (MAI). MAI severely increases with the number of simultaneous users resulting in performance deterioration, increase in bit error rate (BER), and eventually limitation of the capacity of the system. Therefore, MAI is considered the dominant source of noise in an OCDMA system. Due to this problem, it is important that an intelligent design of the code sequence considers reducing the contribution of MAI to the total received signal [12,13]. If we have an ideal cross correlation, it helps in the balance detection scheme and the filtering will be easy, eventually leading to performance improvement.
In this paper, an efficient method is used to address the abovementioned problems by using a Diagonal Permutation Shift (DPS) code family. The new proposed code is a family of bits "0" and "1". It characterized by L which refers to code length, N which represents the code length, code weight P (number of ones), and cross correlation λc. The DPS code family has many advantages such as good property in cross-correlation control, short code length, and easy to implement using fiber Bragg gratings (FBGs).
Moreover, both detection techniques are used with DPS code for mitigating the multiple access interferences between any two code sequences. The performance is evaluated for DPS code in terms of different transmission distance, bit error rate (BER), received power, signal-to-noise ratio (SNR), and eye diagram.
The rest of the paper is organized as follows. Section 2 provides code construction and code properties. Section 3 shows the description of the DPS system. Section 4 explains the detection techniques. Performance analysis is given in Section 5. Section 6 shows the discussion for obtained results followed by conclusion in Section 7.

Algorithm of Code Construction
The mathematical model of Diagonal Permutation Shift (DPS) code is presented in this section. The DPS is characterized by code weight (P), number of users (N), code length (P 2 + P), and cross correlation (λ c ). The construction of DPS can be done using both certain matrix operations and some simple algebraic ways. The derivation of DPS code is done by using prime code sequences that are based on the Galois field GF (P) = {0, 1, . . . , P − 1} for P > 2 where P is a prime number. The following steps explain how the DPS codes were constructed.
Step 1. (Diagonal process): Construct primary diagonal d i,j sequences of integer numbers as shown in Table 1 using Equation (1).
where i and j represent the position of each element over Galois fields and mod represents the modulo operation. Table 1. Tabular representation of integer numbers over GF(P).
Based on Equation (1), a generator sequence D P is constructed as follows.
For any P, the following elements are fixed For P = 3, the following sequences are generated based on Equation (2).
Step 2. (Permutation process): Construct the basic matrix B 0 P by taking D P as a first row, then make a permutation of D P one time in the next rows to get a P × P zero-diagonal symmetric matrix without repeating any row as follows.
For P = 3, the following matrices are obtained based on Equation (5).
Step 4. (Joining process): In the joining process, matrix A is obtained by joining B K P in each sequence, then an extra column of matrix m P is added to each corresponding B K P .
where m P is a P × 1 matrix contains the elements {0, 1, 2, · · · , P − 1} in arbitrary order. The size of matrix A is P 2 × (P − 1) and its elements A i,j where i = 0, 1, 2, · · · , P 2 − 1, and j = 0, 1, 2, · · · , P. The above four steps can be summarized in Equation (9). This equation is valid for any prime number P > 2 to generate a code with a unity cross correlation in the form of a matrix.

Code Properties
The properties of DPS code are mentioned as follows.
• A unity CC between any sequences. • The number of users N = P 2 .

•
The code weight can be any prime number greater than 2.

•
The code length equals P 2 + P.

Code Examples
The DPS code patterns for P = 3 where i = 0, 1, 2, 3, 4, 5, 6, 7, 8, and j = 0, 1, 2, 3 and using Equation (9) is shown in Table 2.  Figure 1 shows the transmitting/receiving structure based on the DPS code sequence for P = 3. As cleared from Figure 1a, the transmitter consists of ON/OFF Keying (OOK) modulation for encoding User#1 information that is 100010010100 as tabulated in Table 2. The arriving signal is then reflected to an FBG group. The FBGs-centered wavelengths depend on the presence of bit "1" in the code sequence as an example for user#1, the centered wavelengths for the FBGs are λ 1 , λ 5 , λ 8 , and λ 10 according to Table 3.

DPS System Description
At the receiver that is shown in Figure 2b, the received signal is divided into two branches: one branch containing the decoder that has the same spectral of encoder of the desired user and the output of this branch contains p + 1 power units for the intended user accompanied by λ power units for interferers from other users. The other branch has the CDS detection technique which contains only the complementary spectrum of the desired user. For example, where user#1 is the desired user, the CDS will detect λ 2 , λ 3 , λ 4 , λ 5 , λ 6 , λ 7 , λ 9 , λ 11 , and λ 12 according to Table 3. Complementary detection is used (Comp-Decoder) which detects the complementary spectrum of the desired user (as shown in Table 2: λ 2 , λ 3 , λ 4 , λ 5 , λ 6 , λ 7 , λ 9 , λ 11 , and λ 12 ).
Then, two photo diodes are used, one at the output of decoder branch and the other one at the output of complementary branch. Photodiodes (PD) detectors here are used for converting the signal from optical domain to electrical domain. The outputs of the PDs are subtracted, then the resultant signal is passed to low pass filter (LPF) and thresholding process where the original data for the desired user are reconstructed.

Detection Techniques Selection
The goal of this work is to design an OCDMA system for low-cost applications with large cardinality, simplified design, minimum cost, and ease of implementation. Thus, an optimal choice of detection techniques with good properties of code structure is needed. Therefore, we principally show the design and operation concept of complementary CDS and SPD detection schemes and choose the best among them in terms of performance and complexity.

Complementary Detection Scheme (CDS)
The DPS system utilizing CDS is given in Figure 2a. An optical software simulator known as Optisystem, version 7.1 (Optiwave Systems Inc, Ottawa, ON, Canada) is utilized to perform CDS operation in this section. Figure 1 is used as a reference prototype to make the simulation setup. The transmitter section consists of LEDs that generate the encoder of SAC-OCDMA that uses DPS codes. Specific wavelengths are combined in the encoder using an optical coupler according to the user's assigned code then modulated by a Mach-Zehnder (MZ) modulator. The data of a pseudo random bit sequence (PRBS) generator are OOK-modulated with a non-return to zero (NRZ) pulses. The assigned wavelengths corresponding to the three users are given in Table 3. The modulated signals are transmitted through single mode fiber (SMF). Figure 2b shows the receiver based on the CDS detection scheme. Here, a power splitter is connected to splitting the spectrum in accordance with the number of users. These portions are connected to a combination of subtractors, positive over intrinsic (PIN) photodiode, FBGs, LPF, and decision-making circuit to extract the desired information via CDS technique.

Single Photodiode (SPD)
In Figure 3, the receiver structure of three users is based on the DPS code sequence for P = 3. The incoming signal is first decoded by the decoder which has a matched spectral response to the intended encoder for the data to be recovered (Decoder) then transferred to the subtractive decoder (s-Decoder).
The s-Decoder contains only frequency bins from different interferers. After the optical subtractor, the result is passed to a single balanced photodetectors whether PIN or avalanche photodiode (APD). Here, the cancellation is done in the optical domain. The logical representation of MAI cancellation for DPS code is presented in Table 4 based on  Table 3. Finally, after photo detections, LPF, and thresholding processes, the original data are reconstructed. CC of (Decoder × User#2) 1 CC of (Decoder × User#2)-CC of (Decoder × User#2) 1-1 0

Pickup of Detection Scheme
In order to select the best detection technique, we listed the required components for CDS and SPD implementation in Table 5 for three users. It shows that, 36 FBGs are needed for CDS compared to 15 FBGs. Moreover, six PINs are required for CDS while only three PINs is sufficient for SPD. In the meantime, numbers of LPFs and Subtractors are the same for both techniques. To conclude, SPD detection needs less components than complementary subtraction as in our simulated system for three users and the more preferable choice in this study.

Performance Analysis
In this section, analytical expressions are presented for the mean optical power and noises in order to get the BER performance of the SAC-OCDMA system using DPS code based on the SPD detection technique.
The mean optical power reaching the PD, when the desired user is active, is where H E (υ) and H D (υ) are the encoder and decoder transfer functions, respectively, S is the received power and B 0 is the optical source bandwidth. These functions are the spectral representations of the filters. C E (i) and C D (i) denote the i th element of the encoder and decoder code words, respectively. The PIIN expression for unpolarized thermal light source can be expressed as where B e is the electrical bandwidth. The variance of shot noise can be expressed as σ shot 2 = 2eB e < P User > (12) where is the responsivity of photodetector. The variance of thermal noise can be evaluated using [5,6] where K b is the Boltzmann's constant, T n is the receiver noise absolute temperature, and R L is the receiver load resistance. The SNR in case of DPS code can be written as [5,6,14]: Based on the Gaussian distribution, the BER is given by [15]

Results and Discussion
The performance of the three users assigned DSP codes is characterized by maximum number of allowed users, maximum transmission distance, BER, Q-factor, the SNR, and eye pattern. The parameters used in the simulation of the proposed system are given in Table 6 [13][14][15][16]. Figure 4 shows BER versus the number of users for the system using DPS code with complementary subtraction detection and SPD detection at different bit rates. As cleared from Figure 4, when the number of users increases, BER increases while the system using SPD detection technique can support a larger number of users. In addition, as the bit rate increases, the number of users that the system can support decreases. The system that uses complementary subtraction can support up to 69, 53, 37, and 22 users at 622 Mbps, 1 Gbps, 2 Gbps, and 5 Gbps, respectively with BERs values 9.01 × 10 −9 , 5.68 × 10 −9 , 7.85 × 10 −9 , and 4.91 × 10 −9 , respectively. As for the system using the SPD detection technique, it can support number of users up to 200, 171, 82, and 28, respectively, at 622 Mbps, 1 Gbps, 2 Gbps, and 5 Gbps, respectively, with BER value ≤ 10 −9 .   Figure 5 shows BER versus the number of users for the system using DPS and RD codes with CDS and SPD detection techniques at 622 Mbps data rate. As shown in Figure 5, when the number of users increases, BER increases in which the system using SPD detection technique can support a larger number of users compared with the CDS technique. The system that uses CDS technique can support up to 22 and 25, for DPS and random diagonal (RD) codes, respectively. In the meantime, at 622 Mbps, the system that uses the SPD technique can support up to 130 users at error free transmission. Figure 6 shows the effect of the effective received power that reaches PD on the performance of the system that uses DPS code with different detection techniques at 622 Mbps and fixed number of users equal to 60. It can be noticed that the system that uses complementary subtraction has a great effect when the value of effective power changed, while for SPD detection, it seems that there is no effect. As the value of effective power increases, the performance of the system using complementary subtraction becomes better while the other system that uses SPD detection has the best performance. At 622 Mbps and number of users equal to 60, BERs values when effective power is −15 dBm are 3.97 × 10 −9 and 1.67 × 10 −31 , respectively, when complementary and SPD detection techniques are used. Figure 7 shows SNR versus number of users for the system using DPS code with different detection schemes at different bit rates. As cleared from Figure 7, as the number of users increases, the SNR decreases while the system using SPD detection technique have greater value of SNR. As an example, at 50 users and bit rate 622 Mbps, SNR values are 23.6 and 28 dB, respectively, for the system use CDS and SPD detection schemes.   The effect of fiber distance on the performance of three users of the SAC-OCDMA system assigned with DPS codes and using SPD detection technique at different bit rates is given in Figure 8. As the transmission distance increases as well as bit rates, the performance of the system decreases. The maximum achievable transmission distance with BER~10 −9 that the system can travel is 52 km at 622 Mbps, which decreases at 1 Gbps and becomes 32 km, while achieving minimum distance at 2 Gbps which is 8 km. Figure 9 displays the eye diagram of one user at 10 km at 622 Mbps, 1 Gbps, and 2 Gbps. It is clear that the eye opening is large at a lower bit rate which indicates the best performance. The obtained results from Figure 10 show that as the transmission distance increases, the Qfactor decreases and the system that operates at 622 Mbps gives better Q-factor than the other ones operating at higher bit rates. The system using DPS code with SPD detection technique can transmit up to 52, 32, and 8 km, respectively, at 622 Mbps, 1 Gbps, and 2 Gbps with Q-factor value~5.6.    Figure 11 represents the way of estimation the value of Q-factor from eye diagram and that can be done by taking the time domain signal and overlapping the terraces for a certain number of symbols. The best time of sampling is that at large eye opening where we can estimate the value of Q-factor then calculate the BER from the known relation, which is BER = 0.5 × erfc(Q/ √ 2). As an example, Q = 9.6 − 0 = 9.6, then BER = 0.5 × erfc(9.6/ √ 2) = 3.9 × 10 −22 . Figure 11. Example of Q-factor reading from eye diagram. Figure 12 shows SNR versus the transmission distance for the system using the DPS code with SPD detection techniques at different bit rates. As expected, shorter transmission distance gives better values for SNR as the value of SNR at 10 km is 20 dB at 622 Mbps, while it dropped to 10 dB when the distance increased to 30 km. Moreover, at higher data rates, SNR decreases.  Figure 13 shows BER versus the received power at different transmission distance for the system using DPS code with SPD detection techniques and different photodiodes at different bit rates. As expected, APD gives higher received power compared to PIN. As cleared from Figure 13a as an example, at received power −25 dBm, the BERs values are 1.14 × 10 −16 and 9.59 × 10 −24 , respectively, when PIN and APD are used. The obtained results from Figure 14 show that as the transmission distance increases, the Q-factor decreases and the system using APD gives better Q-factor than the other one that used PIN at all transmission distances.

Conclusions
In this paper, a feasibility study to choose a detection scheme that suits a DPS code family is presented. The properties of this code family have been proven and discussed. The results of system performance are compared with reported codes. The advantage of the DPS code family can be summarized as follows: (1) good property in cross-correlation control; (2) short code length; (3) and easy to implement using fiber Bragg gratings (FBGs). The architecture of transmitter-receiver structure of both CDS and SPD techniques for DPS OCDMA system is presented. Simulation analysis that calibrates with BER, Q-factor, and eye diagram proves that DPS code using SPD technique is able to maintain error free transmission compared to the CDS technique. When the number of active users is 60, BERs of 3.97 × 10 −9 and 1.67 × 10 −31 are achieved for CDS and SPD at detection techniques, respectively, when effective power is −15 dBm at 622 Mbps. Apart from its improved performance, DPS codes with SPD technique are more flexible and require less complexity in the encoder and decoder designs. In particular, a reduction of FBG sets by 41.6% was achieved for SPD over CDS techniques.

Data Availability Statement:
The data presented in this study are available on request from the corresponding author. The data are not publicly available due to their large size.