2

Find all integers $n$ such that $\dfrac{16(n^2-n-1)^2}{2n-1}$ is an integer.

Bill Dubuque
  • 285,713

5 Answers5

5

This method is not necessarily the "fastest" way to solve this kind of problem, but its power resides in the fact that it always works.

First of all, expand the numerator (I know, this doesn't seem to help at all, but it does!). You get the expression $16n^4 -32n^3-16n^2+32n+16$.

Now perform the long division between that expression and your denominator $2n-1$ (think of these two expressions as if they were polynomials).

You obtain as quotient $8n^3-12n^2-14n+9$ and your remainder is the integer number $25$.

Since you wanted this division to be exact, this means that the remainder $25$ had to be divisible by $2n-1$. So you now try to equate $2n-1$ with every possible divisor of $25$. Those are $-25,-5,-1,1,5,25$. Each of these give a possible value of $n$: $-12,-2,0,1,3,13$.

  • Yes, division is indeed slower here because we don't need the quotient - only the remainder, i.e. $\bmod 2n-1!:\ f(2n)\equiv f(1) = 25,,$ as explained in my answer. – Bill Dubuque Oct 20 '25 at 22:25
4

Hint

$$16(n^2-n-1)^2{=(4n^2-4n+1-5)^2=\Big((2n-1)^2-5\Big)^2\\= (2n-1)^4-10(2n-1)^2+25 }$$ therefore $${16(n^2-n-1)^2\over 2n-1}\in \Bbb Z\iff {25\over 2n-1}\in \Bbb Z$$

Mostafa Ayaz
  • 33,249
2

Starting off with the initial expression: $$\frac{16(n^2-n-1)^2}{2n-1}$$ Completing the square: $$=\frac{4^2(n^2-n-1)^2}{2n-1}$$ $$=\frac{(4n^2-4n-4)^2}{2n-1}$$ $$=\frac{((2n-1)^2-5)^2}{2n-1}$$ Some manipulation: $$=(2n-1)^3(1-\frac{5}{(2n-1)^2})^2$$ Expanding the expression: $$=(2n-1)^3-10(2n-1)+\frac{25}{2n-1}$$

Since the first two terms will always be integers,

If this expression is to be an integer, then: $$(2n-1)= factor\ of\ 25$$ $$n=\frac{1+factor\ of\ 25}{2}$$ The factors of 5 are $\pm 1, \pm 5, \pm 25$

thus,

n=$1\pm1\over 2$

or

n=$1\pm 5 \over 2$

or

n=$1\pm 25 \over 2$

n=1,0,-2,3,-12,13

Boy
  • 427
1

Let $k = 2n-1$ then $$\dfrac{16(n^2-n-1)^2}{2n-1} = \dfrac{(4n^2-4n-4)^2}{2n-1}$$ $$ = \dfrac{((k+1)^2-2(k+1)-4)^2}{k} = {(k^2-5)^2\over k}$$

So $$k\mid (k^2-5)^2= k^4-10k^2+25$$ $$\implies k\mid 25 \implies k\in\{\pm 1, \pm 5,\pm 25\}$$

nonuser
  • 92,607
-1

Hint $\overbrace{ f(\color{#0a0}{2n}) = {\rm dividend} }^{\textstyle\!\!\small\begin{align}{\ \ \ \ \ (4(n^2\,-\ n\ -\ 1))^2\\ =\, ((\color{#0a0}{2n})^2\!-\!\color{darkorange}2(\color{#0a0}{2n})\!-\!\color{#90f}4)^2}\end{align}_{\phantom{|}}} $ & $\bmod \overbrace{2n-1}^{\textstyle\color{#c00}{\color{#0a0}{2n}\equiv 1}}\!:\ f(\color{#0a0}{2n})\equiv f(\color{#c00}1)\,$ by Polynomial Congruence Rule

$${\rm thus}\ \ \ \,2n\!-\!1\mid f(\color{#0a0}{2n})\!\!\overset{\rm\color{darkorange}{MR\!}}\iff 2n\!-\!1\mid f(\color{#c00}1)\ \ {\large[}\!=\:\!25 = (\color{#c00}1^2\!-\!\color{darkorange}2(\color{#c00}1)\!-\!\color{#90f}4)^2\text{ in OP}\,\large]\qquad\ \ $$

The final $(\!\!\iff\!\!)$ is by $\rm\color{darkorange}{MR}$ = divisibility mod reduction $\ d\mid a\!\iff\! d\mid \bar a\ $ if $\ a\equiv \bar a\pmod{\!d}$.


Generally this is a special case of a nonmonic generalization of Factor Theorem divisibility, i.e. we generalize $\, n-a\mid f(n)\iff n-a\mid f(a)\,$ to a nonmonic $(b\nmid 1)$ divisor $\,b\:\!n-a\,$ by scaling $\,f(a/b)\,$ by a power $\,b^k\,$ that clears all denominators, yielding

Theorem $\ \ \bbox[1px,border:1px solid #c00]{\bbox[6px,border:1px solid #c00]{bn\!-\!a\mid f(n)\iff bn\!-\!a\mid b^kf(a/b)\,}}\ $ if $\,(a,b)\!=\!1,\ k=\deg f,\, f\in\Bbb Z[x]$

Proof $ $ by $\color{#0af}{\rm E}$ = Euclid: $\ (a,b)\!=\!1\Rightarrow (bn\!-\!a,b)=(a,b)\!=\!1\,$ so it follows by below, by $\rm\color{darkorange}{MR}$.

$$\begin{align}bn\!-\!a\mid f(n)&= f_k n^k + f_{k-1}n^{k-1} + \cdots + f_0\\[.3em] \overset{\color{#0af}{\rm E\!}}\iff \color{#0a0}{bn}\!-\!\color{#c00}a\mid\, b^k f\ &= f_k (\color{#0a0}{bn})^k + f_{k-1} b (\color{#0a0}{bn})^{k-1}+\cdots + b^k f_0\\[.3em] &\equiv \underbrace{f_k\ \color{#c00}a^k\ \ +\ \ f_{k-1}\, b\,\color{#c00}a^{k-1} + \ \cdots\ \ + b^k f_0}_{\textstyle b^kf(a/b)\in\Bbb Z}\!\!\pmod{\!\color{#0a0}{bn}\!-\!\color{#c00}a} \end{align}\qquad$$

Alternatively we can use modular fractions and simply evaluate $\,f(x)\,$ at $\,\color{#c00}{n\equiv a/b}\,$ or, equivalently, we can use a nonmonic division algorithm to work fraction-free, i.e. we get a simple fraction-free form of the Polynomial Remainder Theorem by clearing denominators as in the above proof.

See also here for analogous methods used in gcd computation.

Bill Dubuque
  • 285,713