Current location - Music Encyclopedia - Chinese History - Introduce some common sense of three-level Rubik's cube
Introduce some common sense of three-level Rubik's cube
The third-order magic square is the simplest magic square, also called Jiugongge. It is a three-row and three-column matrix composed of nine numbers 1, 2, 3, 4, 5, 6, 7, 8 and 9 (as shown in the right figure). It is diagonal, horizontal and vertical.

The sum of is 15, and the magic sum of this simplest magic square is 15. The number of centers is 5.

According to legend, when Dayu was controlling water, a "tortoise" with wonderful patterns appeared in Luoshui, which was called "Luoshu" in history. Translated by the current numbers, it is a third-order Rubik's cube.

2,500 years ago, Confucius recorded in his book "Uploading Cohesion" that he studied the Book of Changes: "Rivers draw pictures, books are published, and saints do it." The earliest record linking numbers with Luo Shu was Zhuangzi Tian Yun 2300 years ago, which said: "Heaven has six poles and five permanents, and emperors will rule if they obey it, but they will be fierce if they disobey it. As a moral preparation, the nine Luo events are supervised by the local authorities and worn by the world. This is called the emperor. " Cheng Dawei, a mathematician in Ming Dynasty, also issued "What is number? Is it from pictures and books? Fuxi got it by painting hexagrams, Dayu got it by defining the territory, and the sage got it by opening things. The general idea is that the number originated from the ancient Yellow River map and Luoshui Luoshu, Fuxi drew eight diagrams by the river, and Dayu divided Kyushu by Luoshu, and formulated nine kinds of Dafa to govern the world. According to them, the saints deduced all kinds of good strategies for governing the country and safeguarding the country, and their understanding of human society and nature was deepened step by step. Inspired by the mutual restriction, balance and unification of the numbers in Luo Shu, Dayu formulated the national legal system, which unified the world and belonged to Da Zhi. This is the beginning of learning from thinking. This way of activating thinking has become one of the sources of scientific inspiration. The Rubik's Cube, which originated from Luo Shu, is more vigorous today after thousands of years, and is called a mathematical problem with eternal charm. /kloc-in the 3rd century, Yang Hui, a mathematician in the Southern Song Dynasty, made a systematic study of the magic square in the world, and in Europe in the 4th century, this work also began. Famous mathematicians Fermat and Euler have studied magic squares. Today, magic square is still one of the research topics of combinatorial mathematics. Through the joint efforts of generations of algebra and math lovers, the Rubik's Cube and its variants are gradually being revealed. At present, it has been widely used in combinatorial analysis, experimental design, graph theory, number theory, group theory, game theory, textile, arts and crafts, programming, artificial intelligence and other fields. 1977, the fourth-order Rubik's Cube was also taken into space by American travelers 1 2, as a special language of human beings, to convey the information and good wishes of human civilization to aliens who may exist in the vast universe!

The magic square generated by continuous natural numbers such as 1, 2, 3, ... is the basic Rubik's cube. On this basis, a new magic square consisting of zero or negative numbers can be formed by adding or subtracting the same number from each number.

A new magic square generated by subtracting 1 from each number of the third-order basic magic square.

The magic sum of the magic square has also changed, and it is no longer the same as the original magic square.

The magic sum of the new magic square generated by subtracting 1 from each number in the basic magic square shown above is 12, as shown below:

Thinking:1+9 =10,2+8 =10,3+7 =10,4+6 =10. If the sum of each logarithm plus 5 equals 15, it can be determined that the center grid should be filled with 5, and these four groups of numbers should be filled in the horizontal, vertical and diagonal positions respectively. Fill in four corners first. If you fill in two odd pairs, then you may get an odd number, because the sum of three odd numbers. You can't fill in any odd numbers in the four squares. No If all four corners are a pair of even numbers and an odd number, that won't do either. Therefore, it is decided that two even pairs must be filled in the four corners. After the numbers on the diagonal are filled in, the odd numbers in the remaining boxes are easy to fill in.

The ancient way

Yang Hui, a mathematician in the Southern Song Dynasty, summarized the construction method as follows:

"Nine oblique row. Up and down is easy,

The left and right sides are more important. Four-dimensional prominence. "

The filling formula of Jiugongge in ancient China is:

Jiugong means, the method is to use Linggui,

24 is the shoulder, 68 is the foot,

Left, right, three, nine, one,

Five in the middle.

There is also a combination of the two:

Nine sons are arranged obliquely, which is changeable up and down.

The left and right sides are more similar, and the four dimensions are prominent.

Wear nine, walk one, left seven, right three,

24 is the shoulder and 68 is the foot.

General construction method of odd-order magic square

Formula:

1 At the center of the uplink,

Don't forget to fill in diagonally in turn.

Write down the upper and lower boundaries of the box,

When you put the box on the right, put it on the left.

Repeat and fill in the box below.

Repeat the same thing at the corner.

Explanation:

1) Put 1 in the square in the middle of the first line, and fill in 2, 3, 4 ... to the upper right in turn;

2) If the cell to put the number has exceeded the top row, it will be placed in the bottom row and still placed in the right column;

3) If the cell to put this number has exceeded the rightmost column, put it in the leftmost column and still put it in the previous row;

4) If the sum of the existing numbers in the upper right corner is diagonal, move down one space and continue to fill in.

5) You can also fill in the corresponding numbers in the Rubik's Cube at the corresponding positions.

For example, if 1 is the middle number of the first line, the corresponding 9 will be filled in the middle of the last line. 2 and so on.

In this way, mirror image or rotational symmetry can be used to obtain other filling methods that are actually the same:

As long as 1 is placed in the middle of the four variables, the remaining numbers are filled obliquely to the outside of the Rubik's cube in turn; If it is the outgoing side, adjust the number to the other side; If the target cell has numbers or corners, return and fill in the numbers, and then continue to fill in the remaining numbers diagonally in the same direction as at the beginning.