Inclusion-exclusion formula

From Encyclopedia of Mathematics
Jump to: navigation, search

inclusion-exclusion principle, inclusion-exclusion method

The inclusion-exclusion principle is used in many branches of pure and applied mathematics. In probability theory it means the following theorem: Let be events in a probability space and


Then one has the relation


This theorem can easily be proved by induction on . Another proof can be given by the use of indicator variables, as follows. In connection with an event one defines if occurs, and otherwise. Then the equation


holds. Taking expectations on both sides, the theorem follows.

If one wants to find the probability of , then first one observes that and then uses (a2) for the events .

The theorem is frequently attributed to H. Poincaré [a8]. However, it was already known to A. De Moivre [a2] and the even more general formula for the probability that at least events occur has been found by r equation','../p/p072950.htm','Positive variation of a function','../p/p073970.htm','Rectifiable curve','../r/r080130.htm','Variation of a function','../v/v096110.htm')" style="background-color:yellow;">C. Jordan [a4]. See also [a5] for further references. All these formulas concern Boolean functions of random events.

An example for the application of formula (a2) is the solution of the classical problem of coincidences proposed by P.R. Montmort [a7]: A box contains cards marked and all cards are drawn, one by one, without replacement, where each sequence has the same probability; one says that a coincidence occurs at the th drawing, or event occurs, if the card drawn is marked ; the problem is to find the probability that at least one coincidence occurs (cf. also Montmort matching problem). One easily sees that for any one has



The numbers have another probabilistic interpretation: , where , i.e., is the number of events which occur. One says that is the th binomial moment of . For a proof of the above equation, see, e.g., [a11].

There are many practical applications where one needs to compute the probability of a union, or other Boolean function of events. Prominent are those in reliability theory. For example, in a communication network, where the links randomly work or fail, one may want to find a two-terminal reliability or the all-terminal reliability. In the former case one has to find the probability that all links in at least one path connecting the two terminal nodes work, and in the latter case the probability that all links in at least one spanning tree work. In both cases the number of random events is too large to apply inclusion-exclusion. In fact, one may be able to compute only a few of the binomial moments involved. In such cases one looks for bounds. The simplest ones, for the probability of the union, are the Bonferroni bounds:

if is even, and

if is odd, where (cf. also Bonferroni inequalities). However, in many cases these bounds are not sufficiently tight.

A general, efficient method for bounding and other Boolean functions of events has been worked out by A. Prékopa (see [a10] and the references therein). In the case of bounding the probability of the union one observes that , where is the probability that exactly events occur. Then, if one knows , where , but the are unknown, one solves the linear programs:


If and are the optimum values corresponding to the min and max problems, respectively, then these are sharp bounds for the probability of the union, i.e.

and no better bounds can be given based on the knowledge of . There are simple and efficient algorithms to solve problems (a4) which are variants of the dual algorithm of linear programming. The sharp bounding formulas can also be written as

where and are optimal solutions of the duals of the min and max problems, respectively. It has been shown that the components of and have alternating signs, starting with , and , . The optimum values can be expressed by formulas if (see the references in [a10]).

Formula (a2) holds for any finitely additive set function defined on an algebra of some subsets of (if , then , and if , then ). In particular, one may take an arbitrary finite set, all subsets of and , the cardinality of the set . The latter case has many applications in combinatorics, especially in enumeration problems. A good sample of combinatorial problems, where inclusion-exclusion is used, is presented in [a6].

Inclusion-exclusion plays also an important role in number theory. Here one calls it the sieve formula or sieve method. In this respect, V. Brun did pioneering work [a1] (cf. also Sieve method; Brun sieve). For a summary of the sieve methods, see [a9] and [a3]. A simple but revealing example is the formula for , the number of those positive integers that are relative prime to, and smaller than, . If has prime divisors , then the inclusion-exclusion principle gives:


[a1] V. Brun, "Le crible d'Eratosthène et le théorème de Goldbach" Skrifter Norske Vid.-Akad. Kristiana I , 3 (1920)
[a2] A. De Moivre, "Doctrine of chances" , London (1718)
[a3] H. Halberstam, H.E. Richert, "Sieve methods" , Acad. Press (1974)
[a4] C. Jordan, "De quelques formules de probabilité" C.R. Acad. Sci. Paris , 65 (1867) pp. 993–994
[a5] K. Jordan, "Chapters on the classical calculus of probability" , Akad. Kiadó (1972)
[a6] L. Lovász, "Combinatorial problems and exercises" , Akad. Kiadó (1993)
[a7] P.R. Montmort, "Essai d'analyse sur les jeux de hazard" , Paris (1708)
[a8] H. Poincaré, "Calcul des probabilités" , Gauthier-Villars (1896)
[a9] K. Prachar, "Primzahlverteilung" , Springer (1957)
[a10] A. Prékopa, "Stochastic programming" , Kluwer Acad. Publ. (1995)
[a11] L. Takács, "On the method of inclusion and exclusion" J. Amer. Statist. Assoc. , 62 (1967) pp. 102–113
How to Cite This Entry:
Inclusion-exclusion formula. András Prékopa (originator), Encyclopedia of Mathematics. URL:
This text originally appeared in Encyclopedia of Mathematics - ISBN 1402006098