A New Prime Code for Synchronous Optical Code Division Multiple-Access Networks

A new spreading code based on a prime code for synchronous optical code-division multiple-access networks that can be used in monitoring applications has been proposed. *e new code is referred to as “extended grouped new modified prime code.” *is new code has the ability to support more terminal devices than other prime codes. In addition, it patches subsequences with “0s” leading to lower power consumption. *e proposed code has an improved cross-correlation resulting in enhanced BER performance. *e code construction and parameters are provided. *e operating performance, using incoherent on-off keying modulation and incoherent pulse position modulation systems, has been analyzed. *e performance of the code was compared with other prime codes. *e results demonstrate an improved performance, and a BER floor of 10 was achieved.


Introduction
With the rapid increase in demand for bandwidth, a network technology that provides reliable, low latency, and highspeed data transfer is required, and advances in optical fiber networking make it a promising solution for access networks [1,2].Various enabling techniques have been extensively investigated, including time division multiplexing (TDM), wavelength division multiplexing (WDM), and optical code division multiplexing (OCDM).While TDM allows user traffic to share the medium in different time slots, WDM allows user traffic to share the medium over different wavelengths.In contrast, the OCDM technique enables user traffic to share the medium in both time and wavelength domains.Furthermore, OCDM offers unique features, such as high security transmission, dynamic bandwidth allocation, and asymmetric bandwidth capability for both downstream and upstream transmissions, in addition to its capability to accommodate a large number of user connections [3].
e general structure of an OCDM access (OCDMA) network consists of five main parts: a transmitter that includes the laser source and modulation unit; an encoder that generates a unique optical code that is used to distinguish users one from the other; a star coupler that combines or splits signals; a decoder that extracts the intended user signal; and, finally, a receiver that includes the optical detector and demodulator.At the transmitter, the information source produces a data bit for the laser at every T seconds.
e encoder then multiplies the data bit by its code word.e code word can be formed by using either a onedimensional (1D) encoding scheme in the time or wavelength domain or a two-dimensional (2D) encoding scheme that is a combination of both domains.In time-based encoding, the bit time is divided into smaller chips that are equal in number to the code length, whereas in wavelength-based encoding, the code is formed by dividing the transmitted bits into a number of unique subsets of wavelengths [4].
e spreading codes are characterized based on two correlation functions: the autocorrelation and the crosscorrelation functions.
e cross-correlation function of a signal is the function in which each signal is distinguished from other users' signals, as well as from their time-shifted version.
e autocorrelation function is the crosscorrelation of the signal with itself [5].Multiple access interference (MAI) is a critical issue in a network with high cross-correlation.
e cross-correlation proportionally increases with the number of simultaneous users in the network, inevitably resulting in performance degradation [6].
e correlation properties will improve by increasing the code length and the code weight (number of 1s in the code) [7].However, this increase leads to an increase in the processing time, hardware complexity, and power consumption [8].
Various address codes that are based on prime code family have been introduced such as basic PCs, extended PC (EPC), modified PCs (MPCs), new MPC (nMPC), padded MPC (PMPC), double-padded MPC (DPMPC), transposed MPC (T-MPC), and transposed sparse-padded MPC (T-SPMPC).e codes and their corresponding parameters including length, weight, cardinality (the number of available code-words), and correlation probabilities are shown in Table 1.As shown in Table 1, some of the codes, including MPC, nMPC, PMPC, and GPMPC, support P 2 users (9 users when P � 3) with different lengths and weights.Other codes such as T-MPC and T-SPMPC support up to 2P 2 users (18 users when P � 3). is research paper, however, proposes a new code that aims to increase the number of simultaneous users up to 4P 2 (36 users when P � 3).e new code is referred to as "extended grouped new modified prime code" (EG-nMPC).
On-off keying (OOK) and pulse position modulation (PPM) are the most popular modulation schemes used in OCDMA systems [9].e PPM-OCDMA scheme has been considered as an energy efficient scheme because, for a given bit error rate (BER), PPM-OCDMA can increase the number of users by increasing the pulse-position multiplicity (M) for the same average power, whereas an OOK-OCDMA scheme cannot increase the number of the users at a given BER [10].On the other hand, however, the OOK-OCDMA scheme has a simple and improved signaling format when compared to PPM-OCDMA, as the chip duration in the former is longer.In addition, the hardware used for the PPM modulation format has a more complex structure [11].
Optical CDMA systems require optical code acquisition and synchronization methods to improve the system's performance and eliminate the MAI [6].e main purpose of the synchronization process is to recover data by aligning the time between the transmitted signal and the decoder at the receiver side [12].Most studies regarding OCDMA systems have assumed perfect synchronization.Limited research on synchronization methods for OCDMA systems has been reported in the literature [12].e most common methods are serial search and parallel search [13].In [14], a serial-search synchronization system has been introduced and evaluated with an OOC code in OOK-OCDMA and PPM-OCDMA systems.In addition, the same authors introduced a parallel-search synchronization system based on a dual-threshold sequential method in [12] for an OOC code.In [15], a synchronization method has been introduced for noncoherent OCDMA.e paper emphasizes the significance of synchronization between the transmitter and the receiver in improving the system performance.In [16], an analysis of a serial-search algorithm for an OCDMA system applying an OOC code has been presented.e analysis is ⎪ ⎪ ⎪ ⎪ ⎩ * PC and EPC are not synchronous codes.
2 Journal of Computer Networks and Communications based on photon counting, considering the effect of MAI, dark current, and shot noise.In [17], a new algorithm referred to as the multiple-shift (MS) algorithm for code acquisition in OCDMA systems was proposed.e performance of the MS algorithm has been evaluated using an OOC code, and the paper highlights that the proposed algorithm helps to reduce the mean synchronization time.A recent work presented in [18] introduced an improved MS (IMS) algorithm.e proposed algorithm is similar to the conventional one in terms of process, but with an improved performance.
OCDM has been used as a monitoring technique for passive optical networks (PONs) due to its simplicity [23].Monitoring PON-based OCDM techniques are referred to as optical coding (OC) techniques.PON is a point-to-multipoint (P2MP) connector that is formed by deploying a passive optical splitter and a combiner at a remote node (RN), to connect an optical line terminal (OLT), located at the central office (CO), to multiple optical network units (ONUs) at the customer premises.e OC functions as a transmitter that transmits the monitoring signal from the network management system (NMS) to the RN. is monitoring signal is split into a number of subsignals that are equal to the number of ONUs.Each of the ONUs receives a subsignal, encodes it, and then sends it back to the NMS.e NMS has the capability to identify faulty ONUs by examining the veracity of the received codes [24].e OC technique utilizes the spreading codes that have been used in OCDMA systems, such as optical orthogonal code (OOC) and PC [23].e literature shows that OOC is the dominant coding technique implemented for time-domain coding in PON monitoring.A 1D OOC code has improved performance in terms of correlation; however, its construction mechanism is relatively complex.In addition, its cardinality is bound by its length and weight [9].On the other hand, 1D PC is characterized by a simple construction mechanism, its cardinality does not have an upper bound, and there is an absence of a mathematical limitation on how it is used other than to match the optical transmission system capabilities [6,9].e correlation probabilities of OOC are higher than those of PC; however, this feature has become less important in PON due to the use of the time division multiple access (TDMA) technique, and the ranging process is performed by the OLT and ONU to avoid upstream burst collision.e selection of the spreading code implemented in OC techniques is determined by the cardinality of the spreading code chosen [23].Hence, the main objective is to provide the number of code-words that are compatible with PON splitting ratios (32, 64, and 128).e proposed code can be implemented in OC techniques as it provides compatible cardinality with lower unused code-words when compared to other PCs, thereby leading to an increase in the code utilization factor that is defined as the number of active users at a given BER to the code cardinality.
e rest of the paper is organized as follows: Section 2 explains the code construction and its properties.Section 3 evaluates the performance of the proposed code with an OOK modulation system.Section 4 assesses the performance of the proposed code with an incoherent PPM system.Section 5 discusses the results.
e conclusion is provided in Section 6.

Proposed Code
A system that uses an incoherent OCDMA is based on the binary 1 and 0, where 1 represents the presence of light and hence the encoding process executes and generates a waveform s(n).e code sequence represents the destination address f(n) [7].On the other hand, 0 represents the absence of light which means the encoding process will not be executed.After the encoding process and transmission to the user, the receiver correlates the received signal with the destination address. is correlation function is denoted by r(n) and expressed as [7] where N is the number of users.If the signal arrives correctly, then the received signal is equal to the destination address with s(n) � f(n) and ( 1) signifies an autocorrelation function.

Construction of EG-nMPC.
e construction of the EG-nMPC is described in the following seven steps: Step 1. Choose the prime number, for example, P � 3.
Step 2. Generate the prime sequence based on a Galois Field GF(P) [6].
Step 3. Map S i into a binary sequence C i as follows [6]: where Step 4. Extend the prime code by patching each subsequence by P of 0s.
Step 5.For each code sequence, apply the time-shifting method described in MPC [6].Table 2 shows the resulting code-words with P � 3.
Step 6. Apply the method used in nMPC which is based on repeating the last sequence stream of the earlier code word and rotating it in the group [9].Table 3 shows the result of this step.In the table, the padded sequence stream of the first code and the last sequence stream of the earlier code are presented in bold.
Step 7. From each group, generate two groups: (i) Group 1 consists of the S i,j , where i � 0, . .., P − 1 and j can take the values of zero or any even number.Other subsequences are patched with blocks of zeros.(ii) Group 2 consists of the S i,j , where i � 0, . .., P − 1 and j is an odd number.Other subsequences are patched with blocks of zeros.
e final code-words are presented in Table 4. e code is represented by C xyz , where x denotes the group (0 to P − 1), y denotes the subgroup (1 or 2), and z denotes the code sequence (0 to 2P − 1).

Code Parameters.
e code length L, code weight w, code cardinality |C|, autocorrelation λ xyz , and crosscorrelation λ x 1 y 1 z 1 ,x 2 y 2 z 2 of EG-nMPC are given by  10) is obtained as follows: each code weight (w) in the code causes a cross-correlation of "1" with only one code from other groups (P − 1 group), which are w(P − 1) cross-correlation pairs.For example, the code C 010 will not cause cross-correlation with any code in the same group either in the same or another subgroup.In addition, the code will not cause cross-correlation with any code in a different group or in a different subgroup, as a consequence of Step 7 in the code construction.However, the code will have a cross-correlation with one code from other groups and in the same subgroup, for example, C 114 , C 115 , C 214 , and C 215 .
us, from (7), the cross-correlation value of "1" for one user and all users can be formed as e probability of a cross-correlation value of "1" can be defined as the number of pairs causing a cross-correlation value of 1 divided by the total number of cross-correlation pairs [7] and can be expressed as e total number of correlation pairs of EG-nMPC is given by us, the probability of a cross-correlation value of "1" and "0" can be obtained as in (15) and (16), respectively.e probability of a cross-correlation value of 1 is given by e probability of a cross-correlation value of 0 is given by In a synchronous OCDMA system, time synchronization (T) is performed at the end of each bit duration, where T � L. chip duration [7].For a "1 1 0 1" data stream and synchronization time T, the correlation values of alternate codes are presented in Figures 1-6. Figure 1 shows the autocorrelation value of C 010 at each time interval T, and it is equal to w (2 in Figure 1).Figures 2 and 3 show the crosscorrelation value between two codes in a different group but the same subgroup.Figure 2 shows the case when the crosscorrelation value is 1, while Figure 3 shows the case when the cross-correlation value is 0. Figures 4-6 present the crosscorrelation values of two codes from the same group and same subgroup, same group and different subgroup, and different group and different subgroup, respectively.As shown in these figures, the value of the cross-correlation at time T is 0.

Performance Analysis of OOK-OCDMA System
e bit error rate (BER) of the one-dimensional timespreading code using incoherent OOK modulation system relies on three main factors: the binary stream, the threshold range, and the probability of "hits" between "1s" within different code-words [8].e BER can be defined as In (17), w is the code weight, N is the number of active users, and q is the hit possibility of 1s between a particular user and the intended user.Equation ( 17) is for an asynchronous OCDMA system applying an OOC code.e difference between an asynchronous and synchronous system is found in the value of q.In (17), "q" is given by

Correlation values
where the factor (1/2) refers to the possibility that the interfering user sends "1".However, the q for a synchronized OCDMA system depends on the cross-correlation expectation (probability of cross-correlation value of "1") between two codes, which can be expressed as [7] By multiplying the above equation with the factor (1/2), the q for a synchronous OCDMA system can be expressed as us, the BER probability of EG-nMPC can be formulated as

Performance Analysis of PPM-OCDMA System
EG-nMPC provides 4P 2 code sequences; thus, the number of users is 4P 2 .By assuming N is the number of active users, 4P 2 -N is the number of idle users.Υ n is defined as a random variable where us, If user 1 is the desired user, the random variable T and the number of active users who are not causing crosscorrelation with user 1 could be defined as in (11): If t is the realization of T, the probability distribution of the random variable T can be obtained as where t ∈ {t min , . .., t max }, Let the photon count collection be denoted by the vector Y n for user n, where Y n � (Y n,0 , Y n,1 , . .., Y n,M−1 ), the interference be denoted by the random vector k, where k � (k 0 , k 1 , . .., k m−1 ) T , and the vector u is the realization of k, where u � (u 0 , u 1 , . .., u M−1 ) T .By then assuming T � t, k can be defined as a multinomial random vector with the following probability [2]: where en, the BER can be defined by [2] where M denotes the multiplicity and P E denotes the error probability [2].Similar to (9) in [2], the lower bounded BER can be obtained in (34) by modifying (5) in [10] based on EG-nMPC properties.By taking Q→∞, where Q defined as µ in (32) is the average photon count per pulse (photons/nat), and nat can be expressed as follows [25,26]: Journal of Computer Networks and Communications

Discussion
A comparison of the results obtained from both EG-nMPC and MPC, which is the base for many standard codes reported in the literature, highlights the performance superiority of EG-nMPC.When EG-nMPC is compared with T-SPMPC, a recently developed code that supports a large number of users with a low code weight as in EG-nMPC, the result shows that EG-nMPC provides an improvement.In Figure 7, the correlation expectation of the MPC, T-SPMPC, and EG-nMPC is presented and, as shown in the figure, the correlation expectation of MPC is the highest.With P � 5, the correlation expectation is 0.83.As P increases to 23 Figure 8 presents the BER performance versus the number of active users of OOK-OCDMA system.It compares the performance of the three codes with P � 11 and P � 13. e figure shows that at the BER of 10 −9 , the performances of the three codes are similar with a slight improvement of MPC, followed by EG-nMPC and then T-SPMPC.However, with increasing the number of the users, the performance of the EG-nMPC has improved, and at a point, its performance with P � 11 is superior than the performance of the other codes with P � 13.In addition, this improvement can be noticed clearly in Figure 9 with P � 23 and P � 37. Figure 9 shows that EG-nMPC has achieved the required BER with more users.
Figure 10 illustrates the BER performance versus the number of active users of PPM-OCDMA system.e figure compares performances of MPC and EG-nMPC, with, µ � 150, M � 16, P � 11, and P � 13.It is important to note that the comparison is made between EG-nMPC and MPC only.
is is so due to the absence of mathematical expressions to evaluate BER of T-SPMPC, in the case of PPM-OCDMA system without interference cancellation.e figure shows that at the BER value of 10 −9 , both codes support almost the same number of users.However, as the number of users increases, the BER of EG-nMPC acquires smaller values, pointing to a better performance.e smaller values of BER are attributed to the higher capability of EG-nMPC to accommodate a larger number of users.e higher capability of EG-nMPC to accommodate more users with the same average photons/nat is also evident from Figure 10, an outcome that points to the code being energy efficient.
It is important to note the significant role played by the multiplicity, M, in improving the system performance, as shown in Figure 11. Figure 11 shows the performance of BER versus the number of active users, with M � 16, M � 8, P � 11, and µ � 150.As shown in the figure, although an increase in the value of M results in an improvement in system performance, larger values of M lead to an increase in system cost and complexity.EG-nMPC increases the cardinality of the code and supports more users with a smaller value of P, as shown in Figure 12.Implementing EG-nMPC as a spreading code for OC to monitor PON networks that support splitting ratios of 32, 64, and 128 could be seen to be an optimal solution.Table 5 shows a comparison of the code parameters for the different splitting ratios of PON.For a splitting ratio of 32, EG-nMPC has been shown to have the lowest weight, length, and unused codes, that is, 2, 24, and 4, respectively.

8
Journal of Computer Networks and Communications is renders EG-nMPC a superior code for supporting a splitting ratio of 32, as compared to other codes.T-SPMPC ranks second in superiority, with MPC being the least desirable code among the three.e very slight increase in the number of unused codes exhibited by T-SPMPC as compared to MPC does not carry any significant weight on this superiority ranking.e inferiority of MPC, for a splitting ratio of 32, is evidenced by the values of its weight, its length, and the number of unused codes, that is, 7, 49, and 17, respectively.
For a splitting ratio of 64, MPC shows the least desirable option with largest values for weight, length, and unused codes, that is, 11, 121, and 57, respectively.When it comes to code length and the number of unused code, T-SPMPC is shown to be a better option when compared to EG-nMPC, with a code length of 49, as compared to 60, and the number of unused codes being 34 as compared to 36.However,     Journal of Computer Networks and Communications EG-nMPC possesses a lower code weight when compared to T-SPMPC, that is, 3 and 4, respectively.For a splitting ratio of 128, although MPC has the lowest number of unused codes, its code weight is far larger and the code length is far longer than in other codes.EG-nMPC exhibits lower code weight, code length, and a smaller number of unused codes as compared to T-SPMPC.Consequently, it could be concluded that EG-nMPC possesses optimal numerical values for code weight, code length, and the number of unused codes.

Conclusion
In this research paper, a new code for a synchronous OCDMA network monitoring that is based on a prime code has been proposed.e paper presents details with respect to code construction and its parameters.e proposed code is based on dividing each code into two groups and patching some subsequences with 0s in order to increase cardinality, reduce probability of cross-correlation values, and reduce energy consumption.e performance of the proposed code has been evaluated using incoherent OOK-OCDMA system, and then compared to both MPC and T-SPMPC.In incoherent PPM-OCDMA systems, however, performance of the proposed code was evaluated and compared to MPC only.In addition, it has been shown that the use of EG-nMPC as a spreading code for a PON monitoring-based OC technique possesses superior characteristics when compared to the other two codes, based on code weight, code length, and the number of unused codes.

Figure 8 :
Figure 8: BER of MPC, T-SPMPC, and EG-nMPC versus the number of active users of OOK-OCDMA system.

Figure 10 :
Figure 10: BER of T-SPMPC and EG-nMPC versus the number of active users of PPM-OCDMA system for M � 8 and µ � 100.

Figure 11 :
Figure 11: e role of multiplicity M in PPM-OCDMA system for MPC and EG-nMPC, with P � 11.

Table 1 :
PC families and parameters.

Table 2 :
Time shifting of extended prime code, P � 3.

Table 3 :
Binary sequence of extended new modified prime code, P � 3.

Table 4 :
Binary sequence of extended grouped new modified prime code, P � 3.
, this figure reaches 0.96.In comparison, T-SPMPC exhibits lower values of correlation expectation.With P � 5, the correlation expectation is 0.32; this figure drops to 0.29 as P increases to 23.EG-nMPC exhibits the smallest values of correlation expectation as compared to the other codes.With P � 5, the correlation expectation of EG-nMPC is 0.1212; this figure increases slightly to reach 0.1248 as P increases to 23.