SoatDev IT Consulting
SoatDev IT Consulting
  • About us
  • Expertise
  • Services
  • How it works
  • Contact Us
  • News
  • May 20, 2025
  • Rss Fetcher

It’s often useful to partition a matrix, thinking of it as a matrix whose entries are matrices. For example, you could look at the matrix 6 × 6

M = begin{bmatrix} 3 & 1 & 4 & 0 & 0 & 0 \ 2 & 7 & 1 & 0 & 0 & 0 \ 5 & 0 & 6 & 0 & 0 & 0 \ 0 & 0 & 0 & 2 & 4 & 8 \ 0 & 0 & 0 & 1 & 7 & 6\ 0 & 0 & 0 & 3 & 5 & 1 \ end{bmatrix}

as a 2 × 2 matrix whose entries are 3 × 3 matrices.

begin{bmatrix} begin{bmatrix} 3 & 1 & 4 \ 2 & 7 & 1 \ 5 & 0 & 6 \ end{bmatrix} & begin{bmatrix} 0 & 0 & 0 \ 0 & 0 & 0 \ 0 & 0 & 0 \ end{bmatrix} \ & \ begin{bmatrix} 0 & 0 & 0 \ 0 & 0 & 0 \ 0 & 0 & 0 \ end{bmatrix} & begin{bmatrix} 2 & 4 & 8 \ 1 & 7 & 6\ 3 & 5 & 1 \ end{bmatrix} end{bmatrix}

M is not a diagonal matrix of real numbers, but its block structure is a diagonal matrix of blocks. It might be possible in some application to take advantage of the fact that the off-diagonal blocks are zero matrices.

You can multiply two partitioned matrices by multiplying the blocks as if they were numbers. The only requirement is that the blocks be of compatible sizes for multiplication: the block widths on the left have to match the corresponding block heights on the right.

For example, if you have two partitioned matrices

A = begin{bmatrix} A_{11} & A_{12} \ A_{21} & A_{22} end{bmatrix}
and
B = begin{bmatrix} B_{11} & B_{12} \ B_{21} & B_{22} end{bmatrix}

then their product is the partitioned matrix

C = begin{bmatrix} A_{11}B_{11} + A_{12}B_{21} & A_{11}B_{12} + A_{12}B_{22} \ A_{21}B_{11} + A_{22}B_{21} & A_{21}B_{12} + A_{22}B_{22} end{bmatrix}

The only requirement is that the matrix products above make sense. The number of columns in A11 must equal the number of rows in B11, and the number of columns in A12 must equal the number of rows in B21. (The rest of the compatibility conditions follow because the blocks in a column of a partitioned matrix have the same number of columns, and the blocks in a row of a partitioned matrix have the same number of rows.)

You can partition matrices into any number of rows and columns of blocks; the examples above have been 2 × 2 arrays of blocks only for convenience.

It’s natural to oscillate a bit between thinking “Of course you can do that” and “Really? That’s incredible.” If you haven’t gone through at least one cycle perhaps you haven’t thought about it long enough.

What could go wrong?

Manipulation of partitioned matrices works so smoothly that you have to wonder where things could go wrong.

For the most part, if a calculation makes logical sense then it’s likely to be correct. If you add two blocks, they have to be compatible for addition. If you “divide” by a block, i.e, multiply by its inverse, then the block must have an inverse. Etc.

One subtle pitfall is that matrix multiplication does not commute in general, and so you have to watch out for implicitly assuming that AB = BA where A and B are blocks. For example, theorems about the determinant of a partitioned matrix are not as simple as you might hope. The determinant of the partitioned matrix

begin{vmatrix} A & B \ C & D end{vmatrix}

is not simply det(AD − BC) in general, though it is true if all the blocks are square matrices of the same size and the blocks in one row or one column commute, i.e. if AB = BA, CD = DC, AC = CA, or BD = DB.

More linear algebra posts

  • An application of Kronecker products
  • The Fredholm alternative
  • What is partial pivoting?

The post Matrices of Matrices first appeared on John D. Cook.

Previous Post
Next Post

Recent Posts

  • Luminar kicks off another round of layoffs amid CEO’s sudden resignation
  • Host a tailored Side Event at TechCrunch All Stage 2025 in Boston
  • Google’s Sergey Brin: ‘I made a lot of mistakes with Google Glass’
  • The latest Google Gemma AI model can run on phones
  • Google commits $150M to develop AI glasses with Warby Parker

Categories

  • Industry News
  • Programming
  • RSS Fetched Articles
  • Uncategorized

Archives

  • May 2025
  • April 2025
  • February 2025
  • January 2025
  • December 2024
  • November 2024
  • October 2024
  • September 2024
  • August 2024
  • July 2024
  • June 2024
  • May 2024
  • April 2024
  • March 2024
  • February 2024
  • January 2024
  • December 2023
  • November 2023
  • October 2023
  • September 2023
  • August 2023
  • July 2023
  • June 2023
  • May 2023
  • April 2023

Tap into the power of Microservices, MVC Architecture, Cloud, Containers, UML, and Scrum methodologies to bolster your project planning, execution, and application development processes.

Solutions

  • IT Consultation
  • Agile Transformation
  • Software Development
  • DevOps & CI/CD

Regions Covered

  • Montreal
  • New York
  • Paris
  • Mauritius
  • Abidjan
  • Dakar

Subscribe to Newsletter

Join our monthly newsletter subscribers to get the latest news and insights.

© Copyright 2023. All Rights Reserved by Soatdev IT Consulting Inc.