Source: https://www.rle.mit.edu/dspg/documents/Generalized_528.pdf