Inverse function of round; solving equations involving round function

1.2k Views Asked by At

I am trying to solve the equation with which I came up from the accounting task:

Round((0.844+delta)*1; 2)=0.89

or generally:

Round((a+delta)*n; 2)=b; delta=?

Of course, delta is not single value, it is interval, set of values but to achieve uniqueness let define the final solution delta^ as:

delta^=sgn(delta)*Min(Abs(delta))

Of course, I can always run iterative search with the step value 0.001 to solve the problem, but maybe there exist explicit function of delta^ as a function of a, b, and n?

It is the usual arithmeitc rounding with 2 positions.