Counting measure
In mathematics, specifically measure theory, the counting measure is an intuitive way to put a measure on any set – the "size" of a subset is taken to be the number of elements in the subset if the subset has finitely many elements, and infinity formula_1 if the subset is infinite. The counting measure can be defined on any measurable space (that is, any set formula_2 along with a sigma-algebra) but is mostly used on countable sets. In formal notation, we can turn any set formula_2 into a measurable space by taking the power set of formula_2 as  the sigma-algebra formula_5 that is, all subsets of formula_2 are measurable sets. Then the counting measure formula_7 on this measurable space formula_8 is the positive measure formula_9 defined by formula_10 for all formula_11 where formula_12 denotes the cardinality of the set formula_13 The counting measure on formula_8 is σ-finite if and only if the space formula_2 is countable. Discussion. The counting measure is a special case of a more general construction. With the notation as above, any function formula_16 defines a measure formula_7 on formula_18 via formula_19 where the possibly uncountable sum of real numbers is defined to  be the supremum of the sums over all finite subsets, that is, formula_20 Taking formula_21 for all formula_22 gives the counting measure.