extremal set, giving a value δ(m) for the min-max error on the present extremal set. Interpolation: Calculate the error function E(ω) over the entire set of frequencies Ω using (2). Look for local maxima of |E(m)(ω)| on the set Ω. If max(ω∈Ω)|E(m)(ω)| > δ(m), then update the extremal set to {ωi(m+1)} by picking new frequencies where |E(m)(ω)| has its local maxima. Make sure that the error alternates on the ordered set of frequencies as described in (4) and (5). Return to Step 2 and iterate. If max(ω∈Ω)|E(m)(ω)| ≤ δ(m), then the algorithm is complete. Use the set {ωi(0)} and the interpolation formula to compute an inverse discrete Fourier transform to obtain the filter coefficients. The Parks–McClellan Algorithm may be restated as the following steps: Make an initial guess of the L+2 extremal frequencies. Compute δ using the equation given. Using Lagrange Interpolation, we compute the dense set of samples of A(ω) over the passband and stopband. Determine the new L+2 largest extrema. If the alternation theorem is not satisfied, then we go back to (2) and iterate until the alternation theorem is satisfied. If the alternation theorem is satisfied, then we compute h(n) and we are done. To gain a basic understanding of the Parks–McClellan Algorithm mentioned above, we can rewrite the algorithm above in a simpler form as: Guess the positions of the extrema are evenly spaced in the pass and stop band. Perform polynomial interpolation and re-estimate positions of the local extrema. Move extrema to new positions and iterate until the extrema stop shifting. Explanation The picture above on the right displays the various extremal frequencies for the plot shown. The extremal frequencies are the maximum and minimum points in the stop and pass bands. The stop band ripple is the lower portion of ripples on the bottom right of the plot and the pass band ripple is the upper portion of the ripples on the top left of the plot. The dashed lines going across the plot indicate the δ or maximum error. Given the positions of the extremal frequencies, there is a formula for the optimum δ or optimum error. Since we do not know the optimum δ or the exact positions of the extrema on the first attempt, we iterate. Effectively, we assume the positions of the extrema initially, and calculate δ. We then re-estimate and move the extrema and recalculate δ, or the error.