MATLAB DFA program