Puzzle with numbers from 1 to 9. How to solve magic squares? What are the solutions?

There are various techniques for constructing squares of single parity and double parity.

  • Calculate the magic constant. This can be done using the simple mathematical formula /2, where n is the number of rows or columns in the square. For example, in a square 6x6 n=6, and its magic constant is:

    • Magic constant = / 2
    • Magic constant = / 2
    • Magic constant = (6 * 37) / 2
    • Magic constant = 222/2
    • The magic constant for a 6x6 square is 111.
    • The sum of the numbers in any row, column and diagonal must be equal to the magic constant.
  • Divide the magic square into four equally sized quadrants. Label the quadrants A (top left), C (top right), D (bottom left), and B (bottom right). To find the size of each quadrant, divide n by 2.

    • Thus, in a 6x6 square, the size of each quadrant is 3x3.
  • In quadrant A, write the fourth part of all numbers; in quadrant B, write the next fourth of all numbers; in quadrant C, write the next fourth of all numbers; in quadrant D, write the final quarter of all numbers.

    • In our example of a 6x6 square, in quadrant A, write the numbers 1-9; in quadrant B - numbers 10-18; in quadrant C - numbers 19-27; in quadrant D - numbers 28-36.
  • Write down the numbers in each quadrant as you would for an odd square. In our example, start filling quadrant A with numbers starting from 1, and quadrants C, B, D - starting with 10, 19, 28, respectively.

    • Always write the number from which you begin filling in each quadrant in the center cell of the top row of a particular quadrant.
    • Fill in each quadrant with numbers as if it were a separate magic square. If an empty cell from another quadrant is available when filling a quadrant, ignore this fact and use the exceptions to the rule for filling odd squares.
  • Highlight specific numbers in quadrants A and D. At this stage, the sum of the numbers in columns, rows and diagonally will not be equal to the magic constant. Therefore, you must swap the numbers in certain cells of the upper left and lower left quadrants.

    • Starting from the first cell of the top row of quadrant A, select a number of cells equal to the median number of cells in the entire row. Thus, in a 6x6 square, select only the first cell of the top row of quadrant A (the number 8 is written in this cell); in a 10x10 square you need to select the first two cells of the top row of quadrant A (the numbers 17 and 24 are written in these cells).
    • Form an intermediate square from the selected cells. Since you have selected only one cell in a 6x6 square, the intermediate square will consist of one cell. Let's call this intermediate square A-1.
    • In a 10x10 square, you selected the two cells in the top row, so you need to select the first two cells in the second row to form an intermediate 2x2 square of four cells.
    • On the next line, skip the number in the first cell, and then highlight as many numbers as you highlighted in the intervening square A-1. Let's call the resulting intermediate square A-2.
    • Obtaining intermediate square A-3 is similar to obtaining intermediate square A-1.
    • Intermediate squares A-1, A-2, A-3 form the selected area A.
    • Repeat the process described in quadrant D: create intermediate squares that form the selected area D.
  • How to solve magic squares?



    A puzzle like Sudoku is commonly called a magic square. This is a square whose cells are filled with numbers so that the sum at the end of any row, column and diagonal is the same. In magic square puzzles, some numbers are missing, and you need to arrange them in such a way as to satisfy the equal sum condition described above. How to solve magic squares?

    Methods for solving magic squares

    In order for the solution of magic squares to be correct, you need to know the very magic sum that should be obtained when adding numbers in rows, columns and diagonals. After this, placing the missing numbers becomes much easier. How to find this amount?

    Method 1

    The simplest version of a magic square is when one of the rows, one of the columns or one of the diagonals is completely filled with numbers. In this case, all that remains is to calculate the sum of these numbers and select solutions.

    Method 2

    The sum of the numbers at the ends of rows, columns and diagonals can be calculated using special formulas. In this case, the formula for squares with an even number of cells in one row will differ from squares with an odd number of cells.

    So, for even squares the following formula is suitable:

    • n + ((n+1) * n * (n-1) / 2) , where n is the number of cells in one row.

    For odd squares the formula is:

    • n * (n 2 +1) / 2, where n is also the number of cells in one row.

    Example solution

    Let's consider solutions to a magic square of nine cells with numbers from 1 to 9. First, let's calculate the sum that should be obtained at the ends. We have 3 cells in one line, that is, n = 3. Substitute the value into the formula:

    • 3 * (3 2 +1) / 2 = 3 * 10 / 2 = 15

    Now we select the numbers so that the sum is 15.

    Next, the algorithm will require a little spatial imagination. Place the number 1 in the middle of the top line. We place each next number on the right diagonally upward. We try to put 2. But there are no cells there, if we substitute another identical imaginary square above our square, then the number 2 will appear in the lower right corner of this
    new square. We transfer it to our square and place it in the lower right corner. We also put the number 3 on the right diagonally upward - and again there is no cell there, using an imaginary square we find out that its place is in the middle of the left column. We put the number 4 according to the same principle, but this cell is occupied by one - in this case we put it directly under the number 3. The number 5 diagonally up and to the right of 4 is in the very center, and the number 6 is in the upper right corner. The number 7, with the help of imagination, should have ended up in the lower left corner. But there is already a 4 there, so we put it directly under the number 6. The number 8 appears with the help of an imaginary square in the upper left corner, and the number 9 in the remaining cell in the middle of the right column. The general algorithm is as follows: put the next number at the top right diagonally, if there is no space, use an imaginary square, and if the cell is occupied, then put the number directly below the previous one.

    I love games where you have to think. Therefore, our series of “top 10” articles smoothly flows into puzzles. Today I will talk about ten number puzzles. When I rushed to compile this rating, I was faced with the problem of finding ten good games, despite the fact that there are tons of digital puzzles in the App Store! The bad thing is that there are a lot of clones, repetitions and low-quality crafts... But when the top was compiled, I realized that everyone will find something new in it! Even I got to know three great games. Go!

    Threes!

    There are numbers on the playing field. The player can move all the numbers in any of the 4 directions. Moreover, if the movement of any row or column is impeded by a wall and there are:

    a) identical numbers greater than or equal to 3
    b) 1 and 2

    then they add up and instead of two numbers a third appears - the sum. The goal is to score as many points as possible. The game is endless, but it is very difficult to score a lot of points.

    After the release of Threes! the App Store became inundated with clones under the name “2048”.

    Shikaku

    A simple and non-pop puzzle from the creators of Sudoku. The goal in this game is to divide the field with numbers into rectangles so that the area of ​​the rectangles is equal to the number inside it. There is only one implementation of this game for iPad.

    Numtris: A game of logic and numbers

    This is an original adventure game. Tetris with numbers. Numbers fall from above and you need to either collect them according to the Threes principle (1 and 2 will give 3), or remove them by collecting several identical ones (for example, four identical fours). Numtris has a full campaign with many missions. The missions are varied: from holding out for 40 seconds to killing a monster... You can compete with friends both online and on the same iPad.

    The game is very stylish with nice graphics. I recommend trying it, since it's free.

    Download Numtris for free (in-app purchases available)

    GREG — A mathematical puzzle game

    An interesting game for speed and the ability to quickly add numbers. There are numbers on a 4 by 4 field. It is necessary to type the sum from these numbers so that you get the number in the circle on top. As soon as the number is collected, it changes and you need to select the numbers again. The less you use some numbers on the field, the more they heat up... After 5 such “heatings” the game may end. Reset occurs after each level. At the end the game rewards you with some title. Can you knock out "Math Genius"?

    There are an unimaginable number of mathematical riddles. Each of them is unique in its own way, but their beauty lies in the fact that to solve it you inevitably need to come to formulas. Of course, you can try to solve them, as they say, but it will be very long and practically unsuccessful.

    This article will talk about one of these riddles, and to be more precise, about the magic square. We will look in detail at how to solve the magic square. 3rd grade of the general education program, of course, this goes through, but perhaps not everyone understood or does not remember at all.

    What is this mystery?

    Or, as it is also called, magic, is a table in which the number of columns and rows is the same, and they are all filled with different numbers. The main task is that these numbers add up vertically, horizontally and diagonally to the same value.

    In addition to the magic square, there is also a semi-magic square. It implies that the sum of numbers is the same only vertically and horizontally. A magic square is “normal” only if one was used to fill it.

    There is also such a thing as a symmetrical magic square - this is when the value of the sum of two digits is equal, while they are located symmetrically with respect to the center.

    It is also important to know that squares can be of any size other than 2 by 2. A 1 by 1 square is also considered magical, since all conditions are met, although it consists of one single number.

    So, we have familiarized ourselves with the definition, now let’s talk about how to solve a magic square. The 3rd grade school curriculum is unlikely to explain everything in as much detail as this article.

    What are the solutions?

    Those people who know how to solve a magic square (grade 3 knows for sure) will immediately say that there are only three solutions, and each of them is suitable for different squares, but still one cannot ignore the fourth solution, namely “at random” . After all, to some extent there is a possibility that an ignorant person will still be able to solve this problem. But we will throw this method into the long box and move directly to formulas and methods.

    First way. When the square is odd

    This method is only suitable for solving a square that has an odd number of cells, for example, 3 by 3 or 5 by 5.

    So, in any case, it is initially necessary to find the magic constant. This is the number that is obtained by summing the numbers diagonally, vertically and horizontally. It is calculated using the formula:

    In this example, we will consider a three by three square, so the formula will look like this (n is the number of columns):

    So, we have a square in front of us. The first thing to do is to enter the number one in the center of the first line from the top. All subsequent numbers must be placed one square to the right diagonally.

    But here the question immediately arises: how to solve the magic square? 3rd grade is unlikely to use this method, and most will have a problem, how to do it this way if this cell does not exist? To do everything correctly, you need to turn on your imagination and draw a similar magic square on top and it will turn out that the number 2 will be in it in the lower right cell. This means that in our square we enter the two in the same place. This means that we need to enter the numbers so that they add up to 15.

    Subsequent numbers are entered in exactly the same way. That is, 3 will be in the center of the first column. But it will not be possible to enter 4 using this principle, since there is already a unit in its place. In this case, place the number 4 under 3 and continue. The 5 is in the center of the square, the 6 is in the top right corner, the 7 is below the 6, the 8 is in the top left, and the 9 is in the center of the bottom line.

    You now know how to solve the magic square. I passed Demidov's 3rd grade, but this author had slightly simpler tasks, however, knowing this method, you will be able to solve any similar problem. But this is if the number of columns is odd. But what should we do if, for example, we have a 4 by 4 square? More on this later in the text.

    Second way. For a double parity square

    A double parity square is one whose number of columns can be divided by both 2 and 4. Now we will consider a 4 by 4 square.

    So, how to solve a magic square (3rd grade, Demidov, Kozlov, Tonkikh - a task in a mathematics textbook) when the number of its columns is 4? And it's very simple. Easier than the example before.

    First of all, we find the magic constant using the same formula that was given last time. In this example, the number is 34. Now you need to arrange the numbers so that the sum vertically, horizontally and diagonally is the same.

    First of all, you need to paint over some cells, you can do this with a pencil or in your imagination. We paint over all the corners, that is, the upper left cell and the upper right, the lower left and the lower right. If the square were 8 by 8, then you need to paint over not one square in the corner, but four, measuring 2 by 2.

    Now you need to paint the center of this square, so that its corners touch the corners of the already shaded cells. In this example, we will get a 2 by 2 square in the center.

    Let's start filling it out. We will fill in from left to right, in the order in which the cells are located, only we will enter the value in the shaded cells. It turns out that we enter 1 in the upper left corner, 4 in the right corner. Then we fill in the central one with 6, 7 and then 10, 11. The lower left 13 and 16 in the right. We think the order of filling is clear.

    We fill out the remaining cells in the same way, only in descending order. That is, since the last number entered was 16, then at the top of the square we write 15. Next is 14. Then 12, 9 and so on, as shown in the picture.

    Now you know the second way to solve the magic square. Year 3 will agree that the double parity square is much easier to solve than the others. Well, we move on to the last method.

    Third way. For a square of single parity

    A square of single parity is a square whose number of columns can be divided by two, but not by four. In this case it is a 6 by 6 square.

    So, let's calculate the magic constant. It is equal to 111.

    Now we need to visually divide our square into four different 3 by 3 squares. You will get four small squares measuring 3 by 3 in one large 6 by 6. Let's call the upper left one A, the lower right one - B, the upper right one - C and the lower left one - D.

    Now you need to solve each small square using the very first method given in this article. It turns out that in square A there will be numbers from 1 to 9, in B - from 10 to 18, in C - from 19 to 27 and D - from 28 to 36.

    Once you have solved all four squares, work will begin on A and D. It is necessary to highlight three cells in square A visually or using a pencil, namely: the upper left, central and lower left. It turns out that the highlighted numbers are 8, 5 and 4. In the same way, you need to select square D (35, 33, 31). All that remains to be done is to swap the selected numbers from square D to A.

    Now you know the last way to solve the magic square. Grade 3 doesn't like the square of single parity the most. And this is not surprising, of all those presented it is the most complex.

    Conclusion

    After reading this article, you learned how to solve a magic square. Grade 3 (Moro is the author of the textbook) offers similar problems with only a few filled cells. There is no point in considering his examples, since knowing all three methods, you can easily solve all the proposed problems.

    Few people loved mathematics in childhood, but mathematical puzzles on the Internet always become hits, because solving them usually does not require in-depth knowledge, but requires ingenuity and innovative thinking. We invite you to test yourself on the five main logic puzzles of this year.

    Task No. 1

    Kumar Ankit invited Facebook users to count how many triangles are shown in his drawing. Almost none of the users coped with the seemingly simple task of counting the figures. Many are close to the correct answer, but most lack a little care.

    Answer:

    There are 24 triangles inside the large triangle, it’s not difficult to count, but most users did not pay attention to another triangle hidden in the author’s signature. Thus, there are 25 triangles in total in the picture.

    Task No. 2

    An unusual problem with two solutions was offered to Internet users by the creators of the site gotumble.com. According to them, one solution to the puzzle is simpler, about 10% of people are able to find it, but only one person in a thousand can reach the second solution. Try it yourself.

    Answer:

    First solution consists of adding to each subsequent example the result of the previous one. So, adding 5 to the sum of 2 and 5, we get 12. Adding 12 to the sum of 3 and 6, we get 21. And so on. In this case, the correct answer to the puzzle will be 40.

    And here second solution, which only one person in a thousand understands, consists of adding the first digit of the example with the product of two digits:

    2 + 2*5 = 12, 3 + 3*6 = 21, 8 + 8*11 = 96.

    Task No. 3

    We have a triangle consisting of four parts, but if we rearrange the parts, it appears as an empty square. How can this be?

    Answer:

    This is not an optical illusion at all. It's all about different angles of inclination of the hypotenuse of the red and turquoise triangle - hence the different sizes of the figures.

    Task No. 4

    Guardian columnist Alex Bellos invited readers to solve a problem that is part of the final math exam in some countries. According to statistics, only one person out of 10 solves it.

    We have a cylinder around which a thread is wound symmetrically four times. The circumference of the cylinder is 4 cm, and its length is 12 cm. You need to find the length of the thread.

    Answer:

    The task seems too complicated to most schoolchildren, but in fact, you just need to understand that by turning the cylinder onto a plane, we get an ordinary rectangle with sides of 4 and 12 cm, which can be divided into four smaller rectangles with sides of 4 and 3 cm. Thread in this case, it will be the hypotenuse of a right triangle and its length in each of the four figures can be calculated using a simple school formula, it is equal to 5 cm. As a result, the total length of the thread is 20 centimeters.

    Problem #5

    And finally, the latest mathematical puzzle that blew up social networks. According to the author of the post, it depicts a riddle that is given as a bonus question to students in Singapore. The compilers of the riddle suggest studying the number sequence and filling in the four empty windows with the missing numbers.

    Answer:

    Netizens puzzled over this problem for a long time, but even serious mathematicians could not cope with it. And the Ministry of Education of Singapore disowned this task, saying that it had nothing to do with it. So most likely the puzzle was just someone's cruel joke.