Keywords

1 Introduction

Multiple access interference can be eliminated by spectral amplitude coding (SAC) by using efficient detection techniques and proper choice of codes. Most commonly used detection methods are complementary detection technique, direct detection technique, and AND subtraction detection [1]. At the receiving end, multiple acces interference (MAI) is eliminated [2].

Codes orthogonality is the main factor which affects OCDMA performance. SAC-OCDMA orthogonal codes are multi-diagonal code, modified quadrature congruent code, double weight code, enhanced double weight code, random diagonal code, etc. [3, 4]. These codes show different auto- and cross-correlation features. Since, the cross relationship is not perfect for Walsh Hadamard code, it experiences MAI. OOC and prime codes are larger length code and therefore are bandwidth inefficient which results in lesser number of supportable users [5].

The presented code has moderate code length with benefit of minimum cross-correlation, and it can be constructed for any weight higher than two. We expected that proposed code gives improved performance due to its efficient code construction algorithm. Balanced weight ideal cross-correlation (BWICC) code algorithm is free from code mapping procedures to obtain higher number of subscribers in the system. Code mapping disadvantage is that cross-correlation increases in system as the number of users increases which results in higher MAI as well as complex receiver and code construction [6].

The remaining paper is compiled as follows: Sect. 2 presents  SAC-OCDMA code properties. Section 3 with sub Sects. 3.13.3 consists of code design, flowchart, and code construction for odd weight. Section 4 discusses SAC-OCDMA framework with code implementation in optical environment. Newly developed code performance analysis is discussed in Sect. 5. The study is summarized with future possibilities in Sect. 6.

2 Code Construction

In an OCDMA environment, the code set (C) is made up of unipolar sequences which is either 0 or 1. An optical code is represented as (N, W, λa, λc), where N is the code length, W is the code weight, λa is the auto correlation, and λc is the in-phase cross-correlation. Codes must be designed with low cross-correlation value generally zero or ideal in-phase cross-correlation (1). Multiple user interferences (MUI) are less in system due to low cross-correlation value [7].

To design good properties, SAC codes following are the measures that should be considered [8,9,10]:

  1. 1.

    The code length should not change with the active clients, and it should be small, so that more number of users can be accommodated.

  2. 2.

    The cross-correlation factor should be zero reduce PIIN and MAI effects.

  3. 3.

    The code design procedure should be simple.

  4. 4.

    The codes should provide higher users with increased data rate, with minimum BER.

  5. 5.

    Low latency time and increased security should be maintained by the codes.

Considering these points, we have proposed a new code which belongs to ideal cross-correlation code family (Sect. 3).

3 Balanced Weight Ideal Cross-Correlation (BWICC) Codes

BWICC code can be designed by following steps:

3.1 The Code Construction Steps

  • Step 1: Number of users (K) is selected based on the system requirement and code weight of code W = 3, 4, …, N is chosen based on the required number of users. Resultant weight (WR) for base matrix is set to W − 1.

  • Step 2: Calculate the length of the code as:

    $$L = \left( {K \times W_{{\text{R}}} } \right) + 2$$
  • Step 3: Size of basic balanced matrix is determined using WR:

    $$I_{{\text{B}}} = 2 \times W_{{\text{R}}} \left( {{\text{Balanced}}} \right) = 2 \times (W - 1)$$
  • Step 4: Basic matrix (IB) is designed for any number of subscribers as:

    $$I_{{\text{B}}} = \left[ {\begin{array}{*{20}c} {R_{1} } \\ {R_{2} } \\ \end{array} } \right] = \left[ {\begin{array}{*{20}c} {\left[ {W/2} \right]1{\text{'s}}} & {\left[ {W - 2} \right]0{\text{'s}}} \\ {\left[ {W + 2/3} \right]0{\text{'s}}} & {~\left[ {W + 1/2} \right]1{\text{'s}}} \\ \end{array} } \right]_{{2 \times (W - 1)}}$$

    where R1 and R2 are Row 1 and Row 2 of the IB.

  • Step 5: Weight matrix is designed to increase the code weight which is added after K × L code matrix construction:

    $$I_{W} = \left[ {\begin{array}{*{20}c} 1 & 0 \\ 0 & 1 \\ . & . \\ . & . \\ m & n \\ \end{array} } \right]$$
    (1)
  • Step 6: Final code is denoted by M of size K × L for K clients. M matrix is constructed in three steps in which first H* is designed. IB is repeated (N − 1) times in M matrix:

    $$H^{*} = \left[ {\begin{array}{*{20}c} {R_{1} } & \cdots & \cdots & \cdots & \cdots & \vdots \\ {R_{2} } & {R_{1} } & \cdots & \cdots & \cdots & \vdots \\ \vdots & {R_{2} } & {R_{1} } & \cdots & \cdots & \vdots \\ \vdots & \vdots & \vdots & \ddots & \ddots & \vdots \\ \vdots & \vdots & \vdots & \ddots & {R_{1} } & \vdots \\ \cdots & \cdots & \cdots & \cdots & {R_{2} } & \cdots \\ \end{array} } \right]_{{K \times L}}$$
    (2)

    Empty spaces of matrix H** are filled with null to make final matrix M:

    $$M = \left[ {\begin{array}{*{20}c} {R_{1} } & \cdots & \cdots & \cdots & \cdots & {} & {R_{2} } \\ {R_{2} } & {R_{1} } & \cdots & \cdots & \cdots & \vdots & \vdots \\ \vdots & {R_{2} } & \ddots & \ddots & \ddots & \vdots & \vdots \\ \vdots & \vdots & \ddots & \ddots & \ddots & \ddots & \ddots \\ \vdots & \vdots & \ddots & \ddots & \ddots & {R_{1} } & \vdots \\ \cdots & \cdots & \cdots & \cdots & \cdots & {R_{2} } & {R_{1} } \\ \end{array} } \right]_{{K \times L}}$$
    (4)

    Secondly, H** is designed by repeating the same procedure for K × L times:

    $$H^{**} = \left[ {\begin{array}{*{20}c} {R_{1} } & \cdots & \cdots & \cdots & \cdots & {} & {R_{2} } \\ {R_{2} } & {R_{1} } & \cdots & \cdots & \cdots & \vdots & \vdots \\ \vdots & {R_{2} } & \ddots & \ddots & \ddots & \vdots & \vdots \\ \vdots & \vdots & \ddots & \ddots & \ddots & \ddots & \ddots \\ \vdots & \vdots & \ddots & \ddots & \ddots & {R_{1} } & \vdots \\ \cdots & \cdots & \cdots & \cdots & \cdots & {R_{2} } & {R_{1} } \\ \end{array} } \right]_{{K \times L}}$$
    (3)

The auto-correlation and cross-correlation functions for the BWICC code are stated as:

  • Auto-correlation: \(Ax,x = \mathop \sum \limits_{{n = 0}}^{{n - 1}} C\left[ x \right]C\left[ x \right]\) where 0 < m < N −1.

  • Cross-correlation: \(~Cx,y = \mathop \sum \limits_{{n = 0}}^{{n - 1}} C\left[ x \right]C\left[ y \right]\) where 0 < m < N −1.

3.2 BWICC Code Implementation Flow Diagram

Figure 1 depicts how the BWICC code is constructed and implemented.

Fig. 1
figure 1

Implementation of BWICC code

3.3 BWICC Code Construction with Weight 3

Let the number of users (K) is 4 and weight (W) is 3.

Resultant weight WR for base matrix be calculated as WR = W – 1, i.e., 2 in this case. Calculate the length of the code as:

$$L = \left( {K \times W_{{\text{R}}} } \right) + 2 = (4 \times 2) + 2 = 10$$
(5)

Size of basic balanced matrix = IB = 2 × WR (Balanced) = 2 × 2

$$I_{{\text{B}}} = \left[ {\begin{array}{*{20}c} {R_{1} } \\ {R_{2} } \\ \end{array} } \right] = \left[ {\begin{array}{*{20}c} {\left[ {W/2} \right]1{\text{'s}}} & {\left[ {W - 2} \right]0{\text{'s}}} \\ {\left[ {W + 2/3} \right]0{\text{'s}}} & {\left[ {W + 1/2} \right]1{\text{'s}}} \\ \end{array} } \right]_{{2 \times (W - 1)}}$$
(6)
$$I_{{\text{B}}} = \left[ {\begin{array}{*{20}c} 1 & 0 \\ 0 & 1 \\ \end{array} } \right]_{{2 \times 2}}$$
(7)
$$H = \left[ {\begin{array}{*{20}l} {1\;0\;0\;0\;0\;0\;0\;1} \hfill \\ {0\;1\;1\;0\;0\;0\;0\;0} \hfill \\ {0\;0\;0\;1\;1\;0\;0\;0~} \hfill \\ {0\;0\;0\;0\;0\;1\;1\;0} \hfill \\ \end{array} } \right]_{{K \times L}}$$
(8)
$${\text{Now add weight matrix}}\quad I_{W} = \left[ {\begin{array}{*{20}c} 1 & 0 \\ 0 & 1 \\ . & . \\ . & . \\ m & n \\ \end{array} } \right]$$
(9)
$${\text{Final code becomes}}\quad H = \left[ {\begin{array}{*{20}l} {1\;0\;0\;0\;0\;0\;0\;1\;1\;0} \hfill \\ {0\;1\;1\;0\;0\;0\;0\;0\;0\;1} \hfill \\ {0\;0\;0\;1\;1\;0\;0\;0\;~1\;0} \hfill \\ {0\;0\;0\;0\;0\;1\;1\;0\;0\;1} \hfill \\ \end{array} } \right]$$
(10)

Therefore, codeword for every user is represented with following wavelengths:

  • Codeword for user 1 = \(\lambda _{1} ,\lambda _{8} ,\lambda _{9}\)

  • Codeword for user 2 = \(\lambda _{2} ,\lambda _{3} ,\lambda _{{10}}\)

  • Codeword for user 3 = \(\lambda _{4} ,\lambda _{5} ,\lambda _{9}\)

  • Codeword for user 4 = \(\lambda _{6} ,\lambda _{7} ,\lambda _{{10}}\).

4 System Setup

Working of the proposed coding scheme and corresponding system architecture is verified by implementation in a highly acknowledged software called Optisystem. The simulation model is developed with reference to the structure of transmitter and receivers modules in Fig. 2. For simulation setup, the proposed code-based system generally consists of a white light LEDs with constant spectrum over a long bandwidth, Mach–Zehnder modulator (MZM), and encoder/decoder sections. Initially, a board band source (BBS) is placed with 30 nm spectral width. It is implemented for four users. Each user has weight 3. The data rate for simulation is 1 Gbps, and spectral chip width is 0.8 nm. Parameters for simulation are as follows: operating wavelength 1550 nm for light source, −10 dBm is transmitted power, and 0.6 is quantum efficiency of LED. In the transmitter, four encoder is placed and code is constructed by selecting particular wavelengths from broadband source. The modulator modulates these wavelengths as per the given data. The modulated data are further transmitted over the optical fiber channel. Fiber length is set to 30 km with dispersion of 18.75 ps/nm-km and attenuation of 0.2 dB/km. At the receiver, each received signal which consists of non-overlapped spectral components are sent to diode detector. Every user code has unique spectrum which can be measured by spectrum analyzer.

Fig. 2
figure 2

SAC-OCDMA system setup for BWICC code with W = 3 and N = 4

At the receiver, the responsivity is set to 1 A/W of PIN photo-diode detector, 5 nA is dark current, and thermal noise of 100 × 10−24 W/Hz is taken into account. Direct detection (DD) technique is used for detecting non-overlapping optical pulses. Therefore, phase-induced intensity noise (PIIN) is suppressed by detecting non-overlapping spectral components [10].

5 Results and Discussion

Eye diagram referring to BER and Q factor demonstrates the performance of BWICC in SAC environment (Figs. 3 and 4). The eye diagram clearly shows that for one user we obtained good performance, i.e., BER is 4.30 × 10−13 with a quality factor value of 7.14 which is desirable for standard error-free transmission case (at 1 Gbps). Figure 3 shows the eye diagram for the proposed setup when four users are communication simultaneously at 1, 1.5, 2, and 2.5 Gbps of data. It is evident from eye openings that the proposed model is able to provide the required performance and support multiple users communicating at large data rates. It is also observed that performance of proposed system decreases with the increase in data rate.

Fig. 3
figure 3

Eye diagram indicating performance of four users with different data rates (1, 1.5, 2 and 2.5 Gbps)

Fig. 4
figure 4

Eye diagram for one user with W = 3 using proposed code at 1 Gbps

6 Conclusion

In this paper, a new code BWICC is designed and implemented for SAC-OCDMA systems. Proposed code construction is simpler compared to existing codes as the code is designed without code mapping compared to other existing techniques of code generation. The codes constructed using code-mapping techniques present limitations on code cardinality. The reason being that code possesses variable cross-correlation problems with increase in users, which further results into MAI. Code-mapping technique is not utilized to construct proposed code; therefore, such problem does not occur which further provides accurate results. Moreover, code can be designed for any weight value more than two. Receiver is implemented with single photo diode and fewer other components which minimizes receiver complexity and implementation cost with improved system performance. Performance analysis can be further carried out numerically which is the future work to be done for this code. Moreover, its performance comparison can be made with recently developed SAC codes. MAI can be reduced to a much higher extent if proposed code be implemented with complementary subtraction or NAND detection technique.