## Cycle detection using a stack (2004)

Venue: | Information Processing Letters |

Citations: | 7 - 0 self |

### BibTeX

@ARTICLE{Nivasch04cycledetection,

author = {Gabriel Nivasch},

title = {Cycle detection using a stack},

journal = {Information Processing Letters},

year = {2004},

volume = {90},

pages = {135--140}

}

### OpenURL

### Abstract

We present an algorithm for detecting periodicity in sequences produced by repeated application of a given function. Our algorithm uses logarithmic memory with high probability, runs in linear time, and is guaranteed to stop within the second loop through the cycle. We also present a partitioning technique that offers a time/memory tradeoff. Our algorithm is especially well suited for sequences where the cycle length is typically small compared to the length of the acyclic prefix.

### Citations

238 |
Monte Carlo methods for index computation (mod p
- Pollard
- 1978
(Show Context)
Citation Context ...several cryptanalytic applications [6, 9]. • In order to detect when, say, a cellular automaton configuration has become periodic. • In Pollard’s rho methods for factorization and discrete logarithms =-=[7, 8]-=-. (The ideas we are about to present in this paper, however, do not seem applicable to the rho factorization method.) 1sIn this paper we present a new cycle detection algorithm. The algorithm requires... |

152 | Parallel Collision Search with Cryptanalytic Applications
- Oorschot, Wiener
- 1999
(Show Context)
Citation Context ...0, and find the cycle length λ of the resulting sequence. Then, using the knowledge of λ, we can reconstruct the collision pair xµ−1, xµ+λ−1. Finding collisions has several cryptanalytic applications =-=[6, 9]-=-. • In order to detect when, say, a cellular automaton configuration has become periodic. • In Pollard’s rho methods for factorization and discrete logarithms [7, 8]. (The ideas we are about to presen... |

121 |
Winning Ways
- Berlekamp, Conway, et al.
- 1982
(Show Context)
Citation Context ...unction. There are situations where it is common for µ to be much larger than λ—for example, when running configurations in certain cellular automata until they oscillate, such as in the Game of Life =-=[2]-=-. Besides the stack algorithm, all the algorithms mentioned so far have a running time proportional to µ as well as to λ. In contrast, the stack algorithm’s running time above µ depends only on λ; the... |

51 |
An improved monte carlo factorization algorithm
- Brent
- 1980
(Show Context)
Citation Context ...ts cycle. The cycle detection problem asks for finding a pair of elements xi = xj for i �= j, and possibly also finding the cycle length λ. There are several existing algorithms for this purpose; see =-=[1, 3]-=-, [5, exercise 3.1–6], [9, 10]. Cycle detection arises in a number of situations: • In studying the behavior of random number generators [5]. • In searching for function collisions. A collision is a p... |

49 |
A Monte Carlo method for factorization
- POLLARD
- 1975
(Show Context)
Citation Context ...several cryptanalytic applications [6, 9]. • In order to detect when, say, a cellular automaton configuration has become periodic. • In Pollard’s rho methods for factorization and discrete logarithms =-=[7, 8]-=-. (The ideas we are about to present in this paper, however, do not seem applicable to the rho factorization method.) 1sIn this paper we present a new cycle detection algorithm. The algorithm requires... |

15 |
The complexity of finding cycles in periodic functions
- Sedgewick, Szymanski, et al.
- 1982
(Show Context)
Citation Context ... problem asks for finding a pair of elements xi = xj for i �= j, and possibly also finding the cycle length λ. There are several existing algorithms for this purpose; see [1, 3], [5, exercise 3.1–6], =-=[9, 10]-=-. Cycle detection arises in a number of situations: • In studying the behavior of random number generators [5]. • In searching for function collisions. A collision is a pair x �= y such that f(x) = f(... |

14 |
How easy is collision search ? Application to DES
- Quisquater, Delescaille
- 1990
(Show Context)
Citation Context ... problem asks for finding a pair of elements xi = xj for i �= j, and possibly also finding the cycle length λ. There are several existing algorithms for this purpose; see [1, 3], [5, exercise 3.1–6], =-=[9, 10]-=-. Cycle detection arises in a number of situations: • In studying the behavior of random number generators [5]. • In searching for function collisions. A collision is a pair x �= y such that f(x) = f(... |

3 |
The Art of Computer Programming Vol. 2, 3rd Edition
- Knuth
- 1997
(Show Context)
Citation Context ...re are several existing algorithms for this purpose; see [1, 3], [5, exercise 3.1–6], [9, 10]. Cycle detection arises in a number of situations: • In studying the behavior of random number generators =-=[5]-=-. • In searching for function collisions. A collision is a pair x �= y such that f(x) = f(y). One way to find a collision is to repeatedly apply f starting from some initial value x0, and find the cyc... |

2 |
private communication
- Woodruff
(Show Context)
Citation Context ...uished points, which is likely if λ happens to be small. Furthermore, our algorithm is simpler because it does not require the use of a hash table. Another approach, based on a suggestion by Woodruff =-=[11]-=-, is to keep a random sample of sequence values. We proceed as follows. As in Section 3, we divide the domain D into k ≥ 2 disjoint classes of equal size. We keep an array S of size k. At each step i,... |

1 | The Art of Computer Programming vol. 1, 3rd edition - Knuth - 1997 |