Refactored Matrix