Next Article in Journal
The Neurological Asymmetry of Self-Face Recognition
Next Article in Special Issue
An Advised Indirect-Utility Ranking of Opportunity Sets
Previous Article in Journal
A Discontinuity of the Energy of Quantum Walk in Impurities
Previous Article in Special Issue
Counting the Ideals with a Given Genus of a Numerical Semigroup with Multiplicity Two
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

A Note on Decomposable and Reducible Integer Matrices

by
Carlos Marijuán
1,
Ignacio Ojeda
2 and
Alberto Vigneron-Tenorio
3,*
1
Departamento de Matemática Aplicada/IMUVA, Universidad de Valladolid, E-47002 Valladolid, Spain
2
Departamento de Matemáticas/IMUEX, Universidad de Extremadura, E-06071 Badajoz, Spain
3
Departamento de Matemáticas/INDESS, Universidad de Cádiz, E-11406 Jerez de la Frontera, Spain
*
Author to whom correspondence should be addressed.
Symmetry 2021, 13(7), 1125; https://doi.org/10.3390/sym13071125
Submission received: 27 May 2021 / Revised: 20 June 2021 / Accepted: 21 June 2021 / Published: 24 June 2021

Abstract

:
We propose necessary and sufficient conditions for an integer matrix to be decomposable in terms of its Hermite normal form. Specifically, to each integer matrix, we associate a symmetric integer matrix whose reducibility can be efficiently determined by elementary linear algebra techniques, and which completely determines the decomposability of the first one.

1. Introduction

For integer valued matrices, the notion of decomposability can be stated analogously to the real case (see Definition 1). The main difference here is that unimodularity is required for the transformation matrices. This is necessary to preserve the Z -module structure generated by the columns of the matrix. Thus, if one wants to keep the group structure unchanged, pure linear algebra techniques cannot be applied to study the decomposability of an integer matrix.
Let m n be two positive integers. Given an m × n integer matrix A, we can consider the submonoid S of Z m generated by the non-negative combinations of the columns of A. A decomposition of A yields a decomposition of S, and vice versa. In [1], the authors deal with the computation of the decompositions of S, if possible, using the (integer) Hermite normal form as the main tool. Following this idea, we relate the decomposition of any integer matrix and the decomposition of its Hermite normal form (Proposition 1). This leads to our main result (Theorem 1) which states that if H is the Hermite normal form of an integer matrix A, the necessary and sufficient condition for A to be decomposable is that a certain symmetric matrix is reducible in the usual sense (see Definition 3). Now, we can adapt the combinatorial and linear algebra machinery to determine if A is decomposable: note that, for a symmetric real matrix, it is possible to decide if it can be decomposed into a direct sum of smaller symmetric real matrices by analyzing the connectivity of a certain associated graph, which is closely related to the spectral properties of the graph. All this allows us to propose an algorithm (Algorithm 1) for the computation of the decomposition of the matrix A, if possible.
Apart from practical computational considerations, we emphasize that, given an integer matrix A, we propose a new approach by associating A with a simple graph whose connectivity determines its decomposition. Consequently, this can be used to determine the decomposition of any finitely generated commutative submonoid of Z m , as an alternative method to [1]. Recall that the study of finitely generated commutative submonoids of Z m is of great interest due to its close relation with Toric Geometry (see [2,3] or [4], and the references therein). Moreover, in this context, integer decomposable matrices have their own importance; to mention a couple of illustrative examples we observe that decomposable graphical models have associated integer decomposable matrices, as can be deduced from [5] (Theorem 4.2), and that decomposable semi-groups correspond to direct products of certain algebraic (toric, in a wide sense) varieties.
 Algorithm 1: HNF-decomposition.
Input: An m × n integer matrix A.
   Output: A unimodular matrix P and a permutation matrix Q such that
    P 1 A Q = H 1 H t with H i into Hermite normal form for every i.
   1. Set H = HNF ( A ) and let P 0 be a unimodular matrix, such that P 0 1 A = H ;
   2. Define the square matrix tim ( H ) and set B = tim ( H ) + tim ( H ) ;
   3. Let D be the diagonal matrix whose elements in the main diagonal are entries of B ( 1 1 1 ) and define L = D B . If n rank ( L ) = 1 , then return P = P 0 and Q equal to the identity matrix;
   4. Let R be the reduced row echelon form of L and let k = 0 ;
   5. For j = 1 to n do
    If the j-th column, v j , of R is a non-pivot column; then
     i.  Set k = k + 1 and k equal to the cardinality of supp ( v j ) ;
     ii. Let Q k be the n × ( k + 1 ) -matrix whose columns are { e j } { e i i supp ( v j ) } , where e i denotes the n-dimensional vector that has the i-th coordinate equal to 1 and all the other coordinates equal to 0.

   6. Set Q = ( Q 1 | | Q t ) ;
   7. Let P 1 be the unimodular matrix such that P 1 1 ( H Q ) = HNF ( H Q ) ;
   8. Return P = P 0 P 1 and Q.

2. On Decomposable and Reducible Integer Matrices

Let m n be two positive integers.
Definition 1.
Let A Z m × n . We say that A is decomposable if there exist a unimodular matrix P and a permutation matrix Q such that P 1 A Q decomposes into a direct sum of matrices.
As mentioned in the introduction, the main purpose of this note is to study decomposable matrices in terms of their Hermite normal form. Let us recall the notion of Hermite normal form of an integer matrix.
Definition 2.
Let A Z m × n of rank r. The Hermite normal form of A , HNF ( A ) , is the unique matrix H = ( h i j ) Z m × n , such that A = P H , for a unimodular matrix P, satisfying the following three conditions:
(a)
there exists a sequence of integers j 1 , , j r such that 1 j 1 < < j r n , and for each 1 i r we have h i j = 0 for all j < j i (row echelon form);
(b)
for 1 k < i r we have 0 h k j i < h i j i (the pivot element is the greatest along its column and the coefficients above are non-negative);
(c)
the last m r rows of H are zero.
We say that A is in Hermite normal form when A = HNF ( A ) .
There are well-known efficient algorithms for the computation of the Hermite normal form of an integer matrix (see, e.g., [6]). They are implemented in the usual computer algebra systems; for example, in GAP ([7]) and Mathematica ([8]), the commands HermiteNormalFormIntegerMat and HermiteDecomposition, respectively, compute the Hermite normal form of an integer matrix.
Example 1.
The Hermite normal form of
A = 2 4 2 5 6 2 2 2 5 3 0 2 1 2 3
is
HNF ( A ) = 1 0 2 1 1 0 1 1 1 A = 2 0 0 1 0 0 2 0 0 3 0 0 1 2 0 ,
where the matrix 1 0 2 1 1 0 1 1 1 is the product of the elementary matrices transforming the matrix A into its reduced row echelon form as above, in such a way that the unimodular matrix in Definition 2 is
P = 1 0 2 1 1 0 1 1 1 1 = 1 2 2 1 1 2 0 1 1 .
The next propositions provide necessary and sufficient conditions for an integer matrix to be decomposable in terms of its Hermite normal form.
Proposition 1.
Let A Z m × n and let H = HNF ( A ) . Then, A is decomposable if and only if H is decomposable.
Proof. 
Let P 1 be a unimodular matrix such that P 1 1 A = H . If A is decomposable, then A 1 A t = P 2 1 A Q = P 2 1 P 1 H Q = ( P 1 1 P 2 ) 1 H Q , for a unimodular matrix P 2 and a permutation matrix Q. Now, since P 1 1 P 2 is unimodular, we have that H is decomposable. Conversely, assume that H is decomposable, so there exist a unimodular matrix P 3 and a permutation matrix Q 1 , such that P 3 1 H Q 1 = H 1 H s . Thus, H 1 H s = P 3 1 P 1 1 A Q 1 = ( P 1 P 3 ) 1 A Q 1 and we are done. □
In the following, we use the symbol to denote the transpose operation.
Proposition 2.
Let H be an m × n integer matrix in Hermite normal form. Then, H is decomposable if and only if there exist permutation matrices P and Q, such that P H Q decomposes into a direct sum of matrices.
Proof. 
First, we observe that if the rank of H is r < m , then the last m r rows of H are zero. As these rows do not affect the condition of H to be decomposable, we assume that H has rank m.
The sufficiency part is obvious since the permutation matrix P is unimodular and P = P 1 . Conversely, if H is decomposable, there exist a unimodular matrix R and a permutation matrix Q such that R 1 H Q = A 1 A t . For simplicity, we assume that t = 2 . Let P 1 and P 2 be unimodular matrices, such that H 1 : = P 1 1 ( A 1 | 0 ) Q and H 2 : = P 2 1 ( 0 | A 2 ) Q are in Hermite normal form, and define the following matrix
B : = H 1 1 1 H 2 = ( P 1 P 2 ) 1 ( A 1 A 2 ) Q = ( P 1 1 A 1 P 2 1 A 2 ) Q .
Since the rank of B is m, each row of B contains a pivot element of H 1 or H 2 . If we move the row containing the first (leftmost) pivot element to the first place, the row containing the second pivot element to the second place and so forth, the resulting matrix is necessarily in Hermite normal form. Thus, there exists a permutation matrix P such that P B = H , by the uniqueness of the Hermite normal form. Therefore, H = P B = P ( P 1 1 A 1 P 2 1 A 2 ) Q and we conclude that P H Q decomposes into P 1 1 A 1 P 2 1 A 2 . □
Example 2.
By Proposition 2, we can easily see that the matrix A in Example 1 is decomposable. Indeed,
1 0 0 0 0 1 0 1 0 HNF ( A ) 1 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 1 = 2 0 1 0 0 0 1 2 0 0 0 0 0 2 3 .
For symmetric matrices, decomposability can be refined to the more restrictive notion of reducibility. This notion has a rich combinatorial nature, because of its relationship with graph theory, as we will see later on.
Definition 3.
A symmetric matrix B Z n × n is reducible if there exists a permutation matrix Q such that Q B Q decomposes into a direct sum of square matrices. Otherwise B is said to be irreducible.
The following result gives a necessary and sufficient condition for an integer matrix to be decomposable in terms of the reducibility of a certain related symmetric matrix. To state our result we need a piece of notation.
Notation 1.
Let H be an m × n integer matrix in Hermite normal form. With the same notation as in Definition 2, we write tim ( H ) for the n × n triangular integer matrix whose j i -th row is the i-row of H , i = 1 , , m , and zeros elsewhere.
The following example illustrates the above notation.
Example 3.
If
H = 1 1 2 0 0 0 2 1 0 0 0 0 0 3 2 ,
then
tim ( H ) = 1 1 2 0 0 0 2 1 0 0 0 0 0 0 0 0 0 0 3 2 0 0 0 0 0 .
Observe that the matrix tim ( H ) is not necessarily in Hermite normal form.
Lemma 1.
Let H be an m × n integer matrix in Hermite normal form. If H is decomposable, then there exists a permutation matrix Q such that Q T tim ( H ) Q decomposes into a direct sum of triangular matrices; in particular, tim ( H ) is decomposable.
Proof. 
By Proposition 2, there exist permutation matrices P 0 and Q, such that P 0 H Q decomposes into a direct sum of matrices. Clearly, adding rows and columns to P 0 conveniently, we may construct an n × n permutation matrix P 1 such that P 1 tim ( H ) Q = H 1 H t . Matrices H i , i = 1 , , t are not necessarily triangular. However, since tim ( H ) is triangular, there exists a permutation matrix P 2 such
( P 1 P 2 ) tim ( H ) Q = P 2 ( P 1 tim ( H ) Q ) = H 1 H t
where H i is triangular for every i { 1 , , t } . Now, since ( P 1 P 2 ) tim ( H ) Q and tim ( H ) are both triangular, we conclude that P 1 P 2 and Q are identical up to permutation of the zero rows of ( P 1 P 2 ) tim ( H ) Q . □
Theorem 1.
Let A be an m × n integer matrix. If H = HNF ( A ) , then A is decomposable if and only if
tim ( H ) + tim ( H )
is reducible.
Proof. 
By Proposition 1, we may assume that A = H . Now, if H is decomposable, by Lemma 1, there exists a permutation matrix Q, such that Q tim ( H ) Q = H 1 H t , with H i , i = 1 , , t , triangular. Therefore,
Q ( tim ( H ) + tim ( H ) ) Q = Q tim ( H ) Q + Q tim ( H ) Q = = Q tim ( H ) Q + ( Q tim ( H ) Q ) = = H 1 H t + ( H 1 H t ) = = H 1 H t + H 1 H t = = ( H 1 + H 1 ) + + ( H 1 + H t ) ,
and we conclude that tim ( H ) + tim ( H ) is reducible.
Conversely, if tim ( H ) + tim ( H ) is reducible, then there exists a permutation matrix Q, such that Q ( tim ( H ) + tim ( H ) ) Q = H 1 H t . Now, since tim ( H ) is triangular, we have that Q ( tim ( H ) tim ( H ) ) Q = H 1 H t , with H i having the same order than H i , for each i { 1 , , t } , respectively. So, it follows that
Q tim ( H ) Q = Q 1 2 tim ( H ) + tim ( H ) + 1 2 tim ( H ) tim ( H ) Q = 1 2 ( H 1 + H 1 ) ( H t + H t ) ,
and we conclude that tim ( H ) is decomposable. □
Example 4.
We already know that the matrix A in Example 1 is decomposable. Thus, in the light of Theorem 1, the symmetric matrix B : = tim ( HNF ( A ) ) + tim ( HNF ( A ) ) must be reducible. Indeed,
B = 4 0 0 1 0 0 4 0 0 3 0 0 2 2 0 1 0 2 0 0 0 3 0 0 0 ,
and
Q B Q = 4 0 1 0 0 0 2 2 0 0 1 2 0 0 0 0 0 0 4 3 0 0 0 3 0 , with Q = 1 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 1 .

3. The Simple Graph of a Integer Matrix. HNF-Decomposition Algorithm

An important advantage of dealing with symmetric matrices is their strong combinatorial meaning: any symmetric matrix B = ( b i j ) Z n × n can be considered as the adjacency matrix of an undirected graph G B with n vertices { 1 , , n } , such that { i , j } is an edge of G B if and only if i j and b i j 0 .
Note that we are not concerned with diagonal elements and magnitudes of B to construct G B .
Example 5.
The graph G B corresponding to the matrix B in Example 4 is Symmetry 13 01125 i001
Notice that G B is not connected in this case.
Clearly, a symmetric matrix B is reducible if and only if the graph G B is not connected. Thus, by Theorem 1, we can study the reducibility of an integer matrix A by means of the graph G B for B = tim ( HNF ( A ) ) + tim ( HNF ( A ) ) as follows.
Corollary 1.
Let A Z m × n and set B = tim ( HNF ( A ) ) + tim ( HNF ( A ) ) . Then A is decomposable if and only if G B is not connected.
Note 1. 
Given A Z m × n , the graph G B , with B = tim ( HNF ( A ) ) + tim ( HNF ( A ) ) , can be constructed directly from H = HNF ( A ) . Indeed, with the notation of Definition 2, it suffices to observe that { i , j } G B if, and only if, h j i j 0 . Therefore, all the information concerning the decomposability of A is encoded in H.
We finalize this note by giving an algorithm for the computation (if possible) of the decomposition of an m × n integer matrix into the direct sum matrices in Hermite normal form.
Let G be the adjacency matrix of an undirected simple graph G . Recall that the degree of the i-vertex of G is
d i : = { i , j } G 1 ,
and the Laplacian matrix of G is D G , where D is the diagonal matrix with diagonal entries ( d 1 , , d n ) .
The second part of the following result is well-known; however, for lack of a reference we sketch a proof.
Proposition 3.
Let G be an undirected simple graph on n vertices. Then, G has t connected components if and only if the Laplacian matrix of G has rank n t . In this case, the connected components of G are completely determined by the reduced row echelon form of the Laplacian matrix of G .
Proof. 
The first statement follows from the well-known matrix-tree theorem (see, e.g., [9] (Section 1) and the references therein). Let us analyze the second statement with a little more detail. First, we observe that the Laplacian matrix of a connected graph on n vertices is an order n symmetric matrix of rank n 1 whose columns sum to zero. So, its reduced row echelon form is equal to
1 0 0 1 0 1 0 1 0 0 1 1 0 0 0 0 .
Thus, if V is the reduced row echelon of the Laplacian matrix of a (non-necessarily connected) undirected simple graph on n vertices, then if the j-th column, v j , of V is not a pivot column, the set of vertices of the connected component containing the vertex j is { j } supp ( v j ) , where supp ( v j ) : = { i v i j 0 } denotes the support of v j .
Example 6.
Consider the graph G with vertex-set { 1 , 2 , 3 , 4 , 5 } and edges { 1 , 4 } , { 2 , 5 } , { 3 , 4 } . The Laplacian matrix of G is
1 0 0 1 0 0 1 0 0 1 0 0 1 1 0 1 0 1 2 0 0 1 0 0 1
and its reduced row echelon form is
R : = 1 0 0 1 0 0 1 0 0 1 0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 .
Now, we can read from R that G has the following two connected components: the subgraph with vertices { 4 , 1 , 3 } and the subgraph with vertices { 5 , 2 } .
The previos proposition is the last piece needed to ensure the correctness of Algorithm 1. We discuss below some aspects of Algorithm 1.
Comments to Algorithm 1:
  • Steps (1)–(6) provide unimodular matrices P 0 and Q, such that P 0 1 A Q = P ˜ ( A 1 A t ) , for some permutation matrix P ˜ ;
  • Clearly t = n rank ( L ) ; moreover, we have that rank ( L ) = k = 1 t k ;
  • If n rank ( L ) = 1 then A is not decomposable. In this case A 1 = HNF ( A ) and Q is the identity matrix. Otherwise, if A is decomposable, we cannot guarantee that P ˜ = I m and that the matrices A i , i = 1 , , t , are in Hermite normal form. However, since HNF ( A 1 ) HNF ( A t ) = HNF ( A 1 A t ) , by the uniqueness of the Hermite normal form, step (7) provides the matrix P 1 such that P 1 1 P 0 1 A Q is in Hermite normal form as desired;
  • By Note Section 3, we may replace the Step (2) by
    (2)
    Let B be the adjacency matrix of the graph G with vertices { 1 , , n } such that { i , j } G if and only if h j i j 0 .
    This is advantageous for small n.
  • An HNF-decomposition, if it exists, is not unique. It depends on the choice of the order of the columns of the matrices Q i , i = 1 , , t and the order in which these matrices are placed.
Example 7.
The matrix
H = 1 0 1 1 2 0 0 0 1 0 0 0 0 3 0 0 3 0 0 3 0 0 0 0 2 1 2 0
is in Hermite normal form and its associated graph G (see Note 1) is Symmetry 13 01125 i002
Therefore, H is a decomposable matrix. Of course, we do not need to construct the graph G to compute an HNF-decomposition of H.
In order to compute effectively two matrices P and Q such that P 1 H Q is in HNF-decomposed form, we compute the reduced row echelon form, R, of the Laplacian matrix of G B , for B = tim ( H ) + tim ( H ) ,
R = 1 0 0 0 0 1 0 0 1 0 0 0 0 1 0 0 1 0 0 1 0 0 0 0 1 0 1 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .
Now, following Steps (5)–(7) in Algorithm 1, we may take the matrix Q equal to ( e 6 | e 1 | e 3 | e 4 | e 5 | e 7 | e 2 ) , in this case, the corresponding matrix P is
0 1 0 0 0 0 0 1 3 0 1 0 2 0 1 0 .
Now, we can check that
P 1 H Q = 1 0 3 2 1 0 0 0 1 1 1 2 0 0 0 0 6 6 3 0 0 0 0 0 0 0 3 1 .
As mentioned above, other choices of Q determine a different P and, consequently, another HNF-decomposition, equivalent to the one given.

4. Conclusions and Future Work

Using the Hermite normal form as the main tool, we have obtained a theoretical criterion to determine whether a given integer matrix decomposes into a direct sum of lower order integer matrices.
This criterion allows us to associate a simple graph to the integer matrix whose connectedness determines the decomposition of the integer matrix and facilitates the formulation of an algorithm to decompose an integer matrix into a direct sum of matrices in Hermite normal form, provided such decomposition exists.
Our results have immediate applications to the study of affine semi-groups and semi-group algebras; in fact, this was our original motivation for tackling this problem. However, we believe that our results can be generalized to matrices with entries in any Euclidean ring further than Z .
Since we were only interested in decomposition issues, we underestimated a lot of information from B when constructing the graph G B . Alternatively, B can be considered as the adjacency matrix of an (undirected) weighted graph G B with n vertices { v 1 , , v n } , where the weight of the edge { v i , v j } is b i j . This alternative graph is sensitive to all the information recorded in the entries of B. One might wonder if this alternative graph can be used to provide information for integer matrices, beyond decomposability and reducibility.

Author Contributions

Investigation, C.M., I.O. and A.V.-T. All authors contributed equally to the work. All authors have read and agreed to the published version of the manuscript.

Funding

This reserach was partially supported by the Ministerio de Economía y Competitividad (Spain) /FEDER-UE under grants PGC2018-096446-B-C21 and MTM2017-84890-P, by the Junta de Extremadura(Spain)/FEDER funds, research group FQM-024, and by the Junta de Andalucía (Spain), research group FQM-366.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. García-García, J.I.; Moreno-Frías, M.A.; Vigneron-Tenorio, A. On decomposable semigroups and applications. J. Symb. Comput. 2013, 58, 103–116. [Google Scholar] [CrossRef]
  2. Cox, D.; Little, B.; Schenck, H. Toric Varieties; Graduate Studies in Mathematics; American Mathematical Society: Providence, RI, USA, 2011; Volume 124. [Google Scholar]
  3. Miller, E.; Sturmfels, B. Combinatorial Commutative Algebra; Vol. 227 of Graduate Texts in Mathematics; Springer: New York, NY, USA, 2005. [Google Scholar]
  4. Rosales, J.C.; García-Sánchez, P.A. Finitely Generated Commutative Monoids; Nova Science Publishers, Inc.: Commack, NY, USA, 1999. [Google Scholar]
  5. Geiger, D.; Meek, C.; Sturmfels, B. On the toric algebra of graphical models. Ann. Stat. 2006, 34, 1463–1492. [Google Scholar] [CrossRef] [Green Version]
  6. Clement, P.; Stein, W. Fast computation of Hermite normal forms of random integer matrices. J. Number Theory 2010, 130, 1675–1683. [Google Scholar]
  7. The GAP Group. GAP—Groups, Algorithms, and Programming, Version 4.11.1. 2021. Available online: https://www.gap-system.org (accessed on 23 June 2021).
  8. Mathematica, Version 12.3; Wolfram Research, Inc.: Champaign, IL, USA, 2021.
  9. Merris, R. Laplacian matrices of graphs: A survey. Linear Algebra Appl. 1994, 197, 143–176. [Google Scholar] [CrossRef] [Green Version]
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Marijuán, C.; Ojeda, I.; Vigneron-Tenorio, A. A Note on Decomposable and Reducible Integer Matrices. Symmetry 2021, 13, 1125. https://doi.org/10.3390/sym13071125

AMA Style

Marijuán C, Ojeda I, Vigneron-Tenorio A. A Note on Decomposable and Reducible Integer Matrices. Symmetry. 2021; 13(7):1125. https://doi.org/10.3390/sym13071125

Chicago/Turabian Style

Marijuán, Carlos, Ignacio Ojeda, and Alberto Vigneron-Tenorio. 2021. "A Note on Decomposable and Reducible Integer Matrices" Symmetry 13, no. 7: 1125. https://doi.org/10.3390/sym13071125

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop