# Affine Magic Cubes of Order 4: Concepts and Applications

Authors: Siriyakorn Duangmoon; Praphon Kanokladarom; Suchada Pongprasert; Thitarie Rungratgasame; Natsima Srithaisong
Journal: International Journal of Mathematics and Mathematical Sciences
 (2022)

---

## Abstract

We convert a classical magic cube of order 4, which is an arrangement of1,2,…,64, to a cube of order 4 whose entries belong to F26. By using finite-dimensional vector spaces over the field F2, we introduce the notion of affine magic cubes and study their properties. The obtained results can be applied to describe some features of various types of magic cubes of order 4.


---

## Body

## 1. Introduction

A magic cube of ordern is an arrangement of the numbers 1,2,…,n3 in an n×n×n cube in which the entries in each row, column, pillar, and triagonal sum to the same number. In 1650, Pierre de Fermat found a cube of order 4 which is almost magic but its four triagonals failed to have the same sum. This type of cube is called semi-magic. Joseph Sauveur later in 1710, published a cube of order 5 with all correct triagonal sums, however, it is still not magic because most orthogonal lines sum incorrectly. The first published magic cube we have been able to locate was published in Germany in 1898 by Hermann Schubert [1]. The appearance of magic cubes has subsequently been found by many mathematicians, for example, other well-known magic cubes are found by Hermann Weidemann and John Hendricks.Appearing as a 3-dimensional shape, a magic cube is more complicated to study than a magic square. This leads to a study on magic cubes by transferring them to magic squares first, e.g., Allan Adler and Shuo-Yen Robert Li in [2] demonstrated a method for transforming a magic cube of order m into a magic square of order 2m.In our work, we transform a magic cube of order 4 into a magic square of order 8 and study the relations between magic cubes and linear algebra. Motivated by John Henrich in [3] where he introduced an affine magic square of order 4, we introduce the notion of affine magic cubes of order 4 and study their properties. Moreover, we show that the famous magic cubes by Hermann Schubert, Hermann Weidemann, and John Hendricks are affine. Their different features are also discussed.


## 2. Preliminary

In this section, the definitions of affine subspaces and affine transformations are given. We also introduce the definitions of magic cubes and their special kinds and provide some examples.


### 2.1. Affine Subspaces and Affine Functions

Definition 1 (see [4]).
LetV be a finite-dimensional vector space over a field F. For a vector v in V and a subspace W of V, the set v+W:=v+w|w∈W is called an affine subspace of V.Definition 2 (see [4]).
LetV be a finite-dimensional vector space over a field F. We say that a function f:V⟶F is an affine function if there are a linear functional g:V⟶F and a constant β∈F such that fx=gx+β for all x∈V. Here, the linear functional g and the constant β with respect to f are unique.
From the above definitions, an affine subspace ofV needs not to be a subspace of V, and an affine function does not need to be a linear functional.Example 1.
LetF be the field F2=0,1 and let V be the vector space F23 over F2, i.e., V=000,001,010,011,100,101,110,111. The set 010,101 is not a subspace of V. However, it is an affine subspace of V because 010,101=010+000,111 is the translation of the subspace 000,111. The constant function fx=1 is not a linear functional but f is an affine function when the corresponding g is the zero linear functional and β=1.Example 2.
LetF be a field and α1,α2,…,αn scalars in F. Let g:Fn⟶F be the function defined by(1)gx1,…,xn=α1x1+α2x2+⋯+αnxn.
Clearly,g is a linear function. For any β≠0, the function fx1,…,xn=α1x1+α2x2+⋯+αnxn+β=gx1,…,xn+β is not a linear functional, but it is an affine function.


### 2.2. Magic Cubes

Definition 3.
Forn∈ℕ, a cube of order n is an n×n×n cube of n3 numbers. In a cube of order n, a row is a set of n numbers on a horizontal line from left to right or right to left. A column is a set of n numbers on a line from back to front or front to back. A pillar is a set of n numbers on a vertical line from top to bottom or bottom to top. A face diagonal is a diagonal on one of the faces of a cube. The main triagonal is a set of n numbers on a line from a corner of a cube, though the center of the cube, toward the opposite corner. A bent triagonal is a set of n numbers on a line from a corner of a cube, through the center of the cube, and then toward the other corners different from the opposite corner. A broken triagonal is a set of numbers that follow a line parallel to the main triagonal of a cube and continues on the corresponding point of an opposite face whenever it reaches the face of the cube.
Note that a broken triagonal may consist of 2 or 3 segments. Forn≥2, a cube of the order n has n2 rows, n2 columns, n2 pillars, and 4 main triagonals.Definition 4.
Amagic cube of ordern is an n×n×n cube of n3 numbers such that the sums of the numbers on each row, each column, each pillar, and each of the main triagonals are equal to the same number called a magic sum.
In this paper, all entries in a cube are thought of as natural numbers1,2,…,n3 where each number is used only once. Then, the magic sum of a magic cube of order n becomes nn3+1/2.Example 3.
In Figure1, there are 4 rows 1,2,3,4,5,6,7,8, 4 columns 1,5,2,6,3,7,4,8, 4 pillars 1,3,2,4,5,7,6,8, and 4 main triagonals 1,8,2,7,3,6,4,5.Figure 1
An example of cubes of order 2 but not magic.Example 4.
From Figure2, this cube is a magic cube of order 3, and there are 9 rows, 9 columns, 9 pillars, and 4 main triagonals. The sum of the numbers in any row, column, and pillar is 42 (for example, row: 2+13+27, column: 2+22+18, and pillar: 2+16+24). The sum along each of the main triagonals is also 42 2+14+26,1+14+27,18+14+10,24+14+4. However, the sum along every face diagonal is not necessary to be the same as the magic sum (for example, 18+7+26≠42). Examples of bent triagonals are 2,14,27,2,14,18,2,14,4,2,14,24,2,14,1,2,14,10, and 1,14,26. The sum along each bent triagonal is not required to be the same as the magic sum.
The above example shows that the sum of entries on some lines of a magic cube needs not be the same as the magic sum, for example, on bent triagonals or broken triagonals. This leads to a study of specific types of magic cubes. We shall give definitions of the types discussed in this work.Figure 2
An example of magic cubes of order 3.Definition 5.
Abent triagonal magic cube is a magic cube such that the sum of all entries in each bent triagonal equals the magic sum. A pantriagonal magic cube is a magic cube such that the sum of all entries in each broken triagonal equals the magic sum.Example 5.
It is clear that the cube of order 3 in example4 is not pantriagonal. In fact, the smallest pantriagonal magic cube possible is of order 4.Definition 6.
Asemi-pantriagonal magic cube of order n is a magic cube of order n such that the sum of all entries in each 2-segment broken triagonals which each segment contains n/2 cells when n is even and n−1/2 cells (the center cell is added) or n+1/2 cells (the center cell is subtracted) when n is odd equals the magic sum.Example 6.
From Figure2, the sum of all entries in each 2-segment broken triagonals in which each segment contains 3+1/2=2 cells when the center cell is subtracted equals the magic sum. In fact, 13+25+3+15−14=11+21+7+17−14=20+25+3+8−14=22+7+21+6−14=42. Clearly, the sum of all entries in each 2-segment broken triagonals which each segment contains 3−1/2=1 cell when the center cell is added also equals the magic sum because they are main triagonals in this case.
Clearly, all pantriagonal magic cubes are semi-pantriagonal. In a cube of order 4, there are 12 broken triagonals that consist of 2-segments where each segment contains 2 cells.Definition 7.
Anassociated magic cube of order n is a magic cube of order n such that every pair on the opposite sides of the center of the cube sums to the same number.Example 7.
The cube of order 3 in example4 is associated because 2+26=22+6=18+10=20+8=4+24=11+17=27+1=13+15=9+19=16+12=3+35=23+5=7+21=28.Definition 8.
Acompact magic cube of order n is a magic cube of order n such that every 1×2×2, 2×1×2 or 2×2×1 block, parallel to the side of the cube, sums to the magic sum.Example 8.
The cube of or order 3 in example4 is not compact because 18+20+23+7=68≠42.


## 2.1. Affine Subspaces and Affine Functions

Definition 1 (see [4]).
LetV be a finite-dimensional vector space over a field F. For a vector v in V and a subspace W of V, the set v+W:=v+w|w∈W is called an affine subspace of V.Definition 2 (see [4]).
LetV be a finite-dimensional vector space over a field F. We say that a function f:V⟶F is an affine function if there are a linear functional g:V⟶F and a constant β∈F such that fx=gx+β for all x∈V. Here, the linear functional g and the constant β with respect to f are unique.
From the above definitions, an affine subspace ofV needs not to be a subspace of V, and an affine function does not need to be a linear functional.Example 1.
LetF be the field F2=0,1 and let V be the vector space F23 over F2, i.e., V=000,001,010,011,100,101,110,111. The set 010,101 is not a subspace of V. However, it is an affine subspace of V because 010,101=010+000,111 is the translation of the subspace 000,111. The constant function fx=1 is not a linear functional but f is an affine function when the corresponding g is the zero linear functional and β=1.Example 2.
LetF be a field and α1,α2,…,αn scalars in F. Let g:Fn⟶F be the function defined by(1)gx1,…,xn=α1x1+α2x2+⋯+αnxn.
Clearly,g is a linear function. For any β≠0, the function fx1,…,xn=α1x1+α2x2+⋯+αnxn+β=gx1,…,xn+β is not a linear functional, but it is an affine function.


## 2.2. Magic Cubes

Definition 3.
Forn∈ℕ, a cube of order n is an n×n×n cube of n3 numbers. In a cube of order n, a row is a set of n numbers on a horizontal line from left to right or right to left. A column is a set of n numbers on a line from back to front or front to back. A pillar is a set of n numbers on a vertical line from top to bottom or bottom to top. A face diagonal is a diagonal on one of the faces of a cube. The main triagonal is a set of n numbers on a line from a corner of a cube, though the center of the cube, toward the opposite corner. A bent triagonal is a set of n numbers on a line from a corner of a cube, through the center of the cube, and then toward the other corners different from the opposite corner. A broken triagonal is a set of numbers that follow a line parallel to the main triagonal of a cube and continues on the corresponding point of an opposite face whenever it reaches the face of the cube.
Note that a broken triagonal may consist of 2 or 3 segments. Forn≥2, a cube of the order n has n2 rows, n2 columns, n2 pillars, and 4 main triagonals.Definition 4.
Amagic cube of ordern is an n×n×n cube of n3 numbers such that the sums of the numbers on each row, each column, each pillar, and each of the main triagonals are equal to the same number called a magic sum.
In this paper, all entries in a cube are thought of as natural numbers1,2,…,n3 where each number is used only once. Then, the magic sum of a magic cube of order n becomes nn3+1/2.Example 3.
In Figure1, there are 4 rows 1,2,3,4,5,6,7,8, 4 columns 1,5,2,6,3,7,4,8, 4 pillars 1,3,2,4,5,7,6,8, and 4 main triagonals 1,8,2,7,3,6,4,5.Figure 1
An example of cubes of order 2 but not magic.Example 4.
From Figure2, this cube is a magic cube of order 3, and there are 9 rows, 9 columns, 9 pillars, and 4 main triagonals. The sum of the numbers in any row, column, and pillar is 42 (for example, row: 2+13+27, column: 2+22+18, and pillar: 2+16+24). The sum along each of the main triagonals is also 42 2+14+26,1+14+27,18+14+10,24+14+4. However, the sum along every face diagonal is not necessary to be the same as the magic sum (for example, 18+7+26≠42). Examples of bent triagonals are 2,14,27,2,14,18,2,14,4,2,14,24,2,14,1,2,14,10, and 1,14,26. The sum along each bent triagonal is not required to be the same as the magic sum.
The above example shows that the sum of entries on some lines of a magic cube needs not be the same as the magic sum, for example, on bent triagonals or broken triagonals. This leads to a study of specific types of magic cubes. We shall give definitions of the types discussed in this work.Figure 2
An example of magic cubes of order 3.Definition 5.
Abent triagonal magic cube is a magic cube such that the sum of all entries in each bent triagonal equals the magic sum. A pantriagonal magic cube is a magic cube such that the sum of all entries in each broken triagonal equals the magic sum.Example 5.
It is clear that the cube of order 3 in example4 is not pantriagonal. In fact, the smallest pantriagonal magic cube possible is of order 4.Definition 6.
Asemi-pantriagonal magic cube of order n is a magic cube of order n such that the sum of all entries in each 2-segment broken triagonals which each segment contains n/2 cells when n is even and n−1/2 cells (the center cell is added) or n+1/2 cells (the center cell is subtracted) when n is odd equals the magic sum.Example 6.
From Figure2, the sum of all entries in each 2-segment broken triagonals in which each segment contains 3+1/2=2 cells when the center cell is subtracted equals the magic sum. In fact, 13+25+3+15−14=11+21+7+17−14=20+25+3+8−14=22+7+21+6−14=42. Clearly, the sum of all entries in each 2-segment broken triagonals which each segment contains 3−1/2=1 cell when the center cell is added also equals the magic sum because they are main triagonals in this case.
Clearly, all pantriagonal magic cubes are semi-pantriagonal. In a cube of order 4, there are 12 broken triagonals that consist of 2-segments where each segment contains 2 cells.Definition 7.
Anassociated magic cube of order n is a magic cube of order n such that every pair on the opposite sides of the center of the cube sums to the same number.Example 7.
The cube of order 3 in example4 is associated because 2+26=22+6=18+10=20+8=4+24=11+17=27+1=13+15=9+19=16+12=3+35=23+5=7+21=28.Definition 8.
Acompact magic cube of order n is a magic cube of order n such that every 1×2×2, 2×1×2 or 2×2×1 block, parallel to the side of the cube, sums to the magic sum.Example 8.
The cube of or order 3 in example4 is not compact because 18+20+23+7=68≠42.


## 3. Magic Cubes of Order 4

We first consider a cube of order 4 whose entries belong toF26. The points on each row (left to right), each column (back to front), and each horizontal plane (top to bottom), starting with 0 by using base-2 notation, are placed accordingly (see Figure 3). In [2], Alder and Li showed that one can transform a magic cube of order m into a magic square of order 2m by taking the rows of the cube one at a time and using them to fill up the square. Figure 4 is the resulting square of order 8 converted from the cube of order 4 when each pair of adjacent rows (no repeated row used) of the cube of Figure 3 is put into one row of the square.Figure 3
Cube of order 4 in base 2.Figure 4
Square of order 8.


## 4. Affine Magic Cubes of Order 4

On the finite-dimensional vector spaceF26 over F2, there are 26=64 elements in F26 and dimF26=6 with the standard basis e1=100000,e2=010000,e3=001000,e4=000100,e5=000010,e6=000001. From Figure 3, we observe that the first pillar is 000000,100000,010000,110000=spane1,e2, the first column is 000000,001000,000100,001100=spane3,e4, the first row is 000000,000010,000001,000011=spane5,e6, and the main triagonal is 000000,101010,010101,111111=spane1+e3+e5,e2+e4+e6. The following subspaces of F26 and their parallel affine subspaces in Figure 3 are noticed:(1)
spane1,e2 and the affine subspaces parallel to it correspond to each pillar.(2)
spane3,e4 and the affine subspaces parallel to it correspond to each column.(3)
spane5,e6 and the affine subspaces parallel to it correspond to each row.(4)
spane1+e3+e5,e2+e4+e6 and the affine subspaces parallel to it correspond to 4 main triagonals and 12 broken triagonals consisting of 2-segments where each segment containing 2 cells.(5)
spane1+e3+e5,e1+e2+e4+e6,spane1+e3+e5,e2+e3+e4+e6,spane1+e3+e5,e2+e4+e5+e6 and the affine subspaces parallel to them correspond to 2-segment and 3-segment broken triagonals.(6)
spane1+e2+e3+e4+e5+e6 and the affine subspaces parallel to it correspond to each pair on the opposite sides of the center of the cube.(7)
spane2,e4,spane2,e6,spane4,e6,spane2,e3+e4,spane2,e5+e6,spane4,e5+e6,spane1+e2,e3+e4,spane1+e2,e5+e6,spane3+e4,e5+e6 and the affine subspaces parallel to them correspond to 1×2×2, 2×1×2, or 2×2×1 block, parallel to the sides of the cube.(8)
spane1+e3+e6,e2+e4+e6,spane1+e4+e5,e2+e4+e6,spane1+e4+e6,e2+e4+e6,spane2+e3+e5,e2+e4+e6,spane2+e3+e6,e2+e4+e6,spane2+e4+e5,e2+e4+e6 and the affine subspaces parallel to them correspond to all bent triagonals in the cube.Letf1,f2,f3,f4,f5,f6 be the dual basis of e1,e2,e3,e4,e5,e6. Then, fiej is 1 if i=j and 0 otherwise. Moreover, for any linear functional ψ∈F26∗, there exist α1,α2,α3,α4,α5,α6∈F2 such that ψ=α1f1+α2f2+α3f3+α4f4+α5f5+α6f6. In [5], Henrich mentioned that each linear functional on F24 either is constant or takes the values 0 and 1 equally often. The following proposition is an analogous result for nonzero linear functionals on F26:Proposition 1.
Letψbe a linear functional onF26with values inF2andEa subspace ofF26which is not contained in the null space ofψ. Then, on any affine subspace parallel toE, the functionalψtakes the values 0 and 1 equally often.Proof.
LetE˜ be an affine subspace parallel to E. Then, there exists a vector v∈F26 such that E˜=E+v. Let A=u∈E˜|ψu=0 and B=u∈E˜|ψu=1. Since E is not in the null space of ψ, there is y∈E such that ψy=1. Then, y+v∈E˜ and ψy+v=ψy+ψv=1+ψv.Case 1: Ifψv=1, then ψy+v=1+1=0, and hence y+v∈A. Define a map ϕ:A⟶B by(2)ϕa=a+y,for alla∈A. Note that for all a∈A, a+y∈E˜, and ψa+y=ψa+ψy=0+1=1, hence a+y∈B. It is easy to see that ϕ is injective. To show that ϕ is surjective, let b∈B. Then, b+y∈E˜ such that ψb+y=ψb+ψy=1+1=0, and hence b+y∈A. Also, we have ϕb+y=b+y+y=b. Thus, ϕ is surjective and hence bijective.Case 2: Ifψv=0, then ψy+v=1+0=1, and hence y+v∈B. Define a map ϕ:B⟶A by(3)ϕb=b+y,for allb∈B. Note that for all b∈B, b+y∈E˜ and ψb+y=ψb+ψy=1+1=0, hence b+y∈A. It is easy to see that ϕ is injective. To show that ϕ is surjective, let a∈A. Then, a+y∈E˜ such that ψa+y=ψa+ψy=0+1, and hence a+y∈B. Also, we have ϕa+y=a+y+y=a. Thus, ϕ is surjective and hence bijective.
SinceA and B are finite, the number of elements in A must be equal to the number of elements in B from both cases. Therefore, ψ takes the values 0 and 1 equally often on E˜.Definition 9.
LetV1,V2,…,V6 be affine functions on F26 with values in F2. The map W from F26 to ℤ given by(4)Wx=∑j=1626−jVjx+1,
is anaffine cube.
In the discussion of a particular affine cubeW, we shall denote the linear part of Vj by ψj.Definition 10.
LetV1,V2,…,V6 be affine functions on F26 with values in F2, and let W be the affine cube from F26 to ℤ determined by all Vj. Let E be a subspace of F26. Then, E is magic for W if each linear functional ψj of Vj is nonzero on E for all j=1,…,6.Proposition 2.
LetV1,V2,…,V6be affine functions onF26with values inF2, and letEbe a subspace ofF26. Then,Eis magic for the affine cubeWdetermined by allVjif and only ifWhas uniform sums on the affine subspaces parallel toE.Proof.
LetE be a subspace of F26 with dimension d. Suppose E is magic. Let E˜ be an affine subspace parallel to E. By Proposition 1, each linear functional ψj takes the values 0 and 1 each 2d−1 times on E˜. Since each affine function Vj is either ψj+0 or ψj+1, Vj takes the values 0 and 1 each 2d−1 times on E˜. Thus, the sum in ℤ of Vj over E˜ is 2d−1. Hence, we have that the sum of W over E˜ is(5)32⋅2d−1+16⋅2d−1+8⋅2d−1+4⋅2d−1+2⋅2d−1+2d−1+2d.
To prove the converse, supposeE is not magic. Let i be the smallest index such that ψi is zero on E. Since ψi is nonzero on F26, there exists a vector v∈F26 such that ψiv≠0. Set E˜=E+v. If Vi=ψi+0, then the sum in ℤ of Vi over E is 0 but the sum in ℤ of Vi over E˜ is 2d. Then, the sum of 26−iVi over E is 0 and the sum of 26−iVi over E˜ is 26+d−i. This implies the sum of W over E is less than the sum of W over E˜ because the sum in ℤ of Vj is between 0 and 2d and 26−i>26−j for all j>i. On the other hand, we can show that if Vi=ψi+1, the sum of W over E is greater than the sum of W over E˜.Definition 11.
LetV1, V2,…,V6 be affine functions on F26 with values in F2 and let W be the affine cube from F26 to ℤ determined by all Vj. Then, W is nonsingular if ψ1,…,ψ6 are linearly independent.Proposition 3.
LetV1, V2,…,V6, be affine functions onF26with values inF2. If the affine cubeWfromF26toℤdetermined by allVjis nonsingular, then the values ofWxare exactly1,…,64with no omissions or duplications.Proof.
SinceWx∈ℤ,1≤Wx≤ 64 for x∈F26. Since there are 64 elements in F26, it is sufficient to show that Wx has a nonrepeating value. Suppose x and y are elements of F26 such that Wx=Wy. Then Vjx=Vjy for j=1,…,6 and hence ψjx=ψjy for j=1,…,6. However, W is nonsingular implies that ψ1,…,ψ6 are linearly independent, and therefore, span F26∗. Let e1,e2,e3,e4,e5,e6 be the dual basis of ψ1,ψ2,ψ3,ψ4,ψ5,ψ6 for F26. Then, x=α1e1+α2e2+α3e3+α4e4+α5e5+α6e6 and y=β1e1+β2e2+β3e3+β4e4+β5e5+β6e6 for some αj,βj∈F2 for j=1,…,6. Since ψjx=ψjy for j=1,…,6, we have αj=βj for j=1,…,6. It follows that x=y.Analogously to the affine magic squares, we will give the definition of affine magic cubes of order 4. Since we only study the magic cube of order 4, we shall omit “of order 4” for convenience.Definition 12.
Anaffine magic cube is an affine cube that is nonsingular and of which the subspaces spane1,e2,spane3,e4,spane5,e6, and spane1+e3+e5,e2+e4+e6 are magic.
In [3], it is shown that an affine magic square is quasi-pandiagonal or pandiagonal. The following theorem is the analog for affine magic cubes.Theorem 1.
LetAbe an affine magic cube. Then(1)
Ais semi-pantriagonal.(2)
Ais pantriagonal if and only ifspane1+e3+e5,e1+e2+e4+e6,spane1+e3+e5,e2+e3+e4+e6, andspane1+e3+e5,e2+e4+e5+e6are magic.Proof.
LetVj,j=1,…,6, be affine functions on F26 with values in F2 which determine A. Let W be the affine cube from F26 to ℤ determined by Vj,j=1,…,6. Suppose W is an affine magic cube. This implies the subspaces spane1,e2,spane3,e4,spane5,e6, and spane1+e3+e5,e2+e4+e6 are magic. By Proposition 2, W has uniform sums on the affine subspaces parallel to spane1,e2,spane3,e4,spane5,e6, and spane1+e3+e5,e2+e4+e6. Note that the subspace spane1,e2 corresponds to the first pillar of A, and the affine subspaces parallel to it correspond to the other pillars. Likewise, spane3,e4 corresponds to the first column of A, and the affine subspaces parallel to it correspond to the other columns. Moreover, spane5,e6 corresponds to the first row of A, and the affine subspaces parallel to it correspond to the other rows. Finally, spane1+e3+e5,e2+e4+e6 corresponds to the main triagonal of A, and the affine subspaces parallel to it correspond to the 4 main triagonals and 12 broken triagonals consist of 2-segments where each segment containing 2 cells of A. Thus, A is semi-pantriagonal. By Proposition 2, the subspaces spane1+e3+e5,e1+e2+e4+e6,spane1+e3+e5,e2+e3+e4+e6, and spane1+e3+e5,e2+e4+e5+e6 are all magic if and only if W has uniform sums on the affine subspaces parallel to spane1+e3+e5,e1+e2+e4+e6,spane1+e3+e5,e2+e3+e4+e6 and spane1+e3+e5,e2+e4+e5+e6 which correspond to 2-segment and 3-segment broken triagonals, i.e., A is pantriagonal by definition.The following results follow directly from Proposition2 and the definitions of associated, compact, and bent triagonal magic cubes.Theorem 2.
LetAbe an affine magic cube. Then(1)
Ais associated if and only ifspane1+e2+e3+e4+e5+e6is magic.(2)
Ais compact if and only ifspane2,e4,spane2,e6,spane4,e6,spane2,e3+e4,spane2,e5+e6,spane4,e5+e6,spane1+e2,e3+e4,spane1+e2,e5+e6andspane3+e4,e5+e6are magic.(3)
Ais bent triagonal if and only ifspane1+e3+e6,e2+e4+e6,spane1+e4+e5,e2+e4+e6,spane1+e4+e6,e2+e4+e6,spane2+e3+e5,e2+e4+e6,spane2+e3+e6,e2+e4+e6.andspane2+e4+e5,e2+e4+e6are magic.


## 5. Applications

The results we have derived in this work can be applied to study some features of magic cubes. In this section, we will discuss some well-known magic cubes of order 4 by applying our results to these affine magic cubes.


### 5.1. Hermann Schubert’s Magic Cube

The following magic cube of order 4 was published by Hermann Schubert in Germany in 1898 [1]. It is the first published magic cube of order 4 by the now-accepted rules.By subtracting 1 from each number in Figure5 and writing them in base 2, we obtain the magic cube on F26 as in Figure 6. Next, we would like to find affine functions V1,V2,V3,V4,V5, and V6 which define Figure 6. Since 000000 needs to be matched with 000000, the following can be derived:(6)V1000000=0,V2000000=0,V3000000=0,V4000000=0,V5000000=0,V6000000=0.Figure 5
Schubert 1898.Figure 6
Modified Schubert.Hence, the affine functions must be in the following forms:(7)V1=ψ1,V2=ψ2,V3=ψ3,V4=ψ4,V5=ψ5,V6=ψ6,where, ψj is the linear part of Vj for j=1,…,6. Note that in this case Vj is a linear functional for j=1,…,6. To find linear parts ψ1,ψ2,ψ3,ψ4,ψ5, and ψ6, we consider mappings of basis elements e1,e2,e3,e4,e5, and e6 of F26 in Table 1.Table 1
Mappings of basis elements to the Modified Schubert.
BasisImageV1=ψ1V2=ψ2V3=ψ3V4=ψ4V5=ψ5V6=ψ6100000111101111101010000111110111110001000110111110111000100111011111011000010011111011111000001101111101111Thus, the values ofψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 of the basis are as in Table 2.Table 2
Linear parts of each basis element.
Basisψ1ψ2ψ3ψ4ψ5ψ6100000111101010000111110001000110111000100111011000010011111000001101111Hence, the affine functions which determine Figure6 are(8)V1=f1+f2+f3+f4+f6,V2=f1+f2+f3+f4+f5,V3=f1+f2+f4+f5+f6,V4=f1+f2+f3+f5+f6,V5=f2+f3+f4+f5+f6,V6=f1+f3+f4+f5+f6,and the corresponding number isWx=∑j=1626−jVjx+1. Note that W is an affine function, and the linear part ψj of each Vj are as follows:(9)ψ1=f1+f2+f3+f4+f6,ψ2=f1+f2+f3+f4+f5,ψ3=f1+f2+f4+f5+f6,ψ4=f1+f2+f3+f5+f6,ψ5=f2+f3+f4+f5+f6,ψ6=f1+f3+f4+f5+f6.It is easy to see thatψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 are linearly independent. Thus, W is nonsingular. Since each ψj is nonzero on the subspaces spane1,e2,spane3,e4,spane5,e6 and spane1+e3+e5,e2+e4+e6, spane1,e2,spane3,e4,spane5,e6 and spane1+e3+e5,e2+e4+e6 are magic. Therefore, Schubert’s cube is an affine magic cube, and hence semi-pantriagonal. This cube is also associated because spane1+e2+e3+e4+e5+e6 is magic. However, it is not pantriagonal, not compact, and also not bent triagonal because the subspaces spane1+e3+e5,e1+e2+e4+e6,spane2,e3+e4 and spane1+e3+e6,e2+e4+e6 are not magic.


### 5.2. Hermann Weidemann’s Magic Cube

The following magic cube of order 4 by Hermann Weidemann was first published in 1922 [5].To find the affine functionsV1,V2,V3,V4,V5, and V6, which define the Modified Weidemann, obtained by subtracting one from each number in Figure 7 and writing them in base 2, we observe that 000000 needs to map to 011000. Thus,(10)V1000000=0,V2000000=1,V3000000=1,V4000000=0,V5000000=0,V6000000=0.Figure 7
Weidemann 1922.Hence, the affine functions must be in the following forms:(11)V1=ψ1+0,V2=ψ2+1,V3=ψ3+1,V4=ψ4+0,V5=ψ5+0,V6=ψ6+0,where, ψj is the linear part of Vj, for j=1,…,6. Note that V2 and V3 are not linear in this case. To find linear parts ψ1,ψ2,ψ3,ψ4,ψ5, and ψ6, we consider mappings of basis elements e1,e2,e3,e4,e5, and e6 of F26 in Table 3.Table 3
Mappings of basis elements to the Modified Weidemann.
BasisImageV1=ψ1+0V2=ψ2+1V3=ψ3+1V4=ψ4+0V5=ψ5+0V6=ψ6+0100000000110000110010000101101101101001000000001000001000100101111101111000010111110111110000001000101000101Hence, the affine functions which determine the Modified Weidemann are(12)V1=f2+f4+f5+0,V2=f1+f2+f3+f4+f6+1,V3=f1+f3+f6+1,V4=f1+f2+f4+f5+f6+0,V5=f1+f4+f5+0,V6=f2+f3+f4+f6+0,and the corresponding number isWx=∑j=1626−jVjx+1. Note that W is an affine function and the linear part ψj of each Vj are as follows:(13)ψ1=f2+f4+f5,ψ2=f1+f2+f3+f4+f6,ψ3=f1+f3+f6,ψ4=f1+f2+f4+f5+f6,ψ5=f1+f4+f5,ψ6=f2+f3+f4+f6.It is easy to see thatψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 are linearly independent. Thus, W is nonsingular. Since each ψj is nonzero on the subspaces spane1,e2,spane3,e4,spane5,e6 and spane1+e3+e5,e2+e4+e6, spane1,e2,spane3,e4,spane5,e6 and spane1+e3+e5,e2+e4+e6 are magic. Therefore, Weidemann’s cube is an affine magic cube and hence semi-pantriagonal. However, it is not pantriagonal, not associated, not compact, and also not bent triagonal because the subspaces spane1+e3+e5,e1+e2+e4+e6, are not magic.


### 5.3. John Hendricks 1972's Magic Cube

John Hendricks published this cube in 1972 when he introduced pantriagonal magic cubes [6].The affine functions which determine the Modified Hendricks 1972 obtained by subtracting one from each number in Figure8 and writing them in base 2 are(14)V1=f2+f4+f5,V2=f2+f4+f5+f6,V3=f2+f3+f6,V4=f2+f3+f4+f6,V5=f1+f4+f6,V6=f1+f2+f4+f6,Figure 8
Hendricks 1972.and the corresponding number isWx=∑j=1626−jVjx+1. Note that W is an affine function. In this case, we have that Vj=ψj is a linear function for j=1,…,6. Since ψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 are linearly independent, W is nonsingular. It is easy to see that spane1,e2,spane3,e4,spane5,e6, and spane1+e3+e5,e2+e4+e6 are magic. Thus, Hendrick 1972's cube is an affine magic cube and hence semi-pantriagonal. It is pantriagonal and also compact because spane1+e3+e5,e1+e2+e4+e6,spane1+e3+e5,e2+e3+e4+e6,spane1+e3+e5,e2+e4+e5+e6,spane2,e4spane2,e6,spane4,e6,spane2,e3+e4,spane2,e5+e6,spane4,e5+e6,spane1+e2,e3+e4,spane1+e2,e5+e6 and spane3+e4,e5+e6 are magic. However, it is neither bent triagonal nor associated because spane1+e3+e6,e2+e4+e6 and spane1+e2+e3+e4+e5+e6 are not magic.


### 5.4. John Hendricks 1999's Magic Cube

In this last example, we consider the magic cube by John Hendricks appearance in his 1999 book [7]. It has the unique feature of containing bent triagonals.The affine functions which determine the Modified Hendricks 1999 obtained by subtracting one from each number in Figure9 and writing them in base 2 are(15)V1=f1+f3+f5+f6+1,V2=f1+f3+f6+1,V3=f1+f3+f4+f5+0,V4=f1+f4+f5+1,V5=f1+f2+f3+f5+1,V6=f2+f3+f5+1,Figure 9
Hendricks 1999.and the corresponding number isWx=∑j=1626−jVjx+1. Note that W is an affine function and the linear part ψj of each Vj are as follows:(16)ψ1=f1+f3+f5+f6,ψ2=f1+f3+f6,ψ3=f1+f3+f4+f5,ψ4=f1+f4+f5,ψ5=f1+f2+f3+f5,ψ6=f2+f3+f5.Thenψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 are linearly independent, and so W is nonsingular. Since spane1,e2,spane3,e4,spane5,e6, and spane1+e3+e5,e2+e4+e6 are magic, Hendrick 1999s cube is an affine magic cube and hence semi-pantriagonal. It is bent triagonal because spane1+e3+e6,e2+e4+e6,spane1+e4+e5,e2+e4+e6,spane1+e4+e6,e2+e4+e6spane2+e3+e5,e2+e4+e6,spane2+e3+e6,e2+e4+e6,andspane2+e4+e5,e2+e4+e6 are magic. However, it is not pantriagonal, not associated, and also not compact because spane1+e3+e5,e1+e2+e4+e6,spane1+e2+e3+e4+e5+e6,spane2,e4 are not magic.


## 5.1. Hermann Schubert’s Magic Cube

The following magic cube of order 4 was published by Hermann Schubert in Germany in 1898 [1]. It is the first published magic cube of order 4 by the now-accepted rules.By subtracting 1 from each number in Figure5 and writing them in base 2, we obtain the magic cube on F26 as in Figure 6. Next, we would like to find affine functions V1,V2,V3,V4,V5, and V6 which define Figure 6. Since 000000 needs to be matched with 000000, the following can be derived:(6)V1000000=0,V2000000=0,V3000000=0,V4000000=0,V5000000=0,V6000000=0.Figure 5
Schubert 1898.Figure 6
Modified Schubert.Hence, the affine functions must be in the following forms:(7)V1=ψ1,V2=ψ2,V3=ψ3,V4=ψ4,V5=ψ5,V6=ψ6,where, ψj is the linear part of Vj for j=1,…,6. Note that in this case Vj is a linear functional for j=1,…,6. To find linear parts ψ1,ψ2,ψ3,ψ4,ψ5, and ψ6, we consider mappings of basis elements e1,e2,e3,e4,e5, and e6 of F26 in Table 1.Table 1
Mappings of basis elements to the Modified Schubert.
BasisImageV1=ψ1V2=ψ2V3=ψ3V4=ψ4V5=ψ5V6=ψ6100000111101111101010000111110111110001000110111110111000100111011111011000010011111011111000001101111101111Thus, the values ofψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 of the basis are as in Table 2.Table 2
Linear parts of each basis element.
Basisψ1ψ2ψ3ψ4ψ5ψ6100000111101010000111110001000110111000100111011000010011111000001101111Hence, the affine functions which determine Figure6 are(8)V1=f1+f2+f3+f4+f6,V2=f1+f2+f3+f4+f5,V3=f1+f2+f4+f5+f6,V4=f1+f2+f3+f5+f6,V5=f2+f3+f4+f5+f6,V6=f1+f3+f4+f5+f6,and the corresponding number isWx=∑j=1626−jVjx+1. Note that W is an affine function, and the linear part ψj of each Vj are as follows:(9)ψ1=f1+f2+f3+f4+f6,ψ2=f1+f2+f3+f4+f5,ψ3=f1+f2+f4+f5+f6,ψ4=f1+f2+f3+f5+f6,ψ5=f2+f3+f4+f5+f6,ψ6=f1+f3+f4+f5+f6.It is easy to see thatψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 are linearly independent. Thus, W is nonsingular. Since each ψj is nonzero on the subspaces spane1,e2,spane3,e4,spane5,e6 and spane1+e3+e5,e2+e4+e6, spane1,e2,spane3,e4,spane5,e6 and spane1+e3+e5,e2+e4+e6 are magic. Therefore, Schubert’s cube is an affine magic cube, and hence semi-pantriagonal. This cube is also associated because spane1+e2+e3+e4+e5+e6 is magic. However, it is not pantriagonal, not compact, and also not bent triagonal because the subspaces spane1+e3+e5,e1+e2+e4+e6,spane2,e3+e4 and spane1+e3+e6,e2+e4+e6 are not magic.


## 5.2. Hermann Weidemann’s Magic Cube

The following magic cube of order 4 by Hermann Weidemann was first published in 1922 [5].To find the affine functionsV1,V2,V3,V4,V5, and V6, which define the Modified Weidemann, obtained by subtracting one from each number in Figure 7 and writing them in base 2, we observe that 000000 needs to map to 011000. Thus,(10)V1000000=0,V2000000=1,V3000000=1,V4000000=0,V5000000=0,V6000000=0.Figure 7
Weidemann 1922.Hence, the affine functions must be in the following forms:(11)V1=ψ1+0,V2=ψ2+1,V3=ψ3+1,V4=ψ4+0,V5=ψ5+0,V6=ψ6+0,where, ψj is the linear part of Vj, for j=1,…,6. Note that V2 and V3 are not linear in this case. To find linear parts ψ1,ψ2,ψ3,ψ4,ψ5, and ψ6, we consider mappings of basis elements e1,e2,e3,e4,e5, and e6 of F26 in Table 3.Table 3
Mappings of basis elements to the Modified Weidemann.
BasisImageV1=ψ1+0V2=ψ2+1V3=ψ3+1V4=ψ4+0V5=ψ5+0V6=ψ6+0100000000110000110010000101101101101001000000001000001000100101111101111000010111110111110000001000101000101Hence, the affine functions which determine the Modified Weidemann are(12)V1=f2+f4+f5+0,V2=f1+f2+f3+f4+f6+1,V3=f1+f3+f6+1,V4=f1+f2+f4+f5+f6+0,V5=f1+f4+f5+0,V6=f2+f3+f4+f6+0,and the corresponding number isWx=∑j=1626−jVjx+1. Note that W is an affine function and the linear part ψj of each Vj are as follows:(13)ψ1=f2+f4+f5,ψ2=f1+f2+f3+f4+f6,ψ3=f1+f3+f6,ψ4=f1+f2+f4+f5+f6,ψ5=f1+f4+f5,ψ6=f2+f3+f4+f6.It is easy to see thatψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 are linearly independent. Thus, W is nonsingular. Since each ψj is nonzero on the subspaces spane1,e2,spane3,e4,spane5,e6 and spane1+e3+e5,e2+e4+e6, spane1,e2,spane3,e4,spane5,e6 and spane1+e3+e5,e2+e4+e6 are magic. Therefore, Weidemann’s cube is an affine magic cube and hence semi-pantriagonal. However, it is not pantriagonal, not associated, not compact, and also not bent triagonal because the subspaces spane1+e3+e5,e1+e2+e4+e6, are not magic.


## 5.3. John Hendricks 1972's Magic Cube

John Hendricks published this cube in 1972 when he introduced pantriagonal magic cubes [6].The affine functions which determine the Modified Hendricks 1972 obtained by subtracting one from each number in Figure8 and writing them in base 2 are(14)V1=f2+f4+f5,V2=f2+f4+f5+f6,V3=f2+f3+f6,V4=f2+f3+f4+f6,V5=f1+f4+f6,V6=f1+f2+f4+f6,Figure 8
Hendricks 1972.and the corresponding number isWx=∑j=1626−jVjx+1. Note that W is an affine function. In this case, we have that Vj=ψj is a linear function for j=1,…,6. Since ψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 are linearly independent, W is nonsingular. It is easy to see that spane1,e2,spane3,e4,spane5,e6, and spane1+e3+e5,e2+e4+e6 are magic. Thus, Hendrick 1972's cube is an affine magic cube and hence semi-pantriagonal. It is pantriagonal and also compact because spane1+e3+e5,e1+e2+e4+e6,spane1+e3+e5,e2+e3+e4+e6,spane1+e3+e5,e2+e4+e5+e6,spane2,e4spane2,e6,spane4,e6,spane2,e3+e4,spane2,e5+e6,spane4,e5+e6,spane1+e2,e3+e4,spane1+e2,e5+e6 and spane3+e4,e5+e6 are magic. However, it is neither bent triagonal nor associated because spane1+e3+e6,e2+e4+e6 and spane1+e2+e3+e4+e5+e6 are not magic.


## 5.4. John Hendricks 1999's Magic Cube

In this last example, we consider the magic cube by John Hendricks appearance in his 1999 book [7]. It has the unique feature of containing bent triagonals.The affine functions which determine the Modified Hendricks 1999 obtained by subtracting one from each number in Figure9 and writing them in base 2 are(15)V1=f1+f3+f5+f6+1,V2=f1+f3+f6+1,V3=f1+f3+f4+f5+0,V4=f1+f4+f5+1,V5=f1+f2+f3+f5+1,V6=f2+f3+f5+1,Figure 9
Hendricks 1999.and the corresponding number isWx=∑j=1626−jVjx+1. Note that W is an affine function and the linear part ψj of each Vj are as follows:(16)ψ1=f1+f3+f5+f6,ψ2=f1+f3+f6,ψ3=f1+f3+f4+f5,ψ4=f1+f4+f5,ψ5=f1+f2+f3+f5,ψ6=f2+f3+f5.Thenψ1,ψ2,ψ3,ψ4,ψ5, and ψ6 are linearly independent, and so W is nonsingular. Since spane1,e2,spane3,e4,spane5,e6, and spane1+e3+e5,e2+e4+e6 are magic, Hendrick 1999s cube is an affine magic cube and hence semi-pantriagonal. It is bent triagonal because spane1+e3+e6,e2+e4+e6,spane1+e4+e5,e2+e4+e6,spane1+e4+e6,e2+e4+e6spane2+e3+e5,e2+e4+e6,spane2+e3+e6,e2+e4+e6,andspane2+e4+e5,e2+e4+e6 are magic. However, it is not pantriagonal, not associated, and also not compact because spane1+e3+e5,e1+e2+e4+e6,spane1+e2+e3+e4+e5+e6,spane2,e4 are not magic.



---

*Source: 2578562-2022-10-26.xml*