This circuit can extract harmonics from various waveforms. With a sloped input waveform, the comparator produces a pulse
width that is proportional to a reference plus input amplitude. As the pulse width changes, the harmonics spectrum changes. Combining the two comparator outputs eliminates some harmonics, depending on the duty cycle. Adjusting the references can create virtually any harmonic. Al and A2 should be matched, Rl and R2 should be equal to 0.1%, and A3 should have good common-mode rejection and high slew rate.