# Singly and doubly even

In mathematics an even integer, that is, a number that is divisible by 2, is called evenly even or doubly even if it is a multiple of 4, and oddly even or singly even if it is not. The former names are traditional ones, derived from ancient Greek mathematics; the latter have become common in recent decades.
These names reflect a basic concept in number theory, the 2-order of an integer: how many times the integer can be divided by 2. Specifically, the 2-order of a nonzero integer n is the maximum integer value k such that n/2$^k$ is an integer. This is equivalent to the multiplicity of 2 in the prime factorization.
* A singly even number can be divided by 2 only once; it is even but its quotient by 2 is odd.
* A doubly even number is an integer that is divisible more than once by 2; it is even and its quotient by 2 is also even.
The separate consideration of oddly and evenly even numbers is useful in many parts of mathematics, especially in number theory, combinatorics, coding theory (see even codes), among others.

## Definitions

The ancient Greek terms "even-times-even" (Ancient Greek: ἀρτιάκις ἄρτιος) and "even-times-odd" (Ancient Greek: ἀρτιάκις περισσός or ἀρτιοπέριττος) were given various inequivalent definitions by Euclid and later writers such as Nicomachus. Today, there is a standard development of the concepts. The 2-order or 2-adic order is simply a special case of the p-adic order at a general prime number p; see p-adic number for more on this broad area of mathematics. Many of the following definitions generalize directly to other primes.
For an integer n, the 2-order of n (also called valuation) is the largest natural number ν such that 2$^ν$ divides n. This definition applies to positive and negative numbers n, although some authors restrict it to positive n; and one may define the 2-order of 0 to be infinity (see also parity of zero). The 2-order of n is written ν$_2$(n) or ord$_2$(n). It is not to be confused with the multiplicative order modulo 2.
The 2-order provides a unified description of various classes of integers defined by evenness:
* Odd numbers are those with ν$_2$(n) = 0, i.e., integers of the form 2m + 1.
* Even numbers are those with ν$_2$(n) > 0, i.e., integers of the form 2m. In particular:
** Singly even numbers are those with ν$_2$(n) = 1, i.e., integers of the form 4m + 2.
** Doubly even numbers are those with ν$_2$(n) > 1, i.e., integers of the form 4m.
*** In this terminology, a doubly even number may or may not be divisible by 8, so there is no particular terminology for "triply even" numbers in pure math, although it is used in children's teaching materials including higher multiples such as "quadruply even."
One can also extend the 2-order to the rational numbers by defining ν$_2$(q) to be the unique integer ν where
    $q=2^{\nu }{\frac {a}{b}}$
and a and b are both odd. For example, half-integers have a negative 2-order, namely −1. Finally, by defining the 2-adic absolute value
    $|n|_{2}=2^{-\nu _{2}(n)},$
one is well on the way to constructing the 2-adic numbers.

## Applications
### Safer outs in darts

The object of the game of darts is to reach a score of 0, so the player with the smaller score is in a better position to win. At the beginning of a leg, "smaller" has the usual meaning of absolute value, and the basic strategy is to aim at high-value areas on the dartboard and score as many points as possible. At the end of a leg, since one needs to double out to win, the 2-adic absolute value becomes the relevant measure. With any odd score no matter how small in absolute value, it takes at least two darts to win. Any even score between 2 and 40 can be satisfied with a single dart, and 40 is a much more desirable score than 2, due to the effects of missing.
A common miss when aiming at the double ring is to hit a single instead and accidentally halve one's score. Given a score of 22 — a singly even number — one has a game shot for double 11. If one hits single 11, the new score is 11, which is odd, and it will take at least two further darts to recover. By contrast, when shooting for double 12, one may make the same mistake but still have 3 game shots in a row: D12, D6, and D3. Generally, with a score of n < 42, one has ν$_2$(n) such game shots. This is why 32 = 2$^5$ is such a desirable score: it splits 5 times.

### Irrationality of the square root of 2

The classic proof that the square root of 2 is irrational operates by infinite descent. Usually, the descent part of the proof is abstracted away by assuming (or proving) the existence of irreducible representations of rational numbers. An alternate approach is to exploit the existence of the ν$_2$ operator.
Assume by contradiction that
    ${\sqrt {2}}={\frac {a}{b}},$
where a and b are non-zero natural numbers. Square both sides of the equality and apply the 2-order valuation operator ν$_2$ to 2b$^2$ = a$^2$:
    $\nu _{2}\left(2b^{2}\right)=\nu _{2}\left(a^{2}\right)$
    $\nu _{2}\left(b^{2}\right)+1=\nu _{2}\left(a^{2}\right)$
    $2\nu _{2}(b)+1=2\nu _{2}(a)$
    $\nu _{2}(a)-\nu _{2}(b)={\frac {1}{2}}$
Since 2-order valuations are integers, the difference cannot be equal to the rational 1/2 {\textstyle {\frac {1}{2}}}. By contradiction, therefore, √2 is not a rational.
More concretely, since the valuation of 2b$^2$ is odd, while valuation of a$^2$ is even, they must be distinct integers, so that $\left|2b^{2}-a^{2}\right|\geq 1$. An easy calculation then yields a lower bound of 1/3b$^2$ {\textstyle {\frac {1}{3b^{2}}}} for the difference $\left|{\sqrt {2}}-a/b\right|$, yielding a direct proof of irrationality not relying on the law of excluded middle.

### Geometric topology

In geometric topology, many properties of manifolds depend only on their dimension mod 4 or mod 8; thus one often studies manifolds of singly even and doubly even dimension (4k+2 and 4k) as classes. For example, doubly even-dimensional manifolds have a symmetric nondegenerate bilinear form on their middle-dimension cohomology group, which thus has an integer-valued signature. Conversely, singly even-dimensional manifolds have a skew-symmetric nondegenerate bilinear form on their middle dimension; if one defines a quadratic refinement of this to a quadratic form (as on a framed manifold), one obtains the Arf invariant as a mod 2 invariant. Odd-dimensional manifolds, by contrast, do not have these invariants, though in algebraic surgery theory one may define more complicated invariants. This 4-fold and 8-fold periodicity in the structure of manifolds is related to the 4-fold periodicity of L-theory and the 8-fold periodicity of real topological K-theory, which is known as Bott periodicity.
If a compact oriented smooth spin manifold has dimension n ≡ 4 mod 8, or ν$_2$(n) = 2 exactly, then its signature is an integer multiple of 16.

### Other appearances

A singly even number cannot be a powerful number. It cannot be represented as a difference of two squares. However, a singly even number can be represented as the difference of two pronic numbers or of two powerful numbers.
In group theory, it is relatively simple to show that the order of a nonabelian finite simple group cannot be a singly even number. In fact, by the Feit–Thompson theorem, it cannot be odd either, so every such group has doubly even order.
Lambert's continued fraction for the tangent function gives the following simple continued fraction involving the positive singly even numbers:
    $\tanh {\frac {1}{2}}={\frac {e-1}{e+1}}=0+{\cfrac {1}{2+{\cfrac {1}{6+{\cfrac {1}{10+{\cfrac {1}{14+{\cfrac {1}{\ddots }}}}}}}}}}$
This expression leads to similar representations of e.
In organic chemistry, Hückel's rule, also known as the 4n + 2 rule, predicts that a cyclic π-bond system containing a singly even number of p electrons will be aromatic.

## Related classifications

Although the 2-order can detect when an integer is congruent to 0 (mod 4) or 2 (mod 4), it cannot tell the difference between 1 (mod 4) or 3 (mod 4). This distinction has some interesting consequences, such as Fermat's theorem on sums of two squares.