cpp port of Spectrum.py