For a project I am trying to build a program that computes a basis for cusp forms of weight 2 over $\Gamma_0(N)$. At one point, I want to represent eigenvalues of multiple Hecke operators. For example, (for $N=23$) I have found the following matrices for the Hecke operators:
$
T_2=\begin{pmatrix} -2 & -1/2 ;
2 & 1 \end{pmatrix}, T_3=\begin{pmatrix} 3 & 1 ;
-4 & -3 \end{pmatrix} \quad T_5=\begin{pmatrix} -2 & -1/2 ;
2 & 1 \end{pmatrix} \quad
$
so we have the following characteristic polynomials $f_2=x^2+x-1$, $f_3=x^2-5$, $f_5=x^2 +2x-4$. Suppose we denote the solution of $f_2$ (eigenvalues of $T_2$) by $a$ and it's conjugate. Then we can denote the solution of $f_3$ by $2a+1$ and of $f_5$ by $2a$.
I am trying to figure out how I can 'make' Sage represent these eigenvalues in this way. I have been trying k.< a >=NumberField(x^2+x-1), but then I don't know how to proceed with this $a$.
Remark: A little context, the goal for this project is to represent newforms in a similar way as Sage does, when you ask for example Newforms(23,2,names='a').