I have a piece of code that describes a recursive relationship to produce a logarithmic sweep:
StartFreq = 1;
EndFreq = 10;
SweepDuration = 100;
k = exp(ln(EndFreq/StartFreq)/SweepDuration);
freq(0) = StartFreq;
for (i=n;n<100;n++){
freq(n) = freq(n-1)*k;
}
I am trying to convert this recursive relationship into an algebraic expression $f(n)$. (Actually I wanted $f(t)$, in this case here we're sampling at 1Hz so the math kind of works out in this case.) I have other code snippets that are similar but I wanted to try to solve those myself. I just kind of wanted to get a walk through the process.