In a random permutation on $n$ elements one expects the largest increasing and decreasing sequences to have size $(2+o(1))\sqrt{n}$. Is it known if this same property holds in sequences given by polynomial progressions? Say that $p$ is a prime and we consider the map $\pi$ sending $x$ to $x^2$ modulo $p$. Then what is the largest $k$ such that there exists $0 \le a_1< \cdots <a_k$ so that $a_i^2$ are (say, nonstrictly) increasing modulo $p$? What if we instead consider the map $x^{-1}$, or some other polynomial or rational map?
The collisions should not be an important issue in general as there are only $O(1)$ of them at each point, and we can break ties arbitrarily. But in any case, I am curious if these maps modulo $p$ are "psuedorandom" in some sense. My first idea for the polynomial case is to try degree reduction. For $x^2$, this map looks locally linear in that $(x+1)^2-x^2 \equiv 2x+1$ does not vary by much when $x$ varies over an interval of length $o(p)$.