[proofplan]
This is the special case of the [Change of Basis Formula](/theorems/387) where domain and codomain are the same space $V$ and the same basis change is applied to both. Since the change-of-basis matrix is the same for the domain and codomain roles, the general formula $B = Q^{-1}AP$ collapses to $B = P^{-1}AP$.
[/proofplan]
[step:Apply the general change-of-basis formula with $U = V$ and $Q = P$]
By the [Change of Basis Formula](/theorems/387), if $A$ is the matrix of $\alpha: V \to V$ with respect to the basis $(e_i)$ and $B$ is the matrix with respect to the basis $(f_i)$, with $P$ the change-of-basis matrix from $(f_i)$ to $(e_i)$ for the domain and $Q$ the change-of-basis matrix from $(f_i)$ to $(e_i)$ for the codomain, then $B = Q^{-1}AP$.
[guided]
The general change-of-basis formula for a linear map $\alpha: U \to V$ involves two potentially different change-of-basis matrices:
$P$ for the domain $U$ and $Q$ for the codomain $V$.
These can differ because the old and new bases for $U$ need not have any relation to those for $V$.
For an endomorphism $\alpha: V \to V$, the domain and codomain are the same space $V$.
When we change basis, we replace the single basis $(e_i)$ with the single basis $(f_i)$ -- the same change is applied to both the domain and the codomain.
The matrix of $\alpha$ in the old basis uses $(e_i)$ for both input and output coordinates, and the new matrix uses $(f_i)$ for both.
The change-of-basis matrix from $(f_i)$ to $(e_i)$ is $P$, defined by $f_i = \sum_{j=1}^n P_{ji}\, e_j$.
This same matrix $P$ serves as both the domain and codomain change-of-basis matrix.
[/guided]
[/step]
[step:Specialise to $Q = P$ and conclude $B = P^{-1}AP$]
Since $\alpha: V \to V$ and we use the same basis for both domain and codomain, the change-of-basis matrix is the same in both roles: $Q = P$. The general formula $B = Q^{-1}AP$ becomes
\begin{align*}
B = P^{-1}AP.
\end{align*}
This is the similarity relation: $B$ is similar to $A$ via the invertible matrix $P$.
[/step]