Method of Viterbi algorithm and receiving device
11108415 · 2021-08-31
Assignee
Inventors
Cpc classification
H03M13/3961
ELECTRICITY
H03M13/4138
ELECTRICITY
H03M13/2732
ELECTRICITY
H03M13/6502
ELECTRICITY
International classification
H03M13/39
ELECTRICITY
H03M13/29
ELECTRICITY
Abstract
The invention discloses a method and a receiving device of the Viterbi algorithm. The method is applicable for a Viterbi decoder that receives an output signal generated by a convolution code encoder processing an original signal. The convolution code encoder includes M registers and M is a positive integer greater than or equal to 2. The method includes the following steps. First, for the first to the Mth data of the output signal, the Viterbi decoder performs the add-compare-select operation based on the known M initial values of the M registers. Then, for the Mth-last to the last data of the output signal, the Viterbi decoder performs the add-compare-select operation based on the known last M bits values of the original signal, thereby reducing the computational complexity of the add-compare-select unit.
Claims
1. A method of Viterbi algorithm applicable for a Viterbi decoder, wherein the Viterbi decoder receives an output signal generated by a convolution code encoder processing an original signal, and the convolution code encoder comprises M registers, M is a positive integer greater than or equal to 2, and the method comprises steps of: performing, by the Viterbi decoder, an add-compare-select operation in the Viterbi algorithm for first to Mth data of the output signal based on known M initial values of the M registers; and performing, by the Viterbi decoder, the add-compare-select operation in the Viterbi algorithm for Mth-last to last data of the output signal based on known last M bits values of the original signal; wherein the Viterbi decoder takes Radix-2.sup.i as radix, i is a positive integer greater than or equal to 1, and the step of performing, by the Viterbi decoder, the add-compare-select operation in the Viterbi algorithm for the first to the Mth data of the output signal based on the known M initial values of the M registers comprises a step of: performing, by the Viterbi decoder, the add-compare-select operation for the first to the Mth data of the output signal by sequentially shifting the known M initial values of the known M registers out of the M registers by i and selecting a first possible state corresponding to the shifting from 2.sup.M states included in the M registers, rather than performing the add-compare-select operation on all the 2.sup.M states, wherein some of bit values of the first possible state are the same as the rest of bit values after each shifting; wherein the step of performing, by the Viterbi decoder, the add-compare-select operation in the Viterbi algorithm for the Mth-last to the last data of the output signal based on the known last M bits values of the original signal comprises a step of: performing, by the Viterbi decoder, the add-compare-select operation for the Mth-last to the last data of the output signal by sequentially shifting the known last M bits values of the original signal into the M registers by i and selecting a second possible state corresponding to the shifting from the 2.sup.M states included in the M registers, rather than performing the add-compare-select operation on all the 2.sup.M states, wherein some of bit values of the second possible state are the same as the rest of bit values after each shifting.
2. A receiving device, comprising: a Viterbi decoder for receiving an output signal generated by a convolution code encoder processing an original signal, and using Viterbi algorithm to decode the output signal, wherein the convolution code encoder comprises M registers, M is a positive integer greater than or equal to 2; and a storage device storing an application program used for indicating a method of Viterbi algorithm for the Viterbi decoder to execute, the method comprises steps of: performing, by the Viterbi decoder, an add-compare-select operation in the Viterbi algorithm for first to Mth data of the output signal, based on known M initial values of the M registers; and performing, by the Viterbi decoder, the add-compare-select operation in the Viterbi algorithm for Mth-last to last data of the output signal, based on known last M bits values of the original signal: wherein the Viterbi decoder takes Radix-2.sup.i as radix, i is a positive integer greater than or equal to 1, and the step of performing, by the Viterbi decoder, the add-compare-select operation in the Viterbi algorithm for the first to the Mth data of the output signal based on the known M initial values of the M registers comprises a step of: performing, by the Viterbi decoder, the add-compare-select operation for the first to the Mth data of the output signal by sequentially shifting the known M initial values of the known M registers out of the M registers by i and selecting a first possible state corresponding to the shifting from 2.sup.M states included in the M registers, rather than performing the add-compare-select operation on all the 2.sup.M states, wherein some of bit values of the first possible state are the same as the rest of bit values after each shifting; wherein the step of performing, by the Viterbi decoder, the add-compare-select operation in the Viterbi algorithm for the Mth-last to the last data of the output signal based on the known last M bits values of the original signal comprises a step of: performing, by the Viterbi decoder, the add-compare-select operation for the Mth-last to the last data of the output signal by sequentially shifting the known last M bits values of the original signal into the M registers by i and selecting a second possible state corresponding to the shifting from the 2.sup.M states included in the M registers, rather than performing the add-compare-select operation on all the 2.sup.M states, wherein some of bit values of the second possible state are the same as the rest of bit values after each shifting.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
(1)
(2)
(3)
(4)
(5)
(6)
(7)
DETAILED DESCRIPTION OF PREFERRED EMBODIMENTS
(8) Hereinafter, the present invention will be described in detail by explaining various embodiments of the invention with reference to the drawings. However, the concept of the invention may be embodied in many different forms and should not be limited to the illustrative embodiments in the description. In addition, the same reference numerals in the drawings can represent the similar components.
(9) In detail, the method of the Viterbi algorithm provided by the embodiment of the present invention may be suitable for a Viterbi decoder in any telecommunication standard. For example, the telecommunication standard may be the IEEE 802.11n or the IEEE 802.11ac, etc., but the invention is not limited thereto. Furthermore, according to the prior art, the Viterbi decoder is used for receiving an output signal generated by a convolution code encoder processing an original signal, and the Viterbi algorithm is used for decoding the output signal, but the present invention does not limit the specific implementation of the Viterbi decoder or the convolution code encoder which can be adaptively designed by those skilled in the art according to actual requirements or applications. Basically, the convolution code encoder has M registers, and M is a positive integer greater than or equal to 2.
Embodiment 1
(10) For convenience of the following description, the present embodiment will be described by a convolution code encoder of (n, k, M)=(2, 1, 3), but it is not intended to limit the present invention. It should be understood that the mentioned n and k respectively represent the number of output bits and the number of input bits of the convolution code encoder. For example, please refer to
Embodiment 2
(11) In addition, in a preferred embodiment, assuming that the bit values stored in each of the registers R0, R1 and R2 are initially “0”, according to the encoding mode of
(12) Briefly, when the branch metric unit 210 receives a new data, the branch metric unit 210 will calculate the branch distance associated with the data, and the add-compare-select unit 220 will continuously update the shortest branch distance of each state after performing the add-compare-select operation. Besides, the survivor path memory unit 230 records the decision result of the add-compare-select unit 220, and traces back the survivor path to find the decoded bits. According to the above teachings, those of ordinary skill in the art can understand that the add-compare-select unit 220 is the most significant part of the circuit or application program to execute the Viterbi algorithm. Also, the computational complexity of the add-compare-select unit 220 increases exponentially according to the number of registers used by the convolution code encoder.
(13) Therefore, as shown in
(14) Further, under certain telecommunication standards, in addition to setting the M initial values of the M registers to be “0”, M “0” are added to the end of signaling or data packet of the telecommunication standard as the tail bits of the original signal. As such, the M registers can be restored to the initial state “000” after the end of the encoding. Alternatively, the receiving end may know the M initial values of the M registers and the last M bits values of the original signal in advance under certain telecommunication standards. Thus, the method of the present embodiment is based on the known coding characteristics to perform special process on initial states and end states of the trellis diagrams.
Embodiment 3
(15) Please refer to
(16) First, in step S410, for the first to the Mth data of the output signal, the Viterbi decoder performs the add-compare-select operation in the Viterbi algorithm based on the known M initial values of the M registers. Thereafter, in step S420, for the Mth-last to the last data of the output signal, the Viterbi decoder performs the add-compare-select operation in the Viterbi algorithm based on the known last M bits values of the original signal. For the convenience of the following description, the embodiment of
(17) Next, please refer to
(18) Similarly, when the second bit value B.sub.2 of the original signal enters the register R0 from the input terminal, the first bit value B.sub.1 in the register R0 and the initial value “0” in the register R1 are respectively bit-shifted to the next registers R1 and R2, and the bit values stored in the registers can be calculated for encoding operation, and then the second data S.sub.2 of the output signal obtained by the encoding operation is transmitted to the output terminal. Therefore, when receiving the second data S.sub.2 of the output signal, the Viterbi decoder 2 can know that it is converted from the state “B.sub.100” to “B.sub.2B.sub.10” in the trellis diagram at the time of encoding. Also, since the second bit value B.sub.2 of the original signal may be “0” or “1”, at this moment the add-compare-select unit 220 only needs to select the four states “000”, “100”, “010” and “110” corresponding to the state “B.sub.2B.sub.10” to perform the add-compare-select operation. Accordingly, the add-compare-select unit 220 only needs to consider selecting the path in which the state “000” changes to the state “000” or “100” or the path in which the state “100” to the state “010” or “110” as the survivor path at this moment. By analogy, when receiving the third data S.sub.3 of the output signal, the Viterbi decoder 2 can know that it is converted from the state “B.sub.2B.sub.10” to “B.sub.3B.sub.2B.sub.1” in the trellis diagram at the time of encoding. Thus, at this moment, the add-compare-select unit 220 needs to perform add-compare-select operation on all the eight states. However, the add-compare-select unit 220 may only consider selecting the path in which the state “000” changes to the state “000” or “100”, the path in which the state “100” changes to the state “010” or “110”, the path in which the state “010” changes to the state “001” or “101”, or the path in which the state “110” changes to the state “011” or “111” as the survivor path at this moment, as shown in
(19) Similarly, when the third-last bit value (e.g., B.sub.25) of the original signal enters the register R0 from the input terminal, the bit values B.sub.24 and B.sub.23 in the registers R0 and R1 are respectively bit-shifted to the next registers R1 and R2, and the bit values stored in the registers can be calculated for encoding operation, and the third-last data S.sub.25 of the output signal obtained by the encoding operation is transmitted to the output terminal. Therefore, as shown in
(20) Similarly, when the penultimate bit value B.sub.26 of the original signal enters the register R0 from the input terminal, the bit values B.sub.25 and B.sub.24 in the registers R0 and R1 are again respectively bit-shifted to the next registers R1 and R2, and the bit values stored in the registers can be calculated for encoding operation, and then the third-last data S.sub.25 of the output signal obtained by the encoding operation is transmitted to the output terminal. Therefore, as shown in
(21) On the other hand, it is considered that the receiving end of some telecommunication standards may know the three initial values of the three registers R0, R1 and R2 and the last three bit values of the original signal, but the last three bits values of the original signal and the three initial values of the three registers R0, R1 and R2 are not all set to “0”. In this condition, please refer to
(22) Herein, as shown in
(23) Similarly, when receiving the second data S.sub.2 of the output signal, the Viterbi decoder 2 can know that it is converted from the state “B.sub.111” to “B.sub.2B.sub.11” in the trellis diagram at the time of encoding. Also, since the second bit value B.sub.2 of the original signal may be “0” or “1”, at this moment the add-compare-select unit 220 only needs to select the four states “001”, “101”, “011” and “111” corresponding to the state “B.sub.2B.sub.11” to perform the add-compare-select operation. Accordingly, the add-compare-select unit 220 only needs to consider selecting the path in which the state “011” changes to the state “001” or “101” or the path in which the state “111” changes to the state “011” or “111” as the survivor path at this moment. By analogy, when receiving the third data S.sub.3 of the output signal, the Viterbi decoder 2 can know that it is converted from the state “B.sub.2B.sub.11” to “B.sub.3B.sub.2B.sub.1” in the trellis diagram at the time of encoding. Thus, at this moment the add-compare-select unit 220 needs to perform add-compare-select operation on all the eight states. However, the add-compare-select unit 220 may only consider selecting the path in which the state “001” changes to the state “000” or “100”, the path in which the state “100” changes to the state “010” or “110”, the path in which the state “011” changes to the state “001” or “101”, or the path in which the state “111” changes to the state “011” or “111” as the survivor path at this moment, as shown in
(24) Similarly, as shown in
(25) That is, as long as the Viterbi decoder 2 already knows the three initial values of the three registers R0, R1, R2 and the last three bits values of the original signal, the method of the embodiment can reduce the computational complexity of the add-compare-select unit 220 preceding the first three data and the last three data of the output signal based on the known coding characteristics. Especially in the case where the original signal length is not long enough, the method of the embodiment can cause the survivor path to converge to the initial state of the registers R0, R1 and R2 more quickly, or can help the Viterbi decoder 2 to find the best decoding path faster. In addition, based on the Viterbi decoder 2 with Radix-2 described by the present embodiment, those of ordinary skill in the art should be able to clearly understand the operation of the Viterbi decoder with other higher dimensions, such as Radix-4.
(26) In summary, if the Viterbi decoder of the present embodiment takes Radix-2.sup.i as the radix, wherein i is a positive integer greater than or equal to 1, then the step S410 of
Embodiment 4
(27) Finally, in order to further explain the implementation of the method, the invention further provides an embodiment of the receiving device. Please refer to
(28) That is, the receiving device 7 can initiate to execute the method of
(29) In summary, the method and receiving device of the Viterbi algorithm provided by the embodiments of the present invention can effectively reduce the computational complexity of the add-compare-select unit, especially when the original signal length is not long enough. The method of the embodiments enables the survivor path to converge to the initial state of the register more quickly, in other words, it helps the Viterbi decoder to find the best decoding path faster.
(30) The above descriptions are merely embodiments of the present invention, and are not intended to limit the scope of the invention.