# Expressing a set of discrete inequalities as a continuous differential equation

I'm trying to work out the solution to a problem of sequential inequalities. I believe the solution collapses to a set of differential equations, but I'm having trouble organizing things and I think I may be mixing up certain concepts.

I'll start with a 3 part example. We have 3 probabilities $p_1,p_2,p_3$ such that $0<p_1<p_2<p_3<1$. There are two functions $X(p)$ and $Y(p)$ such that:

$$0<p_1<\frac{X_2-X_1}{X_2-X_1-(Y_2-Y_1)}<p_2<\frac{X_3-X_2}{X_3-X_2-(Y_3-Y_2)}<p_3<0$$ where $X_n = X(p_n)$. Additionally, $X_n >X_{n+1}$ and $Y_n >Y_{n+1}$ so $X$ is a decreasing function of $p$ and $Y$ is an increasing function of $p$. As it turns out, this series of inequalities also implies that:

$$\frac{X_3-X_2}{X_2-X_1} > \frac{Y_3-Y_2}{Y_2-Y_1}$$

For some arbitrary set of $p$'s the conditions are such that the following is true:

\begin{align} p< \frac{X(p+i)-X(p)}{X(p+i)-X(p)-(Y(p+i)-Y(p))} < p+i \quad (1)\\ \frac{X(p+i+j)-X(p+i)}{X(p+i)-X(p)} > \frac{Y(p+i+j)-Y(p+i)}{Y(p+i)-Y(p)} \quad (2) \end{align}

where $0<p<p+i+j<1$, again remembering that $X$ is a decreasing function of $p$ and $Y$ is an increasing function of $p$, so $[X(p+i)-X(p)]<0$ and $[Y(p+i)-Y(p)]>0$.

It seems that I should be able to reduce these inequalities to an set of differential equations as the set of $p$'s becomes infinite and the distance between $p$ and $p+i$ becomes arbitrarily small. However, the way forward has so far eluded me, in part because I don't quite know how to express the deltas as the natural derivative $\Delta X/\Delta p$.

Can anyone help me with this, or at least tell me that I'm barking up the wrong tree and this is not the right way to do things?

Edit: I should say that it's not particularly important to express it as a differential equation. If I can find a set of functions $X$ and $Y$ which satisfies the inequalities without expressing the conditions as differential equations that would be fine. I just figured it might be easier to conjecture a solution if I could express the conditions in terms of derivatives. I may be wrong.