You are on page 1of 17

CONVOLUCIN La entrada (Seal original) se divide en puras seales impulso La salida proporciona una respuesta al impulso para cada

entrada impulso. La salida correspondiente a la seal original se forma sumando las respuestas impulso individuales.

Sistema

Proceso de convolucin: (n)

Respuesta real del sistema:

Any impulse can be represented shifted and scaled: X[n] Input y[n] Output h[n] Impulse response Considere una seal a[n] que solamente contiene un valor -3 en la muestra 8:

A[n] = -3 [n-8]
Amplitud Homogeneidad: Si [n] es entrada y h[n] es salida entonces -3 [n-8] es entrada Convolution: Takes two signals and produce a third signal. Input signal + Linear system h[n] Impulse response + x[n] Output signal x[n] *h[n] = y[n] Muestra nmero 8

y -3h [n-8] es salida.

y[n]

FIGURE 6-1 Definition of delta function and impulse response. The delta function is a normalized impulse. All of its samples have a value of zero, except for sample number zero, which has a value of one. The Greek letter delta, *[n], is used to identify the delta function. The impulse response of a linear system, usually denoted by h[n] , is the output of the system when the input is a delta function. Ejemplo de aplicacin de la convolucin:

FIGURE 6-3 Examples of low-pass and high-pass filtering using convolution. In this example, the input signal is a few cycles of a sine wave plus a slowly rising ramp. These two components are separated by using properly selected impulse responses.

CHAPTER 2. - CONVERTING ANALOG TO DIGITAL SIGNALS VICE VERSA (Pag 14)

Figure 2.1. The three stages of analogdigitalanalog conversions

FIGURE 2.2. Temperature variation throughout a day.

TABLE 2.1. Temperature measured at each hour of a day.

FIGURE 2.3. (Ver pag 16) The sampling process. 2.2.1. Sampling Theorem

FIGURE 2.4. Two bandlimited spectra. 2.2.2. Frecuency Domain Interpretation (pag 18)

FIGURE 2.5. Replication of spectrum through Sampling

FIGURE 2.6. The original low-pass spectrum and the replicated spectrum after sampling.

FIGURE 2.7. Aliasing. 2.2.3. Aliasing

FIGURE 2.9. Interpolation of sample points with no aliasing.

FIGURE 2.10. Effect of aliasing.

FIGURE 2.11. The analog-to-digital conversion process with anti-alias filtering. 2.2.5. Practical Limits on Sampling Rates. 2.3. Quantization.

FIGURE 2.13. Sample and hold circuit.

2.3.2. Uniform Quantization (Toda la pagina 25 28) 2.3.2. Non Uniform Quantization (Pag 28 - 30) 2.4. ADC (Pag 34) 2.4.3. Flash ADC (Pag 36) 2.4.4. Sigma Delta (Oversampling) (Pag 37 39) 2.5. Analog Reconstruction (Pag 42) 2.5.1. Ideal Reconstructor. 2.5.2. Starcase Reconstructor. 2.6. Digital to Analog Converters. Frecuency Domain (Fourier) + Siglas asociadas. (Pag 61) 4.1. Discrete Fourier series for discrete time periodic signals. Fourier Transformada Laplace Z Transformada de Fourier Real (la ms simple) Complex: Requiere el uso de nmeros complejos Los matemticos los adoran ( ingenieros j, matemticos i) we need periodicity permite el uso de herramientas matemticas

y = 2x + 1 entra x y sale y

funcin Restriccin de las transformadas y=x+z y x,z ? warning y Very important

Resumen: Transformada

Montn de datos

Montn de datos

x[ ] 0 N-1 0

Re X[ ] N/2 0
N/2 + 1 samples Amplitud de los cosenos X[ ]

lm X[ ] N/2
N/2 + 1 samples Amplitud de los senos

Time Dmain Time DFT

The same information (in adiferent form) Frecuency DFT

Frecuency Domain

Inverse

N: Number of samples in the time domine (positive integer) a powerof two is usually chosen (due to digital system: i.e, 128, 256, 512, 1024, etc). FFT: Operates with a power of two. N: Samplse run from 0 to N-1 en lugar de 0 1 N Notation: Lower case letters Upper case letters Time domine X[0] to x[N-1] Frecuency Domine Re X[0] to Re X[N/2] Lm X[0] to lm X[N/2] Time Domine x[ ], y[ ] Frecuency Domine X[ ], Y[ ], Real DFT!! No usaremos Complex DFT Cosine wave amplitude Sine wave amplitude N samples Time N complex numbers Frecuency

N = 128 X[0] to x[127]

Re X[0] to Re X[64] lm X[0] to lm X[64]

65 puntos N/2 + 1 puntos

Metodos para etiquetar el eje horizontal: First method labeled from 0 64 los indices son enteros Re X[k] and Im X[k], k runs from 0 to N/2 in steps of one

FIGURE 8.4.
Example of the DFT. The DFT converts the time domain signal, x[ ], into the frequency domain signals, ReX[ ] and Im X[ ]. Thehorizontal axis of the frequency domain can be labeled in one of three ways: (1) as an arrayindex that runs between 0 and N/2, (2) as afraction of the sampling frequency, runningbetween 0 and 0.5, (3) as a natural frequency,running between 0 and B. In the example shown here, (b) uses the first method, while (c) use the second method.

Second method Horizontal axis labeled as a FRACTION OF THE SAMPLING RATE label from 0 to 0.5 (frequencies between DC and one-half of the sampling rate. Index used is f, for frecuency, Re X[f] and Re Im X[f] where f takes N/2 + 1 equally spaced values between 0 and 0.5. Third method Similar to the past one, but the horizontal axis is multiplied by 2. The index used is (omega). Re X[] and Im X[] where takes on N/2 + 1 equally spaced values between o and . is called the NATURAL FRECUENCY (Radianes) Forth method Label the horizontal axis in terms of the analog frequencies used in a PARTICULAR APPLICATION. For example a sampling rate of 10KHz (10000 samples/second) the horizontal axis will run from 0 to 5KHz. Advantage Real world meaning. Drawback It is tied to a particular sampling rate. Not applicable to DSP algorithm development. Re X[ ]

Cosenos con amplitud unitaria By choosing the proper amplitudes (the basis functions), the result is a set of scaled sine and cosine waves that can be added to form the time domain signal. Ck[i] = Cos(2ki/N) Sk[i] = Sin(2ki/N) Cosines Sines

For each N points: where i is runnin from i = 0 to I = N-1 Parameter k determines the frecuency of the wave, k goes from 0 to N/2. *Nueva seccin a agregarle al programa Re X[k] ACos Smando el Im X[k] BCos Seno y Coseno Se genera : ACos( )+Bsen( ) = MCos(

DFT Re X[k] = Im X[k] = -

Practica de Fourier [] []

Ejemplo: Seal cuadrada: 60.. .. 10 15 20 samples 20mS

05

Sintesis equation:

X[i] =
El indice i corre desde 0 a N-1.

[ ]

(2ki/N) +

[ ]

(2ki/N)

and hold the amplitudes of the cosine and sine waves respectively. k runs from 0 to N/2.
[ ] [ ] [ ] [ ] [ ] [ ]

M= B

ReX[k] = ImX[k] =

[ ] [ ]

[ ] [ ]

Aplicaciones En electrnica de potencia, anlisis del contenido armnico de convertidores de potencia AC/DC rectificadores, DC/AC inversores, facturacin de potencia por parte del proveedor.

ANALISIS ESPECTRAL DE SEALES


1) La forma no importa solamente la frecuencia, fase y amplitud 2) Una secuencia de datos lleva ruido debido a la medicin. Dos opciones La magnitud se promedia (Ventanas Hamming) con datos usados en el DFT cortos (nmero de puntos bajo) Bajo resolucin en frecuencia. 2 option Datos de DFT muy largos (una gran resolucin en frecuencia) pero sigue igual de ruidoso. Se usa un filtro paso bajo para suavizar la seal y quitar el ruido

Primer mtodo Segundo mtodo resolucin.

Fcil. Mejor desempeo

porque se puede optimizar la resolucin ruido-

Cualquiera que se use:

Espectro de la seal:

FIGURE 9.2. Example frequency spectrum. Three types of features appear in the spectra of acquired signals: (1) random noise, such as white noise and 1/f noise, (2) interfering signals from power lines, switching power supplies, radio and TV stations, microphonics, etc., and (3) real signals, usually appearing as a fundamental plus harmonics. This example spectrum (magnitude only) shows several of these features. Ver nmero de puntos (Resolucin de frecuencia):

FIGURE 9.3. Frequency spectrum resolution. The longer the DFT, the better the ability to separate closely spaced features. In these example magnitudes, a 128 point DFT cannot resolve the two peaks, while a 512 point DFT can.

DIGITAL FILTERS
Televisin (UHF, VHF) 1. Separacin de seales que se han mezclado Radio (AM, FM, etc.) Convertidores de potencia (PWM)

2. Restauracin de seales que se han distorsionado en alguna forma, equipo de baja calidad usado. Two Analog filters flavors Digital filters cheap fast, large dynamic range * Para grabar audio Amplitude and frequency * Mejoramiento de imgenes
Ejemplo:

Muy superiores en el desempeo

Ganancias de 1 0.0002 DC Less tan 0.0002 > 1001Hz

1000Hz

Ni en sueos y con peyote es posible Esto con OP AM

Cada filtro lineal tiene

Impulse Response Step Response Frequency Response

Con uno se generan los otros dos

El mtodo mas directo: Impulse Response, (FIR) ya sabemos como usarlo (Convolucin) Alternativa: RECURSIVE FILTERS (IIR) Usa valores previos de la salida adems de datos de la entrada. Recursive Filters: Infinite . Impulse Response (IIR) Filters. Respuestas al impulso con una respuesta que cae de forma exponencial.

Convolution Based Filters (Finite Impulse Response) (FIR filters)

REPASO DE DB

dB =

Para potencias

Para amplitudes Memorizar: -3dB Amplitud reduced to 0.707 y la potencia se reduce a 0.5.

60dB = 1000 40dB= 100 20dB = 10 0dB = 1 -20dB = 10 -40dB = 100 -60dB = 1000

En amplitud

It is not possible optimizer un filtro para ambos mundos: Good performance in the time domain results in poor performance in the frequency domain, and vice versa.

Poor step response Good frequency response

Good time domain response Bad frequency response

TIME DOMAIN PARAMETERS

FIGURE 14.2. Parameters for evaluating time domain performance. The step response is used to measure how well a filter performs in the time domain. Three parameters are important: (1) transition speed (risetime), shown in (a) and (b), (2) overshoot, shown in (c) and (d), and (3) phase linearity (symmetry between the top and bottom halves of the step), shown in (e) and (f).

h[n] x[n] +

y[n]

La fase debe ser igual a todas las frecuancias si no no se puede realizer la diferencia.

[n]

Se dividen por el uso : USE, IMPLEMENTED.

TABLE 14.1. Filter classification. Filters can be divided by their use, and how they are implemented.

CHAPTER 15: MOVING FILTERS CHAPTER 16:


Window Sinc Filters Dominio de la frecuencia, separar una frecuencia de otra. (Muy biuenos) Tienen un pobre funcionamiento en el dominio del tiempo, Ripple and overshoot in the step response. Fillter kernel (Respuesta al impulso del filtro) This provides a perfect low pass filter

[]

Its not a problema for mathematics, it is a problema for computers!! El espectro va de a + . Por tanto hay que hacer modificaciones, truncar a M + 1 points around the main lobe. M even number. All samples outside M + 1 points are set toz ero. Entire sequence is shifted to the right so that it runs from 0 to M (we get only positive indexes). But changes provide excessive ripple in the pass band and poor attenuation in the stop band. Solciones? Ventanas Hamming Blackman

w[i] = 0.54 0-46Cos(2i/M) w[i] = 0.42 0.5Cos(2i/M) + 0.08Cos(4i/M)

Cual usar? Its a tsade off. Hamming window 20% faster roll off than the Blackman (-53dB 0.2%) Blackman has better stopband attenuation (-74dB stop bad attenuation 0.02%) Designing the filter: Cutoff frecuency, fc Fraction of the sampling rate between 0 and 0.5. Length of the filter kernel, M Sets the roll of according to:

Width of the transition band


fc symetrical Function of the sampling frequency (between 0 and 0.5) 99% 1% Cutoff frequency, at the one half amplitude pint (Symetrical)

Computational time Filter Sharpness

Depends on the value of M Depends of the value of BW

Este algoritmo es lento

Porque es importante la simetra? Permite lograr la inversin espectral (spectral inversin). Una vez que se tiene fc M, we can calculate the filter kernel as follows:

[]

)]

)]

M i k

Value between 0 and 0.5 (fraction of the sampling rate) Length of the filter kernel (even integer) An integer that runs from 0 to M (m + 1 points) is chosen to provide unity gain for i = M/2, use h[i] = 2

CHAPTER 19:
Convolution Filters Recursive Filters (Infinite impulse Response IIR) (Impulse responses are composed of decaying exponentials)

y[ ]
x[ ] FIR y[ ] X[ ] IIR

y[ ]

Como cualquier sistema realimentado puede llegar a oscilar [ ] [ ] [ ] [ ] [ ] [ ] [ ] [ ]

The recursin equation de donde: x[ ] the input signal y[ ] the output signal a,b coefficients (In practice, no mate than a dozen recursion coefficients are used) Lo que hacen? Se saltan el proceso de convolucin!!. Si ya conoces de antemano los coeficientes ya no se necesita hacer la convolucin. Z transform Coeficientes (relationship) filters response Out of scape of this course

SINGLE POLE Low pass filter

+ vin -

R C

+ vout -

High pass filter Single pole low pass The amount of decay between adjacent samples Single pole High pass

+ vin

+ vout -

Very important: Single pole recursive filters have little ability to separate one band of frequency from others. Perform well in the time domain, and poorly in the frequency domain. Solucion : filtros en cascada. Pasar una seal por el filtro varias veces Usar la transformada Z para en un solo filtro dar la respuesta of a higher order filter by means the proper choice of the recursion coefficients If this do not fulfill yourrequirements, look at the Chebyshev filters

NARROW BAND FILTERS


It comes in two flavors: Band pass Band reject (notch filter) 1. Band pass Band reject Select center frequency and Bandwidth BW Next calculate R then k Recursion coefficients.