Given a natural number $n$, we define the vector valued random variable $\vec Y_n := (X_1, \ldots X_n)$ where all $X_i$ are independently uniformely distributed on $S_n := \{1, \ldots, n\}$.
Further we define the function $f: S_n^n \to \mathbb N$ where $f( \vec s )$ denotes the length of the longest subsequence of $(s_i)_{i=1}^n$ that forms an arithmetic progression.
Is it somehow possible to say anything (e.g. calculate the expected value) about the distribution of $f(\vec Y_n)$ or even calculate the distribution?
I have no idea how to work with the condition of the arithmetic subsequence.