You Will Need a Square State Of Mind

What is the sum of the 2 \displaystyle 2 smallest possible values of n Z \displaystyle n \in \mathbb{Z} , such that both 2 n + 1 \displaystyle 2n+1 and 3 n + 1 \displaystyle 3n+1 are perfect squares?

Bonus Find the GCD of all such n n .


The answer is 40.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

3 solutions

Vinod Kumar
Feb 11, 2015

2 n + 1 2n+1 is a square so it is odd square.

Now list of odd squares are 1 , 9 , 25 , 49 , 81 , 1,9,25,49,81, \dots , from this list both 1 ( 1 = 2 × 0 + 1 , 3 × 0 + 1 = 1 2 ) , 81 ( 81 = 2 × 40 + 1 ) , ( 3 × 40 + 1 = 121 = 1 1 2 ) (1=2\times 0+1, 3\times 0+1=1^{ 2 }),81(81=2\times 40+1),(3\times 40+1=121=11^{ 2 } ) satisfy the condition so sum is 0 + 40 = 40 0+40=40 .

2 n + 1 2n+1 is a square so it is odd square.

Now list of odd squares are 1 , 9 , 25 , 49 , 81 , 1,9,25,49,81, \dots , from this list both 1 ( 1 = 2 × 0 + 1 , 3 × 0 + 1 = 1 2 ) , 81 ( 81 = 2 × 40 + 1 ) , ( 3 × 40 + 1 = 121 = 1 1 2 ) (1=2\times 0+1, 3\times 0+1=1^{ 2 }),81(81=2\times 40+1),(3\times 40+1=121=11^{ 2 } ) satisfy the condition so sum is 0 + 40 = 40 0+40=40 .

Can you copy the LaTeX \LaTeX off my comment , it'll look better this way ? Also, I didn't mean to be rude if you feel that way , I just wanted your solution to look good . ¨ \ddot\smile . Please check if I made any error and tell me .

A Former Brilliant Member - 6 years, 3 months ago

Log in to reply

Thanks! Done!

Pranjal Jain - 6 years, 2 months ago

Yes, what about the other values of n and the gcd of all such values?

Abhisek Mohanty - 6 years, 2 months ago

what if we put 4 and 1

Avi c - 6 years, 3 months ago
Jehad Aly
Mar 2, 2015

Can anyone please tell me the gcd of n? Gcd(0,40) is 40, but what about the other values of n?

Brock Brown
Feb 16, 2015

Python:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
def perfect(n):
    a = 0
    while a**2 <= n:
        if a**2 == n:
            return True
        a += 1
    return False
def goal(n):
    if perfect(2*n+1):
        if perfect(3*n+1):
            return True
    return False
n = 0
count = 0
total = 0
while count < 2:
    if goal(n):
        count += 1
        total += n
    n += 1
print "Answer:", total

Nice Python script, I think that this equation is also quite well made

Marcelo Carpenter - 4 years, 2 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...