During Software designing our team come across the following problem: we have linear Diophantine equation with n variables with each variable have positive permissible range or allowed range.
a1x1+a2x2+....+anxn = b
known parameters:
a1,a2,...,an and b
unknown parameter x1,x2,....,xn
but we know that
x1 belongs to range [l1,r1]
x2 belongs to range [l2,r2]
.
.
.
xn belongs to range [ln,rn]
0<li<ri
ai>0
b>0
and we need to find values of all xi in above equation(may be float or integer). I have come across lot of solution online one of them CP-algorithm and another one is reduce problem Coin change problem of DP. But I am thinking there must be better algorithm to this problem.