x and nonzero if there is an error. If there are ν errors at distinct powers ik of x, then The goal of the decoder is to find the number of errors (ν), the positions of the errors (ik), and the error values at those positions (eik). From those, e(x) can be calculated and subtracted from r(x) to get the originally sent message s(x). Syndrome decoding The decoder starts by evaluating the polynomial as received at points . We call the results of that evaluation the "syndromes", Sj. They are defined as: Note that because has roots at , as shown in the previous section. The advantage of looking at the syndromes is that the message polynomial drops out. In other words, the syndromes only relate to the error, and are unaffected by the actual contents of the message being transmitted. If the syndromes are all zero, the algorithm stops here and reports that the message was not corrupted in transit. Error locators and error values For convenience, define the error locators Xk and error values Yk as: Then the syndromes can be written in terms of these error locators and error values as This definition of the syndrome values is equivalent to the previous since . The syndromes give a system of equations in 2ν unknowns, but that system of equations is nonlinear in the Xk and does not have an obvious solution. However, if the Xk were known (see below), then the syndrome equations provide a linear system of equations that can easily be solved for the Yk error values. Consequently, the problem is finding the Xk, because then the leftmost matrix would be known, and both sides of the equation could be multiplied by its inverse, yielding Yk In the variant of this algorithm where the locations of the errors are already known (when it is being used as an erasure code), this is the end. The error locations (Xk) are already known by some other method (for example, in an FM transmission, the sections where the bitstream was unclear or overcome with interference are probabilistically determinable from frequency analysis). In this scenario, up to errors can be corrected. The rest of the algorithm serves to locate the errors, and will require syndrome values up to , instead of just the used thus far. This is why 2x as many error correcting symbols need to be added