Hacker News new | ask | show | jobs
by nayuki 439 days ago
> if you needed to exceed 50%, you could have just combined two different square waves

I don't think this is possible. A balanced square wave has no even harmonics in the frequency domain. Anytime the duty cycle is not 0%, 50%, or 100%, you will have non-zero even harmonics.

A linear combination (scaled sum or difference) of two balanced square waves will necessarily still have all even harmonics at zero, and thus cannot emulate a square wave with a duty cycle different from 50%.

1 comments

> Anytime the duty cycle is not 0%, 50%, or 100%, you will have non-zero even harmonics.

The article is specifically trying to achieve those harmonics. This is the initial problem.

> A linear combination (scaled sum or difference) of two balanced square waves will necessarily still have all even harmonics at zero

Yea, that's why you need the phase offset, as I mentioned.

> and thus cannot emulate a square wave with a duty cycle different from 50%.

You can /synthesize/ a square wave at any duty cycle you like. We're still doing Fourier just without the whole transform.