Construct a new slice with ones along a diagonal and zeroes elsewhere of element
type E.
The diagonal is set through the interaction of dimension and k. k
determines the offset of the diagonal and dimension controls the dimension
of that this offset proceeds in. For instance, if dimension = 1 and k = 1,
then the diagonal after the first column is what is filled with ones.
Construct a new slice with ones along a diagonal and zeroes elsewhere of element type E.
The diagonal is set through the interaction of dimension and k. k determines the offset of the diagonal and dimension controls the dimension of that this offset proceeds in. For instance, if dimension = 1 and k = 1, then the diagonal after the first column is what is filled with ones.