New methods added to matrix class