<s>[INST] solve $x^2 - 25 xy + y^2 = 1$ does it have a solution? Usually the Pell equation is written $x^2 - dy^2 = 1$ but here I am looking for solutions to an equation of the type:
$$ x^2 - k xy + y^2 = 1 $$
and In particular, $k$ is a perfect square.  So I am picking $k = 25$ an example.
If we complete the square then $25/2$ is not an integer.
$$ xy + x^2 - 26xy + y^2   = x^2 + xy + \big(x - 13y\big)^2 = 170$$
I think I am better of solving the orginal problem.  Can any variant on the Pell equation work?
 [/INST] Your discriminant, for $x^2 - k x y + y^2,$ is
$$ \Delta = k^2 - 4. $$ The smallest solution, in positive integers, to 
$$ \tau^2 - \Delta \sigma^2 = 4  $$
is $\tau = k, \sigma = 1.$ You have the obvious $-1$ automorphism given by interchanging $x,y.$ The matrix generating the oriented automorphisms is
$$
\left(
\begin{array}{rr}
\frac{\tau - B \sigma}{2} & - C \sigma \\
A \sigma & \frac{\tau + B \sigma}{2}
\end{array}
\right).
$$ 
With $A = 1, B = -k, C = 1$ this becomes
$$
P =
\left(
\begin{array}{rr}
k & - 1 \\
1 & 0
\end{array}
\right).
$$
$$
P^{-1} =
\left(
\begin{array}{rr}
0 &  1 \\
-1 & k
\end{array}
\right).
$$
Beginning with a column vector with entries $(1,0),$ multiplying $P$ times the column repeatedly gives (columns) $(1,0),$ $(k,1),$ $(k^2 - 1,k),$ $(k^3 - 2k,k^2 - 1),$ and so on forever.
as in
$$
\left(
\begin{array}{r}
x_{n+1}  \\
y_{n+1}
\end{array}
\right)
 =
\left(
\begin{array}{rr}
k & - 1 \\
1 & 0
\end{array}
\right)
\left(
\begin{array}{r}
x_n  \\
y_n
\end{array}
\right)
$$
From Cayley-Hamilton on the matrix $P$, we get that both $x_n$ and $y_n$ sequences obey linear recursions
$$ x_{n+2} = k x_{n+1} - x_n,  $$
$$ y_{n+2} = k y_{n+1} - y_n.  $$
For this particular problem, this is also evident from the matrix $P$ since the $x$ and $y$ sequences are the same, only $y_{n+1}= x_n.$
</s>