1 Introduction

The maturity of optical code division multiple access (OCDMA) technology had the use of optical components to produce multiple access networks (Kataoka et al. 2011; Gharaei et al. 2010; Lalmahomed et al. 2010; Chanclou et al. 2012; Kazovsky et al. 2007). Passive optical networks (PONs) used passive optical components to produce network services. The OCDMA PON was based on use of various multiplexing technologies, including time division multiplexing (TDM), wavelength division multiplexing (WDM), hybrid TDM/WDM, code division multiplexing (CDM), and optical code division multiplexing (OCDM) for access networks (Ayotte and Rusch 2005; Salehi and Brackett 1989; Ahmed et al. 2013; Shalaby 2002). The OCDMA-based PON produced a highly promising solution for fiber-to-the-home (FTTH) applications. The PON technology used for OCDMA has seen some improvements in recent decades. The establishment of PON technology (Yoshima et al. 2010; Yang et al. 2004; Ghafouri-Shiraz et al. 2007; Mohamed et al. 2013; Prucnal et al. 1986; Ugale and Mishra 2010) adopted this promising technique to generate broadband access networks with the following advantages: multiple access capability, accurate timing, ability to support variable bit rates, and security against unauthorized users.

Tainta et al. (2011) developed a coding/decoding setup for a spectral phase encoding OCDMA (SPE-OCDMA) system. The use of an easily tunable electro-optic phase modulator based on the temporal self-imaging effect achieved line-by-line coding of the transmitted signal and assured its compatibility with WDM techniques. Modulation of the code sequences was performed at the same rate that was used for the data. The modulation of the code sequences in this manner avoided the need to use high-bandwidth electro-optic modulators. Based on the concept for this technique, an experimental back-to-back coder/decoder setup was produced that transmitted an unmodulated optical pulse train within an optical window. The proposed system avoided the problems inherent in similar schemes related to temperature control or requirements for high-bandwidth electro-optic modulators.

Fathallah et al. (2014) used OCDMA to produce a promising candidate for next generation passive optical networks (NG-PON). The OCDMA-PON can potentially allow all customers to use a Gb/s-class bandwidth upstream with inherent flexibility. OCDMA was subject to multi-user interference (MUI) and various detection noises. The development of an efficient interference-cancelling detection method was based on mixed Poisson–Gaussian noise. A maximum likelihood framework was developed for the system detection process using Gaussian, Poisson and Poisson–Gaussian noise. Then, the interference-cancelling detector was developed for the Poisson–Gaussian noise case after derivation of a conventional expectation–maximization (EM) detector for the Poisson noise case. Finally, the detector was simulated and compared with the projected parallel interference-cancelling EM and other types of detectors to validate its superiority and enhanced performance.

In this paper, we propose a family of new codes called 1-D added length codes for use in OCDMA systems to achieve the proposed structure using an optical line terminal (OLT) and optical network units (ONUs). The proposed structure has a simple architecture for ease of operation, which is produced using the proposed OLT and the ONUs. The OLT transfers the information bits into the code sequences of the 1-D added length codes in OCDMA. The ONUs receive the OCDMA signals and perform a modified cross-correlation, which produces the recovered “1” and “0” bits at the photodiodes. The proposed system suffers from the interference from other simultaneous users, which is called MUI, but the modified cross-correlation of the photodiode signals removes the MUI. The proposed modified cross-correlation process creates a modified photocurrent that suppresses the phase-induced intensity noise (PIIN). In the numerical results, we use the bit error rate (BER) to obverse the corresponding number of simultaneous users, data transmission rate, and effective source power. The number of simultaneous users for the proposed system using the 1-D added length codes is 23 users and is a larger number of simultaneous users than that for the other systems using 1-D M-sequence codes (Yang et al. 2004), 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes (Wei and Ghafouri-Shiraz 2002). When the BER = 10−9, the data transmission rate for the proposed system using the 1-D added length codes is 2.5 Gbps and is higher than that for the other systems using the 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. The effective source power for the proposed system when using the 1-D added length codes is −2 dBm, and is less power than that for the other systems using the 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes.

This paper is organized as follows. In Sect. 2, the code sequences of the 1-D added length codes are developed. In Sect. 3, we use the OLT and ONUs to produce a description of the proposed system. In Sect. 4, a performance analysis is performed to determine the signal-to-noise ratio (SNR) and the BER. In Sect. 5, the numerical results are discussed in terms of the number of simultaneous users, data transmission rate, and effective source power. In Sect. 6, conclusions are drawn.

2 1-D added length codes

We propose the 1-D added length codes for use in spectral amplitude coding (SAC) OCDMA networks. The proposed codes have code structures that enable construction of the new code families for the 1-D added length codes. The proposed codes use elements of the number sequences of the 1-D added length codes that consist of groups. We have a series of new code families for the prime number α used in each group. The 1-D added length codes use the prime number α to determine the number sequences. The proposed codes use the 1-D added length codes to produce number sequences for these 1-D added length codes. The new code families of the 1-D added length codes have the code characteristics required to create the two steps for the 1-D added length codes as follows.

The first step uses the code weight position to derive the following expression:

$$\sigma_{c,\varepsilon } (\delta ) = \left\{ {\begin{array}{*{20}l} {2\left[ {(\delta *(\alpha + c) - \varepsilon - \kappa ) \, } \right] + \nu - 1,} \hfill & {\delta = 0,1, \ldots ,\alpha - 1,} \hfill \\ {[\alpha + cc] \, \bmod \, \alpha ,} \hfill & {\delta = \alpha ,} \hfill \\ \end{array} } \right.$$
(1)

where δ is [0, 1, …, α], α is the prime number, c is [0, 1, 2, …, α − 1], ε is [0, 1, 2, …, α − 1], κ is a selection from the sequence [0, 1, 2, …, α − 1], cc is a selection from the sequence [0, 1, 2, …, α − 1], and v is taken from [1, 2]. We construct the code weight positions in the elements of the number sequences, which are from the sequence [0, 1, …, 2α − 1] in the finite field GP(α) over the prime number α. The number sequence σ c,ε (δ) is used to create the code weight positions. The upper part of Eq. (1) in the 1-D added length codes is formed by the multiplication of δ and (α + c) and subsequent subtraction of δ*(α + c) and (ε + κ). The lower part of Eq. (1) in the 1-D added length codes is formed by addition of α and cc. The proposed codes use different number sequences for each pair of fixed parameters κ and cc by changing the parameters c and ε. When both c and ε change, the different number sequences constitute the code family of the 1-D added length codes.

The second step uses the number sequences σ c,ε (δ) to map the code sequences of the 1-D added length codes. Then, based on the number sequences σ c,ε (δ), the proposed codes have binary number code sequences Q μ,φ that are found using the elements of the following mapping method:

$$\, q_{\mu ,\varphi } = \left\{ {\begin{array}{*{20}l} {1,} \hfill & {\varphi = \sigma_{c,\varepsilon } (\delta ) + 2*\delta *\alpha ,} \hfill \\ {0,} \hfill & {\text{otherwise,}} \hfill \\ \end{array} } \right.$$
(2)

where μ = [0, 1, 2, …, 2α 2 − 1] and φ = [0, 1, 2, …, 2α 2 + 2α]. The proposed codes use the elements of the following mapping method to produce the binary number code sequences Q μ,φ . The 1-D added length codes use the number sequences σ c,ε (δ) to produce the required code sequences for the 1-D added length codes. Table 1 shows the code sequence Q μ,φ of the 1-D added length codes using the prime number 3. Each code sequence has 2α 2 + 2α elements, which are to be divided into 2(α + 1) groups. Each group has one “1” and (α − 1) “0”s. Therefore, the proposed codes transfer the information bits into the code sequences for the 1-D added length codes.

Table 1 Code sequence Q μ,φ of 1-D added length codes using the prime number 3

We use the code sequence Q μ,φ and the code sequence Q μ to produce a cross-correlation between the two code sequences as follows:

$$R(\mu ,\mu^{\prime} ) = \sum\limits_{\mu = 0}^{{2\alpha^{2} + 2\alpha - 1}} {q_{\mu ,\varphi } q_{{\mu^{\prime} ,\varphi }} } ,$$
(3)

where q μ,φ and q μ are the elements of code sequence Q μ,φ and code sequence Q μ , respectively. The proposed codes based on the 1-D added length codes use the code sequence Q μ,φ and code sequence Q μ to produce the cross-correlation R(μ, μ′). The cross correlation R(μ, μ′) of the 1-D added length codes is derived as follows:

$$R(\mu ,\mu^{\prime} ) = \left\{ {\begin{array}{*{20}l} {\alpha + 1,} \hfill & {\mu = \mu^{\prime} ,} \hfill \\ {0,} \hfill & {\mu \ne \mu^{\prime} ,v \ne v^{\prime} ,} \hfill \\ {1,} \hfill & {\text{otherwise}}. \hfill \\ \end{array} } \right.$$
(4)

The cross-correlation R(μ, μ′) of the 1-D added length codes has the classifications μ = μ′, μ ≠ μ′, υ ≠ υ′, and otherwise. If we find that μ = μ′, then the cross-correlation R(μ, μ′) of the 1-D added length codes produces the result α + 1. If we find that μ ≠ μ′ and υ ≠ υ′, then the cross correlation R(μ, μ′) of the 1-D added length codes produces the result 0. If we obtain otherwise, then the cross-correlation R(μ, μ′) of the 1-D added length codes produces the result 1. Therefore, the proposed codes use the code sequence Q μ,φ and the code sequence Q μ to produce the cross-correlation R(μ, μ′) of the 1-D added length codes. The cross-correlation between the code sequence Q μ,φ and the code sequence Q μ produces the interference originating from the other simultaneous users called MUI.

The proposed codes use the code sequence Q μ to operate the modified complementary code sequence Q μ . The cross-correlation between the code sequence Q μ,φ of the 1-D added length codes and the modified complementary code sequence Q μ of the 1-D added length codes is follows:

$$R^{\prime} (\mu ,\mu^{\prime} ) = \sum\limits_{\mu = 0}^{{2\alpha^{2} + 2\alpha - 1}} {q_{\mu ,\varphi } \overline{{q_{{\mu^{\prime} ,\varphi }} }} } ,$$
(5)

where R′(μ, μ′) is the cross-correlation of the 1-D added length codes, and \(\overline{{q_{{\mu^{\prime} ,\varphi }} }}\) represents the elements of the modified complementary code sequence Q μ′,φ of the 1-D added length codes. The cross-correlation between the code sequence Q μ,φ of the 1-D added length codes and the modified complementary code sequence Q μ′,φ of the 1-D added length codes has the classifications μ = μ′, μ ≠ μ′, υ ≠ υ′, and otherwise, which are given as follows:

$$R^{\prime} (\mu ,\mu^{\prime} ) = \left\{ {\begin{array}{*{20}l} {0,} \hfill & {\mu = \mu^{\prime} ,} \hfill \\ {0,} \hfill & {\mu \ne \mu^{\prime} ,\upsilon \ne \upsilon^{\prime} ,} \hfill \\ {\alpha ,} \hfill & {\text{otherwise}}. \hfill \\ \end{array} } \right.$$
(6)

If we obtain μ = μ′, then the cross-correlation R′(μ, μ′) of the 1-D added length codes has the value 0. If we obtain μ ≠ μ′ and υ ≠ υ′, then the cross correlation R′(μ, μ′) of the 1-D added length codes has the value 0. If we obtain otherwise, then the cross-correlation R′(μ, μ′) of the 1-D added length codes has the value α. We use the code sequence Q μ,φ and the modified complementary code sequence Q μ′,φ to produce the cross-correlations R(μ, μ′) and the cross-correlations R′(μ, μ′) for the 1-D added length codes. We use the cross-correlation R(μ, μ′) between the code sequence Q μ,φ and code sequence Q μ′,φ and cross-correlation R′(μ, μ′) between the code sequence Q μ,φ and modified complementary code sequence Q μ′,φ as the equations for Eqs. (4) and (6), respectively. The cross-correlations R(μ, μ′) and R’(μ, μ′) of the 1-D added length codes thus derive the relationships required to produce the MUI.

The modified cross-correlation creates a subtraction between the cross-correlation R(μ, μ′) and cross-correlation R′(μ, μ′)/α. We then use the cross-correlation R(μ, μ′) and cross-correlation R′(μ, μ′)/α of the 1-D added length codes to produce the modified cross-correlation as follows:

$$\begin{aligned} R_{M} (\mu ,\mu^{ \prime} ) & = R(\mu ,\mu^{ \prime} ) - \frac{{R^{ \prime} (\mu ,\mu^{ \prime} )}}{\alpha } \\ & = \left\{ {\begin{array}{*{20}l} {\alpha + 1,} \hfill & {\mu = \mu^{\prime} ,} \hfill \\ {0,} \hfill & {\text{otherwise}}, \hfill \\ \end{array} } \right. \\ \end{aligned}$$
(7)

where R M (μ, μ′) is the modified cross-correlation. R M (μ, μ′) is the auto-cross-correlation = “α + 1” for μ = μ′ or the cross-correlation = “0” for otherwise. The modified cross-correlation provides the ideal cross-correlation required to produce μ = μ′ as the specific recovered bit from the 1-D added length codes. We thus perform the modified cross-correlation to produce the recovered bits. The proposed codes obtain the information bits required to output the code sequence Q μ,φ of the 1-D added length codes, which produces the modified cross-correlation required to recover the recovered bits. The modified cross-correlation R M (μ, μ′) of the 1-D added length codes then eliminates the MUI using the interference contributions of the other simultaneous users. Thus, we obtain the modified cross-correlation R M (μ, μ′) of the 1-D added length codes that is required to perform the ideal cross-correlation, which removes the MUI. We use the photodiodes to perform the modified cross-correlation of the 1-D added length codes to suppress the PIIN. Therefore, the proposed codes create a modified cross-correlation to recover the recovered bits that eliminates the MUI and suppresses the PIIN.

3 System description

Figure 1 shows a schematic block diagram of the 1-D added length codes, where the proposed architecture comprises the OLT, the 1 × 2α 2 optical splitter, and 2α 2 of the ONU(μ), where μ = 0, 1, …, 2α 2 − 1. The OLT connects to the 1 × 2α 2 optical splitter. The 1 × 2α 2 optical splitter then connects to the 2α 2 of the ONU(μ), where μ = 0, 1, …, 2α 2 − 1. The system operation is as follows. The OLT transmits the code sequences of the 1-D added length codes to be sent to the 1 × 2α 2 optical splitter. The 1 × 2α 2 optical splitter separates the code sequences of the 1-D added length codes into the 2α 2 numbers corresponding to the ONUs. The 2α 2 ONUs then receive the code sequences of the 1-D added length codes to decode the recovered bits. Therefore, we use the OLT, 1 × 2α 2 optical splitter, and 2α 2 ONUs to create the optical fiber connections.

Fig. 1
figure 1

Schematic block diagram of the 1-D added length codes

Figure 2 shows the proposed architecture of the OLT. The proposed OLT architecture comprises an unpolarized broadband laser source (BLS), a 1 × 2α 2 optical splitter, 2α 2 electro-optic modulators (EOMs), 2α 2 optical circulators, 2α 2 fiber Bragg gratings FBGtμ_1, where μ = 0, 1, 2, …, 2α 2 − 1, and a 2α 2 × 1 optical combiner. The unpolarized BLS connects to the 1 × 2α 2 optical splitter. The 1 × 2α 2 optical splitter then connects to the 2α 2 EOMs. The 2α 2 EOMs then connect to the 2α 2 optical circulators. The 2α 2 optical circulators then connect to the 2α 2 fiber Bragg gratings FBGtμ_1, where μ = 0, 1, 2, …, 2α 2 − 1. The 2α 2 fiber Bragg gratings FBGtμ_1 then connect to the 2α 2 × 1 optical combiner.

Fig. 2
figure 2

Proposed architecture of the OLT

The OLT system operation is as follows. The unpolarized BLS emits optical light that is delivered to the 1 × 2α 2 optical splitter, which then creates the 2α 2 optical light beams. The 2α 2 optical light beams are delivered to the 2α 2 EOMs with the controlled values b i , where μ = 0, 1, 2, …, 2α 2 − 1, to produce the information bits. The 2α 2 EOMs then deliver the resulting beams to the 2α 2 optical circulators to be sent to the 2α 2 fiber Bragg gratings FBGtμ_1, where μ = 0, 1, 2, …, 2α 2 − 1. The gratings of fiber Bragg gratings FBGtμ_1 is set to match the complementary code sequence Q μ,φ of the 1-D added length codes. The fiber Bragg grating FBGtμ_1 then filters out the complementary code sequence Q μ,φ of the 1-D added length codes and filters the code sequence Q μ,φ of the 1-D added length codes. The reverse path of the optical circulator has the complementary code sequence Q μ,φ of the 1-D added length codes to be filtered out. We use the 2α 2 fiber Bragg gratings FBGtμ_1, where μ = 0, 1, 2, …, 2α 2 − 1, to provide the inputs of the code sequence Q μ,φ of the 1-D added length codes to the 2α 2 × 1 optical combiner. Therefore, the OLT uses the unpolarized BLS to produce the code sequences of the 1-D added length codes, which are sent into the 1 × 2α 2 optical splitter, and 2α 2 ONU(μ), where μ = 0, 1, …, 2α 2 − 1, in Fig. 2.

Figure 3 shows the proposed architecture of the ONU(μ), where μ = [0, 1, …, 2α 2 − 1]. The proposed architecture of the ONU(μ) is composed of a left optical circulator and a right optical circulator, fiber Bragg grating FBGrμ_1, fiber Bragg grating FBGrμ_2, optical attenuator 1/α, and balanced detector using the upper photodiode and the lower photodiode. The code sequences of the 1-D added length codes connect to the left optical circulator of the ONU(μ). The left optical circulator connects to the fiber Bragg grating FBGrμ_1 and the right optical circulator. The right optical circulator then connects to the fiber Bragg grating FBGrμ_2. The fiber Bragg grating FBGrμ_1 and fiber Bragg grating FBGrμ_2 with optical attenuator 1/α then connect to the balanced detector using the upper photodiode and the lower photodiode, respectively.

Fig. 3
figure 3

Proposed architecture of the ONU(μ)

ONU(μ) system operation is as follows. The code sequences of the 1-D added length codes are received by the left optical circulator. The passed path of the left optical circulator then transmits the code sequences of the 1-D added length codes to operate fiber Bragg grating FBGrμ_1. The fiber Bragg grating FBGrμ_1 has the required number of the gratings of the complementary code sequence Q μ,φ of the 1-D added length codes. FBGrμ_1 thus filters the code sequence Q μ,φ of the 1-D added length codes and filters out the complementary code sequence Q μ,φ of the 1-D added length codes, which represents the reverse path of the left optical circulator. The reverse path of the left optical circulator is the passed path of the right optical circulator. The passed path of the right optical circulator is then used to transmit the complementary code sequence Q μ,φ of the 1-D added length codes to operate fiber Bragg grating FBGrμ_2. The fiber Bragg grating FBGrμ_2 has the number of gratings to be equal to the modified complementary code sequence Q μ,φ of the 1-D added length codes. FBGrμ_2 thus filters the modified complementary code sequence Q μ,φ of the 1-D added length codes. The outputs of FBGrμ_1 and FBGrμ_2 with the optical attenuator 1/α then deliver to the upper photodiode and lower photodiode in the balanced detector, respectively.

The output photocurrent of photodiode PD0 is proportional to R (0)(μ, μ′). The output photocurrent of photodiode PD1 is proportional to R (1)(μ, μ′). The proposed ONU(μ) structure suffers the interference from the ONU(μ) using unmatched codewords in the MUI. According to Eq. (7), the modified photocurrent of the photodiodes is proportional to R (0)(μ, μ′) − R (1)(μ, μ′)/α, which is (a + 1) for μ = μ′ or zero otherwise. The MUI is thus completely eliminated by the modified photocurrents of the photodiodes. Additionally, because the PIIN comes from the simultaneous users, the PIIN can also be suppressed using the modified photocurrents of the photodiodes. Therefore, the modified photocurrents of the photodiodes combine to remove the MUI and suppress the PIIN.

4 Performance analysis

The performance analysis provides the number of the simultaneous users, data transmission rate, and effective source power, which are required to measure the BER. A Gaussian approximation is used to calculate the BER. The BER is used to calculate the SNR, which determines the square of the photocurrent from the modified photocurrent and the photocurrent noise variance. The photocurrent noise variance contains the shot noise, PIIN, and thermal noise. Based on a simplified analysis, some assumptions are are defined as follows. Each of the spectral components has an identical spectral width. Each simultaneous user uses equal amounts of power at the ONUs. The broadband light source is ideally unpolarized and has a flat spectrum over [f o  − Δf/2, f o  + Δf/2]. f o and Δf are the central frequency and bandwidth of the source, respectively. The code sequences of the 1-D added length codes arrive at the ONUs. Therefore, the performance analysis uses the BER to measure the proposed system overall.

The power spectral density (PSD) of the received optical laser signals in the ONU(μ) is described as follows:

$$\Lambda (f) = \frac{{P_{sr} }}{{\Delta f}}\sum\limits_{\theta = 1}^{\rm O} {Z(\theta )\sum\limits_{\mu = 0}^{{(2\alpha^{2} - 1)}} {\sum\limits_{\varphi = 0}^{{(2\alpha^{2} + 2\alpha - 1)}} {q_{\mu ,\varphi }\Psi (f,\varphi )} } } ,$$
(8)

where P sr is the effective source power at the ONU(μ), Δf is the source bandwidth, Z(θ) is the data bit of the θ-th user (which can be “1” or “0”), O is the number of simultaneous users, α is the code weight of the code sequence in the 1-D added length codes, and q μ,φ is an element of the θ-th user’s in the code sequence Q μ,φ . For convenience in the analysis, Ψ(f, φ) produces the following equation:

$$\begin{aligned}\Psi (f,\varphi ) & = \left\{ {\upsilon \left[ {f - f_{0} - \frac{{\Delta f}}{{2(2\alpha^{2} + 2\alpha )}}\left( { - (2\alpha^{2} + 2\alpha ) + 2\varphi } \right)} \right]} \right. \\ & \quad - \left. {\upsilon \left[ {f - f_{0} - \frac{{\Delta f}}{{2(2\alpha^{2} + 2\alpha )}}\left( { - (2\alpha^{2} + 2\alpha ) + 2\varphi + 2} \right)} \right]} \right\}, \\ \end{aligned}$$
(9)

υ(f) is the unit step function, as follows:

$$\upsilon (f) = \left\{ {\begin{array}{*{20}l} {1,} \hfill & {f \ge 0,} \hfill \\ {0,} \hfill & {f < 0.} \hfill \\ \end{array} } \right.$$
(10)

Therefore, the PSD of the received optical laser signals in the ONU(μ) is given by Eq. (8).

The cross-correlation between the codewords Q μ,φ and Q 0 is given by the PSDs at the photodiodes of the ONUs. Therefore, the cross-correlation during a single bit period using the PSDs at the photodiodes of the ONUs can be written as follows:

$$H_{0} (f) = \frac{{P_{sr} }}{{\Delta f}}\sum\limits_{\theta = 1}^{\rm O} {Z(\theta )\sum\limits_{\mu = 0}^{{(2\alpha^{2} - 1)}} {\sum\limits_{\varphi = 0}^{{(2\alpha^{2} + 2\alpha - 1)}} {q_{\mu ,\varphi } q_{0,\varphi }\Psi (f,\varphi )} } } ,$$
(11)
$$H_{1} (f) = \frac{{P_{sr} }}{{\Delta f\alpha }}\sum\limits_{\theta = 1}^{\rm O} {Z(\theta )\sum\limits_{\mu = 0}^{{(2\alpha^{2} - 1)}} {\sum\limits_{\varphi = 0}^{{(2\alpha^{2} + 2\alpha - 1)}} {q_{\mu ,\varphi } \overline{{q_{0,\varphi } }}\Psi (f,\varphi )} } } ,$$
(12)

where α is the code weight of the code sequence in the 1-D added length codes. Therefore, H 0(f) and H 1(f) correspond to the cross-correlations. Because the photodiodes are PD0 and PD1, the photocurrents I PD0 and I PD1 are developed as follows:

$$\begin{aligned} I_{PD,i,0} & = R\int_{0}^{\infty } {H_{0} (f)df} \\ & = \frac{{RP_{sr} }}{{\Delta f}}\int_{0}^{\infty } {\sum\limits_{\theta = 1}^{\rm O} {Z(\theta )\sum\limits_{\mu = 0}^{{(2\alpha^{2} - 1)}} {\sum\limits_{\varphi = 0}^{{(2\alpha^{2} + 2\alpha - 1)}} {q_{\mu ,\varphi } q_{0,\varphi }\Psi (f,\varphi )} } } df} \\ & = \frac{{RP_{sr} }}{{2\alpha^{2} + 2\alpha }}\left( {(\alpha + 1) + \frac{{ (O{ - 1)(}\alpha^{2} { - 1)}}}{{ (2\alpha^{2} { - 1)}}}} \right), \\ \end{aligned}$$
(13)
$$\begin{aligned} I_{PD,i,1} & = R\int_{0}^{\infty } {H_{1} (f)df} \\ & = \frac{{RP_{sr} }}{{\Delta f}}\int_{0}^{\infty } {\sum\limits_{\theta = 1}^{\rm O} {Z(\theta )\sum\limits_{\mu = 0}^{{(2\alpha^{2} - 1)}} {\sum\limits_{\varphi = 0}^{{(2\alpha^{2} + 2\alpha - 1)}} {q_{\mu ,\varphi } \overline{{q_{0,\varphi } }}\Psi (f,\varphi )} } } df} \\ & = \frac{{RP_{sr} }}{{\left( {2\alpha^{2} + 2\alpha } \right)}}\left( {\frac{{ (O{ - 1)(}\alpha^{2} { - 1)}}}{{ (2\alpha^{2} { - 1)}}}} \right), \\ \end{aligned}$$
(14)

where R is the photodiode responsivity given by R = ηeλ o /hc, η is the quantum efficiency of the photodiode, e is the electron charge, λ o is the central wavelength, h is Planck’s constant, c is the speed of light, and P sr is the effective source power of each ONU. The proposed system uses Z(θ) = 1 and θ = 1, 2, …, O in the worst case scenario. Therefore, the photocurrents I PD0 and I PD1 in the photodiodes PD0 and PD1, respectively, are based on the cross-correlations.

The cross-correlations operate R (0)(μ, μ′) and R (1)(μ, μ′). The proposed system uses these cross-correlations to produce a modified cross-correlation. The modified cross-correlation thus produces the modified photocurrent. The modified photocurrent can be written as:

$$\begin{aligned} I_{a} & = R\int_{0}^{\infty } {\left[ {H_{0} (f) - H_{1} (f)} \right]df} \\ & = I_{PD0} - I_{PD1} \\ & = \frac{{RP_{sr} (\alpha + 1)}}{{2\alpha^{2} + 2\alpha }}. \\ \end{aligned}$$
(15)

Because the proposed system uses Z(θ) = 1 and θ = 1, 2, …, O in the worst case scenario, the worst case increases the maximum MUI. Therefore, the modified photocurrent is produced to eliminate the MUI.

The photodiodes have photocurrent noise variances that are described as follows:

$$\langle i_{noise}^{2} \rangle = \langle i_{PIIN}^{2} \rangle + \langle i_{shot}^{2} \rangle + \langle i_{themal}^{2} \rangle = I_{a}^{2} B_{r} \mu_{a} + \, 2eI_{t} B_{r} + \, 4K_{a} T_{n} B_{r} /R_{o} ,$$
(16)

where the PIIN, shot noise, and thermal noise are considered in the photocurrent analysis, effect of the dark current is neglected, I a is the modified photocurrent, I t is the total photocurrent, B r is the electrical bandwidth, μ a is the coherence time of the light incident on the photodiode, e is the electron charge, K a is Boltzmann’s constant, T n is the absolute noise temperature, and R o is the load resistance. Therein, μ a is derived as follows:

$$\mu_{a} = {{\int_{0}^{\infty } {H^{2} (f)df} } \mathord{\left/ {\vphantom {{\int_{0}^{\infty } {H^{2} (f)df} } {\left[ {\int_{0}^{\infty } {H(f)df} } \right]^{2} }}} \right. \kern-0pt} {\left[ {\int_{0}^{\infty } {H(f)df} } \right]^{2} }},$$
(17)

where H(f) is the single sideband PSD of the light incident on the photodiode. Therefore, the proposed system suffers from the variances of the photocurrent noise, which provide the PIIN, shot noise, and thermal noise.

The variances of the photocurrent noise are based on statistically independent noise characteristics to produce the PIIN, shot noise, and thermal noise. The variance of the PIIN is derived as follows:

$$\left\langle {i_{PIIN}^{2} } \right\rangle = B_{r} I_{a}^{2} \mu_{a} .$$
(18)

The PIIN has a variance in the ONU that can be written as follows:

$$\begin{aligned} \left\langle {i_{PIIN}^{2} } \right\rangle & = B_{r} I_{a}^{2} {{\int_{0}^{\infty } {H^{2} (f)df} } \mathord{\left/ {\vphantom {{\int_{0}^{\infty } {H^{2} (f)df} } {\left[ {\int_{0}^{\infty } {H(f)df} } \right]}}} \right. \kern-0pt} {\left[ {\int_{0}^{\infty } {H(f)df} } \right]}}^{2} \\ & = B_{r} I_{a}^{2} \frac{{\int_{0}^{\infty } {\left[ {H_{0} (f) - H_{1} (f)} \right]^{2} df} }}{{\left\{ {\int_{0}^{\infty } {\left[ {H_{0} (f) - H_{1} (f)} \right]df} } \right\}^{2} }} \\ & = B_{r} R^{2} \int_{0}^{\infty } {\left[ {H_{0} (f) - H_{1} (f)} \right]^{2} df} \\ & = B_{r} R^{2} \int_{0}^{\infty } {\left[ {H_{0}^{2} (f) + H_{1}^{2} (f)\left. { - 2H_{0} (f)H_{1} (f)} \right]df.} \right.} \\ \end{aligned}$$
(19)

The proposed system uses the spectrum of H 0(f) and H 1(f) such that it does not overlap the spectrum of H 0(f) and H 1(f) given by Eqs. (11) and (12). When the proposed system uses Eqs. (11) and (12), we have H 2 i (f), where i = [0, 1], as follows:

$$\begin{aligned} \int_{0}^{\infty } {H_{0}^{2} (f)df} & = \int_{0}^{\infty } {\left[ {\frac{{P_{sr} }}{{\Delta f}}\sum\limits_{\theta = 1}^{\rm O} {Z(\theta )\sum\limits_{\mu = 0}^{{(2\alpha^{2} - 1)}} {\sum\limits_{\varphi = 0}^{{(2\alpha^{2} + 2\alpha - 1)}} {q_{\mu ,\varphi } q_{0,\varphi }\Psi (f,\varphi )} } } } \right]^{2} df} \\ & = \frac{{P_{sr}^{2} }}{{\Delta f(2\alpha^{2} + 2\alpha )(\alpha + 1)}}\left[ {(\alpha + 1) + \frac{{(O - 1)(\alpha^{2} - 1)}}{{2\alpha^{2} - 1}}} \right]^{2} , \\ \end{aligned}$$
(20)
$$\begin{aligned} \int_{0}^{\infty } {H_{1}^{2} (f)df} & = \int_{0}^{\infty } {\left[ {\frac{{P_{sr} }}{{\Delta f\alpha }}\sum\limits_{\theta = 1}^{\rm O} {Z(\theta )\sum\limits_{\mu = 0}^{{(2\alpha^{2} - 1)}} {\sum\limits_{\varphi = 0}^{{(2\alpha^{2} + 2\alpha - 1)}} {q_{\mu ,\varphi } \overline{{q_{0,\varphi } }}\Psi (f,\varphi )} } } } \right]^{2} df} \\ & = \frac{{P_{sr}^{2} (\alpha + 1 )(O - 1)^{2} (\alpha^{2} - \alpha )^{2} }}{{\Delta f\alpha^{2} (2\alpha^{2} + 2\alpha )(2\alpha^{2} - 1)^{2} }}. \\ \end{aligned}$$
(21)

All simultaneous users use the information bit “1” from the ONU, according to Eqs. (20) and (21). The proposed system suffers from PIIN. \(\langle i_{PIIN}^{2}\rangle\) is described as follows:

$$\begin{aligned} \left\langle {i_{PIIN}^{2} } \right\rangle & = \frac{{B_{r} R^{2} P_{sr}^{2} }}{{\Delta f(2\alpha^{2} + 2\alpha )(\alpha + 1)}}\left[ {(\alpha + 1) + \frac{{(O - 1)(\alpha^{2} - 1)}}{{2\alpha^{2} - 1}}} \right]^{2} \\ & \quad + \frac{{P_{sr}^{2} (\alpha + 1 )(O - 1)^{2} (\alpha^{2} - \alpha )^{2} }}{{\Delta f\alpha^{2} (2\alpha^{2} + 2\alpha )(2\alpha^{2} - 1)^{2} }}. \\ \end{aligned}$$
(22)

Because every simultaneous user uses the information bit “1” and information bit “0” to be sent with equal probability, we revise Eq. (22) as follows:

$$\begin{aligned} \left\langle {i_{PIIN}^{2} } \right\rangle & = \frac{{B_{r} R^{2} P_{sr}^{2} }}{{2\Delta f(2\alpha^{2} + 2\alpha )(\alpha + 1)}}\left[ {(\alpha + 1) + \frac{{(O - 1)(\alpha^{2} - 1)}}{{2\alpha^{2} - 1}}} \right]^{2} \\ & \quad + \frac{{P_{sr}^{2} (\alpha + 1 )(O - 1)^{2} (\alpha^{2} - \alpha )^{2} }}{{2\Delta f\alpha^{2} (2\alpha^{2} + 2\alpha )(2\alpha^{2} - 1)^{2} }} \\ \end{aligned}$$
(23)

The proposed system considers the shot noise to be independent of the PIIN noise and thermal noise. The variance of the shot noise can thus be written as follows:

$$\begin{aligned} \left\langle {i_{shot}^{2} } \right\rangle & = 2eB(I_{total} ) \\ & = \frac{{2eBRP_{sr} }}{{2\alpha^{2} + 2\alpha }}\left( {(\alpha + 1) + \frac{{ 2 (O{ - 1)(}\alpha^{2} { - 1)}}}{{ (2\alpha^{2} { - 1)}}}} \right), \\ \end{aligned}$$
(24)

where I t is the total photocurrent given by I t  = I 0 + I 1. The proposed system allows the information bit “1” and the information bit “0” to be sent with equal probability in every simultaneous user. Thus, the variance of the shot noise can be written as:

$$\left\langle {i_{shot}^{2} } \right\rangle = \frac{{eBRP_{sr} }}{{2\alpha^{2} + 2\alpha }}\left( {(\alpha + 1) + \frac{{2(O - 1)(\alpha^{2} - 1)}}{{(2\alpha^{2} - 1)}}} \right),$$
(25)

The proposed system also considers the thermal noise to be independent of the PIIN noise and the shot noise. The variance of the thermal noise is described as follows:

$$\langle i_{thermal}^{2} \rangle \, = \, 4K_{a} T_{n} B_{r} /R_{L} ,$$
(26)

where K a is Boltzmann’s constant, T n is the absolute temperature, and R L is the load resistance. Therefore, the proposed system provides the square of the modified photocurrent and photocurrent noise variances using the PIIN, shot noise, and thermal noise. The SNR is thus depicted as follows:

$$\begin{aligned} SNR & = {{I_{a}^{2} } \mathord{\left/ {\vphantom {{I_{a}^{2} } {\left\langle {i_{noise}^{2} } \right\rangle }}} \right. \kern-0pt} {\left\langle {i_{noise}^{2} } \right\rangle }} \\ & = I_{a}^{2} /\left( { \langle i_{PIIN}^{2} \rangle + \langle i_{shot}^{2} \rangle + \langle i_{thermal}^{2} \rangle } \right). \\ \end{aligned}$$
(27)

Because the BER uses a Gaussian approximation, the BER is used to calculate the SNR. The BER is thus expressed as follows:

$$BER = {{erfc\left( {\sqrt {SNR/8} } \right)} \mathord{\left/ {\vphantom {{erfc\left( {\sqrt {SNR/8} } \right)} 2}} \right. \kern-0pt} 2},$$
(28)

where erfc(·) is the complementary error function, which is given as follows:

$$erfc(y) = \frac{2}{\sqrt \pi }\int_{\pi }^{\infty } {\exp ( - y^{2} )dz} .$$
(29)

We also use the BER to observe the numbers of simultaneous users, data transmission rate, and effective source power.

5 Numerical results

The results of the numerical calculations are based on use of the following parameters: PD quantum efficiency η = 0.6, data transmission rate = 2.5 Gbps, receiver noise temperature T n  = 300 K, and receiver load resistance R L  = 1030 Ω. The spectral efficiency is used by SE = aggregate information rate/total spectral bandwidth = θ| BER=10−9 Rb/Δf, where θ| BER=10−9 is the number of simultaneous user at BER = 10−9, and Rb = 1/data transmission rate is the data transmission rate per ONU (Chang and Sargent 2003). Figure 4 shows the code length versus the spectral efficiency for SAC-OCDMA systems using the 1-D added length codes, 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. The spectral efficiency using the 1-D added length codes is better than that using the 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. Figure 5 shows the number of simultaneous user versus BER characteristics for the SAC-OCDMA systems using two code lengths of the 1-D added length codes. We use the effect of code set’s properties to achieve the code length. The proposed codes use the larger code length to get the larger number of simultaneous user. Hence, the 1-D added length codes can operate the modified cross-correlation to achieve the larger number of simultaneous user using the larger code length. Figure 6 shows the number of simultaneous users versus the BER for SAC-OCDMA systems using the 1-D added length codes, 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. These systems use similar code lengths. Because these systems using the 1-D added length codes, 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes produce the effective source power of −2 dBm, a data transmission rate of 2.5 Gbps, and a BER of 10−9, the numbers of simultaneous users can be compared. The proposed system using the 1-D added length codes achieves the 23 users, system using the 1-D M-sequence codes achieves only one user, system using the 1-D composite M-sequence codes achieves three users, system using the 1-D Hadamard codes achieves seven users, and system using the 1-D MQC codes achieves seventeen users. The number of simultaneous users for the proposed system using the 1-D added length codes is thus much larger than that for the other systems using the 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. Based on the number of the simultaneous users 23 users, the BER for the proposed system using the 1-D added length codes is 10−9, that for the system using the 1-D M-sequence codes is 10−0.5, that for the system using the 1-D composite M-sequence codes is 10−0.9, that for the system using the 1-D Hadamard codes is 10−1.8, that for the system using the 1-D MQC codes is 10−5.9. The BER for the proposed system using the 1-D added length codes is thus much lower than that for the other systems using the 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes.

Fig. 4
figure 4

Code length versus the spectral efficiency for SAC-OCDMA systems using the 1-D added length codes, 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes

Fig. 5
figure 5

Number of simultaneous users versus BER in the systems using two code lengths of the 1-D added length codes

Fig. 6
figure 6

Number of simultaneous users versus BER in the systems using 1-D added length codes, 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes

Figure 7 shows the data transmission rate versus BER characteristics for SAC-OCDMA systems using the 1-D added length codes, 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. The data transmission rate describes the information bit required to achieve the desired communication speed. Because Fig. 7 describes the number of simultaneous users to be 23 users, effective source power to be −2 dBm, and BER to be 10−9, the data transmission rate for the proposed system using the 1-D added length codes is 2.5 Gbps; in contrast, that for the system using the 1-D M-sequence codes is 0.1 Gbps, that for the system using the 1-D composite M-sequence codes is 0.2 Gbps, that for the system using the 1-D Hadamard codes is 0.3 Gbps, and that for the system using the 1-D MQC codes is 1.3 Gbps. The observed data transmission rate for the proposed system using the 1-D added length codes is thus much higher than that for the other systems using the 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. At the same time, when the number of simultaneous users is 23 users, effective source power is −2 dBm, and data transmission rate is 2.5 Gbps, the BER for the proposed system using the 1-D added length codes is 10−9, that for the system using the 1-D M-sequence codes is 10−0.5, that for the system using the 1-D composite M-sequence codes is 10−0.9, that for the system using the 1-D Hadamard codes is 10−1.7, and that for the system using the 1-D MQC codes is 10−5.8. The BER for the proposed system using the 1-D added length codes is thus much lower than that for the other systems using the 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes.

Fig. 7
figure 7

Data transmission rate versus BER in the systems using 1-D added length codes, 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes

Figure 8 shows the effective source power versus BER characteristics for the SAC-OCDMA systems using the 1-D added length codes, 1-D M-sequence codes, and 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. Again using the number of simultaneous users of 23, the data transmission rate of 2.5 Gbps, and the BER of 10−9, the effective source power for the proposed system using the 1-D added length codes is −2 dBm, that for the systems using the 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes fail to show cross points. The effective source power for the proposed system using the 1-D added length codes is less power than that for the other systems using the 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. Based on the effective source power of −2 dBm, the BER for the proposed system using the 1-D added length codes is 10−9, that for the system using the 1-D M-sequence codes is 10−0.5, and that for the system using the 1-D composite M-sequence codes is 10−0.9, that for the system using the 1-D Hadamard codes is 10−1.8, that for the system using the 1-D MQC codes is 10−5.8. The BER for the proposed system using the 1-D added length codes is thus obtained at lower power than that for the other systems using the 1-D M-sequence codes and 1-D composite M-sequence codes.

Fig. 8
figure 8

Effective source power versus BER in the systems using 1-D added length codes, 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes

6 Conclusions

In this paper, we propose a family of new codes called 1-D added length codes for OCDMA systems. The proposed structure uses the 1-D added length codes to construct the OLT and ONUs. The proposed structure has a simple architecture for ease of operation that produces the proposed OLT and ONUs. The OLT transfers the information bits into the code sequences of the 1-D added length codes in OCDMA. The ONUs receive the OCDMA signals to create a modified cross-correlation, which produces the recovered “0” and “1” bits of the photodiodes. The modified photocurrent removes the interference from other simultaneous users that constitutes the MUI. The proposed modified cross-correlation suppresses the PIIN. In the numerical results, the number of simultaneous users for the proposed system using the 1-D added length codes is 23 users, which is much larger than that for the other systems using 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes based on a BER of 10−9. Using this BER of 10−9, the data transmission rate for the proposed system using the 1-D added length codes is 2.5 Gbps, and is much higher than that for the other systems using 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes. For the same BER, the effective source power for the proposed system using 1-D added length codes is −2 dBm, which is lower than that for the other systems using 1-D M-sequence codes, 1-D composite M-sequence codes, 1-D Hadamard codes, and 1-D MQC codes.