2
$\begingroup$

For what values of $q$ would $3n - q^2 \equiv 0\pmod{4q}$, or for what values of $q$ would $3n - q^2$ divide by $4q$ and leave no remainder, where $n$ is a positive integer and $q$ is a positive divisor of $n$.

1 Answers 1

3

If $n = q k$, $3n - q^2 = (3k - q) q$. So you need $3k - q$ to be divisible by $4$, i.e. $q \equiv -k \mod 4$. Now since $q k = n$, that says $n \equiv -q^2 \mod 4$. The squares mod $4$ are $0$ and $1$, so we have the following possibilities:

  • if $n \equiv 1$ or $2 \mod 4$, it is impossible
  • if $n \equiv 0 \mod 4$, $q \equiv n/q \equiv 0$ or $2 \mod 4$ (thus either $n \equiv 0 \mod 16$ or $n \equiv 4 \mod 8$).
  • if $n \equiv 3 \mod 4$, it is true for any $q$ dividing $n$.