0% found this document useful (0 votes)
59 views9 pages

Adaptive Predictor Computer Experiments

This document describes an experiment using an LMS algorithm and an adaptive first-order predictor to model an autoregressive (AR) process. It discusses generating an AR(1) process with different parameters, initializing and updating the predictor weights according to the LMS equation, repeating this process over multiple iterations and trials to compute average weights. Results are shown comparing the predictor's learned weights to the actual AR process parameter for two cases. The document also presents the equations for an AR(2) process and provides Matlab code for generating different realizations of an AR(2) process.

Uploaded by

ushapverma
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
59 views9 pages

Adaptive Predictor Computer Experiments

This document describes an experiment using an LMS algorithm and an adaptive first-order predictor to model an autoregressive (AR) process. It discusses generating an AR(1) process with different parameters, initializing and updating the predictor weights according to the LMS equation, repeating this process over multiple iterations and trials to compute average weights. Results are shown comparing the predictor's learned weights to the actual AR process parameter for two cases. The document also presents the equations for an AR(2) process and provides Matlab code for generating different realizations of an AR(2) process.

Uploaded by

ushapverma
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 9

LMS Algorithm - Computer

Experiments
Experiment 1: Adaptive Predictor
AR(1) Process
Autoregressive process of order 1 is defined as:
u ( n )=au ( n1 ) +v ( n)
where,
'a' is the parameter of AR(1) process
'v(n)' is WGN with variance

2v

Adaptive First order Predictor

u(n)

Z-

u(n-1)

w (n)
w (n)u (n 1)
+

f(n)

Fig 1: Adaptive First order Predictor

LMS weight update equation is:


w
^ ( n+1 )=^
w ( n )+ u ( n1 ) f (n)
f ( n )=u ( n ) w
^ ( n ) u(n1)

Experiment Results
Experiment is carried out with the following cases:
Case1:
a= -0.99
Variance of u(n)= 0.93627
Case2:
a= +0.99
Variance of u(n)= 0.995
The Step size parameter is taken as =0.05 and initial condition

Steps:
1. Generate AR process
u ( n )=au ( n1 ) +v ( n)

2. Initialize
3. Update

w
^ ( 0 )=0
w
^ (n )

w
^ ( n+1 )=^
w ( n )+ u ( n1 ) f (n)

w
^ ( 0 )=0

f ( n )=u ( n ) w
^ ( n ) u(n1)

4. Repeat step 3 for 500 iterations.


5. Repeat steps 1 to 4 for 100 times and compute ensemble average of
w
^ (n )

Figure 2 shows the transient behavior of


E (w
^ (n ))

w
^ ( n ) . It also shows the

obtained by the ensemble averaging of 100 independent trials.

The experimental learning curves of adaptive first order prediction for


varying step size parameter is shown in Fig.

Problem 5.21
AR(2) Process
Autoregressive process of order 2 is defined as:
u ( n )=a1 u ( n1 )a2 u ( n1 ) + v (n)
a1=0.1
a2=0.8
2
a) Noise variance v

2
such that u =1

( 1a2 ) (( 1+ a2 ) a1 ) 2
=
u
( 1+ a2 )
2
v

v =0.27

Matlab Code for different realization of u(n)


var_v=(1-a2)*((1+a2)^2-a1^2)/(1+a2);
% initial values of u(n)
u(1)=var_v*randn(1,1); %
u(2)=-a1*u(1)+var_v*randn(1,1);
for n=3:N
u(n)=-a1*u(n-1)-a2*u(n-2)+var_v*randn(1,1);
end

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy