added to_mono function and fixed spctrum