Space of linear, continuous, hyperbolic functions is open, dense in the set of invertible functions
Solution 1:
The statement that for $X$ an $\mathbb{F}$-Banach space ($\mathbb{F}=\mathbb{R}$ or $\mathbb{C}$), the set $H(X)$ of hyperbolic automorphisms is dense in $GL(X)$ is true when $\dim(X)<\infty$, and not necessarily true in general (as opposed to openness, which holds without the finite dimension assumption).
(I'm assuming the adjective "continuous" of spectrum above is a typo.)
Finite dimensional Case: In this case the already mentioned argument of "adding a small multiple of identity" works (moving finitely many points on the circle in one direction on the complex plane so that none are on the circle is not hard). One can even be very explicit as to how small of a multiple one ought to use; see Palis and de Melo's Geometric Theory of Dynamical Systems, p.50, Prop.2.11 for details (for the $\mathbb{F}=\mathbb{C}$ case). (An analogous infinitesimal statement is also presented there: put $\mathfrak{h}(X):=\{A\in \operatorname{End}(X)\,|\, \operatorname{spec}(A)\cap i\mathbb{R}=\emptyset\}$ (these are also called hyperbolic, or, elsewhere, elementary). Then $\mathfrak{h}(X)$ is also open and dense (in $\operatorname{End}(X)$). The key observation is the continuity of $\exp: \mathfrak{h}(X)\twoheadrightarrow H(X)$. It is interesting to note that $\exp: \mathfrak{h}(X)\twoheadrightarrow H(X)$ is analogously well-defined in the general case by Dunford's Spectral Mapping Theorem.)
General Case: Here is an explicit example due to M. Monge (see https://www.fc.up.pt/pessoas/jfalves/pub/senegal.pdf (pp.14-15, Ex.5.3) or https://arxiv.org/abs/1510.05831 for details):
Put $D:=\{z\in\mathbb{C}\,||, |z-1|< 1/2\}$ and take $X$ to be the Banach space of all bounded analytic functions $D\to \mathbb{C}$ (with $C^0$ norm). Then
$$T: X\to X,\,\, f\mapsto [z\mapsto zf(z)]$$
is an automorphism with $\operatorname{spec}(T)=\overline{D}\ni 1$. For $S\in GL(X)$, $\Vert T-S\Vert<1/8$, $1\in\operatorname{spec}(S)$. The proof is by elementary complex analysis.
From a more dynamical point of view, Eisenberg and (J.H.) Hedlund proved that any hyperbolic automorphism is uniformly expansive ($T$ is uniformly expansive if $\exists n\in\mathbb{Z}_{>0}, \forall x\in X: |x|=1$ $\implies |T^n(x)|\geq 2 \text{ or } |T^{-n}(x)|\geq2$), and if $X$ is Hilbert then hyperbolic (Banach) automorphisms are not dense among uniformly expansive (Banach) automorphisms. This is a consequence of a result by Halmos and Lumer regarding the semicontinuity of the complement of the approximate point spectrum in the spectrum. (See Eisenberg & Hedlund's "Expansive automorphisms of Banach spaces" and Hedlund's follow-up "Expansive automorphisms of Banach spaces. II" for details.)
Solution 2:
I didn't take a course about the spectral theorem yet but let me try to answer your question. I appreciate to be corrected if I am mistaken.
Your idea can work : To prove $\mathcal{H}(X)$ is dense in $GL(X)$, let $A\in GL(X)\setminus \mathcal{H}(X)$ and $\epsilon> 0$ be arbitraries, then $\exists \lambda_0\in \sigma(A): |\lambda_0|= 1$ , we are looking for a $T\in \mathcal{H}(X)$ ( i.e. $\forall \lambda\in \sigma(T):\ |\lambda|\neq 1$ ) , with $\|A-T\|< \epsilon$
We can consider $T= A+D$ where $D$ is a 'diagonal' operator with respect to a specific basis $\{b_i\}_{i\in I}$ of $X$ , where $Db_i= z_ib_i$ for each $i\in I$ and to satisfy the second condition we can choose the $z_i\in \mathbb{C}$ such that $|z_i|< \frac{\epsilon}{2} \ \forall i\in I$
For an obvious reason in what follows, we need $\{b_i\}_{i\in I}$ to be taken exactly as the basis ( not sure if we need a Hamel basis or a Schauder basis here? ) formed by extending the set of 'eigenvectors' of $A$ such that $Ab_j= \lambda_jb_j \ \forall \lambda_j\in \sigma(A)$ so here $j\in J\subset I$ , whereas $Ab_l= b_l \ \forall l\in I\setminus J$ .
We note that this extension of a linearly independent set to a basis is always possible.
Now to guarantee $\sigma(A+D)\cap S^1= \emptyset$ , we have $$\sigma(A+D)= \{\lambda'_i+z_i\big|\ i\in I ,\ \ \lambda'_i= \lambda_i \ \ \text{if }\ i\in J,\ \ \ \lambda'_i=1 \text{ otherwise}\}$$ For each $i\in I$ to guarantee that $|\lambda'_i+z_i|\neq 1$ we can choose each $z_i$ to have the same argument as $\lambda'_i$ if $|\lambda'_i|>1$ , otherwise if $|\lambda'_i|<1$ we pick $z_i$ to have the 'opposite' argument, that is $arg(z_i)= arg(\lambda'_i)+\pi$ , so to stay away from $S^1$, and we can check that when $\lambda'_i= 1$ then any $z_i\in \mathbb{R}\setminus \{0\}$ works.
Edit : (Thanks to Wraith1995)
We will use $\sigma(T)=\overline{\sigma_p(T)}$, where the $\sigma_p(T)$ is the point spectrum, to 'avoid' an open set containing $S^1$, say the circular sector $S= \{z\in \mathbb{C}:\ 1-\frac{\epsilon}{3}<|z|<1+\frac{\epsilon}{3}\}$
$\{b_i\}_{i\in I}$ is taken exactly as the basis formed by extending the set of 'eigenvectors' of $A$ such that $Ab_j= \lambda_jb_j \ \forall \lambda_j\in \sigma(A)$ and $j\in J\subset I$
$D$ is a 'diagonal' operator with respect to $\{b_i\}_{i\in I}$ of $X$ , where $Db_i= z_ib_i$ for each $i\in J$ and $Db_l= 0 \ \forall l\in I\setminus J$
To guarantee $\sigma(A+D)\cap S^1= \emptyset$ , we have $\sigma_p(A+D)= \{\lambda_i+z_i\big|\ i\in J \}$ and $$\sigma(A+D)= \overline{\{\lambda_i+z_i\big|\ i\in J \}}$$ For each $i\in J$ to guarantee that $|\lambda_i+z_i|\notin S$ we can choose each $z_i$ to have a module $|z_i|>\frac{\epsilon}{3}$ and the same argument as $\lambda_i$ if $|\lambda_i|>1$ , otherwise when $|\lambda'_i|<1$ we pick $z_i$ to have the 'opposite' argument that is $arg(z_i)= arg(\lambda'_i)+\pi$ , so that the closure doesn't intersect $S^1$ as desired.
Of course $\epsilon$ is taken to be very small, say $<\frac{1}{7}$