Biographies Characteristics Analysis

How to solve the black magic square. Magic square: how it works

In ancient times, great scientists considered numbers to be the basis of the essence of the world. The magic square, the secret of which is that the sum of the numbers in the resulting square in each horizontal, in each vertical, and in each diagonal is the same, carries this essence.

But a complete description of magic squares does not yet exist.

The magic square of Pythagoras, "attracting" the energy of wealth, was compiled by the founder
The great scientist, who founded the religious and philosophical doctrine and proclaimed quantitative relations the basis of things, believed that a person's essence lies in the date of birth of a person.

Knowing how the magic square works, one can not only find out the character traits of a person, his state of health, his intellectual and creative abilities, but also draw up a program for his improvement and development. The numbers, which are written in a square in a special way, attract not only wealth, but also the necessary energy flows for a person. For example, Paracelsus depicted his square as a talisman of health. The numbers form three rows, that is, there are nine numbers in a square. To determine your numerological code, you need to calculate these nine numbers.

How does the magic square work?

The first horizontal row of the square is formed by numbers: the day, month and year of a person's birth. For example, the date of birth of a person corresponds to 08/09/1971. Then the first number in the square will be 9, which is written in the first cell. The second number is the number of the month, i.e. 8.

At the same time, it is worth paying attention if the month of a person’s birth corresponds to December, that is, the number 12, then it, therefore, must be converted by addition to a simple number 3. The third digit corresponds to the number of the year. To do this, it is necessary to decompose 1971 into composite numbers and calculate their total amount equal to 18 and further simplify 1 + 8 = 9. We fill in the upper horizontal field of the square with the resulting numbers: 9,8,9.

In the second row of the square, numbers are written corresponding to the name, patronymic and surname of a person according to numerology. Each letter has its own numerical value. Numbers can be obtained from the correspondence table of letters and numbers by numerology. Next, you need to sum the numbers of the first name, patronymic and last name and bring them to simple values.

The second row of the square is filled with the resulting numbers. The fourth number corresponds to the number of the name, the fifth - to the patronymic, and the sixth - to the surname. Now we have the second line of the energy square.

A further principle of how the magic square works is based on astrology.

The seventh digit corresponds to the number of the person's zodiac sign. Aries is the first sign under the number 1, and then in order to the sign of Pisces - 12. When filling out the third row of the square, two-digit numbers should not be reduced to primes, they all have their own meaning.

The eighth digit is the number of the sign according to That is, in our version, 1971 is the year of the Boar.

The ninth digit represents the numerological code of a person's desire. For example, a person strives to have excellent health, therefore, you need to find the numbers corresponding to the letters in this word. The result is 49, which is then simplified by addition to 4. The numbers from 10 to 12, as in the case of the human zodiac sign, do not need to be reduced. Now, knowing how the magic square works, you can easily compose it and carry it with you like a talisman or decorate it like a picture and hang it at home.

There are several different classifications of magic squares.

fifth order, designed to somehow systematize them. In the book

Martin Gardner [GM90, pp. 244-345] describes one of these methods -

according to the number in the central square. The method is curious, but nothing more.

How many squares of the sixth order exist is still unknown, but there are approximately 1.77 x 1019. The number is huge, so there is no hope of counting them using exhaustive search, but no one could come up with a formula for calculating magic squares.

How to make a magic square?

There are many ways to construct magic squares. The easiest way to make magic squares odd order. We will use the method proposed by the French scientist of the 17th century A. de la Louber (De La Loubère). It is based on five rules, the operation of which we will consider on the simplest magic square 3 x 3 cells.

Rule 1. Put 1 in the middle column of the first row (Fig. 5.7).

Rice. 5.7. First number

Rule 2. Put the next number, if possible, in the cell adjacent to the current one diagonally to the right and above (Fig. 5.8).

Rice. 5.8. Trying to put the second number

Rule 3. If the new cell goes beyond the square above, then write the number in the very bottom line and in the next column (Fig. 5.9).

Rice. 5.9. We put the second number

Rule 4. If the cell goes beyond the square on the right, then write the number in the very first column and in the previous line (Fig. 5.10).

Rice. 5.10. We put the third number

Rule 5. If the cell is already occupied, then write down the next number under the current cell (Fig. 5.11).

Rice. 5.11. We put the fourth number

Rice. 5.12. We put the fifth and sixth number

Follow Rules 3, 4, 5 again until you complete the entire square (Fig.

Isn't it true, the rules are very simple and clear, but it's still quite tedious to arrange even 9 numbers. However, knowing the algorithm for constructing magic squares, we can easily entrust the computer with all the routine work, leaving ourselves only creative work, that is, writing a program.

Rice. 5.13. Fill in the square with the following numbers

Project Magic squares (Magic)

Field set for the program magic squares quite obvious:

// PROGRAM FOR GENERATION

// ODD MAGIC SQUARE

// BY THE DE LA LOUBERT METHOD

public partial class Form1 : Form

//Max. square dimensions: const int MAX_SIZE = 27; //var

intn=0; // square order int [,] mq; // magic square

int number=0; // current number to square

intcol=0; // current column int row=0; // current line

The de la Louber method is suitable for making odd squares of any size, so we can let the user choose the order of the square, while reasonably limiting the freedom of choice to 27 cells.

After the user presses the coveted button btnGen Generate! , the btnGen_Click method creates an array to store numbers and passes into the generate method:

// PRESS THE "GENERATE" BUTTON

private void btnGen_Click(object sender, EventArgs e)

//order of the square:

n = (int)udNum.Value;

//create an array:

mq = new int ;

//generate magic square: generate();

lstRes.TopIndex = lstRes.Items.Count-27;

Here we begin to act according to the rules of de la Louber and write the first number - one - in the middle cell of the first row of the square (or array, if you like):

//Generate the magic square void generate()(

//first number: number=1;

//column for the first number - middle: col = n / 2 + 1;

//line for the first number - the first one: row=1;

//square it: mq= number;

Now we sequentially add the rest of the cells in cells - from two to n * n:

// move on to the next number:

We remember, just in case, the coordinates of the actual cell

int tc=col; int tr = row;

and move to the next cell diagonally:

We check the implementation of the third rule:

if (row< 1) row= n;

And then the fourth:

if (col > n) ( col=1;

goto rule3;

And fifth:

if (mq != 0) ( col=tc;

row=tr+1; goto rule3;

How do we know that there is already a number in the cell of the square? - Very simple: we prudently wrote zeros in all cells, and the numbers in the finished square are greater than zero. So, by the value of the array element, we will immediately determine whether the cell is empty or already with a number! Please note that here we need those cell coordinates that we remembered before searching for the cell for the next number.

Sooner or later, we will find a suitable cell for the number and write it to the corresponding array cell:

//square it: mq = number;

Try another way to organize the check of the admissibility of the transition to the

wow cell!

If this number was the last, then the program has fulfilled its obligations, otherwise it voluntarily proceeds to provide the cell with the following number:

//if not all numbers are set, then if (number< n*n)

//go to the next number: goto nextNumber;

And now the square is ready! We calculate its magic sum and print it on the screen:

) //generate()

Printing the elements of an array is very simple, but it is important to take into account the alignment of numbers of different "lengths", because a square can contain one-, two-, and three-digit numbers:

//Print the magic square void writeMQ()

lstRes.ForeColor = Color .Black;

string s = "Magic sum = " + (n*n*n+n)/2; lstRes.Items.Add(s);

lstRes.Items.Add("" );

// print the magic square: for (int i= 1; i<= n; ++i){

s="" ;

for (int j= 1; j<= n; ++j){

if (n*n > 10 && mq< 10) s += " " ; if (n*n >100 && mq< 100) s += " " ; s= s + mq + " " ;

lstRes.Items.Add(s);

lstRes.Items.Add("" ); )//writeMQ()

We launch the program - the squares are obtained quickly and feast for the eyes (Fig.

Rice. 5.14. Quite a square!

In the book by S. Goodman, S. Hidetniemi Introduction to the development and analysis of algorithms

mov , on pages 297-299 we will find the same algorithm, but in a "reduced" presentation. It is not as "transparent" as our version, but it works correctly.

Add a button btnGen2 Generate 2! and write the algorithm in the language

C-sharp to the btnGen2_Click method:

//Algorithm ODDMS

private void btnGen2_Click(object sender, EventArgs e)

//order of the square: n = (int )udNum.Value;

//create an array:

mq = new int ;

//generate magic square: int row = 1;

int col = (n+1)/2;

for (int i = 1; i<= n * n; ++i)

mq = i; if (i % n == 0)

if (row == 1) row = n;

if (col == n) col = 1;

//square completed: writeMQ();

lstRes.TopIndex = lstRes.Items.Count - 27;

We click the button and make sure that “our” squares are generated (Fig.

Rice. 5.15. Old algorithm in a new guise

"Magnet" for wealth, health and other things...

Pythagoras made a magic square capable of "attracting" the energy of wealth.

By the way, Henry Ford himself used the Pythagorean square.
He traced it on a dollar bill and always carried it in a secret compartment of his wallet as a charm.
As you know, Ford did not complain about poverty. At the age of 83, Henry handed over the reins of the corporation and a considerable fortune of $ 1 billion (adjusted for inflation - more than 36 billion at current prices) to his grandchildren.

*** *** *** *** ***

Numbers inscribed in a square in a special way can not only attract wealth.

For example, the great physician Paracelsus made his square - the "talisman of health."

In general, if you correctly build a magic square, you can bring into life those energy flows that you need.

How to make a personal talismanmagic square of Pythagoras I hope you can write numbers and count to ten?

Then go ahead. We draw an energy square that can become your personal talisman.

It has three columns and three rows. There are only nine digits that make up your individual numerological code.

How to calculate this code?

Put in the first row three numbers:

* number of your birthday,
* month of birth
* the year of birth.

For example, you were born on May 25, 1971. Then your first number is the number of the day: 25. This is a complex number, according to the laws of numerology, it must be reduced to a simple one by adding the numbers 2 and 5. It turns out - 7: we will put the seven in the first cell of the square.

The second is the number of the month: 5, because May is the fifth month. Please note: if a person was born in December, that is, in the month number 12, we would have to reduce the number to a simple one: 1 + 2 = 3.

The third is the number of the year. Here everyone will have to reduce to simple. So: 1971 (year of birth) is decomposed into composite numbers and we calculate their sum. 1+9+7+1 = 18, 1+8 =9.

We enter the numbers in the first row: 7, 5, 9.

In the second row we put the numbers:

* fourth - your name,
* fifth - patronymic,
* the sixth - surnames.

We determine them according to the table of alphanumeric correspondences.


Guided by it, you add up the digital values ​​​​of each letter of your name, if necessary, bring the sum to a prime number.

Similarly, we act with patronymic and surname.

For example, Moles= 3+9+7+2+7+3=31=3+1=4

We now have three digits for the second line of the energy square.

Third row

To fill in the third row, to find the seventh, eighth and ninth digits, you will have to turn to astrology.

Seventh digit is the number of your zodiac sign.

Everything is simple here. Aries is the first sign, it corresponds to the number 1. Pisces is the twelfth sign, they correspond to the number 12.

Attention: in this case, two-digit numbers should not be reduced to simple ones, the numbers 10, 11 and 12 have their own meaning!

Eighth digit- the number of your sign according to the Eastern calendar. It is easy to find it in the table below:

That is, if you were born in 1974, your sign number is 3 (Tiger), and if in 1982 - 11 (Dog).

Ninth digit- the numerological code of your desire.

For example, you gain energy for the sake of health. So the key word is "health". We add the letters again according to the first table:

Z - 9, D - 5, O - 7, P - 9, O - 7, B - 3, b - 3, E - 6 \u003d 49, that is, 4 + 9 \u003d 13. Since we again got a complex number, we continue to reduce: 1 + 3 = 4

Keep in mind: if you got the numbers 10, 11 and 12, then in this case they should not be reduced.

Well, if you do not have enough money, then you can calculate the meaning of the words "wealth", "money" or specifically "dollar", "euro".

So, the last ninth digit in your magic square will be a number - the numerological value of your keyword or, in other words, the code of desire.

Sing your "square" meditation

And now let's arrange nine numbers in three rows of three numbers in our magic square.

The drawn square can be framed and hung at home or in the office.

And you can put it in your daddy and put it away from prying eyes. Listen to your inner voice, it tells you what is right for you.

But that's not all. Learn the numbers of your personal numerological code in the order they are in the cells.

What for? This is your personal mantra, your direct line to God, if you will. It tunes you to the desired flow from a huge variety of forces in the Universe, and on the other hand, they hear you and respond to your vibrations.

Therefore, you need to learn your mantra by heart. And to meditate.

While mentally repeating your numerological code, sit in a comfortable chair or lie down on the sofa. Relax. Hold your hands palms up, as if receiving energy. After a while, you will feel a tingling sensation in your fingers, a vibration, maybe warmth or, conversely, a chill in your palms.

Excellent: the energy has gone! Meditation lasts until you want to stop it, until there is a need to get up or ... until you doze off.

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

  • Calculate the magic constant. This can be done using a simple mathematical formula / 2, where n is the number of rows or columns squared. For example, in a 6x6 square, 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 of 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). Divide n by 2 to find the size of each quadrant.

    • Thus, in a 6x6 square, the size of each quadrant is 3x3.
  • In quadrant A, write the fourth part of all the numbers; in quadrant B write the next fourth of all the numbers; in quadrant C, write the next fourth of all the numbers; in quadrant D, write the final fourth 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 the numbers in each quadrant in the same way as you built an odd square. In our example, start filling quadrant A with numbers from 1, and quadrants C, B, D - from 10, 19, 28, respectively.

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

    • Starting with the first cell in the top row of Quadrant A, select a number of cells equal to the median of the 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 selected only one cell in a 6x6 square, the intermediate square will consist of one cell. Let's call this intermediate square as A-1.
    • In the 10x10 square, you have selected two cells of the top row, so you need to select the first two cells of the second row to form an intermediate 2x2 square consisting of four cells.
    • In the next line, skip the number in the first cell, and then select as many numbers as you have selected in the intermediate square A-1. The resulting intermediate square will be called A-2.
    • Obtaining intermediate square A-3 is similar to obtaining intermediate square A-1.
    • Intermediate squares A-1, A-2, A-3 form a selected area A.
    • Repeat the above process in the D quadrant: create intermediate squares that form the D selection.
  • The secret of the game "Magic Square"

    I'm sure you've heard the phrase "magic square" somewhere. We know several representatives of this "tribe". The most common and often found on the Internet is the so-called Magic Square game. Its essence lies in the fact that your attention is invited to a table (this is the “magic square”), which is able to “guess thoughts”. Naturally, like any game, it has certain rules. It is necessary to think of any two-digit number, and then subtract from it the sum consisting of the digits of this number. Find the resulting value in the table along with the symbol corresponding to it. And just this symbol guesses the square. The game is funny and, at first glance, really magical, because no matter what number you think of initially, the square always guesses the symbol. How does it work? How does the "magic square" work? In fact, the answer lies on the surface. If you check the square several times in a row, you will notice that the same symbol falls out all the time. A closer look at the table shows that this symbol is located horizontally and it corresponds to numbers divisible by 9 without a remainder. However, only they are obtained in your answer, no matter what two-digit number you choose. We can say that we have exposed the "magic square". The secret lies not so much in him as in the conditions of the game. The fact is that there is such an indisputable truth that says: “If you subtract the sum of its digits from any two-digit number, you get a number that is divisible by 9 without a remainder.” So we figured out how the "magic square" works. Not an ounce of mysticism! Although, in principle, everything related to numbers is based on calculations and patterns, and not on magic.

    The secret of the magic square:

    7 t41 k86 h21 n33 w1 p35 r61 p12 w90 a
    15 h23 z57 v55 q71 d66 h78 g14 q81 a 10 t
    88 d59 j74 n69 b68 m38 i22 m72 a 3 v58 m
    62 l77 m40 c98 u20 s94 m63 a 87 t99 m37 x
    92 s96 g51 f73 e46 i54 a 53 s44 h43 k2 d
    34 o31 e91 t19 i45 a 50 k85 v28 s38 l75 v
    79 h8 c11 s36 a 16 f24 z4 q67 m6 f48 o
    17 p65 w27 a 42 p89 e39 s95 x32 f25 d26 h
    29 c18 a 82 k60 o93 r83 y52 k56 p53 i30 y
    9 a 80 q47 d84 l5 g13 x70 d49 g76 c64 e

    Albrecht Dürer's magic square

    Sometimes digital patterns take on such incredible proportions that it seems that witchcraft has not been done here. So, for example, another “magic square” is known - Albrecht Dürer. In mathematics, it is understood as a square table with the same number of rows and columns, filled with natural numbers. Moreover, the sum of these numbers horizontally, vertically or diagonally should equal the same result. The magic square came to us from China, today we all know its brightest representative - the Sudoku crossword puzzle. In Europe, it was Dürer who was the first to depict a “magic” figure in his engraving “Melancholia”. What is the uniqueness of this "magic square"? At its base, it has a combination of numbers 15 and 14, which corresponds to the year of publication of the engraving. And the sum of the numbers is made up not only of the rows diagonally, vertically and horizontally, but also of the numbers located at the corners of the square, in the central small square and in each of the four-cell squares on its sides. These figures do not predict fate and do not guess thoughts, they are unique precisely in their patterns.

    Square of Pythagoras

    If we turn to fortune-telling, then there is also a representative here - the “magic square” of Pythagoras. We all know this name from geometry lessons. But only in our time this person began to be called a mathematician and philosopher. In ancient times, he was known as a teacher of wisdom, poems were composed and odes were sung about him, he was worshiped, considered a seer. Pythagoras founded a new science - numerology, in former times it was perceived as a religion.

    He believed that numbers can explain almost every phenomenon, including determining the fate of a person, telling about his character, talents and weaknesses. This could be done using the square of Pythagoras. How does the "magic square" work and what is it? The magic square of Pythagoras is a 3/3 square (rows, columns), in which the numbers from 1 to 9 are entered. The date of birth of a person is taken as the basis for the prediction. It is important that "0" does not appear in the calculations. With the help of simple calculations and formulas, a set of numbers is obtained, which subsequently must be entered into a square. Each number has its own meaning and is responsible for a certain property. So, 4 is “responsible” for health, and 9 is for the mind. Depending on how many times the same number occurs in your square, you can say about the predominance of one or another property. So, for example, the absence of 4 is an indicator of physical weakness and sickness, and 444 is an indicator of good health and cheerfulness. How true the square of Pythagoras is, it is difficult to say, as, indeed, any fortune-telling. But now, knowing how the magic square works, you can at least pass an hour or two pleasantly, calculating the characters of your friends and acquaintances.