1) L L argmaxflEQ(d*) L(-1)9i pi = arg max~ES(d*) L~iPi.(2) i=l i=lThus, the solution to Problem 1, where Pi are replaced by Vi, will also provide a solution to the VQ problem. Recent results in source coding have shown the advantages brought by the flexibility allowed Second application: vector quantization (VQ): In the generic problem of vector quantization a real valued vector 11. of dimension L has to be replaced by its best approximation in a codebook g.For some specific problems, see e.g., [1], the nearest neighbor must be looked for in a particular shell of the codebook g. The nearest neighbor in the Euclidean distance sense minimizes the distancei=l Problem 1 asks thus for the maximum dot product between the vectors~and P when the vectors~belong to the shell of weight d*. ---There are also problems where there is a need of finding only the overall maximum dot product, for all vectors in the codebook, this being the problem discussed in all previous papers, e.g., [3] [4], about ML decoding of Golay codes: Problem 2 For given numbers PI, ... ,PL find L L argmaxflEQ L(-1)9i pi = argmax~Es L~iPi. (3) i=l i=l where dH(g) = Li gi is the Hamming weight of the binary vector g: It is convenient to transform the binary elements of 9 into the symmetrical values~i = (-1)9i = 1 -2g i E {-I, i} and we denote by~= /(g) the element-wise transformation of 9 and by S the codebook resulting when applying the transformation-/ (.) to the vectors in the codebook g. We define the Hamming weight dH (~) of the vector~E S to be the same as the Hamming weight of the vector 9 = /=1 (~) E g. The shell of weight d* in the codebook g is the set g(d*) = {g E gldH(g) = d*} of codevectors having Hamming weight d* , and we also call shell d* in S the set S (d*) = {~E S IdH (~) = d*} of vectors obtained by transforming by / (.) the vectors of the shell d* in g.The ML decoding can thus be achieved by solving the following problem:Problem 1 For given numbers PI, ... ,PL find for each d* E V