<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://en.zaoniao.it/index.php?action=history&amp;feed=atom&amp;title=Berlekamp%E2%80%93Welch_algorithm</id>
	<title>Berlekamp–Welch algorithm - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://en.zaoniao.it/index.php?action=history&amp;feed=atom&amp;title=Berlekamp%E2%80%93Welch_algorithm"/>
	<link rel="alternate" type="text/html" href="http://en.zaoniao.it/index.php?title=Berlekamp%E2%80%93Welch_algorithm&amp;action=history"/>
	<updated>2026-05-16T05:27:04Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.32.0</generator>
	<entry>
		<id>http://en.zaoniao.it/index.php?title=Berlekamp%E2%80%93Welch_algorithm&amp;diff=2371&amp;oldid=prev</id>
		<title>Admin: Created page with &quot;&lt;amp/&gt; The '''Berlekamp–Welch algorithm''', also known as the '''Welch–Berlekamp algorithm''', is named for Elwyn R. Berlekamp and Lloyd R. Welch. The algorithm ef...&quot;</title>
		<link rel="alternate" type="text/html" href="http://en.zaoniao.it/index.php?title=Berlekamp%E2%80%93Welch_algorithm&amp;diff=2371&amp;oldid=prev"/>
		<updated>2019-03-20T04:25:44Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;&amp;lt;amp/&amp;gt; The &amp;#039;&amp;#039;&amp;#039;Berlekamp–Welch algorithm&amp;#039;&amp;#039;&amp;#039;, also known as the &amp;#039;&amp;#039;&amp;#039;Welch–Berlekamp algorithm&amp;#039;&amp;#039;&amp;#039;, is named for &lt;a href=&quot;/index.php?title=Elwyn_R._Berlekamp&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;Elwyn R. Berlekamp (page does not exist)&quot;&gt;Elwyn R. Berlekamp&lt;/a&gt; and &lt;a href=&quot;/index.php?title=Lloyd_R._Welch&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;Lloyd R. Welch (page does not exist)&quot;&gt;Lloyd R. Welch&lt;/a&gt;. The algorithm ef...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;lt;amp/&amp;gt;&lt;br /&gt;
The '''Berlekamp–Welch algorithm''', also known as the '''Welch–Berlekamp algorithm''', is named for [[Elwyn R. Berlekamp]] and [[Lloyd R. Welch]]. The algorithm efficiently corrects errors in [[BCH code]]s and [[Reed–Solomon error correction|Reed–Solomon codes]] (which are a subset of BCH codes). Unlike many other decoding algorithms, and in correspondence with the code-domain [[Berlekamp–Massey algorithm]] that uses [[Decoding methods#Syndrome decoding|syndrome decoding]] and the dual of the codes, the Berlekamp–Welch decoding algorithm provides a method for decoding Reed–Solomon codes using just the generator matrix and not syndromes.&lt;br /&gt;
&lt;br /&gt;
==History on decoding Reed–Solomon codes==&lt;br /&gt;
&lt;br /&gt;
* In 1960, Peterson developed an algorithm for decoding [[BCH codes]]. His algorithm solves the important second stage of the generalized BCH decoding procedure and is used to calculate the error locator polynomial coefficients that in turn provide the error locator polynomial. This is crucial to the decoding of BCH codes.&lt;br /&gt;
* In 1963, Gorenstein–Zierler saw that BCH codes and [[Reed–Solomon error correction|Reed–Solomon codes]] have a common generalization and that the decoding algorithm extends to more general situation.&lt;br /&gt;
* In 1968 / 69, [[Elwyn Berlekamp]] invented an algorithm for decoding BCH codes. [[James Massey]] recognized its application to linear feedback shift registers and simplified the algorithm. Massey termed the algorithm the LFSR Synthesis Algorithm (Berlekamp Iterative Algorithm) but it is now known as the [[Berlekamp–Massey algorithm]].&lt;br /&gt;
* In 1975, Sugiyama ''et al.'' developed a decoder based on the [[extended Euclidean algorithm]]. [[Reed%E2%80%93Solomon_error_correction#Euclidean_decoder]]&lt;br /&gt;
* In 1986, The Welch–Berlekamp algorithm was developed to solve the decoding equation of [[Reed–Solomon error correction|Reed–Solomon codes]], using a fast method to solve a certain polynomial equation. The Berlekamp–Welch algorithm has a running time complexity of &amp;lt;math&amp;gt;\mathcal{O}(N^3)&amp;lt;/math&amp;gt;. The following sections look at the Gemmel and Sudan’s exposition of the Berlekamp&amp;amp;ndash;Welch algorithm.&lt;br /&gt;
&lt;br /&gt;
==Error locator polynomial of Reed–Solomon codes==&lt;br /&gt;
&lt;br /&gt;
In the problem of decoding Reed–Solomon codes, the inputs are pair wise distinct evaluation points &amp;lt;math&amp;gt;\alpha_1, \cdots, \alpha_n&amp;lt;/math&amp;gt; where &amp;lt;math&amp;gt;\alpha_i \in \mathbb{F}&amp;lt;/math&amp;gt; with [[Block code#Definitions|dimension]] &amp;lt;math&amp;gt;k&amp;lt;/math&amp;gt; and [[Block code#Minimum distance|distance]] &amp;lt;math&amp;gt;d = n - k + 1 &amp;lt;/math&amp;gt; and a codeword &amp;lt;math&amp;gt;y = (y_1, \cdots, y_n) \in \mathbb{F}^n.&amp;lt;/math&amp;gt; Our goal is to describe an algorithm that can correct &amp;lt;math&amp;gt;e &amp;lt; \tfrac{1}{2}(n-k+1)&amp;lt;/math&amp;gt; many errors in polynomial time. To do so we have to find &amp;lt;math&amp;gt;P \in \mathbb{F}[X]&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;\deg(P) &amp;lt; k - 1&amp;lt;/math&amp;gt; and the number of indices for which &amp;lt;math&amp;gt;P(\alpha_i) \ne y_i&amp;lt;/math&amp;gt; is less than or equal to &amp;lt;math&amp;gt;e.&amp;lt;/math&amp;gt; We can assume that there exists a polynomial &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; such that&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;\Delta(y, (P (\alpha_i))^N _{i=1}) \leqslant e \leqslant \tfrac{d}{2} = \tfrac{1}{2}(n - k + 1).&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that the coefficients of &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; are the encoded information. To solve this, we use an indicator for those indices where an error may have occurred. Thus we define an error locator polynomial, &amp;lt;math&amp;gt;E \in \mathbb{F}[X],&amp;lt;/math&amp;gt; by:&lt;br /&gt;
&lt;br /&gt;
: &amp;lt;math&amp;gt;E(X) = \prod_{1\leqslant i \leqslant n \atop y_i \ne P(\alpha_i)} (X - \alpha_i)&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that &amp;lt;math&amp;gt;\deg(E) \leqslant \tfrac{1}{2}(n - k).&amp;lt;/math&amp;gt; We can also claim that &amp;lt;math&amp;gt;y_i E(\alpha_i) = P(\alpha_i) E(\alpha_i)&amp;lt;/math&amp;gt; holds for all &amp;lt;math&amp;gt;1 \leqslant i \leqslant n&amp;lt;/math&amp;gt;. This fact holds true because in the event of &amp;lt;math&amp;gt;y_i \ne P(\alpha_i)&amp;lt;/math&amp;gt;, both sides of the above equation vanish because &amp;lt;math&amp;gt;E(\alpha_i) = 0&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
However, since &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; are both unknown, the main task of the decoding algorithm would be to find &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt;. To do this we use a seemingly useless yet very powerful method and define another polynomial &amp;lt;math&amp;gt;Q = PE.&amp;lt;/math&amp;gt; This is because the &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; equations with &amp;lt;math&amp;gt;e + k&amp;lt;/math&amp;gt; we need to solve are quadratic in nature. Thus by defining a product of two variables that gives rise to a quadratic term as one unknown variable, we increase the number of unknowns but make the equations linear in nature. This method is called linearization and is a very powerful tool.&lt;br /&gt;
&lt;br /&gt;
Thus &amp;lt;math&amp;gt;Q \in \mathbb{F}[X]&amp;lt;/math&amp;gt; having the properties:&lt;br /&gt;
# &amp;lt;math&amp;gt;\deg(Q) \leqslant \tfrac{1}{2}(n - k) + k - 1&amp;lt;/math&amp;gt;&lt;br /&gt;
# &amp;lt;math&amp;gt;Q(\alpha_i) = E(\alpha_i)y_i, \qquad 1 \leqslant i \leqslant n&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This helps because if we now manage to find &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt;, we can easily find &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; using &amp;lt;math&amp;gt;P = \tfrac{Q}{E}&amp;lt;/math&amp;gt;. The main purpose of the Berlekamp Welch algorithm is to find out &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; using degree bounded polynomials &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; and the properties of &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;N&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Computing &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; is as hard as finding the end solution &amp;lt;math&amp;gt;P.&amp;lt;/math&amp;gt; Once &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; is computed, using erasure decoding for Reed–Solomon codes, we can easily recover &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt;. However, in a few cases, even the polynomial &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt; is as hard to find as &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt;. As an example, given &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;y&amp;lt;/math&amp;gt; (such that &amp;lt;math&amp;gt;y_i \ne 0&amp;lt;/math&amp;gt; for &amp;lt;math&amp;gt;1 \leqslant i \leqslant n&amp;lt;/math&amp;gt;), by checking positions where &amp;lt;math&amp;gt;Q(i) = 0&amp;lt;/math&amp;gt;, we can find the error locations. Thus the algorithm works on the principle that while each of the polynomials &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt; are hard to find individually; computing them together is much easier.&lt;br /&gt;
&lt;br /&gt;
==The Berlekamp–Welch decoder and algorithm==&lt;br /&gt;
&lt;br /&gt;
The Welch–Berlekamp decoder for Reed–Solomon codes consists of the Welch– Berlekamp algorithm augmented by some additional steps that prepare the received word for the algorithm and interpret the result of the algorithm.&lt;br /&gt;
&lt;br /&gt;
The inputs given to the Berlekamp Welch decoder are the integers denoting Block Length &amp;lt;math&amp;gt;n,&amp;lt;/math&amp;gt; the number of errors &amp;lt;math&amp;gt;e&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;e &amp;lt; \tfrac{1}{2}(n - k + 1),&amp;lt;/math&amp;gt; and the received word &amp;lt;math&amp;gt;(y_i ,\alpha_i)^n _{i=1}&amp;lt;/math&amp;gt; satisfying the condition that there exists at most one &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;\deg(P) \leqslant k - 1&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;\Delta(y, P(\alpha_i)_i) \leqslant e&amp;lt;/math&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The output of the decoder is either the polynomial &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt;, or in some cases, a failure. This decoder functions in two steps as follows:&lt;br /&gt;
# This step is called the interpolation step in which the decoder computes a non zero polynomial &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; of degree &amp;lt;math&amp;gt;e&amp;lt;/math&amp;gt; (This implies that the coefficient of &amp;lt;math&amp;gt;X^e&amp;lt;/math&amp;gt; must be 1) and another polynomial &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt; with &amp;lt;math&amp;gt;\deg(Q) \leqslant e + k - 1.&amp;lt;/math&amp;gt; These polynomials are created such that the condition &amp;lt;math&amp;gt;y_i E(\alpha_i) = Q(\alpha_i)&amp;lt;/math&amp;gt; holds for all &amp;lt;math&amp;gt;1 \leqslant i \leqslant n.&amp;lt;/math&amp;gt; In the case that polynomials satisfying the above condition cannot be computed, the output of the decoder would be a failure.&lt;br /&gt;
# If &amp;lt;math&amp;gt;E \mid Q&amp;lt;/math&amp;gt; then a &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; is defined which equals &amp;lt;math&amp;gt;\tfrac{Q}{E}.&amp;lt;/math&amp;gt; If &amp;lt;math&amp;gt;\Delta(y, (P(\alpha_i)_i ) \leqslant e,&amp;lt;/math&amp;gt; then the decoder outputs &amp;lt;math&amp;gt;P.&amp;lt;/math&amp;gt; If the above condition is not satisfied, i.e. if &amp;lt;math&amp;gt;E \nmid Q&amp;lt;/math&amp;gt; then a failure is returned by the decoder.&lt;br /&gt;
&lt;br /&gt;
According to the algorithm, in the cases where it does not output a failure, it outputs a &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; that is the correct and desired polynomial. To prove that, the algorithm always outputs the desired polynomial, we need to prove a few claims we have made while describing the algorithm. Let us go ahead and do so now.&lt;br /&gt;
&lt;br /&gt;
:'''Claim 1.''' There exist a pair of polynomials, &amp;lt;math&amp;gt;(E, Q),&amp;lt;/math&amp;gt; that satisfy Step 1 of the BW algorithm and &amp;lt;math&amp;gt;\tfrac{Q}{E} = P.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Let &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; be the error-locating polynomial for &amp;lt;math&amp;gt;P&amp;lt;/math&amp;gt; :&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;E(X) = X^{e - \Delta(y, P(\alpha_i)_i)} \prod_{1\leqslant i \leqslant n \atop y_i \ne P(\alpha_i)} \left (X - \alpha_i \right )&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Notice that &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; has the following properties by definition:&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;\deg(E) = e, \qquad E(\alpha_i) = 0 \Leftrightarrow y_i \ne P(\alpha_i).&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now define &amp;lt;math&amp;gt;Q = PE&amp;lt;/math&amp;gt; and note that:&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;\deg(Q) \leqslant \deg(P) + \deg(E) \leqslant e + k - 1.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We can now claim that &amp;lt;math&amp;gt;y_i E(\alpha_i) = Q(\alpha_i)&amp;lt;/math&amp;gt; from the first step of the BW algorithm holds. If &amp;lt;math&amp;gt;E(\alpha_i) = 0,&amp;lt;/math&amp;gt; then &amp;lt;math&amp;gt;Q(\alpha_i) = P(\alpha_i)E(\alpha_i) = y_iE(\alpha_i) = 0&amp;lt;/math&amp;gt;. For &amp;lt;math&amp;gt;E(\alpha_i) \ne 0&amp;lt;/math&amp;gt; we have &amp;lt;math&amp;gt;P(\alpha_i) = y_i&amp;lt;/math&amp;gt; and therefore &amp;lt;math&amp;gt;Q(\alpha_i)= P(\alpha_i)E(\alpha_i) = y_iE(\alpha_i)&amp;lt;/math&amp;gt; just as we claimed.&lt;br /&gt;
&lt;br /&gt;
This above claim however just reiterates and proves the fact that there exists a pair of polynomials &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt; such that &amp;lt;math&amp;gt;P = \tfrac{Q}{E}.&amp;lt;/math&amp;gt; It however does not necessarily guarantee the fact that the algorithm we discussed above would indeed output such a pair of polynomials. We therefore move on to look at another claim that helps establish this fact using the above claim and thereby proving the correctness of the algorithm.&lt;br /&gt;
&lt;br /&gt;
:'''Claim 2.''' If &amp;lt;math&amp;gt;(E_1, Q_1), (E_2, Q_2)&amp;lt;/math&amp;gt; are two distinct solutions that satisfy the first step of the Berlekamp Welch algorithm, then we have &amp;lt;math&amp;gt;\tfrac{Q_1}{E_1} = \tfrac{Q_2}{E_2}.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
First note that&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;\deg(Q_1E_2), \deg(Q_2E_1) \leqslant 2e + k - 1.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then we define:&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;R := Q_1E_2 - Q_2E_1&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that &amp;lt;math&amp;gt;\deg(R) \leqslant 2e + k - 1.&amp;lt;/math&amp;gt; From step 1 of the Berlekamp Welch algorithm we also know that &amp;lt;math&amp;gt;y_iE_1(\alpha_i) = Q_1(\alpha_i)&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;y_iE_2(\alpha_i) = Q_2(\alpha_i).&amp;lt;/math&amp;gt; Now for all &amp;lt;math&amp;gt;i \in \{1, \cdots, n\}&amp;lt;/math&amp;gt; we calculate:&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{align}&lt;br /&gt;
R(\alpha_i) &amp;amp;= Q_1(\alpha_i)E_2(\alpha_i) - Q_2(\alpha_i)E_1(\alpha_i) \\&lt;br /&gt;
&amp;amp;= y_iE_1(\alpha_i)E_2(\alpha_i) - y_iE_2(\alpha_i)E_1(\alpha_i) \\&lt;br /&gt;
&amp;amp;= 0&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Thus &amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt; has &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; roots, on the other hand&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;\deg(R(X)) \leqslant 2e + k - 1 &amp;lt; 2 \tfrac{1}{2}(n - k + 1) + k - 1 = n.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Therefore, &amp;lt;math&amp;gt;R&amp;lt;/math&amp;gt; is the zero polynomial which means that &amp;lt;math&amp;gt;Q_1E_2&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;Q_2E_1&amp;lt;/math&amp;gt; are identical. Since &amp;lt;math&amp;gt;E_1, E_2&amp;lt;/math&amp;gt; are non-zero we can write: &amp;lt;math&amp;gt;\tfrac{Q_1}{E_1} = \tfrac{Q_2}{E_2}&amp;lt;/math&amp;gt; as per our initial claim.&lt;br /&gt;
&lt;br /&gt;
Thus based on the above claims, we can safely state that the output of the Berlekamp Welch algorithm, when outputting the polynomial &amp;lt;math&amp;gt;P(X)&amp;lt;/math&amp;gt; is correct.&lt;br /&gt;
&lt;br /&gt;
We can now claim that the algorithm can be implemented such that it has a running time of &amp;lt;math&amp;gt;O(n^3)&amp;lt;/math&amp;gt;. This can be proved as follows: In Step 1 of the algorithm, the polynomials &amp;lt;math&amp;gt;Q&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; have &amp;lt;math&amp;gt;e + k&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;e + 1&amp;lt;/math&amp;gt; unknown values respectively and the constraints &amp;lt;math&amp;gt;y_i E(\alpha_i) = Q(\alpha_i)&amp;lt;/math&amp;gt; for all &amp;lt;math&amp;gt;1 \leqslant i \leqslant n&amp;lt;/math&amp;gt; acts as a linear equation with these unknowns. We therefore get a system of &amp;lt;math&amp;gt;n&amp;lt;/math&amp;gt; linear equations in &amp;lt;math&amp;gt;2e + k + 1 &amp;lt; n + 2&amp;lt;/math&amp;gt; unknowns. Using our first claim, this system of equations has a solution since &amp;lt;math&amp;gt;\deg(E) = e.&amp;lt;/math&amp;gt; This can be solved in &amp;lt;math&amp;gt;O(n^3)&amp;lt;/math&amp;gt; time, by say Gaussian elimination. Finally, we can note that Step 2 of the algorithm can also be implemented in time &amp;lt;math&amp;gt;O(n^3)&amp;lt;/math&amp;gt; by &amp;quot;long division&amp;quot; method. Hence we can state that the Berlekamp Welch algorithm can be used to uniquely decode any &amp;lt;math&amp;gt;[n,k]_q&amp;lt;/math&amp;gt; Reed–Solomon code in &amp;lt;math&amp;gt;O(n^3)&amp;lt;/math&amp;gt; time for a maximum of &amp;lt;math&amp;gt;\tfrac{1}{2}(n - k + 1)&amp;lt;/math&amp;gt; errors.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
Consider a simple example where a redundant set of points are used to represent the line &amp;lt;math&amp;gt;y = 5 - x&amp;lt;/math&amp;gt;, and one of the points is incorrect. The points that the algorithm gets as an input are &amp;lt;math&amp;gt;(1,4), (2,3), (3,4), (4,1)&amp;lt;/math&amp;gt;, where &amp;lt;math&amp;gt;(3,4)&amp;lt;/math&amp;gt; is the defective point. The algorithm must solve the following system of equations:&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt; \begin{align}&lt;br /&gt;
 Q(1) &amp;amp; = 4*E(1) \\&lt;br /&gt;
 Q(2) &amp;amp; = 3*E(2) \\&lt;br /&gt;
 Q(3) &amp;amp; = 4*E(3) \\&lt;br /&gt;
 Q(4) &amp;amp; = 1*E(4)&lt;br /&gt;
\end{align}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Given a solution pair &amp;lt;math&amp;gt;(Q, E)&amp;lt;/math&amp;gt; to this system of equations, it is evident that at any of the points &amp;lt;math&amp;gt;x = 1,2,3,4&amp;lt;/math&amp;gt; one of the following must be true:&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;Q(\alpha_i) = E(\alpha_i) = 0, \quad \text{or} \quad P(\alpha_i) = \frac{Q(\alpha_i)}{E(\alpha_i)} = y_i.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Since &amp;lt;math&amp;gt;E&amp;lt;/math&amp;gt; is defined as only having a degree of one, the former can only be true in one point. Therefore, &amp;lt;math&amp;gt;P(\alpha_i) = y_i&amp;lt;/math&amp;gt; at the three other points.&lt;br /&gt;
&lt;br /&gt;
Letting &amp;lt;math&amp;gt;E(x) = x + e_0&amp;lt;/math&amp;gt; and &amp;lt;math&amp;gt;Q = q_0 + q_1x + q_2x^2&amp;lt;/math&amp;gt; we can rewrite the system:&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;\begin{cases}&lt;br /&gt;
q_0 + q_1 + q_2 -4 e_0 -4 = 0 \\&lt;br /&gt;
q_0 +2q_1 + 4q_2 - 3e_0 - 6 = 0 \\&lt;br /&gt;
q_0 + 3q_1+ 9q_2 - 4e_0 - 12 = 0 \\&lt;br /&gt;
q_0 + 4q_1 + 16q_2 - e_0 -4 = 0&lt;br /&gt;
\end{cases}&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This system can be solved through [[Gaussian elimination]], and gives the values:&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;q_0 = -15, q_1 = 8, q_2 = -1, e_0 = -3&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Thus:&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;math&amp;gt;Q = -x^2 + 8x - 15, E = x - 3, \quad \text{and} \quad \frac{Q}{E} = P = 5-x.&amp;lt;/math&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;math&amp;gt;5-x&amp;lt;/math&amp;gt; fits three of the four points given, so it is the most likely to be the original polynomial.&lt;br /&gt;
&lt;br /&gt;
==See also==&lt;br /&gt;
&lt;br /&gt;
*[[BCH code]]&lt;br /&gt;
*[[Berlekamp–Massey algorithm]]&lt;br /&gt;
*[[Reed–Solomon error correction]]&lt;br /&gt;
&lt;br /&gt;
==Source==&lt;br /&gt;
&lt;br /&gt;
[http://wikipedia.org/ http://wikipedia.org/]&lt;br /&gt;
&lt;br /&gt;
[[Category:Cryptography]]&lt;br /&gt;
[[Category:Cryptographic algorithms]]&lt;br /&gt;
[[Category:Error-detecting codes]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
		
	</entry>
</feed>