Representation of natural numbers
Natural numbers are represented in the
-adic representation by a finite sequence of digits in the form

is displayed. This sequence of digits is now assigned the number 

where
the digit value assigned to the digit
is the digit value assigned to it.
It can be shown that for every natural number
there exists a sequence of digits whose associated value is
In general, there are even several sequences. It is sufficient to prefix the digit 0 = 0 arbitrarily often on higher-order digits. If sequences with leading 0 are forbidden, it can be shown that this assignment is even one-to-one, that is, for every natural number
there exists exactly one sequence whose assigned value is
As an exception to this prohibition, the number 0 is not assigned the empty sequence (i.e. the sequence without a single member), but the sequence with exactly one digit, namely the one to which the value 0 is assigned (i.e. 0), in order to make this number typographically recognizable.
As an example of the specified number representation, let's consider the sequence of digits 694 in the decimal system (
). It stands for:

The digit sequence 2B6 in the hexadecimal system (
) stands for
with
= 6 = 6;
= B = 11;
= 2 = 2.
So the sequence 2B6 has the value of the decimal number

Accordingly, the sequence of digits 1010110110 in the dual system (
) has the value of the decimal number

Representation of integers
In a system consisting of a positive base and a purely non-negative set of digits, negative numbers cannot be represented. In such systems a minus sign ("-") is added, which is prefixed to the number constants if necessary. This is accompanied by a slight loss of uniqueness, since the number 0 can be written as a signed zero in the form +0, -0, or even ±0. Representations of numbers other than 0 that are not preceded by a minus sign are interpreted as positive numbers. Sometimes, however, one wants to emphasize this positivity (e.g., if the number is to be identified as an increment). In such cases, a plus sign ("+") is prefixed in the display.
Representation of rational numbers
The notation is extended into the negative exponents of the base by connecting the corresponding digits to the right of a separator added for this purpose in a gapless sequence. In German-speaking countries (except Switzerland), the comma "," is used for this purpose, whereas in English-speaking countries the period ". " is commonly used. The values of the digits after the separator are multiplied by
, where indicates
the position after the comma. For example, the rational number 1+3/8 = 1.375 is represented in the 2-adic place value system by the digit sequence 1.011. In fact

After adding the separator, many rational numbers
-adic, but by no means all, for it may happen that an infinite sequence of decimal places is required for the representation, which is then periodic. Usually this period is marked by a line drawn across the repeating digits, thus marking the length of the period and allowing a (finite) writeup without dots.
While the number 1/5 = 0.2 has the finite digit sequence 0.2 in the decimal system, its representation in the dual system is periodic:
0,00110011…2 = 0,00112.
In contrast, the digit sequence 0.1 in the 3-adic (ternary) system means the rational number 1-3-1 = 1/3, which in the decimal system corresponds to an infinite periodic digit sequence 0.333... = 0.3dec.
Provided that 0 is a digit and that for every integer there is a digit whose value
is congruent to it (which is always the case for standard digit systems), it is generally true that a fraction has a finite
-adic representation if, after truncation, all prime factors of its denominator are also prime factors of
(for
and ν
) are. (Thus, for a finite representation in the decimal system, the truncated denominator must be a product of the numbers two and five. Exactly then the fraction is a decimal fraction in the strict sense or becomes one by extending).
The finite representations form the ring
,
where
stands
for the set of prime factors of For these rational numbers, in a fully truncated fraction representation, the denominator has only prime divisors
. For any nonempty
the subring is
of
(like
itself) dense in both
as well as in
, i.e., any real number can be approximated arbitrarily exactly by numbers from
.
If one considers only representations of finite length, then already the digit sequences 1, 1,0, 1,000 in the decimal system all designate the same rational number 1 (not to mention the representations 01, 0001 with leading zeros). These ambiguities can still be suppressed by prohibitions of leading and trailing zeros. If, however, the infinite representations belong to the system from the beginning, then the non-terminating representation 1.000... = 1.0 and, in addition, the completely different looking representation 0.999... = 0.9 (all with the value 1) are added, see the article 0.999.....
Normally, misunderstandings are not to be feared, so that one can allow both representations. However, uniqueness is required, for example, for the Z-curve, which is
maps injectively and where two
-digit sequences are alternately squeezed into one. Incidentally, the discontinuity points of the function
are precisely the arguments that have a finite
-adic representation.
The
-adic representation of a truncated fraction
with
and
divisible to the base
has period length 0 for
, so it is finite. Otherwise,
an element of the prime residue class
such that
(with φ
as the Eulerian φ-function). The
-adic period length of the truncated fraction
is then the smallest exponent
, for which is
a divisor of
(See also the section Algorithm for rational numbers and the article Rational number#decimal fraction development).
Representation of real numbers
The representation of real numbers takes place in principle exactly the same as that of rational numbers by b-adic development. With rational numbers this supplies a terminating or an infinite periodic digit sequence.
The b-adic expansion of an irrational number (like π or
), on the other hand, always yields an infinite non-periodic sequence of digits. By lengthening the decimal part, an arbitrarily exact approximation to the irrational number is possible.
As in the case of rational numbers with an infinitely periodic sequence of digits, a finite representation for irrational numbers is possible by introducing new symbols, as has been done here for the examples π and 
Nevertheless, even with an arbitrary but finite number of additional characters, not every real number can be represented as a finite string. This is because the set of real numbers is overcountable, but the set of all finite representations with finite character set is only countable.
But if the "representation" of a real number is understood as the sequence of digits resulting from the b-adic development, then every real number is representable as a (possibly infinite) b-adic fraction, even if not every such fraction is actually recordable.