TITLE: Under what conditions is a linear automorphism an isometry of some inner product?
QUESTION [9 upvotes]: Assume $V$ is a finite-dimensional vector space over $\mathbb{R}$, and that $T: V \to V$ is a (linear) isomorphism. 

When is it possible to construct an inner product on $V$ 
  making $T$ an isometry?

(Hopefully, I am looking for necessary & sufficient conditions $T$ should satisfy, i.e. a full characterization of the situation).
What I have so far:
A necessary condition: all the real eigenvalues of $T$ are of absolute value $1$. (Since $ T(v)=\lambda v \Rightarrow  \langle v,v\rangle=\langle Tv,Tv\rangle = \langle \lambda v, \lambda v\rangle = \lambda^2\langle v, v\rangle$ and an eigenvector $v$ must be nonzero.)
This condition is certainly not sufficient:
For example look at $A$ = $\begin{pmatrix} 1 & 1 \\\ 0 & 1 \end{pmatrix}: \mathbb{R}^2 \to \mathbb{R}^2$. It is an automorphism which has only one eigenvalue ($\lambda = 1$). However, $A\begin{pmatrix} x \\ y \end{pmatrix}= \begin{pmatrix} x+y \\ y \end{pmatrix}$, hence $A^n\begin{pmatrix} x \\ y \end{pmatrix}= \begin{pmatrix} x+ny \\ y \end{pmatrix}$ and the requirement $A:(\mathbb{R}^2,\langle \rangle) \to (\mathbb{R}^2,\langle \rangle) $ to be an isometry for some inner product $\langle \rangle$ implies: $\lVert \begin{pmatrix} x \\ y \end{pmatrix}\rVert^2=\lVert A^n\begin{pmatrix} x \\ y \end{pmatrix}\rVert^2\Rightarrow x^2 \lVert e_1\rVert^2+y^2 \lVert e_2\rVert^2+2xy\langle e_1,e_2\rangle = (x+ny)^2 \lVert e_1\rVert^2+y^2 \lVert e_2\rVert^2+2y(x+ny) \langle e_1,e_2\rangle \Rightarrow 0=(2nxy+n^2y^2)\lVert e_1\rVert^2+2ny^2 \langle e_1,e_2\rangle$. 
So we get that $0=(2xy+ny^2)\lVert e_1\rVert^2+2y^2 \langle e_1,e_2\rangle$ for any $x,y\in \mathbb{R}, n\in \mathbb{N}$ which is a contradiction since $\lVert e_1 \rVert > 0$.
Some sufficient conditions:
1)  If $T$ is diagonalizable over $\mathbb {R}$ (with all eigenvalues $1$ or $-1$, by our necessary condition), then let ${V_1,...,V_n}$ be a basis of eigenvectors of $T$ , and define $\langle v_i,v_j\rangle = \delta_{ij}$. $T$ will be an isometry.
This condition is certainly not necessary:
just take a rotation (say by $90^{\circ}$) in the plane. note that it is diagonalizable over $\mathbb{C}$. My guess is that if our transformation is diagonalizable over $\mathbb{C}$ (with all eigenvalues with absolute value 1) a similar construction like the above will work. One problem I see with this approach is that an odd-dimensional $\mathbb{R}$-vector space cannot even be considered as a $\mathbb{C}$-vector space. (Though we can always complexify...).
2) $T$ is of finite order. (Then we just start with any inner product on $V$ and construct a new one via summing over iterates of $T$, i.e: $\langle v,w \rangle ' = \sum_{i=0}^{n-1} \langle T^iv,T^iw \rangle $). Note that (as explained for instance here) this implies $T$ is diagonalizable over $\mathbb{C}$, but of course not necessarily over $\mathbb{R}$. (Think about our rotation again.)
Actually, I have now understood that condition (1) implies $T$ is of order 2, (I think the reverse implication also holds, i.e $T^2=Id\Rightarrow T$ is diagonalizable). So condition (1) is a particular case of (2).
However, (2) is  not necessary, since any rotation of irrational multiple of 2$\pi$ is an isometry w.r.t the standard product, but of infinite order.
I somehow think the right way to handle this question is to think over $\mathbb{C}$, but I am not sure how to do this.

REPLY [5 votes]: Curious that the simple necessary and sufficient condition has not been (it would seem to me) clearly mentioned in any of the answers so far:

The linear operator $T$ preserves some inner product on $V$ if and only if $V$ admits a basis for which the matrix of $T$ is orthogonal (in other words the matrix of $T$ on an arbitrary basis is similar to an orthogonal matrix). The occurs if and only if the complexification of $T$ is diagonalisable, and all its (complex) eigenvalues have absolute value$~1$.

For the "if" of the first sentence, it suffices to define the inner product by the formula for the standard inner product of $\Bbb R^n$ in terms of the coordinates with respect to that basis; for the converse (only if) just take any orthonormal basis for the inner product. That the conditions in the second sentence are necessary is because these are well-known properties of orthogonal matrices.
That they are sufficient, in other words that a real matrix$~A$ that is diagonalisable over $\Bbb C$ with all its eigenvalues of absolute value$~1$ is similar (over$~\Bbb R$) to an orthogonal matrix is also standard, but the argument is slightly more involved. Since the complex-linear operator$~\phi$ on$~\Bbb C^n$ defined by$~A$ commutes with the (real-linear) operation$~J$ that performs complex conjugation of all coordinates, one easily shows that a basis of eigenvectors for$~\phi$ can be chosen such that as a set it is stable under$~J$: eigenvectors for real eigenvalues are chosen to be $J$-fixed (have real coordinates), and eigenvectors in the basis for non-real eigenvalues to come in pairs interchanged by$~J$, whose eigenvalues are complex conjugates of each other. This gives a decomposition of$~\Bbb C^n$ into a direct sum of $J$-stable subspaces of (complex) dimension $1$ or$~2$, each of which is the complexification of its real subspace of $J$-fixed vectors. These define a decomposition of (the original real vectors space) $V$ into $T$-stable subspaces of (real) dimension $1$ or$~2$, and it suffices to show that each of these subspaces has a basis for which the matrix of the restriction of$~T$ to the subspace is orthogonal. In dimension$~1$ this is trivial (the restriction is scalar multiplication by $1$ or by$~{-}1$) while in dimension$~2$ one can take a basis consisting of the common "real part" of the pair of complex eigenvectors and of the common (up to sign) "imaginary part", for which the $2\times2$ matrix will be that of a rotation, hence orthogonal.