Home

baserepresentation

Base representation, or base representation of numbers, is the expression of numbers in terms of powers of a fixed base b. In a base-b system, any nonnegative integer n can be written uniquely as n = d_k b^k + d_{k-1} b^{k-1} + ... + d_0, where 0 ≤ d_i < b and d_k ≠ 0. The sequence of digits (d_k ... d_0) is the base-b representation of n. For example, decimal (base 10) representation of 255 is 255, binary (base 2) representation is 11111111, and hexadecimal (base 16) representation is FF.

To obtain the base-b representation, one performs repeated division of n by b, recording the remainders. The

Base representations extend to fractions, where the base-b expansion of a rational number is finite if and

Common bases include binary (base 2), octal (base 8), decimal (base 10), and hexadecimal (base 16). In

remainders
give
the
digits
from
least
significant
to
most
significant.
The
representation
of
0
is
0.
If
the
number
is
negative,
a
minus
sign
is
placed
in
front.
only
if
the
denominator
divides
a
power
of
b;
otherwise
it
is
infinite
and
eventually
periodic.
For
example,
in
base
2,
1/2
=
0.1,
while
in
base
10,
1/3
=
0.333...
with
a
repeating
block.
higher
bases,
digits
beyond
9
are
represented
with
letters
(for
instance,
A–F
for
base
16).
Base
representation
is
fundamental
in
computing,
digital
encoding,
and
mathematical
numeration
systems,
providing
efficient
methods
for
arithmetic,
data
storage,
and
number
interpretation.