Generation of bandlimited sync transitions for sine waveforms

Similar documents
Review: Continuous Fourier Transform

6.003 Homework #10 Solutions

Notes 07 largely plagiarized by %khc

Fourier Transform for Continuous Functions

GATE EE Topic wise Questions SIGNALS & SYSTEMS

4 The Continuous Time Fourier Transform

Preserving the LTI system topology in s- to z-plane transforms

Bridge between continuous time and discrete time signals

ECG782: Multidimensional Digital Signal Processing

Fourier Series. Spectral Analysis of Periodic Signals

Line Spectra and their Applications

ENSC327 Communications Systems 2: Fourier Representations. Jie Liang School of Engineering Science Simon Fraser University

A system that is both linear and time-invariant is called linear time-invariant (LTI).

ENGIN 211, Engineering Math. Fourier Series and Transform

Control Systems I. Lecture 6: Poles and Zeros. Readings: Emilio Frazzoli. Institute for Dynamic Systems and Control D-MAVT ETH Zürich

LOPE3202: Communication Systems 10/18/2017 2

THE LIMIT PROCESS (AN INTUITIVE INTRODUCTION)

PART 1. Review of DSP. f (t)e iωt dt. F(ω) = f (t) = 1 2π. F(ω)e iωt dω. f (t) F (ω) The Fourier Transform. Fourier Transform.

3 Fourier Series Representation of Periodic Signals

Damped harmonic motion

Tutorial Sheet #2 discrete vs. continuous functions, periodicity, sampling

E2.5 Signals & Linear Systems. Tutorial Sheet 1 Introduction to Signals & Systems (Lectures 1 & 2)

CH.4 Continuous-Time Fourier Series

Chapter 5 Frequency Domain Analysis of Systems

The Discrete Fourier Transform

Lecture 28 Continuous-Time Fourier Transform 2

Massachusetts Institute of Technology Department of Electrical Engineering and Computer Science. Fall Solutions for Problem Set 2

Chapter 5 Frequency Domain Analysis of Systems

Antialiased Soft Clipping using an Integrated Bandlimited Ramp

IB Paper 6: Signal and Data Analysis

ECE 451 Black Box Modeling

Control Systems I. Lecture 7: Feedback and the Root Locus method. Readings: Jacopo Tani. Institute for Dynamic Systems and Control D-MAVT ETH Zürich

3.2 Complex Sinusoids and Frequency Response of LTI Systems

Introduction to Initial Value Problems

Solutions to Problems in Chapter 4

LIMITS AND DERIVATIVES

Part 3.3 Differentiation Taylor Polynomials

Chapter 7: Filter Design 7.1 Practical Filter Terminology

2 Fourier Transforms and Sampling

Time and Spatial Series and Transforms

1 Solutions in cylindrical coordinates: Bessel functions

1 Understanding Sampling

Ver 3808 E1.10 Fourier Series and Transforms (2014) E1.10 Fourier Series and Transforms. Problem Sheet 1 (Lecture 1)

Therefore the new Fourier coefficients are. Module 2 : Signals in Frequency Domain Problem Set 2. Problem 1

Infinite Series. 1 Introduction. 2 General discussion on convergence

Topic 3: Fourier Series (FS)

EC Signals and Systems

Fourier Series Example

The Hilbert Transform

ELEN E4810: Digital Signal Processing Topic 11: Continuous Signals. 1. Sampling and Reconstruction 2. Quantization

Lecture 10. Applied Econometrics. Time Series Filters. Jozef Barunik ( utia. cas. cz

Elec4621 Advanced Digital Signal Processing Chapter 11: Time-Frequency Analysis

1 otherwise. Note that the area of the pulse is one. The Dirac delta function (a.k.a. the impulse) can be defined using the pulse as follows:

EE 3054: Signals, Systems, and Transforms Summer It is observed of some continuous-time LTI system that the input signal.

4 Uniform convergence

ECE-700 Review. Phil Schniter. January 5, x c (t)e jωt dt, x[n]z n, Denoting a transform pair by x[n] X(z), some useful properties are

13. Power Spectrum. For a deterministic signal x(t), the spectrum is well defined: If represents its Fourier transform, i.e., if.

Z-Transform. The Z-transform is the Discrete-Time counterpart of the Laplace Transform. Laplace : G(s) = g(t)e st dt. Z : G(z) =

3 What You Should Know About Complex Numbers

FOURIER ANALYSIS using Python

ANALOG AND DIGITAL SIGNAL PROCESSING ADSP - Chapter 8

Fourier transform. Alejandro Ribeiro. February 1, 2018

Lecture 27 Frequency Response 2

CHEE 319 Tutorial 3 Solutions. 1. Using partial fraction expansions, find the causal function f whose Laplace transform. F (s) F (s) = C 1 s + C 2

Filter Banks For "Intensity Analysis"

Review of Linear Time-Invariant Network Analysis

Chapter 17 : Fourier Series Page 1 of 12

E : Lecture 1 Introduction

EA2.3 - Electronics 2 1

APPENDIX A. The Fourier integral theorem

Summary: ISI. No ISI condition in time. II Nyquist theorem. Ideal low pass filter. Raised cosine filters. TX filters

Continuous Fourier transform of a Gaussian Function

8.5 Taylor Polynomials and Taylor Series

ENSC327 Communications Systems 2: Fourier Representations. School of Engineering Science Simon Fraser University

DESIGN OF CMOS ANALOG INTEGRATED CIRCUITS

Digital Filters Ying Sun

2. Signal Space Concepts

Functions not limited in time

6.003: Signals and Systems. Sampling and Quantization

ESS Dirac Comb and Flavors of Fourier Transforms

Predicting the future with Newton s Second Law

Summary of Fourier Transform Properties

06/12/ rws/jMc- modif SuFY10 (MPF) - Textbook Section IX 1

Sensors. Chapter Signal Conditioning

z = x + iy ; x, y R rectangular or Cartesian form z = re iθ ; r, θ R polar form. (1)

Lecture 3 - Design of Digital Filters

Continuous-time Fourier Methods

Chapter 4 The Fourier Series and Fourier Transform

Aspects of Continuous- and Discrete-Time Signals and Systems

Digital Baseband Systems. Reference: Digital Communications John G. Proakis

Examples of the Fourier Theorem (Sect. 10.3). The Fourier Theorem: Continuous case.

ECE Unit 4. Realizable system used to approximate the ideal system is shown below: Figure 4.47 (b) Digital Processing of Analog Signals

STABILITY. Have looked at modeling dynamic systems using differential equations. and used the Laplace transform to help find step and impulse

Finding Limits Graphically and Numerically

Cast of Characters. Some Symbols, Functions, and Variables Used in the Book

2.161 Signal Processing: Continuous and Discrete Fall 2008

Time Response of Systems

2 M. Hasegawa-Johnson. DRAFT COPY.

ω 0 = 2π/T 0 is called the fundamental angular frequency and ω 2 = 2ω 0 is called the

Power Series Solutions We use power series to solve second order differential equations

Transcription:

Generation of bandlimited sync transitions for sine waveforms Vadim Zavalishin May 4, 9 Abstract A common way to generate bandlimited sync transitions for the classical analog waveforms is the BLEP method. The method works well for the sawtooth, pulse, and triangle waveforms, however fails in case of the sine. A number of methods to overcome that problem is proposed in the article. Introduction The BLEP method including its minimum-phase variant [] provides a way for generating bandlimited zero-order discontinuities discontinuities of the signal, which can be applied for generation of bandlimited saw and pulse waveforms and also sync transitions in such waveforms. A triangle waveform contains first-order discontinuities discontinuities of the first derivative plus zero-order discontinuities which may appear during syncing, therefore in addition to the zero-order BLEPs one also needs to use the first-order BLEPs. A sine waveform on its own doesn t require any bandlimiting provided the sine frequency lies below the Nyquist limit, however a sync transition generates discontinuities of all orders up to infinity, therefore an infinite number of BLEPs of all possible orders is theoretically required. In the present article we will discuss a number of ways to deal with that problem. Native Instruments GmbH Problem specification We are going to consider only the constant-frequency sine waveforms, in which case the sync transition is simply a phase discontinuity. Let x t = cost + ϕ = X t + X t x t = cost + ϕ = X t + X t be the signals before and after the transition and let X t = e jt+ϕ X t = e jt+ϕ be their analytic counterparts the asterisk in X t denotes the complex conjugation. Let ht if t < sgn t = if t = if t > be the step function and let the sync transition occur at t =. Then the output signal can be represented as yt = ht x t + + ht x t where = x t + x t + ht x t x t = xt + ht xt xt = x t + x t

is the average of the two signals and xt = x t x t is their difference. Respectively, Xt = X t X t is the difference of the analytic signals. We want to bandlimit the output signal yt to the frequency band from to. Apparently, we can assume the, band without loss of generality, as this means simply a choice of the frequency units. The upper bound of the frequency band would typically correspond to the Nyquist frequency, however doesn t have to, e.g. one could specify a bound slightly below or slightly above the Nyquist limit whatever slightly means. We will also assume that the signals x and x are already bandlimited <. The bandlimited versions of the originally nonbandlimited signals will be denoted by a bar on top, e.g. ȳt. Note that some signals will be bandlimited to other bands than,, in which case we will explicitly mention so. 3 Notation issues In the text of this article we will need to deal with the integral exponents, sines, and cosines. A number of different notations are apparently in use here []. In order to simplify the formulas in the article we will use the following somewhat non-standard notation. Restricting z to taking only purely imaginary values z = jϕ we let Ein z = z e t t dt Ei z = γ + ln z + Ein z E n z = e zt dt n tn ei jϕ = Ei jϕ j sgn ϕ = E jϕ where the absolute value of z in ln z and the term j/ sgn ϕ ensure the conjugate symmetries Ei jϕ = Ei jϕ and ei jϕ = ei jϕ respectively, and γ denotes the Euler s constant. Thus: Therefore Cin ϕ = ϕ cos t t dt Ci ϕ = γ + ln ϕ + Cin ϕ Si ϕ = ϕ sin t t dt si ϕ = Si ϕ sgn ϕ Ein jϕ = Cin ϕ + j Si ϕ Ei jϕ = Ci ϕ + j Si ϕ ei jϕ = Ci ϕ + j si ϕ Ci ϕ = Ci ϕ Si ϕ = Si ϕ si ϕ = si ϕ Ein jϕ = Ein jϕ Ei jϕ = Ei jϕ ei jϕ = ei jϕ E n jϕ = E njϕ ne n+ z = ze n z + e z d dz E nz = E n z The limit values are Ci± = Si± = ± ei± j = E n ± j = E n+ n A robust numerical method to compute Ci ϕ and Si t can be found in [3]. Essentially, it is using the series expansion if ϕ < and the continued fraction for E z otherwise, both of which can be also found in []. The remaining functions can be built from Ci ϕ and Si ϕ. Note that in order to compute Cin ϕ and Ein jϕ it is reasonable to use the series expansion for Cin ϕ instead of the one for Ci ϕ. Also, keep in mind the notation specifics of the present article!

4 Multiple BLEPs method If the sine frequency lies well below the Nyquist limit, then we would intuitively expect higher-order BLEPs to have rather little effect on the waveform, in which case we may simply discard them. Let s analyse this question in more detail. 4. Fundamentals Recalling that ht sgn t = δτ dτ we can refer to ht as to the zero-order step function, and to δt as to the st-order step function, using notations h t = ht and h t = δt, whereas the higher-order step functions are defined as h n t = h n τ dτ = tn n! sgn t We define the aliasing residual of n-th order as h n t = h n t h n t Then the bandlimited output signal is where ȳt = yt ȳt = yt y n h n t n= y n = y n t + y n t 4. Analytic BLEPs Writing the Fourier integral for h t we have h t j d ε lim ε + j d + ε j lim E jεt E jεt ε + j d Thus where H t + H t h t = lim ε + H t j E jεt j ε j d Therefore, H t can be considered as an analytic counterpart of h t except that it s parametrized with ε. Bandlimiting the signal H t: H t j ε j d j E jt ε = we obtain the expression for the aliasing residual H t = H t H t j j E jt = H t ε= Thus, H t doesn t depend on ε and h t = H t + H t Now consider H t = H t + H t which can be alternatively written as H τ dτ = H τ dτ + Evaluating the last term we get H t = H τ dτ j = E jτ t τ= = E jt j d H τ dτ E jτ dτ + The above is not the most desirable scenario, as we would rather have H t for t. Notice however, that the term / is simply a DC offset, therefore it is bandlimited and can be simply included into H : H t = H t = E jt H τ dτ + 3

Continuing in the same manner, we obtain H n t = E n+jt j n+ which is a general expression for an n-th order bandlimited analytic aliasing residue. 4.3 Real-domain BLEPs The real domain expression for the aliasing residuals can be obtained as h n t = H n t + H nt = E n+jt + n+ E n+jt j n+ Notably, for n = the above turns into h t = E jt E jt j sgn t Si t 3 which is the familiar expression for the zero-order aliasing residual. The problem with however, is that the function E jt, which is required to recursively evaluate E n jt, is getting infinitely large around t =. Therefore, for small t one should use 3 at n = and take special care in the evaluation of the term jte jt in the expression for E jt at n >. A better option is to notice that n h n t = n E n+jt + n+ E n+jt j n+ = jt E njt + n+ jte n+jt j n+ + ejt + n+ e jt j n+ = t h n t + sin n t where sin n t is the n-th antiderivative of sin t: { sin n n+/ cos t for odd n t = n/ sin t for even n which allows us to compute h n t from h t. Note that it is also not difficult to obtain the explicit form of ht: h n t Si n t where Si n t is the n-th antiderivative of Si t, which is computed as n Si n t = t Si n+ t sin n t 4.4 Error estimation Now we will estimate the bounds for h n t. First, we notice that for n = we have h t = h t Si t = h For higher orders, using we have hn t E n+ jt + n+ E = n+jt j n+ + n+ e jt n+ d d n+ n = h n Now assume, that instead of the infinite series we use an approximation for ȳ: ȳ N y n h n t n= The error of the approximation is given by the remainder of the series: ε = y n h n t y n h n t n=n+ n=n+ Noticing that y n n, and recalling the bound estimations for h n t we have ε n=n+ n h n = Therefore if then ε. n=n+ n n 4

4.5 Windowing In choosing N one should take into account the fact that the BLEP method doesn t provide the full bandlimiting anyway, as each of the aliasing residuals is infinitely long, and some windowing would be used in practice. Therefore the number of BLEPs and the window size have to be chosen together, as to provide comparable levels of imperfectness. The windowed BLEPs can be constructed in a number of ways. The most obvious way is to window the aliasing residuals directly: hn TL t = W t h n t where W t is the window function, and TL denotes the timelimited version of a function. Note that an important side effect of windowing is that the argument of ht becomes restricted to the window size, and thus the functions h n t can be simply TL tabulated. Another approach can be to window the thorder BLEP: h TL t = W t h t = W t sinc t and compute the rest by the recursive integration of the aliasing residuals: hn TL t = a n hn TL τ dτ + c n where the constants a n and c n should be chosen so as to satisfy the requirement h n ± =. TL The latter approach might not seem very reasonable, because of a large amount of numerical integration involved, which should lead to increasing precision losses. However, there is a special case particularly useful at small window sizes where the integration can be done analytically. Recall that the continuous-time impulse responses of symmetric interpolators are typically approximations of the sinc function [4] [5], and thus one may take such impulse response as h t. Then one can construct higher-order BLEPs from h t as de- W W scribed above. 5 Ring modulation method Consider again. Obviously, xt is already bandlimited, therefore we only need to bandlimit the remainder ht xt remember that ht = h t. Imagine that instead of ht we have used in its bandlimited to, version ht. Then the remainder of turns into ht xt ht Xt + ht X t 4 Recalling that Xt = e jϕ e jϕ and considering the first term of 4 alone, we notice that the multiplication by Xt shifts the spectrum of ht to the right by. Similarly, in the second term the spectrum of ht is shifted to the left by. Therefore, if, then the spectrum of h x will have only minor differences to the ideally bandlimited h x. Already if < /, then all wrong partials that including the aliasing and the missing partials will be located above /. Therefore, if e.g. the sampling rate is 88kHz and the sine frequencies are limited to khz, then all the wrong partials will be located above khz. Considering that the sampling rate of 88kHz or higher may be desirable for a number of other reasons anyway, the above method might be an acceptable option. The time-limited version of ht can be built from the time-limited residual: h t = ht h t TL TL or by direct integration of h TL t: h htl t = h TL TL τ, dτ τ, dτ It is convenient to write the band- and time-limited version of as ȳt = xt + htl t xt = yt h TL t xt because the latter form, by using the residual, allows intuitive handling of time-overlapping transitions. 5

6 Frequency shifting method Now we are going to try to bandlimit h x to exactly,. We ll do so by bandlimiting each of the components h X and h X to,. In order to do that we need to bandlimit ht in h X to, +, and bandlimit ht in h X to, +. 6. Asymmetric BLEP First, we are going to build an analytic expression for the step function ht bandlimited to the frequency range, +, where we will assume < < +. Writing the Fourier integral we get ht j j + j d + j d + + d j + ln + Ein jt = + Ei jt = 5 where the latter transformation is done noticing that ln + ln = ln j + t ln j t 6. Putting the things together Using 5, the bandlimited signal h x is built as the average of signals h X and h X, where in the first case h is limited to a different frequency band than in the second case: Let h x h X + h X = X Ei j + t Ei j t + X Ei j + t Ei j t L H + 6 Note that since <, it means that L H this will be important for estimating the table size for the functions involved in the resulting formula. Using the notation 6 we can write h x = X Ei jl t Ei j H t + X Ei jh t Ei j L t = X Ei jl t Ei j H t X Ei j L t Ei j H t Im Xt Ei j L t Ei j H t Im Xt Ei jt L = H Im Xt ln L H + Ein jt L = H which gives us a formula for bandlimiting yt. Note that if, then L H and h x Im X j Si t = Si t Re X = Si t x which is the ring modulation method s formula. 6.3 Windowing Let so that ht ln j L H + Ein jt L h xt = Re ht Xt = H 6

db Then Figure : Non-bandlimited signal. ȳt = xt + h x = xt + ht xt ht xt + h xt = yt Re ht Xt + Re ht Xt = yt Re ht ht Xt = yt Re ht Xt Noticing that h± =, we conclude that we can timelimit the transition by simply timelimiting the signal ht. Note that in the frequency shifting method the function ht depends on the signal s frequency, therefore one can only tabulate Ein jϕ and the window function, whereas the application of the window must be done in real time. 7 Comparing the spectra In order to compare the methods a test case was created, where the master oscillator frequency was set to M =.5, and the slave oscillator frequency was set to S = 7.3 M. The reset phase was ϕ = Fig.. A samples-long Kaiser window with α = 4 was used for the transition time limiting. The resulting spectra generated numerically for a continuous-time case are plotted in Fig. through Fig. d. The dashed lines correspond to the non-bandlimited spectrum. 8 Conclusion We have described three different methods for generating a bandlimited sync transition in the sine waveform. The third method frequency shifting potentially can generate an almost ideally bandlimited db Figure : Non-bandlimited signal s spectrum. db db Figure a: Single-BLEP method. db db Figure b: Multiple BLEPs N = method. db db Figure c: Ring modulation method. 7

db References [] Brandt E. Hard Sync without Aliasing http://www.cs.cmu.edu/ eli db Figure d: Frequency shifting method. transition, given a long enough window. However it requires the computation of about 6 additional tabulated functions times the real and imaginary parts of the integral exponent, the window function, and the imaginary counterpart of the sine waveform. At a similar computation complexity we could have used the multiple BLEPs method to the 5th order inclusive instead. Another limitation of the frequency shifting method is that it is not immediately offering a conversion option to the minimum-phase version. The linear phase bandlimiting requires a lookahead, which means that a latency needs to be introduced in the output. However, often the latency introduced by the necessary lookahead can be either tolerated or compensated by introducing an equal latency in the parallel signal paths. Also, personally, the author prefers the linear phase antialiasing, because it preserves the phase relationships in the waveform, particularly, the generated waveforms are practically identical to the sampled analog waveforms. Note that all three methods tend to produce larger errors as the signal s frequency gets closer to the band limit. [] Abramowitz M., Stegun I.A. Handbook of Mathematical Functions National Bureau of Standards Scanned online copies at http://www.math.ucla.edu/ cbm/aands, http://www.nr.com, and other places [3] William H. Press et al. Numerical Recipes in C nd ed. Cambridge University Press 99. A full preview of the current edition is also available online at http://www.nr.com [4] Smith J.O. III Digital Audio Resampling Home Page http://ccrma.stanford.edu/ jos [5] Olli Niemitallo Polynomial Interpolators for High-Quality Resampling of Oversampled Audio http://www.student.oulu.fi/ oniemita The http links are at the time of writing the article Acknowledgements The author would like to thank NI, and Stephan Schmitt in particular, for their support and for helping him to release this article. c Vadim Zavalishin. The right is hereby granted to freely distribute this article further, provided no profit is made from such distribution. 8