# Matrix Multiplication $\to$ Function Composition?

One property of matrices that I found very interesting is the fact that if you have two functions of the same form $$f_0(x)=\frac{ax+b}{cx+d}$$ $$f_1(x)=\frac{a'x+b'}{c'x+d'}$$ then the function $f_0\circ f_1$ is in the same form, and if you put the coefficients $a,b,c,d$ and $a',b',c',d'$ into two matrices like this: $$\begin{pmatrix} a&b \\ c&d \end{pmatrix}$$ $$\begin{pmatrix} a'&b' \\ c'&d' \end{pmatrix}$$ Then the coefficients of $f_0\circ f_1$ are given by the matrix $$\begin{pmatrix} a&b \\ c&d \end{pmatrix}\begin{pmatrix} a'&b' \\ c'&d' \end{pmatrix}$$ I use this property quite often when dealing with the composition of rational functions with linear numerators and denominators since it spares me the trouble of putting myself through some unnecessary algebra.

Whilst thinking about this property, however, I was wondering if there is an analogous type of function that corresponds to a three-by-three matrix. I'm looking for some type of function so that if $g$ and $g_0$ are of this type such that the ambiguous non-$x$ variables of the type of function (suppose they are $a,b,c,d,e,f,g,h,i$ and $a',b',c',d',e',f',g',h',i'$) can be assigned to two three-by-three matrices $$\begin{pmatrix} a&b&c \\ d&e&f \\ g&h&i \end{pmatrix}$$ $$\begin{pmatrix} a'&b'&c' \\ d'&e'&f' \\ g'&h'&i' \end{pmatrix}$$ and the matrix corresponding to $g\circ g_0$ is $$\begin{pmatrix} a&b&c \\ d&e&f \\ g&h&i \end{pmatrix}\begin{pmatrix} a'&b'&c' \\ d'&e'&f' \\ g'&h'&i' \end{pmatrix}$$

Can anyone find a type of function like this? This would be very helpful to me in my studies of iterated functions.

• What makes the property interesting that we do not deal with linear maps, but with rational functions and despite of this, the matrix multiplication gives the correct coefficients. (+1) for this interesting application that I didn't know yet. – Peter Aug 18 '17 at 23:35
• @Nilknarf, what books are you using for dynamical systems studies, chances are the isomorphism will be discussed in there. – mdave16 Aug 19 '17 at 0:04
• I just discovered this property, and was about to ask a similar question. – becko Oct 7 '17 at 19:58

## 2 Answers

Instead of the function $f : \mathbb{K} \to \mathbb{K}$, with $$f(x) = \frac{ax+b}{cx+d},$$ think about the function $g:\mathbb{PK} \to \mathbb{PK}$ with $$g([X:Y]) = [aX + bY : cX + dY].$$The $[A:B]$ notation is of projective space, which is $\mathbb{K}^2/\sim$, where $[a : b] \sim [A:B]$ if $aB = bA$.

One can go from one to the other by the natural substitution $x = X/Y$. Indeed, one can think of projective space as a 2-dimensional vector space and as such $g$ is a linear map, (projective linear, but linear nonetheless). So it can be represented by a matrix for $\mathbb{PK}$ to itself (or more fancy: $Aut(\mathbb{PK}) \cong PGL(2, \mathbb{K})$. Which look just like two by two matrices over $\mathbb{K}$ modulo scalar matrices. And this works well for what you want them to do, since if you check then $\frac{ax+0}{0x+a}$ (a function relating to a scalar matrix and the projective function [aX + 0Y: 0X + aY] = [X:Y]) is indeed the identity function.

Although the above is astonishing and does help answer part of your question, it does not answer it entirely. You placed no restriction on $a$, $b$, $c$ or $d$, whereas I did. I assumed $ad-bc \neq 0$. I'm going to show you why this is a valid, and important assumption.

If $ad = bc$, then the fractional map reduces to $\frac ac$ and is constant. Now, if you compose several matrices and one of them is a singular matrix, then the resulting matrix is. Similarly, composing several functions and if one of them is constant, then the resulting function is also.

But $d=2$ was fairly arbitrary here, the same is true for any dimension. However, when $d=2$, we can think of the projective space as fractions, and so can relate the fractional linear maps with the matricies. Note that more generally $Aut(\mathbb{P^nK}) \cong PGL(n+1, \mathbb{K})$. Which has a fairly elementary but lengthy proof in Hartshorne comment 2.7.1.1, which I won't recreate.

You can construct functions which have a similar property to the one you wanted, but instead, it would be a function from $\mathbb{K}^{n-1}$ to itself for $n$ by $n$ matrices. If you wanted to make it work for 1 variable, the only way would be to take a copy of $\mathbb{PK}$ inside a much larger space, and do everything else the same, but this is a rather trivial and disappointing answer.

• "Which look just like two by two matricies over K." Modulo the center, which is the subgroup of scalar matrices. – Andrei Smolensky Aug 19 '17 at 9:52
• @AndreiSmolensky, although I didn't mention the center, i did mention subgroup. I did this because I thought it might seem like an uglier definition involving the center. Comment if you disagree, I'd like to have the best possible answer I could give. (Is there anything else I may have forgot?) – mdave16 Aug 29 '17 at 17:37

The answer is yes. For any positive integer $n$, and linear transformations $T,S:\mathbb R ^n\to \mathbb R^n$, the composition $T\circ S$ has matrix representation $$\left(\begin{matrix} a_{11}\dots a_{1n}\\ a_{21}\dots a_{2n}\\ \dots \\a _{n1}\dots a_{nn}\end{matrix}\right ) \left( \begin{matrix} b_{11} \dots b_{1n}\\b_{21}\dots b_{2n} \\ \dots\\ b_{n1}\dots b_{nn}\end{matrix}\right )$$ the product of the two matrices representing $T$ and $S$ respectively . ..

Similarly if $T$ and $S$ are represented by $m×n$ and $n×k$ matrices, you can also multiply them to get the composition. ..