I'm computing a fraction from a database when both numerator and denominator can be zero. To solve this problem I thought of adding 1 to each.

I know I can add 1 only to the denominator, but this is for optimization of resources and adding 1 to the denominator favors tasks which have a low denominator.

Because 3/3 == 4/4, but 3/4 > 4/5 and thus the task with 4 will get the resources because the program will think it has more to complete.

This brings me to my question:

If I know that

$\frac{a}{b} > \frac {c}{d}$

Can $\frac{a+1}{b+1} < \frac {c+1}{d+1}$ happen, even once?

The above formula translates to

$a+d > c+b+(bc-ad)$

and this is where I'm stuck.

  • 2
    $\begingroup$ This won't be true for suppose $\frac{-2}{5} \gt \frac{-1}{4}$ $\endgroup$ – gemspark Aug 24 at 13:20

$\frac{7}{10}\gt\frac{2}{3}$ but $\frac{8}{11}\lt \frac{3}{4}$

| cite | improve this answer | |
  • $\begingroup$ could you explain how you found this? $\endgroup$ – Hachiloni Aug 24 at 13:40
  • $\begingroup$ @Hachiloni I restricted myself to positive numbers, just in case those were more useful to you. Then I recalled that adding $1$ to both numerator and denominator in those circumstances brings the fraction closer to $1$ (from below or above - fairly easy to prove rigorously), but, following the intuition as in Yves Daoust's graphical answer, I expected that it will "affect" more the fractions with the smaller numerator/denominator. $\endgroup$ – Stinking Bishop Aug 24 at 13:44
  • $\begingroup$ Thus, I had to find a fraction $\gt 1$ with "small" numerator/denominator that is only slightly bigger than another one with "large" numerator/denominator - and then check what happens when I add $1$. Pretty much the first pair of fractions I tried worked. $\endgroup$ – Stinking Bishop Aug 24 at 13:44
  • $\begingroup$ (My claim from above: let $a,b>0, \frac{a}{b}>1$, i.e. $a>b$. Then $\frac{a+1}{b+1}<\frac{a}{b}$ because $(a+1)b=ab+b<ab+a=a(b+1)$. $\endgroup$ – Stinking Bishop Aug 24 at 13:47
  • $\begingroup$ I guess I forgot to limit the question to fractions smaller than 1. I hoped you'd have a formula so I could look at it $\endgroup$ – Hachiloni Aug 24 at 13:50

Answer without words:


enter image description here

| cite | improve this answer | |
  • $\begingroup$ Are not "The ticks show one unit" 5 words? :) $\endgroup$ – user Aug 24 at 13:39
  • $\begingroup$ could you explain the graph? What are the colors? what are the axis? two answers state two different sets, how do I see it here? $\endgroup$ – Hachiloni Aug 24 at 13:39
  • $\begingroup$ @Hachiloni: I want to leave this answer "without words". $\endgroup$ – Yves Daoust Aug 24 at 13:42
  • 1
    $\begingroup$ @user: the editor did not let me write only the title. But I will modify. $\endgroup$ – Yves Daoust Aug 24 at 13:43
  • $\begingroup$ @Hachiloni The small blue triangle has the corners at $(0,0)$, $(b,a)$ and $(b+1, a+1)$. The slope of the sides coming out of $(0,0)$ is, respectively, $\frac{a}{b}, \frac{a+1}{b+1}$, the slope of the third side is $1$. You can see geometrically how the slope is "pushed up" (towards $1$, as it originally was $<1$) when we switch from $(b,a)$ to $(b+1, a+1)$. The same for the green triangle, which is all about $c,d$. $\endgroup$ – Stinking Bishop Aug 24 at 13:52

Assume $a,b,c,d>0$ then we have that

$$\frac{a}{b} > \frac {c}{d} \iff ad-bc>0$$


$$\frac{a+1}{b+1} > \frac {c+1}{d+1} \iff ad-cb+a+d-c-b >0$$

which fails when

$$c+b-a-d>ad-cb \iff c+b+bc>a+d+ad $$

that is for example

$$\frac{4}{7}\gt\frac{1}{2}, \quad \frac{5}{8}\lt\frac{2}{3}$$

indeed in this case


| cite | improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.