I'm trying to understand how to make Sample rate change by a non integer factor say K=1.0012 In real hardware I will be using cubic polynomial but for now I have chosen a linear interpolator. I have calculated the Lagrange coefficients:
Let's simplify my case and assume that K=4/3 So Kinv = 1/K = 0.75
I cannot fugure out the condition when the new sample should be generated. As you can see in my picture the mu range is [-1:0]. So my guess is that as long as mu is in the range we use the input data valid, when mu is out of range - we must generate the new data valid?
mu must be computed like this: mu(n) = mu(n-1) + Kinv + ?
So my questions are
1)Is that correct assumption?
2)How to keep mu in range [-1:0]?
3)mu(0) = 0 or Kinv?
Thanks