Tiling squares with distinct Number-Rectangles

Hello Math-Fun,
Say every integer > 9 can produce an h x w rectangle (height first, then width).
We would then have:
10 = 1 x 0 (no rectangle, nothing that we will use here)
11 = 1 x 1 (the unit cell)
12 = 1 x 2 (see below)
13 = 1 x 3 (see below)
...
21 = 2 x 1 (see below)
31 = 3 x 1 (see below)
...
100 = 10 x 0 (no rectangle, nothing that we will use here)
101 = 10 x 1 (no other choice, we don't accept any height or width starting with zero)
...
111 = 1 x 11 or 11 x 1
112 = 1 x 12 or 11 x 2
...
2023 = 20 x 23 or 202 x 3
...
We will use "NR" for the integers of the above left column (NR stands for Number-Rectangle)
Now we want two things:
1) to tile an n x n square with distinct shapes of NRs
2) the sum of the NRs involved in the tiling is itself a square.
 
Examples
+---+
|   | the 11-NR
+---+
+---+---+
|   |   | the 12-NR
+---+---+
+---+---+---+
|   |   |   | the 13-NR
+---+---+---+
+---+
|   |
+---+ the 21-NR
|   |
+---+
+---+
|   |
+---+
|   | the 31-NR
+---+
|   |
+---+

+---+---+---+
| 11|       |
+---+       +
|   |   32  | a sound 3 x 3 square as 11 + 21 + 32 = 64 = 8^2
| 21|       +
|   |       |
+---+---+---+
 
+---+---+---+
|   12  | 11|
+-------+---+  the above square, tilted here 90 degrees 
|           |  clockwise, is NOT a sound 3 x 3 square 
+    23     +  (as 12 + 11 + 23 = 46 is NOT a square)
|           |
+---+---+---+

+---+---+---+
|     13    |
+---+---+---+
|           | another sound 3 x 3 square as 13 + 23 = 36 = 6^2
+     23    + (found by Scott Shannon)
|           |
+---+---+---+

+---+---+---+---+
| 11|  12   |   |
+---+---+---+   +
|     13    |   |
+---+---+---+ 41sound 4 x 4 square as 11 + 12 + 13 + 23 + 41 = 100 = 10^2
|           |   |
+     23    +   +
|           |   |
+---+---+---+---+

Question
Are there more such sound n x n squares?
Best,
É. 

Maximilian H. was quick to answer, as usual:

Eric,
 are you sure the painting on your blog page is not turned by 90° ?
 ;-)
 Yes there are many such "sound squares".
 I think it's quite a challenge to write a program for the general case,
 but considering just decompositions in 3 rectangles is very easy.
 I get this list:
  3 x 2 + 1 x 1 + 2 x 1 (= 8^2),
  1 x 5 + 4 x 1 + 4 x 4 (= 10^2),
  1 x 5 + 4 x 2 + 4 x 3 (= 10^2),
  1 x 7 + 6 x 1 + 6 x 6 (= 12^2),
  1 x 7 + 6 x 2 + 6 x 5 (= 12^2),
  1 x 7 + 6 x 3 + 6 x 4 (= 12^2),
  8 x 7 + 1 x 1 + 7 x 1 (= 13^2),
  8 x 7 + 2 x 1 + 6 x 1 (= 13^2),
  8 x 7 + 3 x 1 + 5 x 1 (= 13^2),
  9 x 2 + 1 x 7 + 8 x 7 (= 14^2),
  9 x 2 + 2 x 7 + 7 x 7 (= 14^2),
  9 x 2 + 3 x 7 + 6 x 7 (= 14^2),
  9 x 2 + 4 x 7 + 5 x 7 (= 14^2),
 12 x 8 + 1 x 4 + 11 x 4 (= 16^2),
 12 x 8 + 2 x 4 + 10 x 4 (= 16^2),
 12 x 8 + 3 x 4 + 9 x 4 (= 16^2),
 12 x 8 + 4 x 4 + 8 x 4 (= 16^2),
 12 x 8 + 5 x 4 + 7 x 4 (= 16^2),
 13 x 12 + 1 x 1 + 12 x 1 (= 38^2), 
 13 x 12 + 2 x 1 + 11 x 1 (= 38^2), 
 13 x 12 + 3 x 1 + 10 x 1 (= 38^2), 
 13 x 12 + 4 x 1 + 9 x 1 (= 38^2), 
 13 x 12 + 5 x 1 + 8 x 1 (= 38^2), 
 13 x 12 + 6 x 1 + 7 x 1 (= 38^2),
  8 x 15 + 7 x 1 + 7 x 14 (= 40^2),
  8 x 15 + 7 x 2 + 7 x 13 (= 40^2), 
  8 x 15 + 7 x 3 + 7 x 12 (= 40^2),
  8 x 15 + 7 x 4 + 7 x 11 (= 40^2), 
  8 x 15 + 7 x 5 + 7 x 10 (= 40^2), 
15 x 6 + 1 x 9 + 14 x 9 (= 18^2),
15 x 6 + 2 x 9 + 13 x 9 (= 18^2), 
15 x 6 + 3 x 9 + 12 x 9 (= 18^2),
15 x 6 + 4 x 9 + 11 x 9 (= 18^2), 
15 x 6 + 5 x 9 + 10 x 9 (= 18^2),
15 x 6 + 6 x 9 + 9 x 9 (= 18^2), 
15 x 6 + 7 x 9 + 8 x 9 (= 18^2),
 etc.
 Best wishes,
 -M.
(PARI)
{dec3(n)=my( cc(x,y)=eval(Str(x,y)), p(a,b,c,d,e,f,g)=
printf("%d x %d + %d x %d + %d x %d (= %d^2), ",a,b,c,d,e,f,g));
for(x=1,n-1, my( HW=cc(n-x,n), WH=cc(n,n-x), s ); for( a=1, (n-1)\2,
issquare( HW + cc(x,a) + cc(x,n-a), &s ) && p( n-x,n, x,a, x,n-a, s);
issquare( WH + cc(a,x) + cc(n-a,x), &s ) && p( n,n-x, a,x, n-a,x, s)))}

+---+---+---+---+---+
|         15        |
+---+---+---+---+---+
|   |               |
+   +               +
|   |               |
+ 41|      44       + sum = 15 + 41 + 44 = 100 = 10^2
|   |               | +   +               + |   |               | +---+---+---+---+---+   +---+---+---+---+---+ |         15        | +---+---+---+---+---+ |       |           | +       +           + |       |           | +  42   +    43     + sum = 15 + 42 + 43 = 100 = 10^2 |       |           | +       +           + |       |           | +---+---+---+---+---+   +---+---+---+---+---+---+---+ |             17            | +---+---+---+---+---+---+---+ |   |                       | +   +                       + |   |                       | +   +                       + |   |                       | + 61|         66            + sum = 17 + 61 + 66 = 144 = 12^2 |   |                       | +   +                       + |   |                       | +   +                       + |   |                       | +---+---+---+---+---+---+---+   +---+---+---+---+---+---+---+ |            17             | +---+---+---+---+---+---+---+ |       |                   | +       +                   + |       |                   | +       +                   + |       |                   | +   62  |       65            + sum = 17 + 62 + 65 = 144 = 12^2 |       |                   | +       +                   + |       |                   | +       +                   + |       |                   | +---+---+---+---+---+---+---+   +---+---+---+---+---+---+---+ |            17             | +---+---+---+---+---+---+---+ |           |               | +           +               + |           |               | +           +               + |           |               | +     63    |    64         + sum = 17 + 63 + 64 = 144 = 12^2 |           |               | +           +               + |           |               | +           +               + |           |               | +---+---+---+---+---+---+---+   +---+---+---+---+---+---+---+---+ |                           | 11| +                           +---+ |                           |   | +                           +   + |                           |   | +                           +   + |                           |   | +            87             + 71| sum = 87 + 11 + 71 = 169 = 13^2 |                           |   | +                           +   + |                           |   | +                           +   + |                           |   | +                           +   + |                           |   | +---+---+---+---+---+---+---+---+   +---+---+---+---+---+---+---+---+ |                           |   | +                           + 21| |                           |   | +                           +---+ |                           |   | +                           +   + |                           |   | +                           +   + |            87             | 61| sum = 87 + 21 + 61 = 169 = 13^2
+                           +   + |                           |   | +                           +   + |                           |   | +                           +   + |                           |   | +---+---+---+---+---+---+---+---+ 
+---+---+---+---+---+---+---+---+ |                           |   | +                           +   + |                           | 31| +                           +   + |                           |   | +                           +---+ |                           |   | +                           +   | |            87             | 51| sum = 87 + 31 + 41 = 169 = 13^2
+                           +   + |                           |   | +                           +   + |                           |   | +                           +   + |                           |   | +---+---+---+---+---+---+---+---+   +---+---+---+---+---+---+---+---+---+ |       |                           | +       +                           + |       |                           | +       +                           + |       |                           | +       +                           + |       |                           | +       +                           + |  92   |            87             | sum = 92 + 87 + 17 = 196 = 14^2 +       +                           + |       |                           | +       +                           + |       |                           | +       +                           + |       |                           | +       +---+---+---+---+---+---+---+ |       |            17             | +---+---+---+---+---+---+---+---+---+   +---+---+---+---+---+---+---+---+---+ |       |                           | +       +                           + |       |                           | +       +                           + |       |                           | +       +                           + |       |                           | +       +                           + |  92   |            77             | sum 92 + 77 + 27 = 196 = 14^2
+       +                           + |       |                           | +       +                           + |       |                           | +       +---+---+---+---+---+---+---+ |       |                           | +       +            27             + |       |                           | +---+---+---+---+---+---+---+---+---+   +---+---+---+---+---+---+---+---+---+ |       |                           | +       +                           + |       |                           | +       +                           + |       |                           | +       +                           + |       |                           | +       +                           + |  92   |            67             | sum 92 + 67 + 37 = 196 = 14^2 
+       +                           + 
|       |                           | +       +---+---+---+---+---+---+---+ |       |                           | +       +                           + |       |            37             | +       +                           + |       |                           | +---+---+---+---+---+---+---+---+---+   +---+---+---+---+---+---+---+---+---+ |       |                           | +       +                           + |       |                           | +       +                           + |       |                           | +       +                           + |       |                           | +       +                           + |  92   |            57             | sum = 92 + 57 + 47 = 196 = 14^2 +       +---+---+---+---+---+---+---+ |       |                           | +       +                           + |       |                           | +       +            47             + |       |                           | +       +                           + |       |                           | +---+---+---+---+---+---+---+---+---+                                      +---+---+---+---+---+---+---+---+---+---+---+---+ |                               |               | +                               +               + |                               |               | +                               +               + |                               |               | +                               +               + |                               |               | +                               +               + |                               |               | +                               +               + |                               |               | +              128              +      114      +
|                               |               | +                               +               + |                               |               | +                               +               + |                               |               | +                               +               + |                               |               | +                               +               + |                               |               | +                               +---+---+---+---+ |                               |      14       | +---+---+---+---+---+---+---+---+---+---+---+---+
sum = 128 + 114 + 14 = 256 = 16^2 
Next sums (and according 12 x 12 squares):
128 + 104 + 24 = 256 = 16^2
128 + 94 + 34 = 256 = 16^2
128 + 84 + 44 = 256 = 16^2
128 + 74 + 54 = 256 = 16^2
                 


Commentaires

  1. I think it's quite a challenge to write a program for the general case,
    but considering just decompositions in 3 rectangles is very easy.
    I get this list:
    3 x 2 + 1 x 1 + 2 x 1 (= 8^2),
    1 x 5 + 4 x 1 + 4 x 4 (= 10^2), 1 x 5 + 4 x 2 + 4 x 3 (= 10^2),
    1 x 7 + 6 x 1 + 6 x 6 (= 12^2), 1 x 7 + 6 x 2 + 6 x 5 (= 12^2), 1 x 7 + 6 x 3 + 6 x 4 (= 12^2),
    8 x 7 + 1 x 1 + 7 x 1 (= 13^2), 8 x 7 + 2 x 1 + 6 x 1 (= 13^2), 8 x 7 + 3 x 1 + 5 x 1 (= 13^2), 8 x 7 + 4 x 1 + 4 x 1 (= 13^2),
    9 x 2 + 1 x 7 + 8 x 7 (= 14^2), 9 x 2 + 2 x 7 + 7 x 7 (= 14^2), 9 x 2 + 3 x 7 + 6 x 7 (= 14^2), 9 x 2 + 4 x 7 + 5 x 7 (= 14^2),
    12 x 8 + 1 x 4 + 11 x 4 (= 16^2), 12 x 8 + 2 x 4 + 10 x 4 (= 16^2), 12 x 8 + 3 x 4 + 9 x 4 (= 16^2),
    12 x 8 + 4 x 4 + 8 x 4 (= 16^2), 12 x 8 + 5 x 4 + 7 x 4 (= 16^2), 12 x 8 + 6 x 4 + 6 x 4 (= 16^2), ...
    Pasting this PARI code into their online interpreter you can get more:

    {dec3(n)=my( cc(x,y)=eval(Str(x,y)), p(a,b,c,d,e,f,g)=
    printf("%d x %d + %d x %d + %d x %d (= %d^2), ",a,b,c,d,e,f,g));
    for(x=1,n-1, my( HW=cc(n-x,n), WH=cc(n,n-x), s ); for( a=1, n\2,
    issquare( HW + cc(x,a) + cc(x,n-a), &s ) && p(n-x,n, x,a, x,n-a, s);
    issquare( WH + cc(a,x) + cc(n-a,x), &s ) && p( n,n-x, a,x, n-a,x, s)))}
    /* then do: */ for(n=2,12,dec3(n))

    RépondreSupprimer
  2. oops, above program lists duplicates, replace n\2 by (n-1)\2 or n\/2-1 to fix this bug.
    Note, n=15 is the smallest size with a "horizontal" and distinct "vertical" partition, and distinct square sums.

    RépondreSupprimer

Enregistrer un commentaire

Posts les plus consultés de ce blog

Beautés ?

Le tripalin se présente

Underline, reproduce