Problems & Puzzles: Puzzles

Puzzle 869. Prime nested magic squares

Honoring the Matrioskas craftworks art.

During these last two weeks I became busy looking for what I will call "nested prime magic squares".

As its name suggests a nested magic square points to two or more magic squares such that the internal(s) one is(are) contained inside other(s) external(s) one, according to certain valid rules that maintain the magicity property.

But this time we will proceed in a new direction to avoid the so called "bordered magic squares". These, already known, may be seen here.

In the bordered magic squares the magic squares are of different order, in a very precise manner: if the inner magic square is of order n, then the next outer magic square is of order n+2, and so on...

In our nested magic squares the inner and the outer magic squares remain of the same order. The only changes are in the integers inside the cells and differ of course in the magic constant.

Our nested magic squares are based in a very basic property of the magic squares:

If all the integers in the cells of one magic square are multiplied by the same constant k or/and if all the integers in the cells are added the same constant q (or a combination of these two operations) then the resulting square remains magic.

The special feature in our nested magic squares is that in the outer magic square is evident what are the integers that remain from the inner magic square or if you prefer, is evident what digits are going to be peeled off from the outer magic square in order to get the inner magic square.

A very simple and trivial example is given:

inner magic square (n)   outer magic square (m)
2 9 4   427 497 447
7 5 3   477 457 437
6 1 8   467 417 487
Rule: m=(4*10+n)*10+7

According to the example, in a pair of nested magic squares as the exemplified above, every integer in the inner matrix is n and every integer in the outer matrix is m such that m=L&n&R and the general rule is m=(L*10^LN+n)*10^LR+R, where L is the integer to be added at the left of n, LN is the largest quantity of digits of n, R is the integer to be appended at the right of n and LR is the quantity of digits of R.

It may happen that both L&R are positive integers, but it may happen that one of them is missed.

If no other conditions are imposed then the nested magic squares described up to here are trivial.

One simple way to avoid triviality is to demand that all the integers are of special form.

For example, what if all the integers must be prime numbers?

Now, the nested prime magic squares are far from triviality. Nevertheless they exist.

Analyzing all the possible prime magic squares with primes inside less than 1000, I obtained 34 nested solutions: 20 type LR, 10 type L and 4 type R.

Here are the smallest example for each type.

All of these three examples of nested prime magic squares 3x3 are of the type "grade 2" which means that involves 2 magic squares each.

Of course it may exist nested prime magic squares grade k, for k>2.

Next I show three examples of nested prime magic squares 3x3, grade 3.

Here we show only the very outer magic squares. As a matter of fact, we show each of them in two ways: a) in the left side, we use colours in order to indicate what digits must be peeled off to obtain the inner magic squares b) in the right side, we use parentheses for the same purpose than the colours.

Q. Please send one solution of prime nested magic square 3x3, grade 4.



Records   |  Conjectures  |  Problems  |  Puzzles