Skip to main content
Bumped by Community user
added 42 characters in body
Source Link
Jdip
  • 6.8k
  • 3
  • 8
  • 31

I'm trying to understand how to make Sample rate change by a non integer factor say K=1.0012$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: Linear interpolator, Farrow implementation

Let's simplify my case and assume that K=4/3$K=\frac{4}{3}$ So Kinv = 1/K = 0.75$K_{inv} = \frac{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$\mu$ range is [-1:0]. So my guess is that as long as mu$\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$\mu$ must be computed like this: mu(n) = mu(n-1) + Kinv + ?$$\mu(n) = \mu(n-1) + K_{inv} + ?$$

So my questions are

1)Is that correct assumption?

2)How to keep mu$\mu$ in range [-1:0]?

3)mu(0) = 0$\mu(0) = 0$ or Kinv$K_{inv}$?

Thanks

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: Linear interpolator, Farrow implementation

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

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: Linear interpolator, Farrow implementation

Let's simplify my case and assume that $K=\frac{4}{3}$ So $K_{inv} = \frac{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) + K_{inv} + ?$$

So my questions are

1)Is that correct assumption?

2)How to keep $\mu$ in range [-1:0]?

3)$\mu(0) = 0$ or $K_{inv}$?

Thanks

Source Link
dcs
  • 45
  • 5

Sample rate change using Lagrange interpolator

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: Linear interpolator, Farrow implementation

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