JAM Journal of Applied Mathematics 1687-0042 1110-757X Hindawi Publishing Corporation 10.1155/2016/4590817 4590817 Research Article A Note on the vec Operator Applied to Unbalanced Block-Structured Matrices http://orcid.org/0000-0003-4394-6894 Caswell Hal 1 http://orcid.org/0000-0002-2034-8763 van Daalen Silke F. 1 Guichard Frédéric Institute for Biodiversity and Ecosystem Dynamics University of Amsterdam P.O. Box 94248 1090 GE Amsterdam Netherlands uva.nl 2016 9112016 2016 25 07 2016 03 10 2016 2016 Copyright © 2016 Hal Caswell and Silke F. van Daalen. This is an open access article distributed under the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.

The vec operator transforms a matrix to a column vector by stacking each column on top of the next. It is useful to write the vec of a block-structured matrix in terms of the vec operator applied to each of its component blocks. We derive a simple formula for doing so, which applies regardless of whether the blocks are of the same or of different sizes.

ERC 322989 National Science Foundation DEB-1257545 Nederlandse Organisatie voor Wetenschappelijk Onderzoek ALWOP.2015.100
1. Introduction

The vec operator, applied to a r×c  matrix X, produces a rc×1  column vector, denoted  vec(X) by stacking each column of X  on top of the following column . Here, we consider the result of applying the vec operator to block-structured matrices, including the case in which the blocks differ in size. Such a matrix is called unbalanced . Previous studies of the vec operator and Kronecker product applied to block-structured matrices [2, 3] have not addressed this problem.

In many applications, block-structured matrices arise because the blocks represent different states or processes. In general, these blocks will be of different sizes and may depend on different parameters. If the vec operator is applied to such a matrix, it may be helpful to write the result in terms of the vec of each of the component blocks. This calculation arises, inter alia, in applications of matrix calculus  in demography and ecology, including nonlinear matrix population models  and finite-state Markov chains [6, 7]. In such models (we give an example below), the outcome is often a vector-valued function of the same matrix, and the matrix has an inherent block structure.

Our goal is to write the vec of the unbalanced block-structured matrix as a linear combination of the vec operator applied to each of the component blocks. Although the solution is simple, it is widely useful, so we present it here.

2. Results

If the matrix  X  contains  n  blocks, we write it as the sum of  n  matrices, each containing one of the blocks surrounded by zero matrices, as in (1) X = A B C (2) = A 0 0 + 0 B 0 + 0 0 C , where  A,  B, and  C and the corresponding zero matrices may be of different (but compatible) sizes. The vec of X is the sum of the vec operator applied to each of the component matrices in (2). A generic member of this set of component matrices can be written as in the following result.

Theorem 1.

Let X be an  r×c  block-structured matrix, with the dimensions of the blocks indicated as subscripts, written (3) X r × c = 0 r 1 × c 1 0 r 1 × c 2 0 r 1 × c 3 0 r 2 × c 1 A r 2 × c 2 0 r 2 × c 3 0 r 3 × c 1 0 r 3 × c 2 0 r 3 × c 3 , where r=r1+r2+r3  and  c=c1+c2+c3 and   r1,  r3,  c1,  c3, or any combination, may be zero. Then (4)vecX=QPvecA,where (5)P=0r1×r2Ir2×r20r3×r2,Q=0c2×c1Ic2×c20c2×c3.

Proof.

To convert A to X requires the addition of  r1  rows of zeros above,  r3  rows of zeros below,  c1  columns of zeros to the left, and  c3  columns of zeros to the right of A. This is accomplished by multiplying A on the left by P and on the right by  Q, so that (6)X=PAQ.Applying the vec operator to (6), using a well known result of Roth , yields (4).

Remark 2.

We said it was simple.

3. Applications

Here are several examples of interest, to demonstrate the formulation of the block-structured matrices and the result of applying the vec operator.

(1) The transition matrix for a finite-state absorbing Markov chain with  τ  transient states and  α  absorbing states can be written as a block-structured matrix. Numbering the states so that the transient states precede the absorbing states yields a canonical form for the (column-stochastic) transition matrix (e.g., ), (7) P = U τ × τ 0 τ × α M α × τ I α × α . The matrix  U  describes transitions among the transient states and  M  describes transitions from transient states to absorbing states. Suppose that  ξ  is a vector-valued (s×1) differentiable function of  P and that  U  and  M  are differentiable functions of a vector (p×1)  θ  of parameters. In demographic and ecological applications,  U  might describe transitions and survival among life cycle stages of some organism, and  M might describe transitions to different causes of death (e.g., [7, 10]).

Following , the derivative of  ξ  with respect to  θ  is the  s×p  matrix (8)dξdθ=dξdvecPdvecPdθ.To obtain dvecP we must apply the vec operator to the block-structured matrix  dP. Applying the results (5) gives (9)dP=Iτ×τ0α×τdUIτ×τ0τ×α+0τ×αIα×αdMIτ×τ0τ×α(noting that  dI  and  d0  are both zero). Applying the vec operator and the chain rule gives (10)dvecPdθ=Iτ×τ0α×τIτ×τ0α×τdvecUdθ+Iτ×τ0α×τ0τ×αIα×αdvecMdθ.In applications, it is likely that parameters of interest are defined in terms of their effects on  U  and  M; (10) makes it possible to incorporate that dependence easily into the necessary derivative of the block-structured matrix  P.

We note that the intensity matrix of a continuous-time absorbing Markov chain also has a block structure (e.g., [9, Chap. 8]); applications of matrix calculus to such models  will benefit from the results presented here.

(2) The transition matrix of an absorbing Markov chain is a special case of the canonical form of a reducible nonnegative matrix . If  X  is a reducible matrix, it can be written (11)X=A1100A21A220As1As2Ass.Each of the diagonal blocks  Aii  is square and irreducible (or a  1×1  zero matrix). The division into diagonal blocks corresponds to a division of the vector space upon which  X  operates into invariant subspaces.

(3) A balanced block-structured matrix, in which all blocks are the same size, is a special case of an unbalanced matrix. Theorem 1 provides a simple result for the vec of such a matrix. Consider the  pm×qn  matrix (12)X=A11A1qAp1Apq,where   Aij  are each of dimension  m×n. This case is considered by .

From (5)-(6) we have (13)X=i=1pj=1qPiAijQj,where (14)Pi=0i-1m×mIm×m0p-im×m,i=1,,p,Qj=0n×j-1nIn×n0n×q-jn,j=1,,q.The vec of  X  is (15)vecX=i=1pj=1qQjPivecAij.

4. Conclusions

The vec operator, by transforming a matrix into a vector, is useful in many applications . When the matrix is block structured and the blocks represent various processes involved in the application, it is convenient to be able to express the vec of the matrix as a linear combination of the vec operator applied to the component blocks. We have shown how to do so and described a few examples, but these do not exhaust the potential uses of the result.

Competing Interests

The authors declare that they have no competing interests.

Acknowledgments

This research was supported by ERC Advanced Grant 322989, NSF Grant DEB-1257545, and NWO-ALW Project ALWOP.2015.100.

Henderson H. V. Searle S. R. The vec-permutation matrix, the vec operator and Kronecker products: a review Linear and Multilinear Algebra 1981 9 4 271 288 10.1080/03081088108817379 MR611262 Koning R. H. Neudecker H. Wansbeek T. Block Kronecker products and the vecb operator Linear Algebra and Its Applications 1991 149 165 184 10.1016/0024-3795(91)90332-q MR1092876 2-s2.0-0000312206 Ojeda I. Kronecker square roots and the block vec matrix The American Mathematical Monthly 2015 122 1 60 64 10.4169/amer.math.monthly.122.01.60 MR3324956 Magnus J. R. Neudecker H. Matrix Differential Calculus with Applications in Statistics and Econometrics 1988 New York, NY, USA John Wiley & Sons MR940471 Caswell H. Sensitivity and elasticity of density-dependent population models Journal of Difference Equations and Applications 2009 15 4 349 369 10.1080/10236190802282669 MR2513948 2-s2.0-68849102094 Caswell H. Perturbation analysis of continuous-time absorbing Markov chains Numerical Linear Algebra with Applications 2011 18 6 901 917 10.1002/nla.791 MR2861268 2-s2.0-82455187988 Caswell H. Sensitivity analysis of discrete Markov chains via matrix calculus Linear Algebra and Its Applications 2013 438 4 1727 1745 10.1016/j.laa.2011.07.046 MR3005253 2-s2.0-84872112996 Roth W. E. On direct product matrices Bulletin of the American Mathematical Society 1934 40 6 461 468 10.1090/S0002-9904-1934-05899-3 MR1562881 Iosifescu M. Finite Markov Processes and Their Applications 1980 New York, NY, USA Wiley-Interscience MR587116 Caswell H. Stage, age and individual stochasticity in demography Oikos 2009 118 12 1763 1782 10.1111/j.1600-0706.2009.17620.x 2-s2.0-71049129779 Gantmacher F. R. Matrix Theory, Volume 2 1959 New York, NY, USA Chelsea