Matrix.Expand($M$, $n$, $x$) takes a quadratic matrix $M$ and adds diagonal entries with value $x$ to it until it is of size $n \times n$. If $x$ is not given in the input it is set to $1$.
Has yet to be written.
-- some example code
text produced as output