  In this work, inspired by the study of semidefinite programming for
block-diagonalizing matrix *-algebras, we propose an algorithm that can find
the algebraic structure of decoherence-free subspaces (DFS's) for a given noisy
quantum channel. We prove that this algorithm will work for all cases with
probability one, and it is more efficient than the algorithm proposed by
Holbrook, Kribs, and Laflamme [Quant. Inf. Proc. 80, 381 (2003)]. In fact, our
results reveal that this previous algorithm only works for special cases. As an
application, we discuss how this method can be applied to increase the
efficiency of an optimization procedure for finding an approximate DFS.
