5. Given the probability model shown in table 4-9, the real value label for sequence a1a1a3a2a3a1 is obtained.
Probability models of exercise 5 and 6
Letter Probability
A1 0.2
A2 0.3
A3 0.5
Solution: By the knowable
P (A1) =0.2, P (A2) =0.3, P (A3) =0.5
FX (0) =0,FX (1) =0.2, FX (2) =0.5, FX (3) =1.0, U (0) =1, L (0) =0
Because X (AI) =i, so x (A1) =1,x (A2) =2,x (A3) =3
by formula L (n) =l (n-1) + (U (n-1)-L (n-1)) Fx (xn-1)
U (n) =l (n-1) + (U (n-1)-L (n-1)) Fx (xn)
The first occurrence of A1 is:
L (1) =l (0) + (U (0)-L (0)) Fx (0) =0
U (1) =l (0) + (U (0)-L (0)) Fx (1) =0.2
The second occurrence of A1 is:
L (2) =l (1) + (U (1)-L (1)) Fx (0) =0
U (2) =l (1) + (U (1)-L (1)) Fx (1) =0.04
The third occurrence of A3 is:
L (3) =l (2) + (U (2)-L (2)) Fx (2) =0.02
U (3) =l (2) + (U (2)-L (2)) Fx (3) =0.04
The fourth time when A2 appears:
L (4) =l (3) + (U (3)-L (3)) Fx (1) =0.024
U (4) =l (3) + (U (3)-L (3)) Fx (2) =0.03
The fifth time when A3 appears:
L (5) =l (4) + (U (4)-L (4)) Fx (2) =0.027
U (5) =l (4) + (U (4)-L (4)) Fx (3) =0.03
The sixth time when A1 appears:
L (6) =l (5) + (U (5)-L (5)) Fx (0) =0.027
U (6) =l (5) + (U (5)-L (5)) Fx (1) =0.0276
So the real value tag of the sequence A1A1A3A2A3A1 is: T (113231) = (L (6) + U (6))/2=0.0273
6, for the probability model shown in table 4-9, for a label 0.63215699 of the length of a sequence of 10 decoding.
Solution:
By table 4-9 You can know F (x1) =0.2,f (x2) =0.5,f (x3) =1.
First assume L (0) =0,u (0) =1.
(1) t*= (0.63215699-0)/(1-0) =0.63215699
FX (2) =0.5<= t*<= FX (3) =1
L (1) = L (0) + (U (0)-L (0)) Fx (2) =0.5
U (1) = L (0) + (U (0)-L (0)) Fx (3) =1
The first character is a A3
(2) t*= (0.63215699-0.5)/(1-0.5) =0.26431398
FX (1) =0.2<= t*<= FX (2) =0.5
L (2) = L (1) + (U (1)-L (1)) Fx (1) =0.6
U (2) = L (1) + (U (1)-L (1)) Fx (2) =0.75
The second character is A2
(3) t*= (0.63215699-0.6)/(0.75-0.6) =0.21437993
FX (1) =0.2<= t*<= FX (2) =0.5
L (3) = L (2) + (U (2)-L (2) Fx (1) =0.63
U (3) = L (2) + (U (2)-L (2)) Fx (2) =0.635
The third character is A2
(4) t*= (0.63215699-0.63)/(0.635-0.63) =0.431398
FX (1) =0.2<= t*<= FX (2) =0.5
L (4) = L (3) + (U (3)-L (3)) Fx (1) =0.631
U (4) = L (3) + (U (3)-L (3)) Fx2) =0.6325
The fourth character is A2
(5) t*= (0.63215699-0.631)/(0.6325-0.631) =0.77132667
FX (2) =0.5<= t*<= FX (3) =1
L (5) = L (4) + (U (4)-L (4)) Fx (2) =0.63175
U (5) = L (4) + (U (4)-L (4)) Fx (3) =0.6325
The fifth character is A3
(6) t*= (0.63215699-0.63175)/(0.6325-0.63175) =0.5426533
FX (2) =0.5<= t*<= FX (3) =1
L (6) = L (5) + (U (5)-L (5)) Fx (2) =0.632125
U (6) = L (5) + (U (5)-L (5)) Fx (3) =0.6325
The sixth character is A3
(7) t*= (0.63215699-0.632125)/(0.6325-0.632125) =0.04265333
FX (k) =0<= t*<= FX (1) =0.2
L (7) = L (6) + (U (6)-L (6)) Fx (0) =0.632125
U (7) = L (6) + (U (6)-L (6)) Fx (1) =0.632275
The seventh character is A1
(8) t*= (0.63215699-0.632125)/(0. 632125-0.632275) =0.21326667
FX (1) =0.2<= t*<= FX (2) =0.5
L (8) = L (7) + (U (7)-L (7)) Fx (1) =0.632155
U (8) = L (7) + (U (7)-L (7)) Fx (5) =0.6322
The eighth character is A2
(9) t*= (0.63215699-0.632155)/(0.6322-0.632155) =0.04422222
FX (0) =0<= t*<= FX (1) =0.2
L (9) = L (8) + (U (8)-L (8)) Fx (0) =0.632155
U (9) = L (8) + (U (8)-L (8)) Fx (1) =0.632164
The Nineth character is A1
(Ten) t*= (0.63215699-0.632155)/(0.632164-0.632155) =0.22111111
FX (1) =0.2<= t*<= FX (2) =0.5
L (Ten) = L (9) + (U (9)-L (9)) Fx (1) =0.6321568
U (Ten) = L (9) + (U (9)-L (9)) Fx (2) =0.6321595
The tenth character is A2
So a sequence with a label value of 0.63215699 with a length of 10 decoded is: A3A2A2A2A3A3A1A2A1A2
Fourth time assignment