Integer n: Solving the Equation ##\dfrac{n^2+3}{2n+4}## for Integers

  • Context: High School 
  • Thread starter Thread starter anemone
  • Start date Start date
  • Tags Tags
    Integers
Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
14 replies · 2K views
anemone
Gold Member
MHB
POTW Director
Messages
3,851
Reaction score
115
Find all integers n such that ##\dfrac{n^2+3}{2n+4}## is an integer as well.
 
Reply
  • Like
Likes   Reactions: Greg Bernhardt, bob012345 and topsquark
on Phys.org
It is obvious that n is odd integer, so say n=2m+1
The given formula becomes
[tex]m-\frac{1}{2}-\frac{\frac{7}{4}}{m+\frac{3}{2}}[/tex]
So the RHS last term is half integer so
[tex]p(m)=\frac{\frac{7}{2}}{m+\frac{3}{2}}[/tex]is an odd integer.
[tex]|m+\frac{3}{2}|\leq\frac{7}{2}[/tex]
[tex]-5\leq m \leq 2[/tex]
Only p(-5)=-1,p(-2)=-7,p(-1)=7,p(2)=1 are odd integers which result
n=-9,-3,-1,5
 
Last edited:
Reply
  • Like
Likes   Reactions: bob012345
If [tex]n^2 + 3 = k(2n+4)[/tex] then [tex]n^2 - 2kn + (3-4k) = 0.[/tex] The discriminant of that quadratic must be a perfect square, say [tex]k^2 + 4k-3 = m^2.[/tex] Then [tex](k+2)^2 - 7 = m^2.[/tex] The only squares that differ by 7 are 9 and 16, so [tex]k+2 = \pm4.[/tex] Thus either [tex]k = 2[/tex] and [tex]n^2 - 4n - 5 = 0,[/tex] giving [tex]n = -1 \text{ or }5;[/tex] or [tex]k= -6[/tex] and [tex]n^2 + 12n + 27 = 0,[/tex] giving [tex]n = -3 \text{ or }-9.[/tex]
 
Last edited:
Reply
  • Like
  • Love
Likes   Reactions: DaveE, bob012345, Greg Bernhardt and 4 others
Graphically, the relation looks like the following graph if one extends it to the continuous regime. Interestingly, the integer n values are equally spaced on either side of the pole at x=−2 as −2±1 and −2±7.

desmos-graph (32).png
 
Last edited:
Reply
  • Like
Likes   Reactions: Opalg
I also noticed that the lines ##y=x±3## intersect the curve ##\dfrac{x^2+3}{2x+4}## exactly at the integer solution points -9,-3,-1 and 5.

desmos-graph (1).png


If we let ##\dfrac{n^2+3}{2n+4} = n±3 ## we get the four integer solutions quickly because the solutions are the intercepts of the lines with the original function. This can be generalized as;

$$\dfrac{n^2+2k+1}{2n+4} = n±(k+2) \quad k=0,1,2,3...$$
The solutions are $$n=\{-2k-7, -3,-1, 2k+3\}$$ and the original case is recovered with ##k=1##.

EDIT: for very large values of ##k## this method does not get all the cases.
 
Last edited:
bob012345 said:
Graphically, the relation looks like the following graph if one extends it to the continuous regime. Interestingly, the integer n values are equally spaced on either side of the pole at x=−2 as −2±1 and −2±7.
[tex]y=\frac{x^2+3}{2x+4}=\frac{1}{2}(x+2+\frac{7}{x+2})-2[/tex]
So we see the graph is untisymmetric to the line ##y=-2## and ##x=-2##
 
Reply
  • Like
Likes   Reactions: bob012345
(cont.)
say z=x+2
[tex]z+\frac{7}{z}=2n[/tex] even number.
[tex]z^2-2nz+7=0[/tex] should be
[tex](z-1)(z-7)=0[/tex] or
[tex](z+1)(z+7)=0[/tex]
 
Reply
  • Like
Likes   Reactions: bob012345
I leave it so someone else to solve the even cases; $$\dfrac{n^2+2k }{2n+4} \quad k= 1,2,3...$$
 
bob012345 said:
I leave it so someone else to solve the even cases;
As for the extended problem : Find all integers n such that ##\frac{n^2+d}{2n+4}## with integer d, is an integer as well, we should get quadratic equation similar to #7
[tex]z^2-2mz+d+4=0[/tex]
If d+4 is prime number we would get answers similarly.
If d+4 is square number we would get z is ##\pm## square root of it.
More in general if we can factorize
[tex]d+4=MN[/tex]
where M and N are both odd or even, that provides the answer.
As for your interest of even d, it is any multiple of 4 so that both M and N are even.
 
Last edited:
anuttarasammyak said:
As for the extended problem : Find all integers n such that ##\frac{n^2+d}{2n+4}## with integer d, is an integer as well, we should get quadratic equation similar to #7
[tex]z^2-2mz+d+4=0[/tex]
If d+4 is prime number we would get answers similarly.
If d+4 is square number we would get z is ##\pm## square root of it.
More in general if we can factorize
[tex]d+4=MN[/tex]
where M and N are both odd or even, that provides the answer.
As for your interest of even d, it is any multiple of 4 so that both M and N are even.
Please clarify your process in #7. Where does the ##2n## come from?

$$z+\frac{7}{z}=2n$$

Also, for ##d+4=MN##, if d is even, don't both M and N have to be even?
 
bob012345 said:
Please clarify your process in #7. Where does the 2n come from?
In the formula of #6 due to the coefficient ##\frac{1}{2}##, ##z+\frac{7}{z}## is an even number so that y is an integer.
bob012345 said:
Also, for d+4=MN, if d is even, don't both M and N have to be even?
M,N are solutions of the quadratic equation of z. M+N =2m is even, i.e. they are both odd or even.
 
I agree the even cases only work for multiples of 4;

$$f(n)=\dfrac{n^2+4k }{2n+4} \quad k= 1,2,3...$$ where;

$$n=\{-2(k+2), -4,0, 2k\}$$ and the values of the relation are;

$$ f(n)=\{-4-k,k\}$$

EDIT: Again, for large values of ##k## this does not get all possible cases. See post #13 by @anuttarasammyak.
 
Last edited:
I think there are more cases than you show
e.g.
[tex]k+1=\frac{M}{2}\frac{N}{2}[/tex]
for k=119 (M/2,N/2)={(1,120),(2,60),(3,40),(4,30),(5,24),(6,20),(8,15),(10,12)} for M<N
 
Last edited:
anuttarasammyak said:
I think there are more cases than you show
e.g.
[tex]k+1=\frac{M}{2}\frac{N}{2}[/tex]
for k=119 (M/2,N/2)={(1,120),(2,60),(3,40),(4,30),(5,24),(6,20),(8,15),(10,12)} for M<N
Well, I did miss some! According to Wolfram Alpha, there are 32 integer solutions for k=119.

https://www.wolframalpha.com/input?i=+++(x^2++476)/(2x+4)+=+m+

I'm not sure what you mean by

$$k+1=\frac{M}{2}\frac{N}{2}$$ or how it works to generate solutions to the original problem. For example, for k=119, what is (1,120)? How is it a solution to the original problem?

Did you meant solutions to this?

$$ \dfrac{n^2+4*119 }{2n+4} $$
 
Last edited:
Reply
  • Like
Likes   Reactions: anuttarasammyak
bob012345 said:
Well, I did miss some! According to Wolfram Alpha, there are 32 integer solutions for k=119.

https://www.wolframalpha.com/input?i=+++(x^2++476)/(2x+4)+=+m+
bob012345 said:
Did you meant solutions to this?
Yes. 32 solutions correspond with 16 solutions in post #13 doubled by putting minus sign.

bob012345 said:
For example, for k=119, what is (1,120)?
z=x+2=2, 240
x=0, 238
They are in your wolfram solution list. Explicitly
[tex]n=\pm 2q -2[/tex]where q is a devisor of k+1
[tex]k+1 \equiv 0(mod\ q)[/tex]
 
Last edited:
Reply
  • Like
Likes   Reactions: bob012345