Module 9:Combinational Circuit Test Pattern Generation

Lecture 2 and 3: D-Algorithm

Step 3: Determine/update gates in D-frontier and J-frontier, due to signal changes
from X to 0,1, D or . If there is no gate in D-frontier and D / has not reached any primary output, backtrack().
Step-4: If D / has not reached any primary output, propagate D / through one
 of the gates in the D-frontier.
Step-5: Use forward and backward implications to determine as many signal
values as possible. backtrack() in case of an inconsistency.
Step-6: If D / has reached any primary output and the primary inputs have
received values by backward implications, stop; the values of the primary inputs comprise the test pattern. Else, go to Step-3.

The module backtrack(), works as follows.
Step-1: Determine the last choice (of alternatives) taken in selection of gates in D-
frontier or signal values in forward/backward implications, where another new alternative is available. Take any one of the other alternative. If no choice is left, report non testable fault and return.  
Step-2: Undo all steps (i.e., propagation of D / and forward/backward
implications), from the current signal values to point where another
alternative is attempted. Return.

b. An example

The D-algorithm discussed above will now be illustrated using an example. Consider a simple circuit as shown in Figure 7(a). The circuit has a s-a-0 fault at the output of gate-1. Also as mentioned in Step-1 of the algorithm all nets have been initialized to X.


                Figure 7(a) Example of simple digital circuit with a s-a-0 fault
To sensitize the s-a-0 fault, 1 has to be applied in the corresponding net, thereby making signal of the net as D. Now J- frontier and D-frontier needs to be computed. As the output of gate 1 is known (as D) and its inputs are X, J-frontier is gate-1. Since one of the inputs of gate-2 and gate-3 are D, and the outputs are X, D-frontier is gate-2 and gate-3. This step is illustrated in Figure 7(b).

Figure 7(b): Sensitizing the fault location and computation of J- and D-frontier