Solution (source code)

= Solution

Equal <beam waist>[waist] sizes imply equal positive <Rayleigh ranges>, so <2/c> gives $z_R=z_R'=L/2$. Since $z_R=\pi w_0^2/\lambda$, the matched radii are
$$
\boxed{w_0=\sqrt{\frac{\lambda L}{2\pi}},\qquad
w_{M_1}=w_{M_2}=\sqrt2\,w_0=\sqrt{\frac{\lambda L}\pi}.}
$$
These are radii; the corresponding spot diameters are twice these values. One practical disadvantage is the transverse-mode degeneracy of the exact confocal geometry: mode frequencies coincide in families, making clean selection of a single transverse mode more difficult. Its $M=-I$ condition also lies at the strict-stability boundary. For example, perturbing the two radii in opposite directions, $R_1=L(1+\delta)$ and $R_2=L(1-\delta)$, gives $g_1g_2=-\delta^2/(1-\delta^2)<0$ for $0<|\delta|<1$, an unstable perturbation. This does not mean that all perturbations, or the ideal <confocal optical resonator>[confocal resonator] itself, are unstable.