In category theory, a subobject classifier is a special object Ω of a category; intuitively, the subobjects of an object X correspond to the morphisms from X to Ω. As the name suggests, what a subobject classifier does is to identify/classify subobjects of a given object according to which elements belong to the subobject in question. Because of this role, the subobject classifier is also referred to as the "truth value object". In fact, the way in which the subobject classifier classifies subobjects of a given object is by assigning the values true to elements belonging to the subobject in question, and false to elements not belonging to the subobject. This is why the subobject classifier is widely used in the categorical description of logic.
As an example, the set Ω = {0,1} is a subobject classifier in the category of sets and functions: to every subset A of S defined by the inclusion function j : A → S we can assign the function χA from S to Ω that maps precisely the elements of A to 1 (see characteristic function). Every function from S to Ω arises in this fashion from precisely one subset A.
To be clearer, consider a subset A of S (A ⊆ S), where S is a set. The notion of being a subset can be expressed mathematically using the so-called characteristic function χA : S → {0,1}, which is defined as follows:
(Here we interpret 1 as true and 0 as false.) The role of the characteristic function is to determine which elements belong to the subset A. In facts, χA is true precisely on the elements of A.
In this way, the collection of all subsets of S, denoted by P(S), and the collection of all maps from S to Ω = {0,1}, denoted by ΩS, are isomorphic.
To categorize this notion, recall that, in category theory, a subobject is actually a pair consisting of an object and a monic arrow (interpreted as the inclusion into another object). Accordingly, true refers to the element 1, which is selected by the arrow: true: {0} → {0, 1} that maps 0 to 1. The subset A of S can now be defined as the pullback of true along the characteristic function χA, shown on the following diagram: