the global maximum at $t_f = \sqrt{2^{n-1}} \left[{\mathop{\mathrm{acot}}\nolimits}(-\ln\eta\sqrt{2^{n-1}})
+ O(1/n) \right]$. During operation we set $$t_m:= \sqrt{2^{n-1}} {\mathop{\mathrm{acot}}\nolimits}(-\ln\eta\sqrt{2^{n-1}}),$$ or the closest integer, as the time yielding the maximum probability of success.

To simplify the upcoming formulae, we introduce the variables $$\begin{aligned}
x &=& -\ln\eta\ \sqrt{2^{n-1}}, \\
\varepsilon &=& \log_2(1 - \eta).\end{aligned}$$ The variable $\varepsilon$ can be regarded as a logarithmic transmission parameter (the ideal case corresponds to $\varepsilon=\infty$, and complete loss to $\varepsilon=0$). When $\varepsilon$ is sufficiently large, the expression $-\ln\eta$ can be approximated to first order in $2^{-\varepsilon}$ and we obtain $$x \approx 2^{-\varepsilon + n/2 - 1/2}.
\label{eq:x-approx}$$ Upon substituting $t_m$ into (\[eq:prob\_uniform\_approx\]) we can use the new variable $x$ to express the sine term as $$\begin{gathered}
  \sin^2(\omega'_0t_m) =\sin^2(|\omega'_0|t_m) =
  \sin^2\left[{\mathop{\mathrm{acot}}\nolimits}x(1+O(1/n))\right] =\\
  = \frac1{1+x^2} + \frac{2x{\mathop{\mathrm{acot}}\nolimits}x}{1+x^2}O(1/n) + \frac{{\mathop{\mathrm{acot}}\nolimits}^2x}{1+x^2} O(1/n^2).\end{gathered}$$ Thus for the maximum success probability $p_n^{\mathrm{max}}(\eta) =
p_n(\eta, t_m)$ we obtain $$p_n^{\mathrm{max}}(\eta) = \frac{e^{-2x{\mathop{\mathrm{acot}}\nolimits}x}}{ 1 + x^2} \left[
  \frac12 - O(1/n) + x{\mathop{\mathrm{acot}}\nolimits}x\, O(1/n) \right].
\label{eq:maxprob-homo}$$ This formula is our main result for the case of uniform photon losses. In the large $n$ limit it gives the approximate performance of the SKW search algorithm as a function of the transmission rate and the size of the search space. 