# volume of N-d parallelepiped in terms of its edge vectors

**Definition**: Let $\Pi$ be an $n$-dimensional parallelotope defined by edge vectors $\mathcal{B}=\left\{ \mathbf{v}_{1},\ \cdots,\ \mathbf{v}_{n}\right\}$. We define the volume of the parallelotope recursively as follows:

1. For a 1-dimensional parallelotope, we have $\mathrm{vol}(\Pi)$.
 
2. For an $n$-dimensional parallelotope with $n>1$, we define the _base_ of the parllelotope to be the volume of the $(n-1)$-dimensional parallelotope defined by edges $\mathcal{B}\backslash\left\{\mathbf{v}_{n}\right\}$, and we define the _height_ to be the length of the component of $\mathbf{v}_{n}$ orthogonal to every vector in the base. Then we define 
$$\mathrm{vol}\left(\Pi\right)=\mathrm{base}\times\mathrm{height}.$$

**Theorem**: Let $\Pi$ be an $m$-dimensional parallelotope defined by edge vectors $\mathcal{B}=\left\{ \mathbf{v}_{1},\ \dots,\ \mathbf{v}_{m}\right\}$, where $\mathbf{v}_{i}\in\mathbb{R}^{n}$ for $n\ge m$. That is, we are looking at an $m$-dimensional parallelotope embedded inside $n$-dimensional space. Suppose that $A$ is the $m\times n$ matrix with row vectors $\mathcal{B}$, given by
$$A=\begin{pmatrix}\mathbf{v}_{1}^{\mathrm{T}}\\
\vdots\\
\mathbf{v}_{m}^{\mathrm{T}}\end{pmatrix}$$
Then the $m$-dimensional volume of the parallelotope is given by $$\left[\mathrm{vol}\left(\Pi\right)\right]^{2}=\det\left(AA^{\mathrm{T}}\right).$$

**Proof**: Note that $AA^{\mathrm{T}}$ is an $m\times m$ square matrix. Suppose that $m=1$. Then 
$$\det AA^{\mathrm{T}}=\det\left(\mathbf{v}_{1}^{\mathrm{T}}\mathbf{v}_{1}\right)=\mathbf{v}_{1}\cdot\mathbf{v}_{1}=\|\mathbf{v}_{1}\|^{2}=\left[\mathrm{vol}_{1}(\mathbf{v}_{1})\right]^{2},$$
so the proposition holds for $m=1$. Now we induct on $m$. Suppose that the proposition holds for $m\ge 1$ and consider $m+1$. Letting $A_{m}$ denote the matrix containing the rows $\mathbf{v}_{1}$ to $\mathbf{v}_{m}$, we can write $A=A_{m+1}$ as

$$A=\begin{pmatrix}A_{m}\\
\mathbf{v}_{m+1}^{\mathrm{T}}
\end{pmatrix}$$
 
We may decompose $\mathbf{v}_{m+1}$ orthogonally as 
$$\mathbf{v}_{m+1}=\mathbf{v}_{\perp}+\mathbf{v}_{\parallel},$$
where $\mathbf{v}_{\perp}$ lies in the orthogonal complement of the base (this is our height), i.e. $\mathbf{v}_{\perp}\cdot\mathbf{v}_{i}=0$ for $1\le i\le m$, and where $\mathbf{v}_{\parallel}\in\mathrm{span}\left\{ \mathbf{v}_{1},\ \cdots,\ \mathbf{v}_{m}\right\}$. Suppose that $$\mathbf{v}_{\parallel}=c_{1}\mathbf{v}_{1}+\cdots+c_{m}\mathbf{v}_{m}.$$ 
We apply a sequence of elementary row operations to $A$, adding a multiple $-c_{i}$ of row $i$ to row $m+1$ for each $1\le i\le m$. Write the resulting matrix as $B$, and we have
$$B=\begin{pmatrix}A_{m}\\
\mathbf{v}_{\perp}^{\mathrm{T}}
\end{pmatrix}=E_{m}\cdots E_{1}A,$$

where each $E_{i}$ is an elementary matrix adding a multiple of $i$ row to $m+1$ row.
\begin{equation}
    E_i =
    \begin{bmatrix}
        1 \\
        & 1 \\
        & & \ddots \\
        & -c_i & \cdots & 1
    \end{bmatrix}
\end{equation}
Notice that the above operation corresponds to shearing the parallelotope so that the last edge is perpendicular to the base. We see that these operations do not change the determinant as
$$\det\left(BB^{\mathrm{T}}\right)=\det\left(E_{m}\cdots E_{1}\left(AA^{\mathrm{T}}\right)E_{1}^{\mathrm{T}}\cdots E_{m}^{\mathrm{T}}\right)=\det\left(AA^{\mathrm{T}}\right).$$
 
Through block-multiplication, we get $BB^{\mathrm{T}}$ as
$$BB^{\mathrm{T}}=\begin{pmatrix}A_{m}\\
\mathbf{v}_{\perp}^{\mathrm{T}}
\end{pmatrix}\begin{pmatrix}A_{m}^{\mathrm{T}} & \mathbf{v}_{\perp}\end{pmatrix}=\begin{pmatrix}A_{m}A_{m}^{\mathrm{T}} & A_{m}\mathbf{v}_{\perp}\\
\mathbf{v}_{\perp}^{\mathrm{T}}A_{m}^{\mathrm{T}} & \mathbf{v}_{\perp}^{\mathrm{T}}\mathbf{v}_{\perp}
\end{pmatrix}=\begin{pmatrix}A_{m}A_{m}^{\mathrm{T}} & A_{m}\mathbf{v}_{\perp}\\
\left(A_{m}\mathbf{v}_{\perp}\right)^{\mathrm{T}} & \|\mathbf{v}_{\perp}\|^{2}
\end{pmatrix}.$$
 

Now notice that 
$$A_{m}\mathbf{v}_{\perp}=\begin{pmatrix}\mathbf{v}_{1}^{\mathrm{T}}\\
\vdots\\
\mathbf{v}_{m}^{\mathrm{T}}
\end{pmatrix}\mathbf{v}_{\perp}=\begin{pmatrix}\mathbf{v}_{1}\cdot\mathbf{v}_{\perp}\\
\vdots\\
\mathbf{v}_{m}\cdot\mathbf{v}_{\perp}
\end{pmatrix}=\mathbf{0}.$$
Therefore we have
$$BB^{\mathrm{T}}=\begin{pmatrix}A_{m}A_{m}^{\mathrm{T}} & \mathbf{0}\\
\mathbf{0}^{\mathrm{T}} & \|\mathbf{v}_{\perp}\|^{2}
\end{pmatrix}$$
 
Taking the determinant, we therefore have
$$\det\left(BB^{\mathrm{T}}\right)=\|\mathbf{v}_{\perp}\|^{2}\det\left(A_{m}A_{m}^{\mathrm{T}}\right).$$

By definition, $\|\mathbf{v}_{\perp}\|$ is the height of the parallelotope, and by the induction hypothesis, $\det\left(A_{m}A_{m}^{\mathrm{T}}\right)$ is the square of the base. Therefore the result follows. $\square$

As a corollary, we can easily verify that the volume is independent of which $n-1$ vectors you choose to define your base, as it should be.

**Corollary**: The volume of a parallelotope is invariant of which base and height you choose.

**Proof**: Choosing a different base and height corresponds to permuting the rows of the matrix $A$. This does not change the magnitude of the resulting determinant. $\square$

Finally, note that the singular values are the absolute values of $A$ are precisely the square roots of the eigenvalues of $AA^\mathrm{T}$. Since the product of the eigenvalues is the determinant, it follows that the product of the singular values of $A$ gives the square root of $\det(AA^\mathrm{T})$, which is precisely the volume.


```python

```

f8730b634a6938e4e2421ac250f03030a17e999d
ipynb
Jupyter Notebook
math/algebra/linear-algebra.ipynb
Naitreey/notes-and-knowledge
48603b2ad11c16d9430eb0293d845364ed40321c
BSD-3-Clause
2018-05-16T06:06:45.000Z
2021-05-12T08:46:18.000Z
math/algebra/linear-algebra.ipynb
Naitreey/notes-and-knowledge
48603b2ad11c16d9430eb0293d845364ed40321c
BSD-3-Clause
2018-04-06T01:46:22.000Z
2019-02-13T03:11:33.000Z
math/algebra/linear-algebra.ipynb
Naitreey/notes-and-knowledge
48603b2ad11c16d9430eb0293d845364ed40321c
BSD-3-Clause
2019-04-11T11:02:32.000Z
2020-06-27T11:59:09.000Z
Qwen/Qwen-72B
1. YES
2. YES