Special Matrices

  1. A sparse matrix is a matrix that has a relatively large number of zero elements: elements whose value is equal to $0$ in it.
    • What "relatively large" means would depend on the algorithm. For instance, one algorithm would consider matrices with $70\%$ or more zero elements as sparse, while another would require $90\%$. This is called the sparsity threshold.
      • In our lecture notes (and HW and exams,) we set the sparsity threshold to $50\%$.
    • The sparsity ratio for a matrix $A_{n \times m}$ is the following number: $\text{sparsity}(A) =$$\; \frac{\text{number of zero elements}}{n \cdot m}$. For $A$ to be considered sparse in our course, the following must be true: $\text{sparsity}(A) \ge 0.5$.
    Examples of sparse matrices:

    26. $Q_3 = \begin{bmatrix} -19 & 0 & 0 \\ 0 & 2.2 & 0 \\ 0 & 0 & \frac{1}{2} \end{bmatrix}$

    6. $\begin{bmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 1 \end{bmatrix}$

    19. $Z_1 = \begin{bmatrix} 0 \end{bmatrix}$

    32. $M = \begin{bmatrix} 1 & 0 & 0 \\ 0 & 0 & 5 \end{bmatrix}$

    33. $N = \begin{bmatrix} 0 & 6 \\ 3 & 0 \\ 0 & 10 \end{bmatrix}$