Reply by robert bristow-johnson●April 6, 20122012-04-06
On 4/2/12 9:39 PM, mishrask wrote:
> This is not a public document but still I will try to put as much
> details as i can here .But my focus was on something else ..I have to
> implement it in hardware (Verilog,it's part of an ASIC).
sounds like you will want to minimize the number of coefficients. do
you have MIPS to burn with your ASIC? (probably not.)
> I request you and
> others also to please try to answer my ignored Qs ----
i sorta ignore Qs that i dunno what they mean. thems are hard questions.
> "and one more question --- can someone please elaborate on the clock
> requirements in a sample rate converter with a suitable example [sampling
> rate and clock rates say for SRC by factor of 1.3564]
are you asking how to derive the output clock, given an input clock and
an SRC ratio? you need to have a very high frequency constant clock
that you can divide off of with a counter.
if it's an ASRC ("A" for "asynchronous"), then you are given two clocks,
one for the input samples and one for the output and you have to derive
the SRC ratio from that. this requires a servo-control mechanism like
we learned in our control systems classes besides some other techniques.
> (I didn't get any
> reference about this ,so please give if you know.The books I have referred
> to are dsp books and they don't at all talk about the clock rates) ....
> Lets' say I have a single clock in my design ,then do I need to divide
> the clock and use different clocks for i/p and o/p (in this case how to go
> about for like SRC by 1.765 factor)...or some other way is there ."
you still need to decide how you're getting that 1.765 factor. from two
different clocks? or is that a constant parameter, and you need to
derive an output clock from that parameter (and the input clock)?
can't help you much more without this getting thought out (by you).
--
r b-j rbj@audioimagination.com
"Imagination is more important than knowledge."
Reply by robert bristow-johnson●April 6, 20122012-04-06
On 4/2/12 11:00 PM, Randy Yates wrote:
> robert bristow-johnson<rbj@audioimagination.com> writes:
>> [...]
>
> Thanks for that Robert. Truly.
yer welcome Randy. i was hoping that Bob Adams (who sometimes visits
these parts) might see his name in the subject header and pipe in on
this. i really don't know fer sure what he did with coefficients, but i
seem to remember he had 64-tap polyphase FIRs in the AD1890. how many
phases he used, i dunno. i usually say you need 512 phases if you
linearly interpolate and 512K phases if you don't interpolate at all (to
get 130 dB S/N).
--
r b-j rbj@audioimagination.com
"Imagination is more important than knowledge."
Reply by robert bristow-johnson●April 6, 20122012-04-06
On 4/5/12 7:42 PM, Eric Jacobsen wrote:
> On Thu, 05 Apr 2012 18:02:37 -0500, Randy Yates
> <yates@digitalsignallabs.com> wrote:
>
>> Jerry Avins<jya@ieee.org> writes:
>>
>>> On 4/4/2012 3:21 PM, Randy Yates wrote:
>>>> Rick Lyons<R.Lyons@_BOGUS_ieee.org> writes:
>>>>
>>>>> On Sun, 01 Apr 2012 23:28:00 -0500, Randy Yates
>>>>> <yates@digitalsignallabs.com> wrote:
>>>>>
>>>>> [Snipped by Lyons]
>>>>>>
>>>>>> So we now have 5 terms on the table:
>>>>>>
>>>>>> interpolation
>>>>>> resampling
>>>>>> sample rate conversion
>>>>>> upsampling
>>>>>> reconstruction
>>>>>>
>>>>>
>>>>> I haven't carefully followed the details of this
>>>>> thread, but I'll support you in saying that the
>>>>> terminology of "sample rate change" has caused troubles
>>>>> for both practitioners and readers. So many words,
>>>>> terms, mean one thing to one person and another
>>>>> thing to another person. Because of this confusion
>>>>> and misunderstandings abound.
>>>>
>>>> Ayup. I still feel a bit uneasy when I try to discern the difference
>>>> between "upsampler" and "interpolator." Isn't upsampling by M just
>>>> inserting M-1 zeros between samples? And yet we throw it around
>>>> as if it were synonymous with "interpolator." (Or at least I do...)
>>>
>>> I'd be willing to wager that it's only part of what you do.
i'm with Jerry. equating zero-stuffing with "upsampling" is, in my
intolerant opinion, a misuse of semantic. zero-stuffing is really just
a conceptual step. nobody actually does that. (you could if you were
using an IIR LPF for reconstruction, but any efficient code would not do
that. you would send the IIR one sample, then you would just let the
feedback portion of the IIR do its thing for N-1 more samples assuming
zero input.)
>>
>> You're making my (and I think Rick's) point. What is the definition of
>> "upsample?" In Rick's third edition , he defines it as simply the
>> zero insertion step (i.e., without filtering). The old chestnut
>> "Multirate Digital Signal Processing" (Crochiere and Rabiner) calls
>> it "sample rate expansion." Etc., etc., etc.
>>
>> I see Eric's point about talking it out, but can't we have the
>> best of both worlds? Define them AND talk about it?!?
>
> I think not practically, because there's no central authority to
> define it and too many people use the terms differently. In other
> words, I don't see how it can happen practically.
>
for me, it's like the meaning of "Nyquist frequency". even though it is
not used by everyone, there really is only one correct definition.
how'zat for tossing fuel on the flame?
the constant reference here is the bandlimited signal, x(t), that is
adequately represented by the original samples, x[n]:
+inf
x(t) = SUM{ x[n] * sinc(t-n) }
n=-inf
that's different from saying that it's the samples themselves (which is
what the zero-stuffing meaning of "upsampling" says).
"upsampling", "downsampling", "resampling", "sample rate conversion" are
about the same thing that you do to those original samples. samples go
in and samples come out. "downsampling" might imply low-pass filtering
or suffering the consequences of aliasing. "decimation" is simply
picking out 1 sample out of every N.
"reconstruction" or "interpolation" means discrete samples, x[n], going
in and continuous-time signal, y(t), coming out. because
"interpolation" had meaning before digital signal processing existed, i
might grant that the word means a particular kind of reconstruction that
implies the c.t. signal goes through the original sample points. more
general practical reconstruction would not necessarily do that. i
think, for linear reconstruction, that "interpolation" with that extra
meaning would imply that your reconstruction impulse response has to be
some kinda windowed sinc(). and Lagrange and Hermite polynomial
interpolation can be put into a form of a windowed sinc().
another application of all this (besides SRC) is a precision delay for
whatever reason:
y(t - tau) tau > 0
where
y(t) = x(t) + error
+inf
= SUM{ x[m] * h(t-m) }
m=-inf
if h(t) has finite length (as it does for polyphase FIR), then that
summation is finite. the output of the precision delay is
y[n] = y(n-tau) = SUM{ x[n-m] * h(tau+m) }
with whatever finite limits on the summation.
(lot'sa fun making comb filters outa a precision delay.)
so then you still have the windowed-sinc() vs. more general
reconstruction issues underneath, but it's one thing to resample at the
same rate a reconstructed signal (but at a precisely delayed time) and
it's another thing to resample that at a different rate (which is SRC).
for the former, it's just a filter and you don't get aliasing noise,
but the variation of phase linearity and amplitude may be issues to
quantify if your delay is slowly modulated. for the latter (SRC), then
the precision delay is wildly modulated all over the place and you have
to model what's going on differently to quantify how well it's working.
when i think of it, i want to quantify how well beaten down the images
are and i assume they are all folded back into the passband.
i'm just saying this to spell out where i might use the terms
"reconstruction" and "interpolation" in a context other than sample rate
conversion. but those are about the only two broad applications i'm
aware of about the whole Nyquist/Shannon bandlimited interpolation
filtering polyphase resampling thing. (any other buzzwords to toss at it?)
--
r b-j rbj@audioimagination.com
"Imagination is more important than knowledge."
Reply by Eric Jacobsen●April 5, 20122012-04-05
On Thu, 05 Apr 2012 18:02:37 -0500, Randy Yates
<yates@digitalsignallabs.com> wrote:
>Jerry Avins <jya@ieee.org> writes:
>
>> On 4/4/2012 3:21 PM, Randy Yates wrote:
>>> Rick Lyons<R.Lyons@_BOGUS_ieee.org> writes:
>>>
>>>> On Sun, 01 Apr 2012 23:28:00 -0500, Randy Yates
>>>> <yates@digitalsignallabs.com> wrote:
>>>>
>>>> [Snipped by Lyons]
>>>>>
>>>>> So we now have 5 terms on the table:
>>>>>
>>>>> interpolation
>>>>> resampling
>>>>> sample rate conversion
>>>>> upsampling
>>>>> reconstruction
>>>>>
>>>>
>>>> Hi Randy,
>>>> I haven't carefully followed the details of this
>>>> thread, but I'll support you in saying that the
>>>> terminology of "sample rate change" has caused troubles
>>>> for both practitioners and readers. So many words,
>>>> terms, mean one thing to one person and another
>>>> thing to another person. Because of this confusion
>>>> and misunderstandings abound.
>>>
>>> Hey Rick,
>>>
>>> Ayup. I still feel a bit uneasy when I try to discern the difference
>>> between "upsampler" and "interpolator." Isn't upsampling by M just
>>> inserting M-1 zeros between samples? And yet we throw it around
>>> as if it were synonymous with "interpolator." (Or at least I do...)
>>
>> I'd be willing to wager that it's only part of what you do.
>
>Hi Jerry,
>
>You're making my (and I think Rick's) point. What is the definition of
>"upsample?" In Rick's third edition , he defines it as simply the
>zero insertion step (i.e., without filtering). The old chestnut
>"Multirate Digital Signal Processing" (Crochiere and Rabiner) calls
>it "sample rate expansion." Etc., etc., etc.
>
>I see Eric's point about talking it out, but can't we have the
>best of both worlds? Define them AND talk about it?!?
I think not practically, because there's no central authority to
define it and too many people use the terms differently. In other
words, I don't see how it can happen practically.
Eric Jacobsen
Anchor Hill Communications
www.anchorhill.com
Reply by Randy Yates●April 5, 20122012-04-05
Jerry Avins <jya@ieee.org> writes:
> On 4/4/2012 3:21 PM, Randy Yates wrote:
>> Rick Lyons<R.Lyons@_BOGUS_ieee.org> writes:
>>
>>> On Sun, 01 Apr 2012 23:28:00 -0500, Randy Yates
>>> <yates@digitalsignallabs.com> wrote:
>>>
>>> [Snipped by Lyons]
>>>>
>>>> So we now have 5 terms on the table:
>>>>
>>>> interpolation
>>>> resampling
>>>> sample rate conversion
>>>> upsampling
>>>> reconstruction
>>>>
>>>
>>> Hi Randy,
>>> I haven't carefully followed the details of this
>>> thread, but I'll support you in saying that the
>>> terminology of "sample rate change" has caused troubles
>>> for both practitioners and readers. So many words,
>>> terms, mean one thing to one person and another
>>> thing to another person. Because of this confusion
>>> and misunderstandings abound.
>>
>> Hey Rick,
>>
>> Ayup. I still feel a bit uneasy when I try to discern the difference
>> between "upsampler" and "interpolator." Isn't upsampling by M just
>> inserting M-1 zeros between samples? And yet we throw it around
>> as if it were synonymous with "interpolator." (Or at least I do...)
>
> I'd be willing to wager that it's only part of what you do.
Hi Jerry,
You're making my (and I think Rick's) point. What is the definition of
"upsample?" In Rick's third edition , he defines it as simply the
zero insertion step (i.e., without filtering). The old chestnut
"Multirate Digital Signal Processing" (Crochiere and Rabiner) calls
it "sample rate expansion." Etc., etc., etc.
I see Eric's point about talking it out, but can't we have the
best of both worlds? Define them AND talk about it?!?
--Randy
--
Randy Yates
DSP/Firmware Engineer
919-577-9882 (H)
919-720-2916 (C)
Reply by Jerry Avins●April 5, 20122012-04-05
On 4/4/2012 3:21 PM, Randy Yates wrote:
> Rick Lyons<R.Lyons@_BOGUS_ieee.org> writes:
>
>> On Sun, 01 Apr 2012 23:28:00 -0500, Randy Yates
>> <yates@digitalsignallabs.com> wrote:
>>
>> [Snipped by Lyons]
>>>
>>> So we now have 5 terms on the table:
>>>
>>> interpolation
>>> resampling
>>> sample rate conversion
>>> upsampling
>>> reconstruction
>>>
>>
>> Hi Randy,
>> I haven't carefully followed the details of this
>> thread, but I'll support you in saying that the
>> terminology of "sample rate change" has caused troubles
>> for both practitioners and readers. So many words,
>> terms, mean one thing to one person and another
>> thing to another person. Because of this confusion
>> and misunderstandings abound.
>
> Hey Rick,
>
> Ayup. I still feel a bit uneasy when I try to discern the difference
> between "upsampler" and "interpolator." Isn't upsampling by M just
> inserting M-1 zeros between samples? And yet we throw it around
> as if it were synonymous with "interpolator." (Or at least I do...)
I'd be willing to wager that it's only part of what you do. First you
insert the zeros, but I can't imagine that you leave it at that. Don't
you filter afterward? The filter interpolates for sure. Have you ever
checked that it doesn't alter the original sample?
Jerry
--
Engineering is the art of making what you want from things you can get.
�����������������������������������������������������������������������
Reply by Eric Jacobsen●April 4, 20122012-04-04
On Wed, 04 Apr 2012 14:21:06 -0500, Randy Yates
<yates@digitalsignallabs.com> wrote:
>Rick Lyons <R.Lyons@_BOGUS_ieee.org> writes:
>
>> On Sun, 01 Apr 2012 23:28:00 -0500, Randy Yates
>> <yates@digitalsignallabs.com> wrote:
>>
>> [Snipped by Lyons]
>>>
>>>So we now have 5 terms on the table:
>>>
>>> interpolation
>>> resampling
>>> sample rate conversion
>>> upsampling
>>> reconstruction
>>>
>>
>> Hi Randy,
>> I haven't carefully followed the details of this
>> thread, but I'll support you in saying that the
>> terminology of "sample rate change" has caused troubles
>> for both practitioners and readers. So many words,
>> terms, mean one thing to one person and another
>> thing to another person. Because of this confusion
>> and misunderstandings abound.
>
>Hey Rick,
>
>Ayup. I still feel a bit uneasy when I try to discern the difference
>between "upsampler" and "interpolator." Isn't upsampling by M just
>inserting M-1 zeros between samples? And yet we throw it around
>as if it were synonymous with "interpolator." (Or at least I do...)
>--
>Randy Yates
>DSP/Firmware Engineer
>919-577-9882 (H)
>919-720-2916 (C)
It's also been discussed here previously that a decimator can
"interpolate", too, if the output samples are between input samples,
which is a very practical case (e.g., an even number of taps in a
symmetric decimating FIR filter).
Personally, I kind of like that the industry is not super-anal and/or
legalistic about terminology, as it encourages people to talk about
concepts just to ensure clarity.
Eric Jacobsen
Anchor Hill Communications
www.anchorhill.com
Reply by Randy Yates●April 4, 20122012-04-04
Rick Lyons <R.Lyons@_BOGUS_ieee.org> writes:
> On Sun, 01 Apr 2012 23:28:00 -0500, Randy Yates
> <yates@digitalsignallabs.com> wrote:
>
> [Snipped by Lyons]
>>
>>So we now have 5 terms on the table:
>>
>> interpolation
>> resampling
>> sample rate conversion
>> upsampling
>> reconstruction
>>
>
> Hi Randy,
> I haven't carefully followed the details of this
> thread, but I'll support you in saying that the
> terminology of "sample rate change" has caused troubles
> for both practitioners and readers. So many words,
> terms, mean one thing to one person and another
> thing to another person. Because of this confusion
> and misunderstandings abound.
Hey Rick,
Ayup. I still feel a bit uneasy when I try to discern the difference
between "upsampler" and "interpolator." Isn't upsampling by M just
inserting M-1 zeros between samples? And yet we throw it around
as if it were synonymous with "interpolator." (Or at least I do...)
--
Randy Yates
DSP/Firmware Engineer
919-577-9882 (H)
919-720-2916 (C)
Reply by Rick Lyons●April 3, 20122012-04-03
On Sun, 01 Apr 2012 23:28:00 -0500, Randy Yates
<yates@digitalsignallabs.com> wrote:
[Snipped by Lyons]
>
>So we now have 5 terms on the table:
>
> interpolation
> resampling
> sample rate conversion
> upsampling
> reconstruction
>
Hi Randy,
I haven't carefully followed the details of this
thread, but I'll support you in saying that the
terminology of "sample rate change" has caused troubles
for both practitioners and readers. So many words,
terms, mean one thing to one person and another
thing to another person. Because of this confusion
and misunderstandings abound.
[-Rick-]
Reply by Randy Yates●April 3, 20122012-04-03
robert bristow-johnson <rbj@audioimagination.com> writes:
> [...]
Thanks for that Robert. Truly.
I had not seen that the 2n + 1 trick results in symmetry. And I do agree
that PM or FIRLS is going to give you a better stopband response than
windowed-sinc for a given filter length. In fact I should be correcting
our system engineers' filters (which are <guess what?> windowed sincs),
but I'm so busy cranking out code I don't have time!
So it appears that I must retract my blanket assertion to mishrask -
there are common cases where all 64 phases are interpolated for a x64
upsampler.
--
Randy Yates
DSP/Firmware Engineer
919-577-9882 (H)
919-720-2916 (C)