#### 2.1. AWG

An

N ×

N AWG is associated with a set of

N wavelengths {0, 1, …,

N − 1}. A signal from input port

i to output port

o, using wavelength

w, is denoted by [

i,

w,

o], where

w ∈ {0, 1, …,

N − 1}. An AWG has different cyclic wavelength routing properties, which lead to contention-free wavelength assignments [

8,

23,

27,

28]. One cyclic wavelength routing property, a relationship among parameters

i,

o, and

w, in an

N ×

N AWG is given by Equation (1) [

27,

28]:

An AWG is a passive device. Equation (1) implies that given a wavelength

w, the wavelength routing of a signal [

i,

w,

o] in an AWG is determined and unique. Equation (1) also implies that each input of an

N ×

N AWG can send

N signals, each destined to a different output, of

N different wavelengths simultaneously. Thus, an

N ×

N AWG can send all

N^{2} signals simultaneously without blocking. An example of the routing of nine signals in a 3 × 3 AWG is given in

Figure 1.

#### 2.2. 3-Stage ASA Switch Architecture

Figure 2a presents an AWG-based switch architecture, called a 3-stage ASA switch [

24], that contains two planes, one of which is an electronic control plane and the other is an optical data plane. Each input port of a 3-stage ASA switch has separate fibers connecting the control plane and the data plane. The control plane of the 3-stage ASA switch implements scheduling first to guarantee collision-free data transmissions.

Figure 2b presents the architecture of the data plane, which chooses a Clos topology and consists of three stages. The first (or third) stage consists of

N N ×

N AWGs, and the middle stage consists of

N N ×

N space switches, (i.e., optical crossbars). It is worth noting that

N must be odd.

From the topology of the data plane of the 3-stage ASA switch (

Figure 2b), we can see that the wavelength routing of the 3-stage ASA switch only depends on the wavelength routings of the

N ×

N AWGs in the first and third stages. Thus, the theoretical foundation for determining the wavelength routing of the 3-stage ASA switch is based on the 2-stage switch made from cascading two

N ×

N AWGs (see

Figure 2c). The same as for a signal in an

N ×

N AWG, we also use (

i,

w,

o) to denote a signal in the 2-stage switch from input

i to output

o, using wavelength

w. The relationship among the parameters

i,

o, and

w in a 2-stage switch is derived in Equation (2):

A nonblocking switch means that each input can reach all outputs and two signals using the same wavelength do not collide at a link. However, the term 2

w in Equation (2) suggests that the 2-stage switch is not always nonblocking. Specifically, some inputs in the 2-stage switch may not reach all outputs. Reference [

24] proves that the 2-stage switch is nonblocking if

N is odd. It is worth noting that to ensure the 2-stage switch is nonblocking, each wavelength

w must be guaranteed to be uniquely determined by input

i and output

o. Suppose (

i_{1},

w_{1},

o_{1}) and (

i_{2},

w_{2},

o_{2}) are two signals in the 2-stage switch with

o_{1} =

o_{2} and

i_{1} =

i_{2}, where

o_{1} = (

i_{1} + 2

w_{1}) mod

N and

o_{2} = (

i_{2} + 2

w_{2}) mod

N. This leads to 2(

w_{1} −

w_{2}) mod

N = 0, and the wavelength can be uniquely determined, (i.e.,

w_{1} =

w_{2}), only if

N is odd.

For a 3-stage ASA switch, a two-tuple [group, member] is used to represent an input (or output) port address, where group refers to

N ×

N AWG, member refers to the link of

N ×

N AWG to which the input (output) port is attached, and 0 ≤ group, member ≤

N − 1 (see

Figure 2b). Hence, a signal from input port [

g_{s},

m_{s}] to output port [

g_{d},

m_{d}], using the wavelength

w is represented as ([

g_{s},

m_{s}],

w, [

g_{d},

m_{d}]), where 0 ≤

g_{s},

m_{s},

g_{d},

m_{d} ≤

N − 1. According to Equation (2), the relationship among

m_{s},

m_{d}, and

w satisfies Equation (3):

where

N is odd. Thus, member fields are used for wavelength routing in the first and third stages of the 3-stage ASA switch. In addition, group fields are used for space switching in the middle stage. Specifically, signal [[

g_{s},

m_{s}],

w, [

g_{d},

m_{d}]] is routed from the

g_{s}th input to the

g_{d}th output of the (

m_{s} +

w)th space switch in the middle stage. Consequently, a 3-stage ASA switch can send a signal from each input to any output when the wavelength is correctly chosen (Equation (3)). An example is given in

Figure 2b, where input [0, 0] can reach outputs [0, 0], [1, 1], and [0, 2] by using wavelengths

w = 0, 2, and 1, respectively.

It is worth noting that each port can transmit

N wavelengths simultaneously without blocking each other if signals from inputs with the same member field, (i.e.,

m_{s}), are destined to distinct outputs. This is because signals in a 3-stage ASA switch can only collide at the same link in stage 2 [

24]. The collision occurs if signals are from inputs with the same member field and to the same output (Equation (3)). Note that signals from inputs with the same member field and to the same output pass through the same link in stage 2 and use the same wavelength (Equation (3)). An example is given in

Figure 2d, where inputs [0, 0] and [1, 0], which use the same member field, cannot reach output [0, 0] simultaneously because they collide at the same link in stage 2. Therefore, the 3-stage ASA switch with an odd

N is nonblocking if signals from inputs with the same member field are destined to distinct outputs. Since each port of an

N ×

N AWG can transmit up to

N wavelengths simultaneously, the total capacity of a 3-stage

N^{2} ×

N^{2} ASA switch is close to

N^{3} × the bandwidth of a wavelength channel.