Jump to content
IGNORED

Time resolution of digital sampling


Don Hills

Recommended Posts

I'm glad you continue to edit the posts above. The first versions of a couple were gobbledegook. But I have no interest in sifting through what you come up with. You're still learning... on display for everyone. And so far I've not seen a lot of progress.

I'm not interested in flying in your plane while you learn.

24 minutes ago, manueljenkin said:

Only for steady state signals. Transients are much worse, and you can enter aliasing/modulation territory.

No matter how many times you repeat something that's incorrect, it remains incorrect... like multiple passes of a sinc filter!

 

It might help if you created a sig stating you're learning this stuff (which is admirable), but that your "statements" need review.

Link to comment
2 hours ago, SoundAndMotion said:

Where was the result of multiplication with ft of sinc function? 🤔 That was the context of my question.

 

2 hours ago, SoundAndMotion said:

I'm glad you continue to edit the posts above. The first versions of a couple were gobbledegook. But I have no interest in sifting through what you come up with. You're still learning... on display for everyone. And so far I've not seen a lot of progress.

I'm not interested in flying in your plane while you learn.

No matter how many times you repeat something that's incorrect, it remains incorrect... like multiple passes of a sinc filter!

 

It might help if you created a sig stating you're learning this stuff (which is admirable), but that your "statements" need review.

Ahaha. That's a clever way to try to escape. Throwing tags, I've seen that before, your last escape resort. You know what? There's set of people whose brain is faster than their hands, so things don't flow well enough when they write. That's the reason for edits, not misunderstandings. This is not bragging, this is just a procedure of working for few people. There are instances where precision in the first shot is needed, like an exam or assignment, and I do take my sweet time there, but that's not a prime necessity here, so I do go with the flow. After all, this place is meant for our "hobbies".

 

My response gets edits even when I reply to Peter in a normal way, or when I write a review or when I try to describe a sound. English isn't my first language neither is signal processing my first subject of study, I am not accustomed to the "terminology", doesn't mean the concept is wrong. I just take my sweet share of edits to convey the context clearer. If you can't follow it, I can't help it. There are others here who could. I did mention that one instance where I deviated from what I had in mind (I'm human after all, nothing gets stored with infinite precision 😉), and I have linked the correct reference just below there.

 

Either way, this is a clear indication that what I've said is right, and you're just trying to escape. That's when people throw these cowardly escape gestures or subtle personal attacks. Trying to tell someone is lacking knowledge. I've seen that earlier in the first few pages of the thread, and now.  I know that's your secret weapon, have seen it in multiple places, and you comfortably try to disguise it in the name of "help", which I wasn't really asking for. When I expose your hypocrisy, you throw up a tantrum! You keep beating around the random optimistic instance demonstration without really proving the true scenario. I've shown what it is. Now go ahead and do the result of the above!! Let's see how you can "bandlimit" real transients!

 

Note: this comment too was edited multiple times!

Link to comment
4 hours ago, manueljenkin said:

The best way to think of transients would be to use any periodic signal (steady state) and convolve it over a heaviside (or unit step) function. For better visualization, delay the heaviside function by maybe some x seconds.

 

First lets take some periodic function, say a sine of 5khz. Find it's ft (Fourier transform). Now let's take ft of the sinc low pass. It is a rectangular function between -w0 and +w0. Multiply the two functions take ift and see, and you'll get back the original fft of 5khz since since it is completely band limited. Taking ift will return back the 5khz function. If there was a phase shift it'll be present in ft of 5khz and that shall also be retrieved effectively.

 

Now let's keep that periodic signal aside, and analyse the heaviside function and the low pass, because that's where the transients lie. Take ft of heaviside function (I don't know how you'd do this though), multiply with ft of sinc function. Now things break loose. If I multiply this with ft of sine, only at time = + infinity would my output be sine of the same amplitude again. If doing in frequency domain is hard, just try convolving with sinc. Convolution of sinc over heaviside function will ring to -infinity time.

 

3 hours ago, manueljenkin said:

Try looking at how the time instance where heaviside function steps up behaves after convolving with sinc. Check if it is still within band limits around these areas. 😁. You'll get your answer to why Nyquist-Shannon sampling isn't optimal for transient instances. And definitely not that super optimistic timing precision formula which works only when I have a repeating cycle of steady state signals (paragraph 2). The time precision for such steady state signals is actually infinite, only the bit depth is limiting it there. But sadly only for steady state truly periodic signals, not for real sounds. It is much worser and you just get modulations instead generally (paragraph 3). Granted heaviside function is the best showcase of transients, and real world transients might be somewhat slower (but definitely not within 20khz limits).

 

Also note, for the heaviside function, why it doesn't have a unique "frequency". If I window it just before and after the transition, it's frequency would be shown as infinite because within 0 time there is a transistion. If I increase my window size the frequency visualized would keep reducing. There is only one instance, not a periodically repeating signal, so it doesn't have a unique "frequency" for it. It's a transient, that's how it be treated. It's not quite the same as impulse either. Impulse is a limit time tending to 0 condition of a rectangular pulse (amplitude tends to move up, to get the product finite, so it's not even directly relatable to a rectangular pulse 😅). These functions return back to 0. Heaviside function doesn't, it stays up.

@pkane2001heres your answer.

 

Tl;dr,  Multiply the fft of heaviside function with fft of a sinc filter and see how it behaves in the transition point of the heaviside function. You can also do it by convolving them in time domain. See if it is really "Bandlimited".

 

Also another correction. I never said "static" and "dynamic". I was only talking about "transients", vs "steady state".

Link to comment
14 hours ago, manueljenkin said:

In simpler words only a truly perodic function has an absolute frequency. And that would automatically imply only periodic signals in steady state condition. Any transient change from earlier cyclic flow would mean it's no longer truly periodic, and the point of disruption would be the most deviated. For anything else, your visualization of frequency vs time domain interpretations will clash into each other in terms of compromises.

 

Something I want to stress, don't get confused by looking at the leading edge of an infinite time periodic square wave thiking it conveys transients. You should look at the start of the pulse from inertial condition to truly analyse transients, meaning you should have it begin at 0 time or +ve time and analyse it's behavior at this time after applying a low pass. It doesn't even need to be a square, you can even have a 5khz sinusoid begining after say 5s, apply a sinc low pass, at say, 20khz and see the behavior around this 5s instance. Transient is a change of state, a change of flow : https://en.m.wikipedia.org/wiki/Transient_(oscillation) . Those squares (band limited or not) that repeat themselves for infinite time have a consistent flow.

This is what I mean by transients, more specifically paragraph 2.

Link to comment
9 minutes ago, manueljenkin said:

This is what I mean by transients, more specifically paragraph 2.

Point spread functions might oscillate somewhat nonetheless the deconvolution is quite effective at recovering the original signal when performed in the Fourier domain. https://en.wikipedia.org/wiki/Point_spread_function  https://en.wikipedia.org/wiki/Deconvolution

Custom room treatments for headphone users.

Link to comment
10 minutes ago, jabbr said:

Point spread functions might oscillate somewhat nonetheless the deconvolution is quite effective at recovering the original signal when performed in the Fourier domain. https://en.wikipedia.org/wiki/Point_spread_function  https://en.wikipedia.org/wiki/Deconvolution

The deconvolution would work if the artefact is mere noise or just the blur effect due to low pass or anything very predictable. But in case of 10us or so delayed echo in transient scenario, when sampled at 44.1khz we have more complex problems (modulation) than just noise and blur effect. Not easy to model/predict the scenarios. I guess it could be fairly effective if we can up the sample rate to say 96khz or better 192khz.

Link to comment
1 hour ago, manueljenkin said:

 

@pkane2001heres your answer.

 

Tl;dr,  Multiply the fft of heaviside function with fft of a sinc filter and see how it behaves in the transition point of the heaviside function. You can also do it by convolving them in time domain. See if it is really "Bandlimited".

 

Also another correction. I never said "static" and "dynamic". I was only talking about "transients", vs "steady state".

 

You did in our earlier conversation, so I assumed you are still talking about the same thing. Forgive me, I didn't understand it then, and still don't understand it now.

 

image.png.be1f518eb893b93725a0395095d7b6a8.png

 

I'm still not sure what a transient vs. steady state means. Is transient a Heaviside function or a Dirac pulse? A mathematical function doesn't need to be bandlimited. But how is this related to audio, where signal is always bandlimited, where infinite slope functions do not exist?

Link to comment
30 minutes ago, pkane2001 said:

 

You did in our earlier conversation, so I assumed you are still talking about the same thing. Forgive me, I didn't understand it then, and still don't understand it now.

 

image.png.be1f518eb893b93725a0395095d7b6a8.png

 

I'm still not sure what a transient vs. steady state means. Is transient a Heaviside function or a Dirac pulse? A mathematical function doesn't need to be bandlimited. But how is this related to audio, where signal is always bandlimited, where infinite slope functions do not exist?

Well I'm saying the very act of bandlimiting the signal to 22khz is cutting off transients. The transients may not be as abrupt as heaviside function, but there is no guarantee it is naturally Bandlimited to 22khz, I certainly haven't seen any studies that prove it. And for benefit of doubt it can always be wise to see how the heaviside function response is, until we can get a real defined bound. Just because our hearing system doesn't "oscillate" at more than 20khz doesn't mean an impulse containing a faster transient can't be perceived. Oscillation and transient response are not the same.

 

Transient response is just the property exhibited by the system during the time from inertia to steady state. If you have worked with Laplace transforms, steady state is when the e^(-st)'ish terms decay to zero, or in practical situations, we take it when it could be approximated to zero. It generally is taken at 5 times the time constant when the transient components are less than 1% as compared to initial stage (e^-5 nearly equals 0.0673).

 

Edit: now I remember the old conversation. I used static and dynamic to describe the property of the tone. Dynamic is "having variations", static is just being bare minimum without variations. A song with variations in tone, amplitude etc is dynamic, a constant c note at fixed amplitude in a flute is static in comparison. The steady state and transients I'm describing are property of the system response to an input stimuli. The terms are a little "related" but not quite the same, and not often usable interchangeably.

Link to comment
2 hours ago, manueljenkin said:

Well I'm saying the very act of bandlimiting the signal to 22khz is cutting off transients. The transients may not be as abrupt as heaviside function, but there is no guarantee it is naturally Bandlimited to 22khz, I certainly haven't seen any studies that prove it. 

 

That's correct, and I wouldn't think you need a study to show that. There are plenty of natural and artificial sounds that have frequencies well above 22kHz. But there are also plenty of studies that show humans can't hear much above 20kHz, and this also gets significantly worse with age. So, even if we are missing some components of the Heaviside function in the recording above 22kHz, is this really significant for audio reproduction (for humans)?

 

2 hours ago, manueljenkin said:

Transient response is just the property exhibited by the system during the time from inertia to steady state. If you have worked with Laplace transforms, steady state is when the e^(-st)'ish terms decay to zero, or in practical situations, we take it when it could be approximated to zero. It generally is taken at 5 times the time constant when the transient components are less than 1% as compared to initial stage (e^-5 nearly equals 0.0673).

 

OK, but what is the significance of this? Nothing in the real world has a 0 time transition from one state to another, except maybe at the quantum entanglement level :) A transient response, a transition from state A to state B over time t is just part of a naturally band-limited signal that is just as much subject to the sampling theorem and Fourier analysis as any other. 

Link to comment

Hi Paul, it looks like you just don't want to read it. And you don't want to see (through) the real-life plots either ?

 

46 minutes ago, pkane2001 said:

Nothing in the real world has a 0 time transition from one state to another

 

Not correct. Synthesizers can and they do (and don't let an ADC loose on them or else you are correct 🤪).

 

46 minutes ago, pkane2001 said:

A transient response, a transition from state A to state B over time t is just part of a naturally band-limited signal that is just as much subject to the sampling theorem and Fourier analysis as any other.

 

Why ? just because you think so ? Can you prove it ? I won't repeat all the posts and plots again about the opposite (I already did it twice). Btw, I don't think you did not read them (you were here all the time). You just seem to ignore what I show.

(I know, my English 🤫)

 

46 minutes ago, pkane2001 said:

A transient response, a transition from state A to state B over time

 

Why do you call that a state ? There is no such thing as a state or changing state etc. There's a steep rise (or drop) of level. I am afraid you miss the point somewhere. Maybe investigate "Steady State" better ? I am not sure. But it is the opposite of a state of a signal as what you seem to refer to (again, I am guessing).

 

The only thing which definitely would be true is that after we applied the reconstruction in the (sinc) fashion we know it, Shannon / Nyquist has been applied. And then it is too late ...

So you must think prior to that situation.

 

Peter

 

Lush^3-e      Lush^2      Blaxius^2.5      Ethernet^3     HDMI^2     XLR^2

XXHighEnd (developer)

Phasure NOS1 24/768 Async USB DAC (manufacturer)

Phasure Mach III Audio PC with Linear PSU (manufacturer)

Orelino & Orelo MKII Speakers (designer/supplier)

Link to comment
52 minutes ago, pkane2001 said:
3 hours ago, manueljenkin said:

Well I'm saying the very act of bandlimiting the signal to 22khz is cutting off transients. The transients may not be as abrupt as heaviside function, but there is no guarantee it is naturally Bandlimited to 22khz, I certainly haven't seen any studies that prove it. 

 

That's correct, and I wouldn't think you need a study to show that. There are plenty of natural and artificial sounds that have frequencies well above 22kHz. But there are also plenty of studies that show humans can't hear much above 20kHz

 

I'd really like to see your explanation of why you have such a response. To me it does not make a but of sense. Please read carefully what Manuel says, and please know (or acknowledge) that a transient is not a frequency. It just is not. And it you think it is, please lay it out.

Hint: Mathematically the steep rise is a sinus of infinite frequency. Electrically no difference. And ... in practice it does not need bandlimiting to quite perfectly show it at the output of a DAC which leaves the signal alone (no filtering).

The point of course is, that when we do nothing with the signal (no filtering) that fact thus severely interferes with the reconstruction (it just did not happen then). So how to apply both worlds in best fashion.

 

The DAC (which is sufficiently fast) can show the transients (per proof of the pulses I showed).

The DAC can-not show a square, which-can-not-even-exist-in-real life. Thus, a synthesizer may theoretically be able to produce a so called pure square in a digital form, but it would be stupid if some artist would let it do that. It will be a mess at playback. But transients are fine. And On/Off "sound" as modulation on a random wave form is thus also fine (I mean a wave form of any kind the artist liked). This happens continuously.

 

You should come over and listen to my synthesizers. Next listen to them through my playback system for comparison.

Then listen to them through your playback system.

And the gag: from the very start of this hobby for me, I was of the stance that only one instrument should be used to judge reality of the music reproduction system: the synthesizer. I know, if that does not sound as a contradiction then I don't know (nobody knows how the synth sounded when the artist used it for his piece of work). Still it holds true ...

Lush^3-e      Lush^2      Blaxius^2.5      Ethernet^3     HDMI^2     XLR^2

XXHighEnd (developer)

Phasure NOS1 24/768 Async USB DAC (manufacturer)

Phasure Mach III Audio PC with Linear PSU (manufacturer)

Orelino & Orelo MKII Speakers (designer/supplier)

Link to comment
27 minutes ago, PeterSt said:

Not correct. Synthesizers can and they do (and don't let an ADC loose on them or else you are correct 🤪).

 

No Peter. In a synthesized series of values in a file, the values each have a time. The rate of change from one value to another is not infinite slope, rather the slope can vary as long as the rise time is less than or equal to the sample time. 
 

In no real DAC is the rise time ever zero. If no spec is the rise time zero.

Custom room treatments for headphone users.

Link to comment
28 minutes ago, PeterSt said:

Hi Paul, it looks like you just don't want to read it. And you don't want to see (through) the real-life plots either ?

 

Peter

 

Hi Peter,

 

Quote

Not correct. Synthesizers can and they do (and don't let an ADC loose on them or else you are correct 🤪).

Hmm? Digital isn't real, Peter. Digital isn't a signal. It's a mathematical representation of a signal. So yes, inside the computer, one can encode a 0-time transition. Show me any real signal that transitions between two states in 0 time.

 

Quote

 Why ? just because you think so ? Can you prove it ? I won't repeat all the posts and plots again about the opposite (I already did it twice). Btw, I don't think you did not read them (you were here all the time). You just seem to ignore what I show.

(I know, my English 🤫)

No, i didn't ignore you. I've been extremely busy, and have not kept up with this thread or what's been posted (and there's been a lot!) Just surfacing for air for a few hours. I'll go look for your examples of 0 time transition, but they better be good, or else you're wasting my time! ;) See below as to why I don't need to prove it.

 

Quote

Why do you call that a state ? There is no such thing as a state or changing state etc. There's a steep rise (or drop) of level. I am afraid you miss the point somewhere. Maybe investigate "Steady State" better ? I am not sure. But it is the opposite of a state of a signal as what you seem to refer to (again, I am guessing).

 

All physical phenomena have a state. A state is just a point in multiple dimensions, including time. A transition between two states is a vector.  A Heaviside function is a step transition between two points with infinite slope. There's no physical (not mathematical!) signal that transitions between two states in zero time, that would violate known laws of Physics. Infinities are not easy to find in the natural world, so if you've found one, publish a paper and quickly!

 

Quote

The only thing which definitely would be true is that after we applied the reconstruction in the (sinc) fashion we know it, Shannon / Nyquist has been applied. And then it is too late ...

So you must think prior to that situation.

 

It's too late for what? Why do I care about discarded frequencies that are far out of my ability to hear them? Regardless of how hard you try to reproduce an infinite slope of a signal, you'll never succeed, so there is always something missing compared to the idealized, digital or mathematical encoding of a pulse or a step.

 

 

Link to comment
1 minute ago, jabbr said:

No Peter. In a synthesized series of values in a file, the values each have a time. The rate of change from one value to another is not infinite slope, rather the slope can vary as long as the rise time is less than or equal to the sample time.

 

Yeah, hahaha.

That doesn't make the rises used way beyond any Nyquist limit. Let's keep in mind the gist. But literally you will be correct because 90 degree steep rise won't be used. Make it 80 degree. Or I make it 90 degree after all. Just because it can be done (no use case at hand).

Lush^3-e      Lush^2      Blaxius^2.5      Ethernet^3     HDMI^2     XLR^2

XXHighEnd (developer)

Phasure NOS1 24/768 Async USB DAC (manufacturer)

Phasure Mach III Audio PC with Linear PSU (manufacturer)

Orelino & Orelo MKII Speakers (designer/supplier)

Link to comment
5 minutes ago, PeterSt said:

 

Yeah, hahaha.

That doesn't make the rises used way beyond any Nyquist limit. Let's keep in mind the gist. But literally you will be correct because 90 degree steep rise won't be used. Make it 80 degree. Or I make it 90 degree after all. Just because it can be done (no use case at hand).


The way I see the crux of this issue is whether a recording at 44 kHz  upsampled to xxx  kHz is ever inferior to a recording at xxx kHz. If the higher recording rate is needed then 44 kHz doesn’t contain all the information whether that be tone or timing.

Custom room treatments for headphone users.

Link to comment

For those who haven't been able to follow till now. You can look into the derivations below. @Jud This one is for your request mainly.

 

I have taken an "ideal" infinite time sinc filter which has the best frequency response of a rectangular function. So this is an ideal scenario, in reality we only have truncated or windowed sinc function and I have already drawn and shown what happens if I convolve one over another for these non ideal functions (the modulations/deviations grow much larger every iteration)

 

I am just multiplying them in frequency domain to see how the results come out.

 

Formula references here: https://math.stackexchange.com/questions/736749/fourier-transform-of-sinc-function

 

http://www.thefouriertransform.com/pairs/sinusoids.php

 

I have done the operation of ideal low passing on steady state sines that begin at time -infinity and end at time +infinity (otherwise the derived Fourier transform won't be the same as above, and you'll have deviations/alias components at the filtered output) and squares (again repetitive pulses from -infinity to +infinity) till input 4 and I have shown how you can perfectly bandlimit it if you can have such an ideal scenario with ideal infinite time low pass. Whatever phase deviations I have from the ideal zero point will still be preserved in the Fourier transform and I can extract it very well since passing them through an ideal low pass either passes them directly, or completely truncates their component. Provided I have high enough bit depth I can precisely say the delta time. When I don't have enough bit depth the formula described in the first post of this thread comes into play. All of these are assuming steady state signals having components of time -infinity to infinity. So far so good.


Real truncated low pass as I said will leak some content out of the spectral band, but let's keep it aside for now.

 

Now the fun comes in when you use a real transient scenario, change from one periodic/a-periodic state to another. One of the best examples to show this transient scenario from inertia is the heaviside function. You can just take the heaviside function, or take a transient scenario of any periodic function which would just be the function from -infinity to + infinity multiplied piecewise over the heaviside function. Just try passing this heaviside function over the sinc low pass and let me know your results.

 

http://www.theochem.ru.nl/~pwormer/Knowino/knowino.org/wiki/Heaviside_step_function.html

 

You'll always have it leaking things out of the pass band. It doesn't even matter if these are themselves audible or not (prior to sampling), if they exist in the signal when sampling (ie input signal is not completely band limited), they will alias and influence the audible bands when sampled and reconstructed!! Some of these transients may be audible some may not be, regardless, their mere existence and inability to be completely band limited will influence additional modulations, on top of discarding potentially audible info. If you want this to be free of issues, you need to visualize the true bounds of real world transients and then optimize for it, not randomly chop at 22khz. People love to throw around the terms practically it doesn't go to "infinite slew" yeah it doesn't, but analyse and judge the true bounds in which it really occurs and also optimize the mic to the limits of human hearing (and not cause any transient noise 😉). Till then I can ask for higher sample rate to be on the safer side of data preservation. The moment you sample a non band limited waveform and introduce aliasing components, you've introduced modulations of extremely unpredictable order.

IMG_20201002_073018__01.jpg

IMG_20201002_073109__01.jpg

 

Also stop saying wrong conclusions and then cloaking it inside "math". Math doesn't say it. I've often see people invoke the word "science" for things it never said. They just try to push their personal opinion by falsely stating it as science. We've had our fair share of such instances in audio - especially analog circuits. Only a truly periodic function has a unique frequency. Anything that's not periodic/transient doesn't have a unique frequency. It'll change wildly depending upon how you window and visualize it, and this windowing will have trade offs in time domain visualization. I've already described this in previous posts. They don't have a "frequency", since they don't repeat.

 

If you don't like heaviside function, do some other function with real transient. You'll end up with similar dilemma.

 

Also regarding transients of synths or codes. I'm not going to comment on Synth, but a coder can intend it to have "any" transient rate. If you don't sample it properly, you end up with modulations, that's all.

Link to comment

I am thinking of a best example of synthesized needle ticks or scratches, which definitely won't show on your system, while on mine they are louder than the "song", so to speak. I know, because the faster I make my system (as a whole) the louder they become. I should e.g. look at the very first track I played with the new cable we have here, with such a loud thick within the first 5 seconds that it would even show SPL on the meter. And that thick was never there before that I noticed. It is full with such stuff, but play the proper music for it.

 

This is not related to frequency. It is related to transients and how fast they can be represented.

For the so-maniest time: synthesizers work most often (more do than don't) with Off-ing the whatever sound. According to you this should come along with a 10KHz (11024 max) sinus sound. But the digital code of it, won't show that. It will show nulls (or close to that, depending on how deep the Off was made). Again, this is not a transient as such as in a tick - it is about probably a triangle shape wave, as a base where a wanted wave forum is modulated upon.

You would make that into a sinus shaped wave or the base. Also nice, but not intended.

And I know ... I know ... what happens in 99.99% of cases is that this will be gray sound because the reconstruction makes it that. Not over here.

 

image.png.8363bf6a68588ed2656336010bb5f916.png

 

Trust me, this is what can be "set" (among numerous base shapes). So if I set that (as the artist), would I like that to be a sinus at playback ? Or do we think it remains to have that shape after reconstruction ?

Please choose or ad other options ... I already showed the plots from real life DAC output, though from not-so-real-life Dirac pulses - and I can't tell what's illegal about it when compared with a synthesizer. One difference: the above shows a steep fall. So do you want me to first apply DC offset of 2V and then let let fall the signal once in a while ? Or do we really think it is not necessary.

We want to approach what's intended as good as possible and we don't want to listen to Shannon, Nyquist and a few others. But I know the rules ...

Lush^3-e      Lush^2      Blaxius^2.5      Ethernet^3     HDMI^2     XLR^2

XXHighEnd (developer)

Phasure NOS1 24/768 Async USB DAC (manufacturer)

Phasure Mach III Audio PC with Linear PSU (manufacturer)

Orelino & Orelo MKII Speakers (designer/supplier)

Link to comment
8 minutes ago, PeterSt said:

So if I set that (as the artist), would I like that to be a sinus at playback ? Or do we think it remains to have that shape after reconstruction ?

 

Sorry, but as an artist you don't get a choice, Peter. Fourier decided this for you over 200 years ago: any signal can be decomposed into a sum of sines. Even the sawtooth one that you like so much ;)

 

Link to comment
1 minute ago, pkane2001 said:

 

Sorry, but as an artist you don't get a choice, Peter. Fourier decided this for you over 200 years ago: any signal can be decomposed into a sum of sines. Even the sawtooth one that you like so much ;)

 

Only for any "truly periodic" signal. If he has a sawtooth running from -infinity to +infinity, yeah. Otherwise, no!

Link to comment
1 hour ago, manueljenkin said:

For those who haven't been able to follow till now. You can look into the derivations below. @Jud This one is for your request mainly.

 

I have taken an "ideal" infinite time sinc filter which has the best frequency response of a rectangular function. So this is an ideal scenario, in reality we only have truncated or windowed sinc function and I have already drawn and shown what happens if I convolve one over another for these non ideal functions (the modulations/deviations grow much larger every iteration)

 

I am just multiplying them in frequency domain to see how the results come out.

 

Formula references here: https://math.stackexchange.com/questions/736749/fourier-transform-of-sinc-function

 

http://www.thefouriertransform.com/pairs/sinusoids.php

 

I have done the operation of ideal low passing on steady state sines that begin at time -infinity and end at time +infinity (otherwise the derived Fourier transform won't be the same as above, and you'll have deviations/alias components at the filtered output) and squares (again repetitive pulses from -infinity to +infinity) till input 4 and I have shown how you can perfectly bandlimit it if you can have such an ideal scenario with ideal infinite time low pass. Whatever phase deviations I have from the ideal zero point will still be preserved in the Fourier transform and I can extract it very well since passing them through an ideal low pass either passes them directly, or completely truncates their component. Provided I have high enough bit depth I can precisely say the delta time. When I don't have enough bit depth the formula described in the first post of this thread comes into play. All of these are assuming steady state signals having components of time -infinity to infinity. So far so good.


Real truncated low pass as I said will leak some content out of the spectral band, but let's keep it aside for now.

 

Now the fun comes in when you use a real transient scenario, change from one periodic/a-periodic state to another. One of the best examples to show this transient scenario from inertia is the heaviside function. You can just take the heaviside function, or take a transient scenario of any periodic function which would just be the function from -infinity to + infinity multiplied piecewise over the heaviside function. Just try passing this heaviside function over the sinc low pass and let me know your results.

 

http://www.theochem.ru.nl/~pwormer/Knowino/knowino.org/wiki/Heaviside_step_function.html

 

You'll always have it leaking things out of the pass band. It doesn't even matter if these are themselves audible or not (prior to sampling), if they exist in the signal when sampling (ie input signal is not completely band limited), they will alias and influence the audible bands when sampled and reconstructed!! Some of these transients may be audible some may not be, regardless, their mere existence and inability to be completely band limited will influence additional modulations, on top of discarding potentially audible info. If you want this to be free of issues, you need to visualize the true bounds of real world transients and then optimize for it, not randomly chop at 22khz. People love to throw around the terms practically it doesn't go to "infinite slew" yeah it doesn't, but analyse and judge the true bounds in which it really occurs and also optimize the mic to the limits of human hearing (and not cause any transient noise 😉). Till then I can ask for higher sample rate to be on the safer side of data preservation. The moment you sample a non band limited waveform and introduce aliasing components, you've introduced modulations of extremely unpredictable order.

IMG_20201002_073018__01.jpg

IMG_20201002_073109__01.jpg

 

Also stop saying wrong conclusions and then cloaking it inside "math". Math doesn't say it. I've often see people invoke the word "science" for things it never said. They just try to push their personal opinion by falsely stating it as science. We've had our fair share of such instances in audio - especially analog circuits. Only a truly periodic function has a unique frequency. Anything that's not periodic/transient doesn't have a unique frequency. It'll change wildly depending upon how you window and visualize it, and this windowing will have trade offs in time domain visualization. I've already described this in previous posts. They don't have a "frequency", since they don't repeat.

 

If you don't like heaviside function, do some other function with real transient. You'll end up with similar dilemma.

 

Also regarding transients of synths or codes. I'm not going to comment on Synth, but a coder can intend it to have "any" transient rate. If you don't sample it properly, you end up with modulations, that's all.

Some more additions. Peter "demonstrated" this effect of modulation, where he showed the prescence of a false sinusoid (page 2) when sampling reconstructing with ideal Nyquist Shannon at sampling rates less than ideal for the pauses (the same rate which in the first post in this thread was claimed to be able to "reliably" capture and reproduce "all" such scenarios). In this particular example, these false sinusoids are in the audible band, in place of what should have been pauses naturally. I've already linked papers on why those pauses shall be discernible by humans. Sampling and reconstructing it as is is necessary for higher fidelity of audio as we hear it.

 

And one correction. Just noticed I made one small mistake in the second image, input 6 description. It is not convolution for heaviside * sine, it is piecewise multiplication in time domain, as I mentioned in the writing. You can try deriving it too. It just would get even more complicated than just doing direct heaviside sine though out of band content will be spread out differently (but will still have those).

 

This frequency domain vs time domain representation clashes/compromises for non periodic signals is well known in math, and there are different analysis techniques that let you slide between compromise in one domain to another. Higher sampling rate helps here too, giving more scope of better visualization in both domain. Further reading :

 

https://en.m.wikipedia.org/wiki/Time–frequency_analysis

 

https://en.m.wikipedia.org/wiki/Short-time_Fourier_transform

 

https://www.subsurfwiki.org/wiki/Gabor_uncertainty

Link to comment
On 9/27/2020 at 9:27 AM, PeterSt said:

 

Manuel, we must be very careful with "thinking" theories only;

In the electrical world (or the electrical domain), there's also this swing. If you think about that in the end all is always sines, no matter how "straight up" you want to see it in theory. If you think about squares you already know that. Well, the Dirac pulse does not behave differently.

 

These are three Dirac pulses of 2V :

 

image.png.f00e85de72e374dfe564d0dafe1bf28d.png

 

 

Unfiltered, this shows the spectral content up to 1MHz :

 

image.png.026b0e79356a7b62428b62c51ebfd69c.png

 

 

In more detail, up to 100KHz :

 

image.png.7bc44bd30e37a9dee01ae016c409c33f.png

 

 

Or for the audio band (~ 5KHz) :

 

image.png.e976dcbacb5529a58b9ee6e633a640a1.png

 

 

And just the one pulse (time axis is in us) :

 

image.png.ba1f41fb67c4bf899ee1d575f29175e0.png

 

Of course you see Gibbs, but you also see the swing-up.

And down for that matter (a sheer ~200mV on the total of 2V) :

 

image.png.3c7dc3c04a05c19621521539ac285320.png

 

 

And more zoomed in :

 

image.png.db0facf038f2dce4c9a5022de3d674f1.png

 

Mind you, this too (above) is the going down from 2V to 0V. So the going down implies the swing up first. And if you look closely at the last part of the Gibbs effect, you see that the swing up which electrically is just there, again implies a small swing down first :

 

image.png.8a35e3ceda117660870ecf2dfd6fa29a.png

 

image.png.334074af023c8d762d25c0f969d7ee41.png

And if we would zoom in even further on the Gibbs effect, we'd see the same happening for each of the above "sines". And notice for your fun that the above does not show even (while in practice it will be) because this analyzer has its (band)limits too. 😞 So it looks like a 20KHz not decently low passed signal now (while it is something like 14MHz - analyser is 20Msps).

 

So ...

So before we forget, we were not looking at a frequency; we were looking at pulses with silence in between them. In itself such a pulse implies the most severe sh*t because its frequency is infinite (because the steepness is infinite). Nothing strange.

Now we are going to filter this nicely, and then this comes from it (time scale is ms now):

 

image.png.6f27607abe2475775f1afe282cd7e0ba.png

 

... and our pulses with silence in between them (btw at a rate of 10KHz) was turned into a 10KHz sinus.

And so instead of the synth showing all the frequencies possible (think ticks with "distortion" and which just is so and which also would be so for our ears (limited to 20KHz) we now hear a tone of 10KHz which just was not meant to be at all. Also notice the Voltage drop and you could even assert that our pulse train of +2V now has become a sinus with DC offset.

 

To finish this off, this is how it can be done with filtering means more suitable for it (this is 16x upsampled):

 

image.png.432cd5fb10dcf208a89b7cac8ca90168.png

 

but keep in mind that this is actually a silent part:

image.png.48ea3640f63795c9f02ac8b3680192ed.png

 

and the one between -0.7ms and -0.6ms is wider spaced for better filter testing (the sinc filter will choke on this).

 

From the above we could (try to) learn that the one-sample pulse could be broadened to 16 samples, therefore making its distortions less severe;

Of course in practice these pulses won't exist, but the up (and down) going transients for sure do (and indeed DC offset related as you mention) and they better go instantly with some way down distortion product than a wheeeeep because it's turned into a sinus of some frequency.

 

Nyquist et all is not wrong, but different approaches exist. Mine makes the time domain prevalent but has the frequency domain in mind. Shannon and friends approaches it the other way around.

The results of both are very different.

 

DDDAC would be fine, as long as it allows at least one upsampling step for testing (and I am not sure about that).

But speaking of Doede Douma, I already wanted to ask you whether you are Germany-schooled. It is my experience that in Germany they allow this thinking - special engineering coming from that.

 

Regards,

Peter

 

PS: I can't get rid of the picture below. It shouldn't be there.

 

image.png

Here it is!

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...