The present paper proposes a new method for detecting arbitrary faults in a functional circuit when the set of codewords is limited and known in advance. The method is based on implementation of the functional circuit by a plurality of separate independent sub-circuits. Each of such sub-circuits generates its own subset of output signals. Since the sub-circuits do not have common elements, any single fault may result in errors only in one of the subsets. The paper presents a solution of the problem of optimal partition of the set of output variables into independent subsets. A number of properties of partitions are proven. The proposed algorithms of the optimal partition are based on these properties. A scheme of the checker for the proposed self-checking approach is presented. Benchmarks’ results indicate efficiency of the described technique.