I’m not sure how to phrase this question so i’ll just give an example.
We all know if you want to change the pitch of a signal, you can iterate through it’s buffer at a different speed than the sampling rate, effectively resampling the signal, to make it’s pitch change.
If you wanted to increase the pitch by 12 semitone up, you’d iterate through the buffer by +2 samples per tick. And if you wanted to play back normal speed, +1 samples per tick. Octave down? 0.5 samples per tick.
Is there an equation that returns this value, for example, if you passed in 0, it would return 1, if you passed in 12, it would return +2, -12 would return 0.5, and +3 would return the float value you should move per tick to change the signal three semitone up.
I know this function exists but i’m not sure what it’s called or what to search for it 0.o
Thank you for any responses !