This is a question on a definition of attractor of a dynamical system.
Consider a dynamical system $\phi(t,x)$ satisfying
$$ \lim_{t\to\infty}\phi(t,x) = \begin{cases} -1 & \text{if } x < 0 \\ 0 & \text{if } x = 0 \\ +1 & \text{if } x > 0 \\ \end{cases} $$
Hence $x=-1$ and $+1$ are stable fixed points, with basin of attraction $(-\infty,0)$ and $(0,\infty)$ respectively, and $x=0$ is an unstable fixed points.
We have the following definitions:
a closed invariant set $A\subset\mathbb R$ is an attracting set if there is an open neighborhood $U\supseteq A$ such that $\forall x\in U$ we have $\phi_t(x)\in U$ for all $t\geq 0$ and $\phi_t(x)\to A$ as $t\to \infty$.
An attractor is an attracting set which contains a dense orbit.
My question is whether the set $[-1,1]$ is an attractor? Clearly it is an attracting set because every initial condition in $\mathbb R$ will converge inside $[-1,1]$. But this is not an attractor, beacuse we can split into two disjoint basins of attraction, namely $[-1,0)$ and $(0,1]$. I would claim that the only attractors of this system are $\{-1\}$ and $\{1\}$.
However based on our definition, it seems that $[-1,1]$ is an attractor because it contains a dense orbit. Of course, take any orbit like $x_0=\frac{1}{2}$, then $\phi(t,x_0)$ accumulates at $x=1$, hence it is dense. So how can my book claim that $[-1,1]$ does not contain any dense orbit? Besides, how could the subset $(0,1]$ contain a dense orbit and $[-1,1]$ not contain a dense orbit, when $(0,1]\subseteq[-1,1]$? Some clarification would be appreciated. Thanks.