Weight (strings)
The -weight of a string, for a letter, is the number of times that letter occurs in the string. More precisely, let be a finite set, a letter of, and a
string. Then the -weight of, denoted by, is the number of times the generator occurs in the unique expression for as a product of letters in.
If is an abelian group, the Hamming weight of,
often simply referred to as "weight", is the number of nonzero letters in.Examples
- Let. In the string, occurs 5 times, so the -weight of is.
- Let and. Then,, and.