In Sections 11, 12, and 13, Rubini demonstrated powerful applications of determinants. In particular, he used determinants to obtain Lagrange's Four Squares Theorem and then derived other known results from it.

- In Section 11, he derived Lagrange's Four Square Theorem using determinants.
- In Section 12, he demonstrated a geometric application of Lagrange's Four Square Theorem.
- In the last section, Section 13, he presented the following theorem:
*"every number is the sum of four squares"* [Rubini, 1857, p. 200].

We summarize Rubini's derivation of Lagrange's Four Squares Theorem below. In Section 8, he introduced matrices \(P_{a+ih}\) and \(P_{a - ih}\) as square matrices with entries consisting of corresponding complex conjugates \(\left(i=\sqrt{-1}\right).\) Therefore, the product, \(Q =P_{a+ih} \times P_{a - ih},\) is a matrix with complex entries, except for the elements on the main diagonal, which are real. In Section 11, Rubini calculated the determinant of \(P_{a+ih} \times P_{a - ih}\left(=Q\right)\) to be (54):

\[{\left|{\begin{vmatrix}a_{1,1} & a_{1,2}\\a_{2,1} & a_{2,2}\end{vmatrix}-\begin{vmatrix}h_{1,1} & h_{1,2}\\h_{2,1} & h_{2,2}\end{vmatrix}}\right|}^2+{\left|{\begin{vmatrix}h_{1,1} & a_{1,2}\\h_{2,1} & a_{2,2}\end{vmatrix}+\begin{vmatrix}a_{1,1} & h_{1,2}\\ a_{2,1} & h_{2,2}\end{vmatrix}}\right|}^2\]

\[={(a_{1,1}a_{2,2} - a_{1,2}a_{2,1} + h_{1,2}h_{2,1} - h_{1,1}h_{2,2})}^2+{(h_{1,1}a_{2,2} - a_{1,2}h_{2,1} + a_{1,1}h_{2,2} - h_{1,2}a_{2,1})}^2,\]

and the determinant of \(Q\) to be (55):

\(({a^2}_{1,1} + {h^2}_{1,1} + {a^2}_{1,2} + {h^2}_{1,2})({a^2}_{2,1} + {h^2}_{2,1} + {a^2}_{2,2} + {h^2}_{2,2})\)

\(- \ (a_{1,1}a_{2,1} + h_{1,1}h_{2,1} + a_{1,2}a_{2,2} + h_{1,2}h_{2,2})^2\)

\(- \ (a_{1,1}h_{2,1} - h_{1,1}a_{2,1} + a_{1,2}h_{2,2} - h_{1,2}a_{2,2})^2.\)

Rubini then set these two determinants equal to one another and simplified to obtain the following equation (56):

\(({a^2}_{1,1} + {h^2}_{1,1} + {a^2}_{1,2} + {h^2}_{1,2})({a^2}_{2,1} + {h^2}_{2,1} + {a^2}_{2,2} + {h^2}_{2,2})\)

\(=(a_{1,1}a_{2,1} + h_{1,1}h_{2,1} + a_{1,2}a_{2,2} + h_{1,2}h_{2,2})^2\)

\(+ \ (a_{1,1}a_{2,2} - a_{1,2}a_{2,1} + h_{1,2}h_{2,1} - h_{1,1}h_{2,2})^2\)

\(+ \ (a_{1,1}h_{2,1} - h_{1,1}a_{2,1} + a_{1,2}h_{2,2} - h_{1,2}a_{2,2})^2\)

\(+ \ (h_{1,1}a_{2,2} - a_{1,2}h_{2,1} + a_{1,1}h_{2,2} - h_{1,2}a_{2,1})^2.\)

The equation above led Rubini to the known mathematical theorem that *"every number is the sum of four squares,"* which he credited to Legendre [Rubini, 1857, p. 197]. Rubini used the power of determinants to demonstrate this theorem, where mathematicians such as Legendre and Lagrange used number theory. (See the article by Beintema and Khosravani [2003] for a historical discussion of the proof of this famous theorem.). Although several mathematicians made contributions to this theorem, it is usually attributed to Lagrange, who proved the theorem in 1770. The theorem is more accurately formulated as *"every ***natural** number is the sum of four squares" [O'Connor and Robertson, 1999]. Today the theorem is known as Lagrange's Four Square Theorem. Numerical examples include:

\[50 = 6^2 + 3^2 + 2^2 + 1^2\]

and

\[13 = 3^2 + 2^2 + 0^2 + 0^2,\]

and thus this theorem can be more generally stated as:

*For all natural numbers* \(x,\) *there exist integers* \(b, c, d, e \geq 0\) *such that* \[x = b^2 + c^2 + d^2 + e^2.\]

These representations are not necessarily unique; some numbers are produced by more than one set of four squares. For example, the number \(50\) can also be expressed as \[50=7^2+ 1^2+ 0^2+0^2.\]

In Section 13, Rubini set certain elements equal to each other, putting \(a_{1,1}\) = \(a_{2,2},\) \(h_{1,1}\) = \(h_{2,2},\) \(a_{1,2}\) = \(a_{2,1}\) and \(h_{1,2}\) = \(h_{2,1}.\) Then he applied these newly established equalities to two previously defined equations: (54), which appears above, and (59), which expresses the partial determinant of \(P_{a + ih} \times P_{a - ih}\) as \( A -\Sigma\,A_2 =\)

\( ({a^2}_{1,1} + {h^2}_{1,1} + a_{1,2}a_{2,1} + h_{1,2}h_{2,1})\)

\(\times \ ({a^2}_{2,2} + {h^2}_{2,2} + a_{1,2}a_{2,1} + h_{1,2}h_{2,1})\)

\(- \ [a_{1,2}(a_{1,1}+ a_{2,2}) + h_{1,2}(h_{1,1} + h_{2,2})]\)

\(\times \ [a_{2,1}(a_{1,1} + a_{2,2}) + h_{2,1}(h_{1,1} + h_{2,2})]\)

\(- \ [a_{1,2}(h_{1,1} - h_{2,2}) - h_{1,2}(a_{1,1} - a_{2,2})]\)

\(\times \ [a_{2,1}(h_{1,1} - h_{2,2}) + h_{2,1}(a_{1,1} - a_{2,2})]\)

\(+ \ (a_{1,2}h_{2,1} - h_{1,2}a_{2,1})^2. \)

With these substitutions, formula (54) could then be expressed as:

\[({a^2}_{1,1} - {h^2}_{1,1} + {h^2}_{1,2} - {a^2}_{1,2})^2 + \ (h_{1,1}a_{1,1} + a_{1,1}h_{1,1} - a_{1,2}h_{1,2} - h_{1,2}a_{1,2})^2,\]

which can be simplified to:

\[({a^2}_{1,1} - {h^2}_{1,1} + {h^2}_{1,2} - {a^2}_{1,2})^2 + \ [2(a_{1,1}h_{1,1} - a_{1,2}h_{1,2})]^2.\]

Formula (59), could be expressed as:

\(({a^2}_{1,1} + {h^2}_{1,1} + {a^2}_{1,2} + {h^2}_{1,2})^2 - \ [a_{1,2}(2a_{1,1}) + h_{1,2}(2h_{1,1})][a_{1,2}(2a_{1,1}) + h_{1,2}(2h_{1,1})]\)

\(- \ [a_{1,2}(h_{1,1} - h_{1,1}) - h_{1,2}(a_{1,1} - a_{1,1})][a_{1,2}(h_{1,1} - h_{1,1}) - h_{1,2}(a_{1,1} - a_{1,1})]\)

\(+ \ (a_{1,2}h_{1,2} - h_{1,2}a_{1,2}),\)

and simplified to:

\[({a^2}_{1,1} + {h^2}_{1,1} + {a^2}_{1,2} + {h^2}_{1,2})^2 - \ [2(a_{1,1}a_{1,2} + h_{1,1}h_{1,2})]^2.\]

Upon setting these new equations equal to each other and solving for \(({a^2}_{1,1} + {h^2}_{1,1} + {a^2}_{1,2} + {h^2}_{1,2})^2,\) Rubini arrived at the following equation (61):

\(({a^2}_{1,1} + {h^2}_{1,1} + {a^2}_{1,2} + {h^2}_{1,2})^2=\)

\(({a^2}_{1,1} - {h^2}_{1,1} + {h^2}_{1,2} - {a^2}_{1,2})^2+\ [2(a_{1,1}a_{1,2} + h_{1,1}h_{1,2})]^2 + [2(a_{1,1}h_{1,1} - a_{1,2}h_{1,2})]^2.\)

This led Rubini to yet another known mathematical theorem that he derived through determinants, the theorem – researched by various mathematicians including Leonhard Euler (1707–1783) and Christian Goldbach (1690–1764) – that the *"square of a number is always the sum of only three squares"* [Lemmermeyer, n.d.; Rubini, 1857, p. 200]. The formula above can be generalized to \(b^2 = c^2 + d^2 + e^2.\) Every Pythagorean triple can be written in this form with \(0\) as one of the three squares. We can get a better sense of the validity of this theorem and see how the theorem works by examining a couple of numerical examples:

\[5^2 = 4^2 + 3^2 + 0^2= 16 + 9 + 0= 25\]

and

\[3^2 = 2^2 + 2^2 + 1^2= 4 + 4 + 1= 9.\]

Rubini's selection of these two theorems about sums of squares as part of his article further supports the conjecture that one of his purposes in publishing this work was to compile some of the work previously done by other analytic mathematicians and share it with mathematical scholars residing in the Kingdom of Two Sicilies. Also, Rubini may have chosen these two striking mathematical theorems to show the superiority of the analytic concepts of determinants and functions over those of synthetic mathematics. Although these theorems can be reached through complicated procedures utilizing number theory, Rubini arrived at the theorems rather easily by using determinants, demonstrating to the reader the superiority of this new mathematical concept.