You are given a multigraph with $n$ vertices. Every vertex is colored with maximum of $k$ colors. If two vertices share a color, there is an edge between them which is colored with that color. (A pair of vertices may have more than one edge as they may share more than one color.) There is at least one edge between every pair of vertices.
Define $F(n, k)$ to be the maximal number $s$ such that for any graph with $n$ vertices colored with $k$ colors as above, there is a clique of size $s$ where each edge is colored with the same color, i.e. there is guaranteed to be a set of $s$ vertices which share the same color.
So a few simple examples: $F(n, 1) = n$, clearly because every vertex has to have the same color.
It is easy to show that, $F(n, 2) = n-1$ and $F(n, n-1) = 2$.
With some effort one can prove that $F(9, 3)= 5$ and that can be generalized to $F(3n, 3) \ge n+2$.
My question is what is the method to solve this for general $n$ and $k$? Is there a way to reformulate this problem in a different way so that it resembles a known graph theory problem / theorem.