511 (number)
# 511 (number)

511 is the natural number following 510 and preceding 512.

It is a Mersenne number, being one less than a power of 2: $511=2^{9}-1$. As a result, 511 is a palindromic number and a repdigit in bases 2 $(111111111_2).$ It is also palindromic and a repdigit in base 8 $(777_8).$

It is a generalized heptagonal number (sequence A085787 in the OEIS), since $511={\frac {1}{2}}(5n^{2}-3n)$ when $n=-14$.

It is a Harshad number in bases 3, 5, 7, 10, 13 and 15.

## Special use in computers

The octal representation of 511 $(777_8)$ is commonly used by Unix commands to specify a custom record separator in order to "slurp" input as a whole, rather than line-by-line (i.e. separated at newline characters).

