  Consider an unweighted, directed graph $G$ with the diameter $D$. In this
paper, we introduce the framework for counting cycles and walks of given length
in matrix multiplication time $\widetilde{O}(n^\omega)$. The framework is based
on the fast decomposition into Frobenius normal form and the Hankel
matrix-vector multiplication. It allows us to solve the All-Nodes Shortest
Cycles, All-Pairs All Walks problems efficiently and also give some improvement
upon distance queries in unweighted graphs.
