Algebra common utilities
diageye
ReactiveMP.diageye
— Functiondiageye(::Type{T}, n::Int)
An alias for the Matrix{T}(I, n, n)
. Returns a matrix of size n x n
with ones (of type T
) on the diagonal and zeros everywhere else.
diageye(n::Int)
An alias for the Matrix{Float64}(I, n, n)
. Returns a matrix of size n x n
with ones (of type Float64
) on the diagonal and zeros everywhere else.