Say we have a probability vector or population density $p = (p_1,...,p_n)$ with $p_i \geq 0$ and $\sum_i p_i =1$. Also assume we know the functions $g=(g_1,...,g_n)$ such that:
$$p_i(t+1) = g_i(p(t))$$
where $t$ is a discrete time index. Is there a way to check whether $g$ implements a discrete time replicator equation? I.e. whether there is a function $f=(f_1,...,f_n)$, called the fitness landscape, such that:
$$p_i(t+1)= \frac{f_i(p(t))}{\langle f \rangle_{p(t)}} p_i(t).$$
where $\langle f \rangle_{p(t)}:=\sum_j p_j(t) f_j(p(t))$ is the average fitness of the population density. Pluggin in $g_i(p(t))$ gives an equation that we could try to solve for $f$ but I don't know how:
$$g_i(p(t)) = \frac{f_i(p(t))}{\langle f \rangle_{p(t)}} p_i(t)$$
or equivalently:
$$\frac{g_i(p(t))}{p_i(t)} = \frac{f_i(p(t))}{\langle f \rangle_{p(t)}}.$$
We can of course also drop the time dependency and write:
$$\frac{g_i(p)}{p_i} = \frac{f_i(p)}{\langle f \rangle_{p}}.$$
Is there a (in the best case necessary and sufficient) criterion that has to be satisfied for this equation to have a solution? I am also grateful for tips how to tackle this problem in a principled way, including numerically.