Modified unitary_matrix method to calculate matrix for both normal and resolved circuit