  We study the two-dimensional toric code Hamiltonian with effective long-range
interactions between its anyonic excitations induced by coupling the toric code
to external fields. It has been shown that such interactions allow to increase
the lifetime of the stored quantum information arbitrarily by making $L$, the
linear size of the memory, larger [Phys. Rev. A 82 022305 (2010)]. We show that
for these systems the choice of boundary conditions (open boundaries as opposed
to periodic boundary conditions) is not a mere technicality; the influence of
anyons produced at the boundaries becomes in fact dominant for large enough
$L$. This influence can be both beneficial or detrimental. In particular, we
study an effective Hamiltonian proposed in [Phys. Rev. B 83 115415 (2011)] that
describes repulsion between anyons and anyon holes. For this system, we find a
lifetime of the stored quantum information that grows exponentially in $L^2$
for both periodic and open boundary conditions, though the exponent in the
latter case is found to be less favourable. However, $L$ is upper-bounded
through the breakdown of the perturbative treatment of the underlying
Hamiltonian.
