<s>[INST] An inequality for a bi-modal hypergeometric distribution Say $X$ has a hypergeometric distribution with parameters $m$, $n$ and $k$, with $k\leq n<\frac12m$.
I know that $X$ has a dual mode if and only if $d=\frac{(k+1)(n+1)}{m+2}$ is integer. In that case $P(X=d)=P(X=d-1)$ equals the maximum probability.
I am wondering if I can say anything about $P(X=d+1)$ versus $P(X=d-2)$ then. When is the former higher than the latter? I.e. when is:
$P(X=d+1)>P(X=d-2)$
Always? I tried many combinations programmatically and did not find any counterexample.
So far I have found:
$\frac{P(X=d+1)}{P(X=d-2)}=\frac{(k-d+2)(k-d+1)(k-d)(n-d+2)(n-d+1)(n-d)}{(d+1)d(d-1)(m-k-n+d+1)(m-k-n+d)(m-k-n+d-1)}$
Because $d=\frac{(k+1)(n+1)}{m+2}$, this can be simplified to:
$\frac{P(X=d+1)}{P(X=d-2)}=\frac{(k-d+2)(k-d)(n-d+2)(n-d)}{(d+1)(d-1)(m-k-n+d+1)(m-k-n+d-1)}$
I have tried further combining this with $d=\frac{(k+1)(n+1)}{m+2}$ being integer, but that gets quite complex and gives me no further clue.
I feel there is something relatively easy to prove here...?
For $n=\frac12m$, $P(X=d+1)=P(X=d-2)$ due to symmetry.
 [/INST] In the case you are considering you have $P(X=d)=P(X=d-1)$ 
so  let's consider the sign of $$\frac{P(X=d+1)}{P(X=d)}-\frac{P(X=d-2)}{P(X=d-1)} = \tfrac{(k-d)(n-d)}{(d+1) (m-k-n+d+1)} -\tfrac{ (d-1) (m-k-n+d-1)}{(k-d+2)(n-d+2)} \\= \tfrac{(k-d)(n-d)(k-d+2)(n-d+2)-(d-1) (m-k-n+d-1)(d+1) (m-k-n+d+1)}{(d+1) (m-k-n+d+1)(k-d+2)(n-d+2)}$$
The denominator is positive so does not affect the sign.  In the numerator, we can make the substitution $d=\frac{(k+1)(n+1)}{m+2}$ and then multiply through by the positive $(m+2)^4$. Expanding the result and factorising gives  
$$\tfrac{m^6 +(8-2n-2k)m^5 +(24-16n-16k+kn)m^4 +(32-48n-48k+32kn)m^3 +(16-64n-64k+96kn)m^2 +(-32n-32k+128kn)m +64kn}{\text{something positive}}  \\ = \frac{(m+2)^4(m-2n)(m-2k)}{\text{something positive}} $$ 
and this is positive, i.e. $P(X=d+1) > P(X=d-2)$, when $k\leq n<\frac12m$. $\blacksquare$
As a check, the difference is actually $\frac{(m-2n)(m-2k)}{(d+1) (m-k-n+d+1)(k-d+2)(n-d+2)}$. 
It is also positive when $n\lt k<\frac12m$, and when both $k > \frac12m$ and $n>\frac12m$.
It is negative , i.e. $P(X=d+1) < P(X=d-2)$ when $k\lt \frac12m <n$ or $n\lt \frac12m <k$.
Finally, it is zero, i.e. $P(X=d+1) = P(X=d-2)$ when $k= \frac12m$ or $n= \frac12m$.
</s>