Added new methods to Matrix classes