Вы находитесь на странице: 1из 30

..

" "

.., ..


MATLAB
( 050702)
2

2005

62.50
: .., ...
.
MATLAB (
050702). 2. : , 2005.
30.



.

,
MATLAB .

050702.
.3. . 1. . 7 .
: .., . . ., .


2005 .
, 2005




,
.
,

.
,
: ,
, ,
, ,

MATLAB.

,
,
.

:


;
MATLAB;

.
,
:
;
;
, ,
, , ;

;
.

.

7.

:
.
7.1

,
.
.
,
.


a0 y ( n ) (t ) a1 y n 1 (t ) ... an y (t ) b0u ( m ) (t ) ... bm u (t ),
(7.1)
y (t 0 ) y0 (t ),..., y ( n 1) (t 0 ) yon 1 (t ),
(t) ;
u(t) ;
0, 1,...,an; b0,...,bm ;
n m n.


y(t)= y (t)+ (t),
(7.2)
(t) ,
;
y(t) ,
.


a0 y (n) (t ) a1 y n 1 (t ) ... an y(t ) 0, y(t0 ) y0 (t ),..., y (n 1) (t0 ) yon 1 (t ) . (7.3)

(7.1) .
. ( 7.1)
,
(t)
t t0 ,
lim y(t ) 0 . ( 7.1)
t

, u(t)
y(t)
t t0 , . ,
,
.
4

..

u(t)

y(t)

y(t)

7.1

(7.3)
n

y c (t )

i 1

yi (t )

i e s t ,

(7.4)

i 1

yi(t) i (7.4);
Ci , ;
si
a0 s n a1s n 1 ... an 1s an 0 .
(7.5)
si

i
(7.4) yi Ci e t . ,
i<0
( 7.2), ai>0
( 7.2) i=0
Ci ( 7.2).

i

yi (t ) Ci e

Ci 1e

Ae t sin t
i

A .
ai<0
( 7.2), ai>0 ( 7.2),
ai=0 ( 7.2).
.
,
.

, .
,
:
1 ;
2 ;
3 .
,
(7.5)
an=0. ,
(t).

( 7.2).
5


, .
Ck e t (7.4), k, ,
(7.3)
.
k

y (t)
Ci

i<0

y (t)

y (t)
Ci
t

i=0

i>0

Ci

t
)

t
)

1)
y (t)

y (t)

i<0

y(t)

i>0

i=0

2)
7.2
,
( 7.3)
,

b
h (t ) lim h(t ) m .
an
t

h(t)

h(t)

h(t)

h(t)

7.3
6

7.2
1. ,
7.1 ( 1,2,3).
:
;

;
.
2.
.
, .
3. k T
.
7.1

0
1
2
3
4
5
6
7
8
9

W s
W s
W s

W s
W s

W s
W s

k
Ts 1
k
Ts 1
k
s(Ts 1)
k
T 2s2 1
k
, =0.5
2 2
T s
2T s 1
k
, =0.5
2 2
T s 2T s 1
k

0,5

10

0,5

0,01

100

T1

0,5

0,1

0,1

T2

0,07

0,02

0,02

T3

0,003

0,001

0,002

0,01

T1s 1 T2 s 1

k
(T1 s 1)(T2 s 1)(T3 s 1)
s k
W ( s)
(T1 s 1)(T2 s 1)(T3 s 1)
W ( s)

W ( s)

k
s(T1 s 1)(T2 1)(T3 1)

7.3
CST MATLAB

20
.
W ( s)
0.00025s 3 0.0286s 2 0.36s 1
LTImodel
w, pole(w),
step(w).
>> =tf([20],[0.00025 0.0286 0.36 1])
>> pole(w)
ans =
100.4626
9.9262
4.0112
:
, ,
.
>> step(w)
Step Response
20
18
16
14

Amplitude

12
10
8
6
4
2
0

0.5

1.5

Time (sec)

7.4 ,
step(w)
:
.

h(t)=20,

7.4
1. .
2. ,

3. ( ).
8

8.
:
.
8.1

.
,
.
.

( 8.1),
( 8.2).

.
U(s)

W(s)

Y(s)

8.1
U(s)

W(s)

Y(s)

8.2
8.1.1

a0 s n a1s n 1 ... an 0 ,

a1 a3 ... 0

(8.1)

a0 a2 ... 0
.
(8.2)
0 a1 ... 0
... ... ... an
.
,
(8.1) 0,

(8.2) 0.

8.1.2

,
(8.1)
(8.3)
D( j ) a0 ( j )n a1 ( j ) n 1 ... an Re( ) jIm( ) .
(8.3)
.
.
,
1) ;
0,
2)
(
);
3) n , , n
.
Im
=0
Re

0
=+

8.3 ( n=3 )
Im

Im
=0
Re

Im

=+

=+

) n=4

=0
Re

) n=4

=0
0

Re

=+

) n=2

8.4
8.1.3

.
,
,
. .
1 .
,
,
0
+ (1 ; j0).
10

Im

Im

=+

=0

=+
0

(1,j0)

Im

(1,j0) 0

Re

=0
Re

=+
0

(1,j0)

=0
Re

8.5
2 .
,
, 0
l/2
(1 ; j 0 ) , l .

0 +

1
, .
Im

Im

=+

=+
(1,j0) 0

Re

(1,j0)

)
(l=2)

Re

)
(l=2)

8.6
3 .
,
,
0
, ,
[1;j0].
Im

Im
=+

=+

=0
(1,j0)

Re

=0

(1,j0)

Re

8.7
( R )
11

.
,

1 l/2
, l
.
Im
Im

=+
(1,j0)

=+

Re

(1,j0)

)
(l=2,

1)

Re

)
(l=0,

0)

8.8
8.1.4
.
1 .
,
, (0 )

.
L( )[]
20

10
2
( )[] 10
0

101

10

[c1]

101

10

[c1]

45
90
135
180
102

8.9
12

8.2
8 ,
6.5 ( 3 4).
, 6.5.
.
6.5., .
1 .
.
2 . :
;

;

.
3 . :

(
)
, : ,
, .
.

, (
)
, : ,
, ;
(
MATLAB)
,
: , ,
.
5. .
8.3 8
1 .

10
10
,
. (8.4)
W ( p)
W
(
p
)

1s 3 0.3s 2 0.5s 0.1


1s 3 0.3s 2 0.5s 10.1
(8.4)
0.3 0.1 0
0.3 10.1 0
(8.5)

1 0.5 0 ,

1 0.5
0 .
0

0.3 0.1

0
13

0.3 10.1

CST MATLAB.
(8.5) :

>> G22=[0.3 0.1;1 0.5]
G22 =
0.3000 0.1000
1.0000 0.5000
>> det(G22)
ans = 0.0500
>> G33=[0.3 0.1 0;1 0.5 0;0 0.3 0.1]
G33 =
0.3000 0.1000
0
1.0000 0.5000
0
0 0.3000 0.1000
>> det(G33)
ans = 0.0050


>> G22=[0.3 10.1;1 0.5]
G22 =
0.3000 10.1000
1.0000 0.5000
>> det(G22)
ans =
9.9500
>> G33=[0.3 10.1 0;1 0.5 0;0 0.3 10.1]
G33 =
0.3000 10.1000
0
1.0000 0.5000
0
0
0.3000 10.1000
>> det(G33)
ans =
100.4950

:
1,
a0
,
.
2 .

9
W( p)
.
s(0.4s 1)(0.15s 1)(0.002s 1)
Re( )
Im( ) (8.3).
MATLAB Simulink Re( ) Im( )
Math Operation
Ramp ( 8.10).
.
14

8.10
:
, .
3 . .
1 .
.

)
)
)
) ; )
; ) ; )

8.11
15

2 .
.
)

)
)
) ; )
; ) ; )

8.12
3 . (
Vissim)
.

8.13

8.4
1. .
2. .
3. ,
.
4. , , .
16

9.

:
,
.
9.1
,
. ,
,
,
,
.
,

.
,

:
;
.

.
9.1.1

h(t). ,
,
( 9.1).
h(t)

hmax1

hmax1(t)

hmax2

h(t)

h(t)
hmax2(t)

h(t)

t tax

9.1
17

1. tp,
.
tp ,
h
:
h lim h(t ) .
h h < ,
t

5% h.
= 2% h = 1% h, .
2.


hmax1 h.
%:
hmax 1 h
*100% .
h
,
1030%, 70%. , , = 0.
3.
,
h(t) tp. 12, 34
, .
4. . ( )
hmax 2
*100% .
hmax 1

100%.
, ..
=0.
5.
2 / T ,
.
6.
,

g 0 h

*100%
*100% ,

g0
g0
g0 ;
.
:
7. tmax.
8. t.
9. ,
:
hmax 1 h
.
hmax 2 h
18

9.1.2

,

.
,

()
(, )
:
A3 max ( )
1.
A3 (0)
A3 max ( )
=0 ( 9.2).
3
3max
(

)=1

0,707(0)

9.2
1,11,5,
22,5. ,
.
2. ,
( 9.2), ..

.
3. =0 0,
0,7073(0) 3( ) ( 9.2).
,
.
4. ,
, 1, .. 3( ) =1.
,
2
t p (1 2) .
c

,
t max

.
c

19

9.1.3 .
,
,
(
), .
, ,
, .
.
.
1. .
.

k
.
W ( p)
1s 3 0.3s 2 0.5s 0.05 k

0.3 0.05 k
0
.

1
0.5
0
0
0
0.05 k


a0 1 0,
a1 0.3 0, a2 0.5 0, a3 0.05 k 0,

(0.15 0.05 k ) 0,
0.15 (0.05 k ) (0.05 k ) 2
3 3
,
0.05 k 0,
k
0.05,
2 2

a3

(0.15 0.05 k ) 0,

0.

k 0.1,

0.15 (0.05 k ) (0.05 k ) 2 0,


0.005 0.05k k 2
(k 0.05)( k 0.1) 0.
: ,
0.05 k 0.1.
2. .
,
.

20
.
W ( p)
0.00025s 3 0.0285s 2 0.36s 1
MATLAB
>bode ( 9.3).
,
,
,
k.
20

k ( 9.3)
,
k. ,

20 lg k 60
k 1000 .
=450 =20 ( 9.3)
,
=0 = .
k
Bode Diagram
40

Magnitude (dB)


20

-20

-40
0

Phase (deg)

-45
-90
-135
-180
-2

-1

10

10

10

10

10

Frequency (rad/sec)

9.3
9.2


( 9.4).
U(s)

Y(s)

Y(s)

W(s)

E(s)

9.4 E(s)

I1

e t

h t

e t dt ,

I2

e(t ) dt ,
0

h t ( 9.5).

9.5
21

,
.
, ,
:
1) I1 ;
2) I2
;
3) I2
( ).
1 2 I1 I2
I I'
e 2 (t )dt , I '

I
0

e 2 (t )dt .
0

I1, I2, I I'


I T12 I '

e 2 T12e 2 dt .

9.3
1. ( 7.1),
.
2. ,
k.
3. .
4. e(t).
.
5.
,
, k,
.
6. , /1,
.351-353/, tp .
8. ,
.
9.4
1. .
2. ?
3. ?
4. ?

22

10.

:

. .
10.1 .

, ..
. ,
,
.


.
,
, .
,
,
u(t)
: g(t), /
x(t) , , f (t).

: (), (),
().
: , , ,
.
10.1.1 .

, 10.1.
G(s)

E(s)

U(s)

Y(s)

10.1

k0
.
(10.1)
W ( s)
(T1s 1)(T2 s 1)

23

W(s)

:
k
1 t
1
ut
e t dt ,
:
,
W s
T 0
T s
s
W s k ,
u t k e t ,
:
1 t
U s
u t k e t
e t dt .
:
,
W s k
T 0
T s E s
:
T T1T2 s 3 T (T1 T2 )s 2 T (1 k k0 )s k0 0 .
(,
),

k0T1T2
,
(10.2)
T
(T1 T2 )(1 k k0 )
.

T T1T2 s 3 T (T1 T2 )s 2 T s k0 0 .


k0T1T2
.
(10.3)
T
T1 T2
(10.2) (10.3) ,
,

.


(10.4)
T1T2 s 2 (T1 T2 )s 1 k0 k 0 .
, ,

, , ,
.

10.1.2
,
e t .
e t

e . lim e t .
t

24


.
,
, ,
,
.
,
,

.
,
,
e lim e t lim sE s lim sG s s ,
t

E s L e t ;
G s ,
A
G s L g t
;
L A 1t
s
1
e s
.
1 W s W p s

:
Tu s T1s 1 T2 s 1
:
;
e s
Tu s T1s 1 T2 s 1 k0 kTu s 1
Tu s T1s 1 T2 s 1
:
;
e s
Tu s T1s 1 T2 s 1 k0
T1s 1 T2 s 1
:
.
e s
T1s 1 T2 s 1 k k0
e :
:

0,

A
.
1 k k0
,
,
. , ,
.
,
. ,

.

25

10.2

. ,
.
,
,
Tu .
.
,
Tu , I min .
.


1 c j
2
(10.5)
I
e1 t dt
E1 s E1 s ds .
2
j
0
c j
,
(10.5) s j :

1
1
E1 j 2 d
j 2 G j 2 d .
2
2

B j
B j
E j 2 j 2 G j 2
,
A j 2 A j A j

A j
a0 j n a1 j n 1 an 1 j
an ,

(10.6)

B j
b0 j 2n 2 b1 j 2n
(10.6)
1
B j
I
d
2
A j 2
b0 b1 b2 ...bn
a0 a2 a4 ...0

bn

bn

(10.7)
1

(10.8)

1 n 1Mn
,
2a0 n

(10.9)

a1 a3 a5 0

det

E1 s

a0 a 2 a 4 0

.
n
......................

0 0 0 an
0 0 0 0
. E1 s
T1 T2 :

Mn

det

1
1
s 1 W0 s W p s

26

TuT12 s 2
TuT12 s 3

2TuT1s Tu

2TuT1s 2

Tu s k0

TuT12 s 2

2TuT1s Tu

.
TuT1s 2TuT1s Tu 1 k k0 s k0
I .
A j B j (10.7) (10.8):

A j

E1 ( s)

TuT12 j

2TuT1 j

Tu 1 k k0 j

k0 ;

B j
Tu2T14 j 4 2Tu2T12 j 2 Tu2 ;
(2.10) (2.11) a b :
a0 TnT12 , a1 2TnT1 , a2 Tn 1 k k0 , a3 k0

(10.10)
(10.11)

2Tu2T12 , b2 Tu2 .
b0 Tu2T14 , b1
(10.9)

Tu 2Tu 3 k k0 k0T1
:
.
(10.12)
I
2k0 2Tu 1 k k0 k0T1
I (10.12),
k 0
Tu 2T 3k 0T1
:
(10.13)
I
2k 0 2Tu k 0T1
Tu . , I min , ,
(10.12) (10.13) Tu :
3 k k0 k T1
:
,
(10.14)
Tu .
2 1 k k0
:
(10.15)
Tu : 1.5T1k0 .

1
ku Tu .
(10.14) (10.15),

2 1 k k0
:
,
ku
k T01 3 k k0
0.67
ku
:
.
k 0 T01
10.3
1. ( 10.1).

7.1. 10.1.
27

10.1


k
k
k0

10
0.05 1 0

0
1
0.05 10

1
1
0.05 10
2.
k,
.
.
k.
3.
, .
4. e
e=f(k).
5. e=f(k)
. .

.
6.
k .
k= k.
7.
k
k
I f
.
k :
8. ,
.


1) k= 0.2k; 2) k=k;
3) k= 2k.
10.4
1. .
2.
.
3. , ,
.
4. .
5. .
.
6. .
28


1. . MATLAB. .
.: , 2005. 512 .
2. .. VisSim+Mathcad+MATLAB.
. .: , 2004. 384 .
3. .., .. .
.: , 2004. 640 .
4. .. : . .:
, 2003. 583 .
5. . .1. / ..
.: , 1978.
6. / ..
. .: , 1987.
7. .., ..
. .: , 2003.

.............................................................................................................. 3
7.
.................................................... 4
7.1 .............................................................. 4
7.2 ........................................................................ 7
7.3 ................................................................................... 8
7.4 ................................................................................... 8
8. . 9
8.1 .............................................................. 9
8.2 ...................................................................... 13
8.3 8 .............. 13
8.4 ................................................................................. 16
9.
.......................................... 17
9.1 ...................................................... 17
9.2 .................................................................................. 21
9.3 ...................................................................... 22
9.4 ................................................................................. 22
10.
........................................................... 23
10.1 . ............... 23
10.2 ....................................... 26
10.3 .................................................................... 27
10.4 ............................................................................... 28
.................................................................................................29
29

. 2005, ____


MATLAB
( 050702)
2
..
. ..

.. 22 2005 .

. . 6 2005 .

________ 2005 .

100 . 60 84 1/16
1
1,5 ..


. ..

, ., 32.

30