I am currently working on a software implementation of matrices and vectors. (No, this isn't a programming related question!)
As far as I understand, vectors in $R_n$ can be described as a special case of matrices, where the width of the matrix is always $1$.
For using the vectors later on, I need to be able to calculate the length of a vector.
As far as I understand, the length of a vector with $n$ dimensions can be calculated with:
$$|\vec{v}| = \sqrt{v_1^2 + v_2^2 + ... + v_n^2}$$
Now I am asking myself if there is a generalization of this for matrices of any width and length, how it is called and how to calculate it, and what it would be used for.
What you call length of a vector is usually called its norm. And, yes, matrices have norms, too. For instance,$$\left\|\begin{pmatrix}a_{11}&\ldots&a_{nn}\\\vdots&\ddots&\vdots\\a_{n1}&\cdots&a_{nn}\end{pmatrix}\right\|=\sqrt{\sum_{i,j=1}^n{a_{ij}}^2}.$$