Is there a dynamical system such that every orbit is either periodic or dense? Let $(T,X)$ be a discrete dynamical system. By this I mean that $X$ is a compact Hausdorff space and $T: X \to X$ a homeomorphism.
For example, take $X$ to be the sequence space $2^{\mathbb{Z}}$ and $T$ the Bernoulli shift. Then there is a dense set of periodic points, and there is another (disjoint) dense set of points whose orbits are dense (in view of topological transitivity).  However, there are also points of $X$ that belong to neither of these sets---for instance, the sequence $(\dots, 1, 1, 1, 0, 0, 0, \dots )$.
This led to me the following:

Question: Is there a discrete dynamical system $(T,X)$ such that
every point has either a finite or a
dense orbit? (Cf. the below caveats.)

There are a few caveats to add.  We want both periodicity and topological transitivity to occur; this rules out examples such as rotations of the circle (where every point is of the same type, either periodic or with a dense orbit). So assume:

*

*there is at least a point with dense orbit;

*there is at least a periodic point;

*also, assume there is no isolated point.

I've been thinking on and off about this question for a couple of days, and the basic examples of dynamical systems that I learned (shift spaces, toral endomorphisms, etc.) don't seem to satisfy this condition, and intuitively it feels like the compactness condition should imply that there are points which are "almost periodic," but not, kind of like the $(\dots, 1, 1, 1, 0, 0,0, \dots)$ example mentioned earlier.  Nevertheless, I don't see how to prove this.
 A: This reminds me of the theorem of Le Calvez and Yoccoz: There is no minimal homeomorphism on the multipunctured sphere, i.e. there is no homeomorphism on the 2-sphere such that every orbit is dense except a finite set. Clearly, the finite set consists of periodic points.
Now, to question. Google leads to https://arxiv.org/abs/1605.08873
This article is exactly the idea of Andrey Gogolev.
This technique shows that there are diffeomorphisms on all orientable surfaces (of course, except the sphere) such that the non dense orbits form a finite set.
I am sure that there are older proofs.
A: In the following paper the authors give an almost 1-1 extension for a minimal system $(X,\mathbb{Z})$ which is transitive and the only non-transitive point is a fixed point.
For $\mathbb{N}$ action they can have a similar one with positive topological entropy.
T.Downarowicz, X. Ye: When every point is either transitive or periodic, Colloq. Math. 93 (2002) pp. 137-150.
I do not know whether hese examples can exists on manifolds.
A: I believe you will find such examples for $X=\mathbb{C}$ and $T$ a rational map in
Mary Rees, Ergodic rational maps with dense critical point forward orbit,  Ergodic Theory and Dynamical Systems 4 (1984), 311-322.  official version.
In my Ph.D. thesis, I showed that some of these even support a metric with respect to which these dynamical systems are ``hyperbolic''.  This metric gives a notion of length of curves comparable to the usual metric on the Riemann sphere, but is defined by a function which is singular on a dense set of points on the sphere (the forward orbit of the critical point).
A: Here is a really simple example,  based on the proposer's comments. Let $X$ consist of two fixed points and a single orbit, whose forward limit point is one of the fixed points and whose backward limit point is the other. This is a compact zero-dimensional system,  easily embeddable in the full 2-shift: the fixed points are $0^{\infty}, 1^{\infty}$, and the single orbit is that of $0^{-N}1^N$. Or did I miss something?
A: one can construct a self-mapping of a disk, mixing in the interior, identical on the boundary and glue together several copies using a periodic rotation of the boundary.
