Skip to content

num::eye

Defined in header <linear/matrix_utils.hpp>

mat<real> eye(idx size);  // (1)

mat<real> eye(idx rows, idx cols);  // (2)

(1) Construct an n x n identity matrix.

(2) Construct an n x m identity-like matrix.