You are on page 1of 6

Câu 1a,b,c

x=[-1-j -3+j -3-j -3-3j]

x=

Columns 1 through 3

-1.0000 - 1.0000i -3.0000 + 1.0000i -3.0000 - 1.0000i

Column 4

-3.0000 - 3.0000i

>> h=[0.8 0.4 -0.4 -0.4]

h=

0.8000 0.4000 -0.4000 -0.4000

>> y= conv(x,h)

y=

Columns 1 through 3

-0.8000 - 0.8000i -2.8000 + 0.4000i -3.2000 + 0.0000i

Columns 4 through 6

-2.0000 - 2.8000i 1.2000 - 1.2000i 2.4000 + 1.6000i

Column 7

1.2000 + 1.2000i

>> h = [ 0.8 0 0 0 0; 0.4 0.8 0 0 0; -0.4 0.4 0.8 0 0; -0.4 -0.4 0.4 0.8 0;0 -0.4 -0.4 0.4 0.8]

h=

0.8000 0 0 0 0
0.4000 0.8000 0 0 0
-0.4000 0.4000 0.8000 0 0
-0.4000 -0.4000 0.4000 0.8000 0
0 -0.4000 -0.4000 0.4000 0.8000
>> h^-1

ans =

1.2500 0 0 0 0
-0.6250 1.2500 0 0 0
0.9375 -0.6250 1.2500 0 0
-0.1563 0.9375 -0.6250 1.2500 0
0.2344 -0.1563 0.9375 -0.6250 1.2500

>> c= [ 0 0 1.25 -0.625 0.9375]

c=

0 0 1.2500 -0.6250 0.9375

>> z=conv(c,y)

z=

Columns 1 through 3

0.0000 + 0.0000i 0.0000 + 0.0000i -1.0000 - 1.0000i

Columns 4 through 6

-3.0000 + 1.0000i -3.0000 - 1.0000i -3.1250 - 3.1250i

Columns 7 through 9

-0.2500 + 0.2500i 0.3750 + 0.1250i 1.1250 - 0.6250i

Columns 10 through 11

1.5000 + 0.7500i 1.1250 + 1.1250i

>> rxy=xcorr(x,y)

rxy =

Columns 1 through 3

-2.4000 + 0.0000i -6.4000 + 4.0000i -10.4000 + 7.2000i


Columns 4 through 6

-16.0000 - 0.8000i -8.0000 -14.4000i 20.8000 -13.6000i

Columns 7 through 9

34.4000 - 0.8000i 19.2000 +10.4000i 10.4000 + 8.0000i

Columns 10 through 12

4.8000 + 0.0000i -0.0000 - 0.0000i -0.0000 - 0.0000i

Column 13

-0.0000 - 0.0000i

>> ryy=xcorr(y,y)

ryy =

Columns 1 through 3

-1.9200 + 0.0000i -6.0800 + 3.2000i -9.9200 + 7.3600i

Columns 4 through 6

-13.4400 + 0.6400i -6.0800 -16.3200i 24.0000 -19.2000i

Columns 7 through 9

45.4400 + 0.0000i 24.0000 +19.2000i -6.0800 +16.3200i

Columns 10 through 12

-13.4400 - 0.6400i -9.9200 - 7.3600i -6.0800 - 3.2000i

Column 13

-1.9200 - 0.0000i

>> Rxy=[ -8-14.4j 20.8-13.6j 34.4-0.8j 19.2+10.4j 10.4+8j]

Rxy =
Columns 1 through 3

-8.0000 -14.4000i 20.8000 -13.6000i 34.4000 - 0.8000i

Columns 4 through 5

19.2000 +10.4000i 10.4000 + 8.0000i

>> Ryy=[45.44 24+19.2j -6.08+16.32j -13.44-0.64j -9.92-7.36j;24-19.2j 45.44 24+19.2j -


6.08+16.32j -13.44-0.64j;-6.08-16.32j 24-19.2j 45.44 24+19.2j -6.08+16.32j;-13.44+0.64j -6.08-
16.32j 24-19.2j 45.44 24+19.2j;-9.92+7.36j -13.44+0.64j -6.08-16.32j 24-19.2j 45.44]

Ryy =

45.4400 + 0.0000i 24.0000 +19.2000i -6.0800 +16.3200i -13.4400 - 0.6400i -9.9200 - 7.3600i
24.0000 -19.2000i 45.4400 + 0.0000i 24.0000 +19.2000i -6.0800 +16.3200i -13.4400 - 0.6400i
-6.0800 -16.3200i 24.0000 -19.2000i 45.4400 + 0.0000i 24.0000 +19.2000i -6.0800 +16.3200i
-13.4400 + 0.6400i -6.0800 -16.3200i 24.0000 -19.2000i 45.4400 + 0.0000i 24.0000 +19.2000i
-9.9200 + 7.3600i -13.4400 + 0.6400i -6.0800 -16.3200i 24.0000 -19.2000i 45.4400 + 0.0000i

>> c=Ryy^-1*Rxy'

c=

-0.0523 + 0.0571i
0.0329 - 0.0721i
1.0382 + 0.1166i
-0.4528 - 0.1552i
0.6372 + 0.1022i

>> z=conv(y,c)

z=

Columns 1 through 7

0.0875 - 0.0038i 0.0396 - 0.1493i -0.6331 - 0.8913i -2.5562 + 0.8384i -2.6823 - 0.5275i -
2.3901 - 2.7474i -0.1193 + 0.0303i

Columns 8 through 11

0.7134 + 0.2623i 1.1549 - 0.3532i 1.0086 + 0.5352i 0.6419 + 0.8873i


>> x_mmse=[-0.6331 - 0.8913i -2.5562 + 0.8384i -2.6823 - 0.5275i -2.3901 - 2.7474i]

x_mmse =

-0.6331 - 0.8913i -2.5562 + 0.8384i -2.6823 - 0.5275i -2.3901 - 2.7474i

>> e_mmse=mean((x_mmse-x).^2)

e_mmse =

0.1199 + 0.1362i

>> x_zf=[-1.0000 - 1.0000j -3.0000 + 1.0000i -3.0000 - 1.0000i -3.1250 - 3.1250j]

x_zf =

-1.0000 - 1.0000i -3.0000 + 1.0000i -3.0000 - 1.0000i -3.1250 - 3.1250i

>> e_zf=mean((x_zf-x).^2)

e_zf =

0.0000 + 0.0078i
Câu 1d:
htt=[0.8 -0.5 0.7 -0.3; -0.4 -0.2 0.7 0.2; 0.8 0.4 -0.4 -0.4; -0.9 0.7 -0.4 0.3] : tự nhập

htt =

0.8000 -0.5000 0.7000 -0.3000


-0.4000 -0.2000 0.7000 0.2000
0.8000 0.4000 -0.4000 -0.4000
-0.9000 0.7000 -0.4000 0.3000

Ptt=htt.^2 : tự nhập

Ptt =

0.6400 0.2500 0.4900 0.0900


0.1600 0.0400 0.4900 0.0400
0.6400 0.1600 0.1600 0.1600
0.8100 0.4900 0.1600 0.0900

Pt=mean(Ptt) : tự nhập
Pt =

0.5625 0.2350 0.3250 0.0950

You might also like