Skip to content

Indicator FunctionΒΆ

DefinitionΒΆ

The indicator function is a function that identifies whether an element of a set satisfies a given property. It is denoted as πŸ™1A(x)\indicator_{A}(x) and defined as:

πŸ™1A(x)={ 1,ifΒ x∈A, 0,ifΒ xβˆ‰A.\indicator_{A}(x)= \begin{cases} \displaystyle \,1, & \text{if } x \in A, \\[2pt] \displaystyle \,0, & \text{if } x \notin A. \end{cases}

InterpretationΒΆ

An indicator function encodes set membership as a number: it answers the question "is xx in AA?" with 11 for yes and 00 for no.

The indicator function of an interval A, equal to 1 on A, drawn as a raised segment, and 0 elsewhere on the line.

Here A=[1,3]A=[1,3]. The graph is at height 11 above AA and at height 00 everywhere else, so it jumps at the two endpoints. The filled dots at (1,1)(1,1) and (3,1)(3,1) show that the endpoints belong to AA and receive the value 11.

Set operations become arithmetic on the values. For all sets AA and BB,

πŸ™1A∩B=πŸ™1AπŸ™1B,πŸ™1A∁=1βˆ’πŸ™1A,\indicator_{A\cap B}=\indicator_A\indicator_B,\quad \indicator_{A^{\complement}}=1-\indicator_A,

and πŸ™1AβˆͺB=πŸ™1A+πŸ™1Bβˆ’πŸ™1AπŸ™1B\indicator_{A\cup B}=\indicator_A+\indicator_B-\indicator_A\indicator_B; each identity is checked by going through the four cases of whether xx lies in AA and in BB. In probability the same idea returns as the indicator random variable, which is 11 when an event occurs and 00 otherwise.


Key ResultsΒΆ

  • Indicator functions take only the values 00 and 1.1\text{.}
  • Set operations can be translated into algebraic relations between indicator functions.
  • Indicator functions are widely used in integration and probability.

ExamplesΒΆ

  • πŸ™1[0,1](x)=1\indicator_{[0,1]}(x)=1 for x∈[0,1]x\in[0,1] and 00 otherwise.
  • πŸ™1Q(x)\indicator_{\mathbb{Q}}(x) distinguishes rational from irrational numbers.

PrerequisitesΒΆ

SourcesΒΆ

Aliases: characteristic function of a set Symbols: element of, intersection, rational numbers, union

Last updated: 20 October 2026 03:02