Step 1: Precompute the values of
${\mathcal{P}}_{1}(hi,j,k)$
[Eq. (3)], which are independent of
traffic loads. 
Step 2: Consider each single link. The values of
${\rho}_{u,v}$
,
${F}_{k}(u,v)$
,
$F(u,v)$
, and
$\widehat{F}(u,v)$
will be used later when considering
paths with multiple links. 
for each link
${l}_{u,v}$
do 
1. Calculate offered load
${\rho}_{u,v}$
[Eq. (1)] 
2. Calculate the probability that the link has
$k$
free wavelengths,
${F}_{k}(u,v)$
[Eq. (5)] 
3. Calculate the probability that the link has at least
one free wavelength,
$F(u,v)={\sum}_{k=1}^{W}{F}_{k}(u,v)$

4. Calculate the probability
${\widehat{F}}_{k}(u,v)$
(defined in Table IV) 
5. Calculate the blocking probability of singlehop
path
$p$
between nodes
$u$
,
$v$
,
${B}_{p}={F}_{0}(u,v)$

end for

Step 3: Then we consider paths with more than one link.
We need the steadystate distribution of the 5D Markov
chain, and the offered loads for the five types of
connections,
${\rho}_{e}$
,
${\rho}_{f}$
,
${\rho}_{c}$
,
${\rho}_{w}$
, and
${\rho}_{r}$
. In this step, the values of
${\widehat{x}}_{i}^{l}(p)$
and
${\overline{x}}_{i}^{l}(p)$
are calculated, which are used to get
${\rho}_{w}$
and
${\rho}_{r}$
in the next step. 
for each path
${p}_{s,d}$
containing at least one 3R node
do 
for each 3R node
$i$
on path
${p}_{s,d}$
, starting from the one closest to
$s$
and proceeding to the one closest to
$d$
do 
1. Calculate the values of
$X(s,i,g)$
[Eq. (C3)],
${X}^{\prime}(s,i,g)$
[Eq. (C4)],
$Z(s,i,g)$
[Eq. (C7)],
${Z}^{\prime}(s,i,g)$
[Eq. (C8)],
$X(h,i,g)$
[Eq. (C5)],
${X}^{\prime}(h,i,g)$
[Eq. (C6)],
$Z(h,i,g)$
[Eq. (C9)], and
${Z}^{\prime}(h,i,g)$
[Eq. (C10)] (in Appendix C) (The values of
${b}_{n}^{l}$
,
$F(u,v)$
,
${\widehat{F}}_{k}(u,v)$
,
${\overline{F}}_{k}(u,v,t)$
, and
${F}_{k}^{\prime}(u,v,t)$
needed are those found in Steps 5 and
6 of the previous iteration, as explained in
Subsection III.C) 
2. Calculate
${\widehat{x}}_{i}^{l}(p)$
[Eq. (13)] and
${\overline{x}}_{i}^{l}(p)$
[Eq. (14)] (where
$l$
is the corresponding outgoing link of
3R node
$i$
on path
$p$
) 
end for 
end for

Step 4: Now we can calculate the offered loads of the
five types of connections. Then we can get the
steadystate distribution of the Markov chain. In turn,
we can compute the values of
${\mathcal{P}}_{2}(i)$
,
${\mathcal{P}}_{3}(i)$
, and
${\mathcal{P}}_{4}(i)$
, which are used in the next step to
find the value of
${T}^{m}(h,e)$
. 
for each pair of adjacent links on all
paths do 
1. Calculate the values of
${\rho}_{e}$
[Eq. (6)],
${\rho}_{f}$
[Eq. (7)],
${\rho}_{r}$
[Eq. (11)],
${\rho}_{w}$
[Eq. (12)], and
${\rho}_{c}$
[Eq. (8)] 
2. Calculate the steadystate probability
$\mathit{\pi}({\mathcal{C}}_{e},{\mathcal{C}}_{f},{\mathcal{C}}_{c},{\mathcal{C}}_{r},{\mathcal{C}}_{w})$
[Eq. (9)] 
3. Calculate
$P(\alpha ,{\mathcal{C}}_{r}K,{\mathcal{C}}_{w},{\mathcal{C}}_{c},{\mathcal{C}}_{e},{\mathcal{C}}_{f})$
[Eq. (A1)] based on the value of
$Y(a,bm,u,v)$
[Eqs. (D1) and (D2)] 
4. Calculate
$P(K{\mathcal{C}}_{w},{\mathcal{C}}_{c},{\mathcal{C}}_{e},{\mathcal{C}}_{f})$
[Eq. (A3)] 
5. Calculate
$P(\alpha ,K,{\mathcal{C}}_{r},{\mathcal{C}}_{w},{\mathcal{C}}_{c},{\mathcal{C}}_{e},{\mathcal{C}}_{f})$
[Eq. (A2)] 
6. Calculate
${\mathcal{P}}_{2}(i)$
[Eq. (15)],
${\mathcal{P}}_{3}(ji)$
[Eq. (16)], and
${\mathcal{P}}_{4}(kj,i)$
[Eq. (17)] 
end for

Step 5: In this step we calculate
${T}^{m}(h,e)$
, which is used to find the blocking
probabilities for paths without 3R nodes. 
for each path
$s$
,
$d$
(
$m>1$
hops) do 
1. Calculate
${T}^{m}(h,e)$
[Eq. (18)] 
2. Calculate
${F}_{k}(s,d)$
[Eq. (4)],
${\widehat{F}}_{k}(u,v)$
(defined in Table IV),
${\overline{F}}_{k}(u,v,t)$
[Eq. (C1)], and
${F}_{k}^{\prime}(u,v,t)$
[Eq. (C2)]. (Note that these values will
be used in Step 3 of the next iteration.) 
end for

Step 6: 
for each path
$s$
,
$d$
(
$m>1$
hops) without 3R nodes
do 
Calculate the blocking probability
${B}_{p}={F}_{0}(s,d)$

end for

Step 7: Now we consider the paths with 3R nodes. In this
step, we calculate the offered loads to each 3R node’s
outgoing link
${\rho}_{n}^{l}$
, and in turn, the probability that
there are no available OEO converters at a 3R node
${b}_{n}^{l}$
. Then we can get the acceptance
probability of a path
${A}_{p}$
based on
$M(i,j,d)$
and
${M}^{\prime}(i,j,d,k)$
. 
for each path
$s$
,
$d$
containing 3R nodes
do 
for each 3R node
$n$
on the path do 
1. Calculate the offered load to 3R node
$n$
on outgoing link
$l$
;
${\rho}_{n}^{l}={\sum}_{l\in p}{\widehat{x}}_{n}^{l}(p)+{\overline{x}}_{n}^{l}(p)$

2. Calculate the probability that there are no OEOs
available at the node
${b}_{n}^{l}$
[Eq. (19)] (where
$l$
is the corresponding outgoing link
with node
$n$
on the path) (Note that these values
will be used in Step 3 of the next iteration.) 
end for 
1. Calculate the acceptance probability of the path
${A}_{p}$
[Eq. (20)] depending on the OEO
availability at the first 3R node on the path. This
calculation is based on the values of
$M(i,j,d)$
[Eq. (22)] and
${M}^{\prime}(i,j,d,k)$
[Eq. (23)] 
2. Calculate the blocking probability
${B}_{p}=1{A}_{p}$

end for

Step 8: Calculate the network blocking probability
${B}_{N}=\frac{\sum _{s,d}{\lambda}_{s,d}{B}_{s,d}}{\sum _{s,d}{\lambda}_{s,d}}$
