In linear algebra, the identity matrix of size n {\displaystyle n} is the n × n {\displaystyle n\times n} square matrix with ones on the main diagonal and zeros elsewhere. It has unique properties, for example when the identity matrix represents a geometric transformation, the object remains unchanged by the transformation. In other contexts, it is analogous to multiplying by the number 1.