A total variation distance between PP and QQ on the same (Ω,F)(\Omega,\mathcal F) is

dTV(P,Q)  =  sup⁡A∈F ∣P(A)−Q(A)∣d_{\mathrm{TV}}(P,Q)\;=\;\sup_{A\in\mathcal F}\,\bigl|P(A)-Q(A)\bigr|

where the supremum ranges over AA.

If P,Q≪μP,Q\ll\mu with densities p=dP/dμp=dP/d\mu and q=dQ/dμq=dQ/d\mu, then

dTV(P,Q)=12∫Ω∣p−q∣ dμ.d_{\mathrm{TV}}(P,Q)=\frac12\int_\Omega |p-q|\,d\mu.
Examples
  • For with parameters pp and qq, dTV(P,Q)=∣p−q∣d_{\mathrm{TV}}(P,Q)=|p-q|.
  • For (pi)(p_i) and (qi)(q_i) on a finite set,
    dTV(P,Q)=12∑i∣pi−qi∣.d_{\mathrm{TV}}(P,Q)=\frac12\sum_i|p_i-q_i|.