  The visibility algorithm has been recently introduced as a mapping between
time series and complex networks. This procedure allows to apply methods of
complex network theory for characterizing time series. In this work we present
the horizontal visibility algorithm, a geometrically simpler and analytically
solvable version of our former algorithm, focusing on the mapping of random
series (series of independent identically distributed random variables). After
presenting some properties of the algorithm, we present exact results on the
topological properties of graphs associated to random series, namely the degree
distribution, clustering coefficient, and mean path length. We show that the
horizontal visibility algorithm stands as a simple method to discriminate
randomness in time series, since any random series maps to a graph with an
exponential degree distribution of the shape P(k) = (1/3)(2/3)**(k-2),
independently of the probability distribution from which the series was
generated. Accordingly, visibility graphs with other P(k) are related to
non-random series. Numerical simulations confirm the accuracy of the theorems
for finite series. In a second part, we show that the method is able to
distinguish chaotic series from i.i.d. theory, studying the following
situations: (i) noise-free low-dimensional chaotic series, (ii) low-dimensional
noisy chaotic series, even in the presence of large amounts of noise, and (iii)
high-dimensional chaotic series (coupled map lattice), without needs for
additional techniques such as surrogate data or noise reduction methods.
Finally, heuristic arguments are given to explain the topological properties of
chaotic series and several sequences which are conjectured to be random are
analyzed.
