# Thread: Inversion of a particular quadratic form

1. ## Inversion of a particular quadratic form

Let $A$ be a $n \times p$ matrix, $I \ \ n \times n$ identity matrix and $B_1$ and $B_2$ are $n \times n$ regular matrices. Anyone who knows a smart way of inverting the quadratic form

$X^{\top}Y X=
\left[\begin{array}{cc}A^{\top}&0\\I&I\end{array}\right]
\left[\begin{array}{cc}B_1&0\\0&B_2\end{array}\right]
\left[\begin{array}{cc}A&I\\0&I\end{array}\right]
$

Thanks
René

2. Do you know what the rank of the matrix A is?

If $rank(A)=min(n,p)$ then you can isolate in terms of either the right or left inverses (depending on the rank) of $X$ and $X^T$ and the inverse of $Y$ which are easy to determine.

3. Sorry, the $Rank(A)=p$. I'm however not sure I see what you mean. Can you elaborate, please.

/Rene

4. The inverse is strictly well defined for square matrices but for non-square matrices you can define a left or right inverse. Say you have a matrix $B$ which is an $m \times n$ matrix then if it has rank $n$ there is an $n \times m$ matrix, C, such that:

$B C = I_m$

and this is referred to as its left inverse.

Unfortunately, I think I was too hasty in thinking this would help with your problem as it does not seem to give a matrix of the correct dimensions for the inverse using the simple method I was thinking of.

I do have another idea but it's late now so will post it tomorrow if it works.

5. Thanks Doc. I'm looking forward to see what else you have in mind. Finding the inverse of a quadratic form is a problem that I've come across quite often and I don't think there is an universal solution to it. I was (and still am) however hoping for a solution for this particular case with the rather simple structure of the "bread" matrix.

/René

6. Well what do you know - my original method does work! Just goes to show the perils of late night maths! LOL.

I'll demonstrate my original method as it's the quickest!

OK, since the $Rank(A) = p$ then the rank of $X$ and hence $X^T$ must be $n+p$. This allows us to define the following special inverses (order of multiplication being important!):

$X X^{-1} = I_{2n}$ and $(X^{T})^{-1} X^T = I_{2n}$ .

Consequently we also have that:

$(X^{T})^{-1} = (X^{-1})^T$

Now if we call your quadratic form $M$ then, using the fact that

$(AB)^{-1} = B^{-1} \, A^{-1}$ , we have

$M^{-1} = X^{-1} Y^{-1} (X^{T})^{-1}$ .

So the problem has now been reduced to finding the inverse of X.

This is easy as you just need to make sure you partition your unknown matrix representing the inverse in a way so that you can treat it as a $2 \times 2$ matrix type problem. Then it's just a matter of solving for the unknown elements which is infact so easy that you can do it by just looking at it! Anyway, it turns out that:

$X^{-1} = \begin{bmatrix} A^{-1} & -A^{-1} \\
0 & I_n
\end{bmatrix}$

and so

$(X^{T})^{-1} = \begin{bmatrix} (A^{T})^{-1} & 0 \\
-(A^{T})^{-1}& I_n
\end{bmatrix}$
.

Of course it should be obvious that

$Y^{-1} = \begin{bmatrix} B_1^{-1} & 0 \\
0 & B_2^{-1}
\end{bmatrix}$
.

So there you are the product of these inverses in the order I specified above should give you the inverse. The only thing you need to determine are the inverses of $B_1$, $B_2$ and $A$ where

$A A^{-1} = I_n$

with $A^{-1}$ necessarily being a $p \times n$ matrix. Note also that for $A$ you have

$(A^{T})^{-1} \, A^T = I_n$

so

$(A^{T})^{-1} = (A^{-1})^T$ .

Well I don't know if that is sufficiently clever a method but I believe it should work. I would test it out on a few trial matrices where $n$ and $p$ are small like 3 and 2.

Hope that was of some help!

P.S. Do let me know if it works.

7. Hello Doc,

Thanks for your reply and your effort. I was quite excited about the idea, but it seems that there is problem or I may have missed something.

If $A$ is $n \times p$ (with $p < n$) and $Rank(A)=p$ then $A$ has a left inverse $A^{-L}$ given by $(A^\top A)^{-1}A^\top$.

So the inverse of $X$ is actually a left inverse $X^{-L}=\begin{bmatrix}A^{-L} &-A^{-L}\\
0 & I\end{bmatrix}$
.

Now the problem comes when we want to find the inverse of $X^\top Y X$. As far as I can see $X^{-1} Y^{-1} (X^\top)^{-1}$ (see your previous posting) is not defined because $X^\top$ does not have a left inverse as it doesn't have full rank.

I'll be gratefull if you can help me clarify the issue if I haven't got it right or if there really is problem I hope you can help me fix it. Life will be much easier if I can find an easy way of inverting $X^{\top} Y X$

Cheers,

$\rho$

8. Yes, this was the initial snag that I referred to in an earlier post but then it seemed to work out the next day (which I now realise was) because I confused my left and right inverses for the problem.

The curious thing is that if you carry out the multiplication of your quadratic form to put it in its explicitly square matrix form and then consider the matrix inverse as a block matrix with four unknown matrices and multiply out, solving for those unknowns whilst ensuring to use correct inverses (left or right) it does give the same result. This was my second method.

So in short, sadly, I don't think there is an easy way. Though I think it is still worth trying it out with a numerical example, but with any inverse taken as left or right depending on whichever is defined, and seeing if that works.

Sorry to have disappointed if it doesn't work out.

Perhaps there is someone else at the forum who has more experience with quadratic forms that may be able to help?