# Pernicious number

Jump to navigation
Jump to search

This article needs additional citations for verification. (October 2018) (Learn how and when to remove this template message) |

In number theory, a **pernicious number** is a positive integer such that the Hamming weight of its binary representation is prime.

## Examples[edit]

The first pernicious number is 3, since 3 = 11_{2} and 1 + 1 = 2, which is a prime. The next pernicious number is 5, since 5 = 101_{2}, followed by 6, 7 and 9 (sequence A052294 in the OEIS).

## Properties[edit]

- No power of two is a pernicious number. This is trivially true, because powers of two in binary form are represented as a one followed by zeros. So each power of two has a Hamming weight of one, and one is not considered to be a prime.
- Every number of the form 2
^{n}+ 1 with*n*> 0, including every Fermat number, is a pernicious number. This is because the sum of the digits in binary form is 2, which is a prime number. - Every even perfect number is a pernicious number. This is based on the fact that every even perfect number can be represented as 2
^{p−1}(2^{p}− 1) with*p*a prime. Owing to this form, every even perfect number is represented in binary as*p*ones followed by*p*− 1 zeros. - A number of the form 2
^{p}− 1 with prime*p*is a pernicious number known as a Mersenne number (although sometimes Mersenne numbers are defined as 2^{n}− 1 for any natural number*n*).

## Related numbers[edit]

- Odious numbers are numbers with an odd number of 1s in their binary expansion (sequence A000069 in the OEIS).
- Evil numbers are numbers with an even number of 1s in their binary expansion (sequence A001969 in the OEIS).

## External links[edit]

- The NumbersWithNames Program pp. 6–7.
^{[dead link]}