In the subpatch [pd fft] you have these multiplications inbetween [rfft~] and [rifft~]. Real and imaginary coefficients of the input signal's spectrum are multiplied by the values in table 'fft', which acts as an amplitude spectrum of a filter in that case. It really is what they call (zero phase) filtering via frequency domain, an equivalent of convolution in time domain. Filters can not add frequency components which were not in the signal originally, they can only amplify or attenuate existing components, that is, the non-zero real- and imaginary coefficients in this case. Any spectrum coefficient which is zero will remain zero after multiplication....

For inserting new spectral components you could use [+~] instead of [*~] there, for a start. Then you are really creating new spectrum coefficients which translate to signal domain as new frequency components, albeit with rough method. But it would be wise to first normalise the real and imaginary coefficients from [rfft~], then insert new coefficients at a level which is in accordance with the signal's spectrum itself (check with [scope~] for example, because [snapshot~] will only show the first value in each block which happens to be DC component here). You'd need to auto-erase values in array 'fft' after each new pitch detect.

One more remark: blocksize should be set to a power of two, as Slur mentioned, otherwise Pd will reduce blocksize to a power of two without notice and your fft array length does not match spectrumsize.

Happy to see you're still busy with it. Good luck!

Katja