  In many singular metric spaces, the regularity of a shortest-length curve is
unknown. Algebraic varieties, or more generally sets defined by finitely many
polynomial or real analytic equalities or inequalities, all locally partition
into finitely many real analytic submanifolds called strata. So any component
of a shortest-length curve which lies completely in one such stratum is a
geodesic in the stratum, hence an embedded real analytic curve. The key
question thus is whether there are only finitely many components. F. Albrecht
and I.D. Berg proved this is true for a geodesic in a closed region of
$n$-dimensional Euclidean space with a smooth real analytic hyper surface as
boundary.
  Here the curve consists of finitely many interior line segments alternating
with boundary hypersurface geodesics. Their bound on the number of these
depended on the initial velocity of the geodesic, and they conjectured that is
independent. Here we prove this independence in $\mathbb{R}^3$. We also
generalize their result to regions whose boundary is locally the boundary of
the union of two transversally intersecting analytic hypersurfaces in
$\mathbb{R}^3$.
