Added printing support for initial and final matrix