# Stuck solving an equation using the floor operator.

I am not entirely familiar with the equation ninja'ing involving the floor operators. Here is my problem. I need to solve for $x$. Everything is an integer, including $x$:

$$a - 1 = \lfloor {\frac{x - b}{b - c} \rfloor}$$

The wiki has a nice page on the floor operator, but I am new at equations involving floor manipulations, so I am not really sure how to go about isolating $x$ at this point, thereby solving for it. Thanks.

EDIT: This is not a homework problem. I am writing software that needs to solve this for a seismological problem.

Hint: $a - 1 = \lfloor {\frac{x - b}{b - c} \rfloor}$ if and only if $a - 1\le \frac{x - b}{b - c}<a$. So you have to solve this system of inequalities.
• @Spacey Of course, this is possible, there are clearly exactly $|b-c|$ solutions. Jan 2, 2014 at 17:03