+ All Categories
Home > Documents > Homework 9

Homework 9

Date post: 01-Jan-2016
Category:
Upload: jolie-williams
View: 32 times
Download: 0 times
Share this document with a friend
Description:
Chapter 6. Identification from Step Response. Homework 9. Time Percent Value Method Determine the approximation of the model in the last example, if after examining the t / t table, the model order is chosen to be 4 instead of 5. Solution to Homework 9. Chapter 6. - PowerPoint PPT Presentation
18
President University Erwin Sitompul SMI 10/1 Lecture 10 System Modeling and Identification Dr.-Ing. Erwin Sitompul President University http://zitompul.wordpress.com 2 0 1 4
Transcript
Page 1: Homework 9

President University Erwin Sitompul SMI 10/1

Lecture 10

System Modeling and Identification

Dr.-Ing. Erwin SitompulPresident University

http://zitompul.wordpress.com

2 0 1 4

Page 2: Homework 9

President University Erwin Sitompul SMI 10/2

Homework 9Chapter 6 Identification from Step Response

Time Percent Value MethodDetermine the approximation of the model in the last example, if after examining the t/t table, the model order is chosen to be 4 instead of 5.

Page 3: Homework 9

President University Erwin Sitompul SMI 10/3

t/τ Table

5 values of ti/τ are to be located for n = 4

10 1.8t

30 2.7t

50 3.6t

70 4.8t

90 6.7t

405.97

6.7

296.04

4.8

23.56.53

3.6

186.67

2.7

126.67

1.8

avg

(5.97 6.04 6.53 6.67 6.67)6.38

5

4

50( )

(6.38 1)G s

s

Result:

Solution to Homework 9Chapter 6 Identification from Step Response

Page 4: Homework 9

President University Erwin Sitompul SMI 10/4

Solution to Homework 9Chapter 6 Identification from Step Response

Step Response

Time (sec)

0 5 10 15 20 25 30 35 40 45 50 55 60 65 700

10

20

30

40

50

60

70

80

90

100

110

120

130

140

150

: 5th order approximation: 4th order approximation

Page 5: Homework 9

President University Erwin Sitompul SMI 10/5

Least Squares MethodsChapter 6 Least Squares Methods

The Least Squares Methods are based on the minimization of squares of errors.

The errors are defined as the difference between the measured value and the estimated value of the process output, or between y(k) and y(k).

There are two version of the methods: batch version and recursive version.

^

Page 6: Homework 9

President University Erwin Sitompul SMI 10/6

Least Squares MethodsChapter 6 Least Squares Methods

Consider the discrete-time transfer function in the form of:1

11

1

( )1

mm

nn

b z b zG z

a z a z

The aim of Least Squares (LS) Methods is to identify the parameters a1, ..., an, b1, ..., bm from the knowledge of process inputs u(k) and process output y(k).

As described by the transfer function above, the relation of process inputs and process outputs is:

1 1( ) ( 1) ( ) ( 1) ( )n my k a y k a y k n b u k b u k m

Page 7: Homework 9

President University Erwin Sitompul SMI 10/7

Least Squares MethodsChapter 6 Least Squares Methods

This relation can be written in matrix notation as:T( ) ( )y k km θ

where: T

1 1n ma a b bθ

T ( ) ( 1) ( ) ( 1) ( )k y k y k n u k u k m m

• Vector of Parameters

• Vector of Measured Data

Hence, the identification problem in this case is how to find θ based on the actual process output y(k) and the measured data from the past m(k).

Page 8: Homework 9

President University Erwin Sitompul SMI 10/8

Least Squares MethodsChapter 6 Least Squares Methods

Assuming that the measurement was done for k times, with the condition k ≥ n + m, then k equations can be constructed as:

1 1(1) (0) (1 ) (0) (1 )n my a y a y n b u b u m

1 1(2) (1) (2 ) (1) (2 )n my a y a y n b u b u m

1 1( ) ( 1) ( ) ( 1) ( )n my k a y k a y k n b u k b u k m

or:T

T

T

(1)(1)

(2) (2)

( ) ( )

y

y

y k k

m

m

Y Mθ

Page 9: Homework 9

President University Erwin Sitompul SMI 10/9

If M is nonsingular, then the direct solution can be calculated as:1θ M Y

In this method, error is minimized as a linear function of the parameter vector.

The disadvantage of this solution is, that error can be abruptly larger for t > k.

Least Squares MethodsChapter 6 Least Squares Methods

• Least Error (LE) Method, Batch Version

Page 10: Homework 9

President University Erwin Sitompul SMI 10/10

Least Squares MethodsChapter 6 Least Squares Methods

A better way to calculate the parameter estimate θ is to find the parameter set that will minimize the sum of squares of errors between the measured outputs y(k) and the model outputs y(k) = mT(k)θ

^

2T

1

( ) ( )i

k

J y k k

θ m θ

T Y Mθ Y Mθ

T T T T T T Y Y Y Mθ θ M Y θ M Mθ

The extreme of J with respect to θ is found when:

0

dJ

d

θ

θ

Page 11: Homework 9

President University Erwin Sitompul SMI 10/11

The derivation of J(θ) with respect to θ can be calculated as:

Least Squares MethodsChapter 6 Least Squares Methods

T TTd d

d d Ax A x A

x xif A symmetric

T T T0 2dJ

d

θM Y M Y M Mθ

θ

T T T T T TJ θ Y Y Y Mθ θ M Y θ M Mθ

TTd

d x Ax A A x

x2 Ax

0

T T2 2M Y M Mθ

1T Tθ M M M Y• Least Squares (LS) Method,

Batch Version

Page 12: Homework 9

President University Erwin Sitompul SMI 10/12

Performing the “Second Derivative Test”,

Least Squares MethodsChapter 6 Least Squares Methods

Second Derivative Test• If f ’(x) = 0 and f ”(x) > 0 then f has a local minimum at x• If f ’(x) = 0 and f ”(x) < 0 then f has a local maximum at x• If f ’(x) = 0 and f ”(x) = 0 then no conclusion can be drawn

T T T0 2dJ

d

θM Y M Y M Mθ

θ

2T

2 2d J

d

θM M

θAlways positive definite

1T T θ M M M Y is a solution that will minimize the

squares of errors

Page 13: Homework 9

President University Erwin Sitompul SMI 10/13

In order to guarantee that MTM is invertible, the number of row of M must be at least equal to the number of its column, which is again the number of parameters to be identified.

More row of M increase the accuracy of the calculation. In other words, the number of data row does not have to be the same as the sum of the order of numerator and denominator of the model to be identified.

If possible, rows with any value assumed to be zero (because no measurement data exist) should not be used.

Least Squares MethodsChapter 6 Least Squares Methods

Page 14: Homework 9

President University Erwin Sitompul SMI 10/14

The parameters of a model with the structure of:

Example: Least Squares MethodsChapter 6 Least Squares Methods

22

1 1 21 2

( )1

b zG z

a z a z

are to be identified out of the following measurement data:0 1 2 3 4 5 6

( ) 0.5 0.8 0.2 0.8 0.7 0.8 0.7

( ) 0 0 1 1.4 0.6 5.4 17.2

k

u k

y k

Perform the batch version of the Least Squares Methods to find out a1, a2, and b2.

Hint: n + m = 2 + 1 At least 3 measurements must be available/ utilized.Hint: If possible, avoid to many zeros due to unavailable data for u(k) = 0 and y(k) = 0, k < 0.

Page 15: Homework 9

President University Erwin Sitompul SMI 10/15

Using the least allowable data, from k = 2 to k = 4, the matrices Y and M can be constructed as:

(2)

(3)

(4)

y

y

y

Y

0 1 2 3 4 5 6

( ) 0.5 0.8 0.2 0.8 0.7 0.8 0.7

( ) 0 0 1 1.4 0.6 5.4 17.2

k

u k

y k

T

T

T

(2)

(3)

(4)

m

M m

m

1

1.4

0.6

(1) (0) (0)

(2) (1) (1)

(3) (2) (2)

y y u

y y u

y y u

0 0 0.5

1 0 0.8

1.4 1 0.2

Example: Least Squares MethodsChapter 6 Least Squares Methods

1

2

2

a

a

b

θ

Page 16: Homework 9

President University Erwin Sitompul SMI 10/16

Example: Least Squares MethodsChapter 6 Least Squares Methods

1T

3.56 5.62 3.20

5.62 9.93 5.28

3.20 5.28 4

M M

T

2.24

0.6

0.5

M Y

1T Tθ M M M Y

3

4

2

1

2

2

a

a

b

2

1 1 2

2 ( )

1 3 4

zG z

z z

Page 17: Homework 9

President University Erwin Sitompul SMI 10/17

Homework 10Chapter 6 Least Squares Methods

Redo the example, utilizing as many data as possible. Does your result differ from the result given in the slide? What could be the reason for that? Which result is more accurate?

Page 18: Homework 9

President University Erwin Sitompul SMI 10/18

Homework 10AChapter 6 Least Squares Methods

Redo the example, utilizing least allowable data, if the structure of the model is chosen to be

11

2 1 21 2

( )1

b zG z

a z a z

After you found the three parameters a1, a2, and b1, for G2(z), use Matlab/Simulink to calculate the response of both G1(z) and G2(z) if they are given the sequence of input as given before.

2

1 1 2

2( )

1 3 4

zG z

z z

Compare y(k) from Slide 10/15 with y1(k) and y2(k) from the outputs of the transfer functions G1(z) and G2(z). Give analysis and conclusions.

0 1 2 3 4 5 6

( ) 0.5 0.8 0.2 0.8 0.7 0.8 0.7

k

u k

Odd-numbered Student-ID

11

2 11

( )1

b zG z

a z

Even-numbered Student-ID


Recommended