Research Methods in Acoustics Lecture 7: Convolution and Fourier Transform Jonas Braasch Partly based on Jens Blauert’s Communication Acoustics script.

Slides:



Advertisements
Similar presentations
For more ppt’s, visit Fourier Series For more ppt’s, visit
Advertisements

Signals and Fourier Theory
ECE 8443 – Pattern Recognition EE 3512 – Signals: Continuous and Discrete Objectives: Response to a Sinusoidal Input Frequency Analysis of an RC Circuit.
Lecture 7: Basis Functions & Fourier Series
Fourier Series 主講者:虞台文.
Aristotle University of Thessaloniki – Department of Geodesy and Surveying A. DermanisSignals and Spectral Methods in Geoinformatics A. Dermanis Signals.
Environmental Data Analysis with MatLab Lecture 11: Lessons Learned from the Fourier Transform.
Review of Frequency Domain
EE-2027 SaS 06-07, L11 1/12 Lecture 11: Fourier Transform Properties and Examples 3. Basis functions (3 lectures): Concept of basis function. Fourier series.
Lecture 8: Fourier Series and Fourier Transform
Lecture 14: Laplace Transform Properties
APPLICATIONS OF FOURIER REPRESENTATIONS TO
Lecture 9: Fourier Transform Properties and Examples
Deconstructing periodic driving voltages (or any functions) into their sinusoidal components: It's easy to build a periodic functions by choosing coefficients.
Continuous-Time Fourier Methods
Continuous-Time Convolution EE 313 Linear Systems and Signals Fall 2005 Initial conversion of content to PowerPoint by Dr. Wade C. Schwartzkopf Prof. Brian.
Chapter 25 Nonsinusoidal Waveforms. 2 Waveforms Used in electronics except for sinusoidal Any periodic waveform may be expressed as –Sum of a series of.
Where we’re going Speed, Storage Issues Frequency Space.
Fourier Series Summary (From Salivahanan et al, 2002)
Chapter 2. Fourier Representation of Signals and Systems
CISE315 SaS, L171/16 Lecture 8: Basis Functions & Fourier Series 3. Basis functions: Concept of basis function. Fourier series representation of time functions.
Module 2 SPECTRAL ANALYSIS OF COMMUNICATION SIGNAL.
Fourier Series. Introduction Decompose a periodic input signal into primitive periodic components. A periodic sequence T2T3T t f(t)f(t)
1 Fourier Representations of Signals & Linear Time-Invariant Systems Chapter 3.
EE104: Lecture 5 Outline Review of Last Lecture Introduction to Fourier Transforms Fourier Transform from Fourier Series Fourier Transform Pair and Signal.
Continuous-Time Convolution Impulse Response Impulse response of a system is response of the system to an input that is a unit impulse (i.e., a.
Course Outline (Tentative) Fundamental Concepts of Signals and Systems Signals Systems Linear Time-Invariant (LTI) Systems Convolution integral and sum.
Chapter 2. Signals and Linear Systems
Fourier Analysis of Signals and Systems
Linear Constant-Coefficient Difference Equations
1 Roadmap SignalSystem Input Signal Output Signal characteristics Given input and system information, solve for the response Solving differential equation.
Frequency domain analysis and Fourier Transform
1 Fourier Representation of Signals and LTI Systems. CHAPTER 3 School of Computer and Communication Engineering, UniMAP Amir Razif B. Jamil Abdullah EKT.
Eeng360 1 Chapter 2 Linear Systems Topics:  Review of Linear Systems Linear Time-Invariant Systems Impulse Response Transfer Functions Distortionless.
Chapter 2. Signals and Linear Systems
CH#3 Fourier Series and Transform 1 st semester King Saud University College of Applied studies and Community Service 1301CT By: Nour Alhariqi.
Math for CS Fourier Transforms
Time Domain Representations of Linear Time-Invariant Systems
Then,  Fourier Series: Suppose that f(x) can be expressed as the following series sum because Fourier Series cf. Orthogonal Functions Note: At this point,
Signal Fndamentals Analogue, Discrete and Digital Signals
Lecture 7: Basis Functions & Fourier Series
Linear Constant-Coefficient Difference Equations
Chapter 2. Signals and Linear Systems
Review of DSP.
Opracowanie językowe dr inż. J. Jarnicki
CEN352 Dr. Nassim Ammour King Saud University
SIGNALS PROCESSING AND ANALYSIS
Recap: Chapters 1-7: Signals and Systems
Signals and Systems EE235 Lecture 26 Leo Lam ©
Description and Analysis of Systems
Chapter 2. Fourier Representation of Signals and Systems
UNIT II Analysis of Continuous Time signal
Research Methods in Acoustics Lecture 6: Musical Acoustics
Signals and Systems Networks and Communication Department Chapter (1)
DCSP-3: Fourier Transform (continuous time)
Research Methods in Acoustics Lecture 9: Laplace Transform and z-Transform Jonas Braasch.
Research Methods in Acoustics Lecture 6: Musical Acoustics
3 General forced response
Signal and Systems Chapter 2: LTI Systems
UNIT-I SIGNALS & SYSTEMS.
Advanced Digital Signal Processing
Notes Assignments Tutorial problems
LECTURE 18: FOURIER ANALYSIS OF CT SYSTEMS
Signals and Systems EE235 Leo Lam ©
Correlation, Energy Spectral Density and Power Spectral Density
Lesson Week 8 Fourier Transform of Time Functions (DC Signal, Periodic Signals, and Pulsed Cosine)
Signals and Systems Lecture 2
Signals and Systems Revision Lecture 1
LECTURE 02: BASIC PROPERTIES OF SIGNALS
Review of DSP.
Presentation transcript:

Research Methods in Acoustics Lecture 7: Convolution and Fourier Transform Jonas Braasch Partly based on Jens Blauert’s Communication Acoustics script.

Definition of a System system A mathematical model of a physical process that relates the input signal to the output signal (excitation and response) is a system. The unequivocal relationship of two mathematical functions, here s(t) and g(t), is typically referred to as a transformation or system: system e.g., loudspeaker e.g., microphone

System If we know how the system transforms the input signal, we can determine the output signal for a given input signal. The system that we are most interested in this class is the acoustics of a room Today we will learn to determine how a given input signal is transformed through a room. The underlying process is called convolution. For a room, the system is described by the so-called room impulse response for a given source/receiver position configuration.

LTI systems As we will see later, the convolution only works with Linear Time Invariant systems, so-called LTI systems. Two requirements have to be met for an LTI system: 1.) Superpositon (to meet the requirement of linearity) 2.) Displacement Law (to meet the requirement of time invariance)

Superposition Each linear combination of input signals leads to a linear combination of the output signals that are derived from the individual input signals:

Superposition Linear Example

Superposition Non-Linear Example

Displacement Law For any (real) time shift T we find that the shape of the output signal g(t) is independent of the reference point in time of the input signal s(t). Example for time-variant system:

The impulse response of a system As the word impulse response suggests, it is the response of a system to an impulse as input signal. We will now need to define an impulse mathematically to define convolution system (room)

The Kronecker delta function A delta function is a function that is zero for any other values than zero. Two different delta functions with different amplitudes are common. The Kronecker delta is defined as: 1 t0=0 t Kronecker delta

The Dirac delta function The Dirac delta is an impulse of infinite amplitude: Dirac delta Nevertheless, its area is well defined over its distribution: Area of the Dirac delta

The Dirac delta function Using this area definition, we can use the Dirac delta to blend out the value of a signal s(t) at any time instance t we want:

The Dirac delta function Visually speaking, we cut out a very thin piece of our integral using the delta function. f(t) A=1 s(t) d(t-t) t t

Resynthesizing the function s(t) Since the delta function is symmetrical, we can write: Basically, we synthesize the signal s(t) from many delta impulses d(t) that are weighted with s(t). (It is like a cake that while having many cuts, is still a complete cake).

Impulse Response system We can also use the delta function to determine the impulse response h(t) of our system (This is very similar to our approach to hear the impulse response of a room using a hand-clap).

Example for an impulse response Let us start with a good example of an impulse response. There is one type of impulse response we all know by now: The room impulse response. The room impulse response can be measured or heard after performing a hand clap. We measure the response of the room by ear or microphone: room (system)

Example for an impulse response h(t) direct sound early reflections late reflections t Even though we excite the room only at one point in time t with d(t−t), we receive a response that is spread over time. Since the room responds to events that happened in the past, it has some type of memory. Memory of d(t−t) after T seconds h(t) t t t+T

Room Impulse response The memory effect is induced due to the circumstance that the sound needs time to travel through the room (with the speed of sound). The sound is typically reflected one or more times before it reaches the listener’s position. For most purposes, it is valid to assume that the room is an LTI system. In reality, the room impulse response changes constantly, because of temperature fluctuations in the room and the fact that the speed of sounds is dependant on T. Since the room is an LTI system, the overall amplitude of the room response is in linear relation to the amplitude of the hand clap. Furthermore, we receive the same room response for a hand clap of the same amplitude at any point in time.

Linearity Example for an impulse response s(t) g(t) ad(t−t) ah(t−t) t t 0.5ad(t−t) 0.5ah(t−t) t t a is a constant

Double Handclap (double excitation) + hand clap 1.+2.

Two hand claps (previous slide) Now, let us consider what will happen, if we carry out a second hand clap before the room response to the first hand clap fully decayed. Naturally, the room would respond to the second hand clap, but still would finish its response to the first hand clap. Both impulse responses will add up – delayed in time according to the superposition equation:

Simple impulse response Consisting of only the direct sound a1 at t1 and one reflection a2 at t2. a1 a2 t1 t2 t The transformation of a signal x(t) will be similar to our organ pipe Simulation from last week:

Simple impulse response x (t) t t rd(t − T) rx (t−T) t t

Convolution We can now generalize the equation above to any impulse response with N reflections: With the impulse response h:

General Convolution Since we can synthesize any signal in time using weighted impulse responses, we can generalize our finding about the response of the room to two hand claps. We just have to replace the delta function with the impulse of our room:

Convolution f(t) s(t) h(t-t) t t Convolution

Convolution f(t) s(t) h(t-t) t t current point in time Point in past time. The value of the impulse response at this point is weighted with the corresponding signal. This memorized part of the impulse response is audible at t.

Convolution t t + t t d(t=0) d(t)=1 for t=0 =0 elsewhere rd(t − T) Impulse response of a cylindrical resonator

Convolution t t t t + t t t t x (t) d(t=0) rd(t − T) rx (t−T)

Convolution Now let us go into the digital domain with the time indices n and k. We can now generalize the last equation: Impulse Response Convolution impulse response 2. time signal With the help of the convolution, we can calculate the output y(k) for an input signal x(k) and the impulse response h(k).

Definition of Convolution A convolution is an integral that expresses the amount of overlap of one function as it is shifted over another function . It therefore "blends" one function with another. http://mathworld.wolfram.com/Convolution.html In mathematics and, in particular, functional analysis, convolution is a mathematical operator which takes two functions f and g and produces a third function that in a sense represents the amount of overlap between f and a reversed and translated version of g. A convolution is a kind of very general moving average, as one can see by taking one of the functions to be an indicator function of an interval. http://en.wikipedia.org/wiki/Convolution

Convolution z(k)= x(k)*y(k)= S x(m) y(k-m) + k,m: samples in time inf z(k)= x(k)*y(k)= S x(m) y(k-m) m=-inf + k,m: samples in time x: signal y: impulse response z: convolved signal

Convolution [signal,Fs]=wavread('MarlabSoloMono2'); [ir,Fs]=wavread('gs201m.wav'); tic y=conv(signal,ir); toc y=0.8.*y./max(abs(y)); wavwrite(y,Fs,'ConvSignal.wav'); Elapsed time is 403.312000 seconds. Name Size Bytes Class Fs 1x1 8 double array ir 121466x1 971728 double array signal 326707x1 2613656 double array y 448172x1 3585376 double array

Fourier Transformation We would now like to develop a technique to analyze the frequency content of a signal s(t). The most common technique is the so-called Fourier Transformation. A period function is defined as: with T the period. A periodic function will repeat itself every interval of T. s = for all t that are element of R

Fourier Transformation According to Fourier, we can write every period function as a series of cosine and sine functions with multiple frequencies (the so-called Fourier Series): with

Rectangular wave function Other signals that are often used in electronics are the square wave the sawtooth and the triangular function. Each of the signals is synthesized by adding several sinusoids with its frequencies n being multiples of the fundamental frequency f to create a harmonic frequency spectrum. The square-wave function is defined as:

Sawtooth Function

Triangular wave function

Orthogonal relationships The sine and cosine functions follow the following orthogonal relationships: k, l=harmonic indices Kronecker delta:

Fourier coefficients to insert into: The orthogonal relationships between the sine and cosine functions are helpful to determine the Fourier coefficients: to insert into:

Inverse Fourier Transformation We can group each pair: to one frequency. Using ak and bk we can set the phase: and amplitude:

Fourier Transformation with e-function Basically, we can also treat non-harmonic functions by setting T to ∞. We can also use the complex e-function instead of sine and cosine: x=2pt, T→∞

Relationship between exp and sine Proof:

Fourier Transformation for NON-harmonic signals (T→∞) S(f) is complex! Inverse Fourier transformation

Now let us apply the Fourier transform to convolution Now we easily separated s and h Because of the orthogonal relationships and the superposition principle, we can generalize our finding to any s(t) [no proof].

FFT and convolution in Matlab function [y_fft,y_trad]=fftconv(x,h); % traditional convolution tic y_trad=conv(x,h); toc % fft convolution Y=fft(x,(length(x)+length(h)-1)); H=fft(h,(length(x)+length(h)-1)); G=Y.*H; y_fft=real(ifft(G));