Deriving a distance formula from the hyperbolic metric $(e^{2ty}(dx)^2+(dy)^2)$ Consider attempting to derive the distance formula
$$d((x_1, y_1), (x_2, y_2)) = \operatorname{arcosh} \left( 1 + \frac{ {(x_2 - x_1)}^2 + {(y_2 - y_1)}^2 }{ 2 y_1 y_2 } \right)$$
from the metric of the Poincare upper half-plane model
$$(ds)^2 = \frac{(dx)^2 + (dy)^2}{y^2}$$
See e.g. here. Though, from what I can see, this is not a straightforward calculation, since it involves solving the geodesic equation.
The problem I have is, what if I need a distance formula for a hyperbolic metric such as from this post, for some $t \in [0,1]$,
$$e^{2ty}(dx)^2+(dy)^2$$
I can no longer fall back on the standard theory of the distance in hyperbolic space to derive the first formula above, since the space no longer has sectional curvature $-1$. Can a distance formula be given in a similar way for $t \in [0,1]$? Would I need to solve the geodesic equation from scratch?
I would have just integrated along a geodesic in the usual way to find the arc length, given the metric as a function of $t$, but even the simple case $t=1$ seems intractable.
 A: The metric  $$ds^2 = e^{2ty}dx^2 + dy^2$$ has constant curvature $-t^2$, which goes from $0$ to $-1$ as $t$ goes from $0$ to $1$. After a few moments' work, for $t\ne 0$, I don't see obvious geodesics other than vertical lines. So I don't see a distance formula in general.
Now, for $t=1$, the metric $e^{2y}dx^2 + dy^2$ is isometric to the usual hyperbolic metric $(du^2+dv^2)/v^2$ on the upper half-plane. The mapping $u=x$, $v=e^{-y}$ is a global isometry. So you can transform the geodesics, and hence the distance formula, back to the plane with this metric of curvature $-1$.
A: EDIT: Fixed the scaling of the distance function: $d_h = d/t$ and not $td$.
It is not hard to verify that with respect to the metric
$$
g = e^{2ty}\,dx^2 + dy^2,
$$
the vertical lines are geodesics and the horizontal lines are curves with curvature $-t$ orthogonal to the vertical geodesics. On the other hand, with respect to the metric
$$
h = \frac{du^2+dv^2}{t^2v^2}
$$
the vertical lines are geodesics and the horizontal lines are curves with curvature $t$ orthogonal to the vertical geodesics. Both metrics have constant Gauss curvature $-t^2$.
Therefore, there is an isometry of the form $(x,y)\mapsto (u(x), v(y))$, which simply reparametrizes the horizontal and vertical lines. If we pull back the metric $h$ using this map, we get
\begin{align*}
  \frac{du^2+dv^2}{t^2v^2} &= \frac{(u'(x))^2\,dx^2 + (v'(y))^2\,dy^2}{(tv(y))^2}
\end{align*}
Therefore, the map is an isometry if
\begin{align*}
  \left(\frac{u'(x)}{v(y)}\right)^2 &= t^2e^{2ty}\\
  \left(\frac{v'(y)}{v(y)}\right)^2 &= t^2
\end{align*}
One possible solution is $(u,v) = (tx, e^{-ty})$. Double checking this,
\begin{align*}
  \frac{du^2+dv^2}{t^2v^2} &= \frac{t^2dx^2+ (-te^{-ty}\,dy)^2}{t^2e^{-2ty}}\\ &= e^{2ty}\,dx^2 + dy^2.
\end{align*}
$\newcommand\arccosh{\operatorname{arccosh}}$
According to Wikipedia (https://en.wikipedia.org/wiki/Poincar\'e_half-plane_model#Distance_calculation), the distance between two points $(u_1,v_1)$ and $(u_2,v_2)$ in the upper half-plane model of hyperbolic space is
$$
d((u_1,v_1),(u_2,v_2)) = \arccosh\left(1 + \frac{|(u_1-u_2,v_1-v_2)|^2}{2v_1v_2}\right).
$$
Rescaling this, we see that
$$
d_h(u_1,v_1),(u_2,v_2)) = \frac{1}{t}\arccosh\left(1 + \frac{|(u_1-u_2,v_1-v_2)|^2}{2v_1v_2}\right).
$$
Therefore, with respect to the metric $g$, the distance between two points $(x_1,y_1)$ and $(x_2,y_2)$ is
$$
d_g((x_1,y_1),(x_2,y_2)) = \frac{1}{t}\arccosh\left(1 + \frac{|(t(x_1-x_2),e^{-ty_1}_1-e^{ty_2})|^2}{2e^{-t(y_1-y_2)}}\right).
$$
