This is the equation
$$y=(K-3x)/(1+2x)$$
$K$ is a positive integer
I want to know for any given $K>0$, without plotting a graph, is it possible to know this equation has positive integer solutions or not?
It may be simple but I already left school for decades. I just come across maths problem again and I find it interesting. So please help.
Many Thanks in advance.
Suppose there is a positive integer solution, that is, for some positive integers $x,y$:
$$K - 3x = y(1+2x)$$
Observe that: $$2K + 3 = (2K-6x)+(3+6x) = (2y+3)(1+2x)$$
which is also a multiple of $1+2x$.
So we only need to check whether $2K+3$ has factors of the form $1+2x$.
But $2K+3$ is odd, so all its factors are odd.
However we require $x, y > 0$. This leads to (edited): $$x< \frac K3 \implies 3 \le 1+2x < 1+\frac {2K}3 = \frac {2K+3}3$$
and we can show that, whenever $2K+3$ is not prime and greater than $9$, there is an odd factor of $2K+3$ satisfying the above inequality.
Therefore there is a positive integer solution whenever $2K+3$ is composite and $>9$.