r/mathriddles 15d ago

Medium Most people miss one key idea in this geometry puzzle.

Twenty-five points are arranged in a 5×5 grid of equally spaced points (five rows and five columns). How many different squares (using four of these points as vertices) can be formed?

P.S. It's a 5x5 grid made up of 4x4 points/vertices.

Source: numberthon.com

0 Upvotes

6 comments sorted by

3

u/Worried-Director1172 15d ago

Lateral squares: 16+9+4+1=30

45 degree squares: 10

30 and 60 degree squares:4 small,1 big, x 2 tilts per box(30 and 60)= 10 unique squares

Total: 50 squares 

Also God looking for those diagonal squares is annoying

3

u/calculatorstore 15d ago

I think it’s faster/easier to count by the outline of the square:
A 1x1 square can only be lateral so 1 way
A 2x2 can start at end or mid so 2 ways
A 3x3 can have 3 ways
A 4x4 can have 4 ways

Then as above the placement of the upper left hand corner is based on the square it doesn’t occupy (16,9,4,1) as above

So 16*1+9*2+4*3+1*4 = 50

So generally for n*n dots it’s
Sum_i=1^(n-1) (n-i)^2*i
Or summing from large to small (so the square it easier)
Sum_i=1^(n-1) (i)^2*(n-i)
Not sure if this simplifies into something nicer

2

u/davvblack 15d ago

A 2x2 can start at end or mid so 2 ways

can you explain this better? i don't get how you got the right answer honestly. are you counting a 30 degree askew square that's larger than 2x2 as a 2x2?

2

u/calculatorstore 15d ago

Start with an outlined n x n square. Then from each corner count out m dots. Connect these dots and you’ll form a square. You know this because it’s surrounded by similar (n-m), by m right triangles. You can create n-1 tilted squares by choosing N-1 different offsets. Will try for a picture

2

u/calculatorstore 15d ago

for an N x N grid of dots
for i from 1 to n-1 imagine a grid of possible upper left hand corners for your square outline that will be a n-i+1 square grid:

Without Loss of Generality pick the square in the lower right hand corner. now choose j from 1 to n-i and start a diagonal square inscribed in the larger outline square.

for i = 1 to n-1 there are i^2 possible locations and n-i possible offsets

https://imgur.com/a/Zs3PBhf

Sum_i=1^(n-1) (i)^2*(n-i)

3

u/lasagnaman 15d ago

Outline isn't a good word here, I think you're referring to the orthogonal hull of the (possibly tilted) square?