Binary inner product (source code)

= Binary inner product
{title2=$x\cdot y$}

For <vectors> $x,y\in\mathbb F_2^n$, the binary inner product is the <bilinear form>
$$
x\cdot y=\sum_{i=1}^n x_i y_i\quad\text{in }\mathbb F_2.
$$
Its value is the <parity> of the coordinates at which both <vectors> are one. For example, $(1,1,0)\cdot(1,0,1)=1$, whereas $(1,1)\cdot(1,1)=0$ because $1+1=0$ in the <finite field> $\mathbb F_2$.

The terminology does not impose the <positive definiteness> axiom of a real or complex <inner product>. A nonzero <vector> can have zero self-pairing, as the second example shows. The form is nevertheless a <nondegenerate bilinear form>: a nonzero coordinate of $x$ is detected by pairing with the corresponding <standard basis vector>. This pairing defines <orthogonality> and <dual codes> in <coding theory>.