# Integer factorization: Single solution for integer equation

While working on my integer factorization project, I came to this:

$(A + CX)(B + CY) = D$

• $X,Y,A,B,C,D$ Are integer numbers
• $A,B,C,D > 0$
• $X,Y >= 0$
• $A,B,X,Y < C < D$
• If $X=Y$ than $Y > 0$ to avoid trivial solutions where $X = Y = 0$

What assignment of $A,B,C,D$ will provide only one solution for $X,Y$?

It looks like Diophantine equation can be handy here. But I do not know how to apply it.

I am not looking for example but for patterns.

Here is an example for such case:
$A=7;B=3;C=10;D=391$
$(7 + 10X)(3 + 10Y)=391$
The only solution here is: $X=1;Y=2$

• Take $A, B$ arbitrary, $C$ satisfying $\max\{A,B\}<C<AB$. Then set $D=AB$ and again $X=Y=0$ is the unique solution. – vadim123 Jan 16 '15 at 21:52
• @vadim123 Nice one! I added another qualification to avoid those cases. – Ilya Gazman Jan 16 '15 at 22:00
• Okay, look, that's twice I've solved your problem, and twice you've changed it. I will solve it one more time, and that's it. – vadim123 Jan 16 '15 at 23:42
• Take $A=1, B=2, C=3, D=5$. Then $X=1, Y=0$ is the only solution. – vadim123 Jan 16 '15 at 23:43

For $D$ arbitrary, let $A=1$, $B=1$, $C=D-1$. Then the only solution is $X=0$, $Y=1$.