Mathematics · Article
Random variables and probability distributions
Build probability laws for numerical recordings, distinguish mass, density and cumulative probability, and transform distributions without losing support or atoms. Develop quantiles, inverse sampling, mixed and singular laws, and joint distributions with their dependence.
Back to MathematicsAfter reading, you can
- Distinguish an underlying outcome, a numerical recording and the induced probability law.
- Explain measurability in a finite or coarse event model and derive the pushforward construction.
- Use mass functions and cumulative distribution functions with correct interval endpoints and jumps.
- Apply a stated lower-quantile convention and explain inverse-transform sampling.
- Distinguish discrete, absolutely continuous, mixed and singular continuous laws, including their units and support.
- Transform discrete and continuous laws through preimages, valid inverse branches and appropriate Jacobians.
- Construct joint and marginal laws and test independence without inferring it from marginals alone.
A random variable is a recording rule
An experiment produces an outcomeω in a sample spaceΩ. A real-valued random variable X assigns a number X(ω) to each outcome. The number may record a count, a time, an energy, a payout or another specified quantity. X is the recording function;ω is the underlying outcome; x denotes a possible recorded value. These are different objects even when a simple model labels its outcomes with numbers.
Roll one fair six-sided die and record X=−2 on faces 1,2; X=0 on faces 3,4,5; and X=5 on face 6. The die still has six equally weighted detailed outcomes, but the recording has three possible values with unequal probabilities. The value 0 collects three faces, so it has probability 1/2. The function has changed what is recorded, not the probabilities of the original faces.
One experiment can support several recordings. For a sequence of coin tosses, X could count H results, Y could record the position of the first H and Z could record a payout determined by the sequence. Their definitions can share information and create dependence. Choosing numerical labels is not a claim that those recordings are independent or that their values are equally likely.
The word random does not mean the function itself must change from trial to trial. The rule X is fixed in the model; uncertainty aboutω induces uncertainty about X(ω). A constant function also qualifies: recording 7 for every outcome gives a variable equal to 7 with probability one. Random-variable theory includes such degenerate cases and does not require positive variation.
Specify units and exceptional outcomes when defining the rule. A waiting-time record might include censoring, a failed measurement or a convention for no event before a deadline. A finite real-valued model cannot silently assign∞ without expanding its stated value space. Counts and times are different recordings even if both are represented by numbers; their possible values, units and laws must follow their definitions.
Advanced foundation: the recording must define events
On a probability space(Ω,ℱ,P), a real random variable is a measurable function. This means that for every Borel set B of real values, the preimage X⁻¹(B)={ω:X(ω)∈B} belongs toℱ, so its probability is defined. Borel sets include intervals and the sets generated from them by countable event operations. Equivalently, it is enough to require{X≤t}∈ℱ for every real t, because those half-lines generate the Borel event collection.
In an elementary finite model where every subset ofΩ is an event, this requirement is automatic for every real-valued function. You can work directly with the outcome table without a technical measurability proof. The definition matters when the event collection is coarser or the outcome space is infinite. It ensures that statements about the recorded number correspond to legitimate events of the model.
For example, letΩ={a,b,c,d} andℱ={∅,Ω,{a,b},{c,d}}. Define X(a)=X(c)=0 and X(b)=X(d)=1. Then{X≤1/2}={a,c}, which is not inℱ. This numerical function is not a random variable on that specified event space. The issue is not its arithmetic; the model did not assign probabilities to the events that this recording needs.
One could choose a different measurable recording, such as a common value on each of the two event-space blocks. Alternatively, one could enlarge the event model and supply an appropriate probability extension. These are explicit modeling changes. Do not calculate a probability for{a,c} from the coarse event model without supplying the missing structure.
This foundation need not obstruct the practical route through the lesson. For ordinary discrete tables and the stated density models below, the recordings used are measurable. The useful habit is to translate a numerical question back to an outcome event. The formal condition explains why that translation is legitimate and prevents treating every arbitrary map on every event space as automatically admissible.
Move the original probability onto recorded values
The law or distribution of X is the probability measureμ_X defined byμ_X(B)=P(X∈B)=P(X⁻¹(B)). The term pushforward describes this transfer from detailed outcomes to recorded values. The preimage notation does not require X to have an inverse function. Many outcomes may map to the same value; their masses are combined rather than lost.
The construction preserves the probability rules. X⁻¹(ℝ)=Ω givesμ_X(ℝ)=1. Preimages of disjoint sets are disjoint, and the preimage of a countable union is the union of the preimages. Thereforeμ_X(⋃ᵢBᵢ)=Σᵢμ_X(Bᵢ) for disjoint Bᵢ, using additivity of P. Nonnegativity is inherited. This is why an induced law is a probability measure, rather than merely a list of descriptive numbers.
In the die recording, the masses areμ_X({−2})=2/6=1/3, μ_X({0})=3/6=1/2 andμ_X({5})=1/6. To ask whether−1<X≤6, take the preimage of(−1,6], which is the four faces 3,4,5,6. The probability is 4/6=2/3, also obtained by adding the recorded-value masses 1/2+1/6.
The declared original law is validated; the recording does not change it. The finite event collection is the full power set.
| Recorded value | Source outcomes | Induced probability |
|---|---|---|
| -2 | 1, 2 | 1/3 |
| 0 | 3, 4, 5 | 1/2 |
| 5 | 6 | 1/6 |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Target recorded-event mass | 2/3 | Probability of the complete preimage |
| Total induced mass | 1 | The pushforward preserves normalization |
The variable X and its lawμ_X are not interchangeable. X tells us which detailed outcomes receive which values;μ_X tells us the probabilities of sets of those values. A mass function, a density when available, and a cumulative distribution function are ways to represent aspects of the law. None is the underlying recording function itself.
Coarsening or transforming a recording repeats the same construction. If Y=g(X), then{Y∈B}={X∈g⁻¹(B)}. Probability follows the complete preimage through the recording maps. This perspective will handle discrete sums, decreasing transformations, multiple inverse branches and atoms without requiring a separate informal rule for each situation.
Equal distributions do not identify the same recording
Two variables have the same law when they assign the same probabilities to every Borel set. They need not be the same function or have the same value on each outcome. On a common probability space, X=Y almost surely means P(X=Y)=1. That stronger relation implies equal laws, because the events{X∈B} and{Y∈B} can differ only on the null set where X≠Y.
The converse fails. Let U be uniform on(0,1), and define X=U and Y=1−U. Both have the uniform law on(0,1): reflecting an interval preserves its length. Yet X=Y only when U=1/2, an event of probability zero. Thus they have equal laws while being unequal almost surely. The law of a single recording does not retain its point-by-point relation with another recording.
Another pair could use a fresh independent uniform variable V instead of 1−U. The marginals would again both be uniform, but the joint behavior would differ. With Y=U, the event{X≤1/5,Y≤1/5} has probability 1/5. With Y=1−U it has probability 0. With an independent V it has probability 1/25. The same two marginal laws support three different dependence structures.
A simulation, measurement model or mathematical proof therefore needs a joint construction whenever it asks how several variables behave together. Saying that every measurement has the same marginal distribution is not the same as saying the measurements are independent, identical as functions, or interchangeable under every operation involving the full sequence.
This distinction also clarifies scientific statements such as “two models predict the same distribution.” They may agree for one measured quantity and disagree for joint records, time ordering or interventions. Specify which law is being compared. Equality for one summary does not establish equality of the entire data-generating model.
Add the masses at possible values
A real-valued law is discrete if some finite or countable set S carries probability one. Its probability mass function is p_X(s)=P(X=s). The masses are nonnegative andΣ_{s∈S}p_X(s)=1. For a set A, P(X∈A)=Σ_{s∈S∩A}p_X(s). The values may be negative, noninteger or irregularly spaced; discreteness refers to countable mass, not to a particular numerical grid.
Suppose p(k)=c(k+1) for k=0,1,2,3 and zero elsewhere. The weights 1,2,3,4 sum to 10, so c=1/10. The masses are 1/10,1/5,3/10,2/5. Their total is one. The probability 1≤X<3 is the sum at 1 and 2, namely 1/2. The interval’s length is irrelevant to this mass calculation.
A stem plot can place one labelled mass at each value. Its vertical heights are probabilities, and their sum—not an area under a connecting line—is one. Connecting stems with a curve can falsely suggest that intermediate values have mass or that the shape is an ordinary density. Keep the discrete value set and the probability encoding visible.
Countably infinite laws need convergent sums. For example, p(k)=2^{−k} on k=1,2,… sums to one by the geometric series. Its tail P(X≥3)=Σ_{k≥3}2^{−k}=1/4. Nonnegative mass allows these sums to be formed without cancellation. An infinite list of equal positive singleton masses could not sum to one, so “uniform on all positive integers” is not an ordinary probability mass function.
A discrete law can even have atoms dense in an interval if positive summable weights are assigned to a countable dense set. Thus a topological support need not look like isolated points. For elementary computations, identify the values carrying mass and add their weights. A more precise discussion of support below separates that mass list from the law’s closed topological support.
Cumulative probability works for every real-valued law
The cumulative distribution function, or CDF, is F_X(t)=P(X≤t). It applies to discrete, density-based, mixed and singular laws. Unlike a density, it does not require an integral representation with respect to ordinary length. Because it records the probabilities of all lower half-lines, it determines the complete law of a real-valued variable.
Every CDF is nondecreasing: if a≤b, then{X≤a}⊆{X≤b}. It is right-continuous, and its limits are zero as t tends to−∞ and one as t tends to+∞. Conversely, a real function with these properties is the CDF of a real-valued probability law. Differentiability is not part of the characterization. Jumps and flat stretches are both allowed.
For the masses 1/10,1/5,3/10,2/5 at 0,1,2,3, the CDF is 0 below 0;1/10 on[0,1);3/10 on[1,2);3/5 on[2,3); and 1 at or above 3. Its value at a mass point includes that point’s mass because the defining event uses≤. A step plot should show closed and open endpoints consistently with this convention.
CDFs are dimensionless probabilities plotted against values of the variable. If the horizontal axis is time, its unit is time while the vertical axis remains probability. A CDF cannot decrease, exceed one or fall below zero. A candidate that satisfies those easy checks can still fail right-continuity or a limiting condition, so a plausible-looking curve is not sufficient.
A flat stretch means that the corresponding open range carries no additional mass. A jump means that an exact value has positive mass. A smoothly increasing segment may come from a density, but mere continuity does not guarantee one. Keeping the CDF as the general representation lets us compare these different kinds of law without assigning an ordinary density where none exists.
Keep the interval endpoints in the calculation
Write F(a−)=lim_{t↑a}F(t)=P(X<a). The mass at a is P(X=a)=F(a)−F(a−), the CDF’s jump. This formula works at negative values, zero and nonintegers. There is no general reason for a point probability to vanish unless the law is known to be atomless.
For a<b, P(a<X≤b)=F(b)−F(a). Including the left endpoint instead gives P(a≤X≤b)=F(b)−F(a−). Excluding the right endpoint gives P(a<X<b)=F(b−)−F(a). Derive each expression by subtracting the appropriate nested half-line events. Memorizing only one subtraction formula can produce an error when an endpoint has mass.
Let the masses at−1,2,4 be 1/4,1/2,1/4. Then F(2−)=1/4 while F(2)=3/4, so the atom at 2 has mass 1/2. The interval−1≤X<2 contains only the mass at−1 and has probability 1/4. The interval−1<X≤2 instead contains only the mass at 2 and has probability 1/2. Equal geometric lengths do not make their probabilities equal.
The CDF is right-continuous. An open interval with equal endpoints is empty; a closed singleton may carry an atom. The finite CDF window has labelled continuation arrows for outside query bounds; probabilities use the actual unmodified bounds.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Interval probability | 1/4 | Endpoint membership is evaluated before summing |
| Left query endpoint a | -1 | Actual input; continuation arrows only bound its drawing |
| Right query endpoint b | 2 | Actual input; continuation arrows only bound its drawing |
| F(a−) | 0 | Strictly below the left endpoint |
| F(a) | 1/4 | At or below the left endpoint |
| F(b−) | 1/4 | Strictly below the right endpoint |
| F(b) | 3/4 | At or below the right endpoint |
| P(X=b) | 1/2 | Jump mass at b |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Interval probability | 1/4 | Endpoint membership is evaluated before summing |
| Left query endpoint a | -1 | Actual input; continuation arrows only bound its drawing |
| Right query endpoint b | 2 | Actual input; continuation arrows only bound its drawing |
| F(a−) | 0 | Strictly below the left endpoint |
| F(a) | 1/4 | At or below the left endpoint |
| F(b−) | 1/4 | Strictly below the right endpoint |
| F(b) | 3/4 | At or below the right endpoint |
| P(X=b) | 1/2 | Jump mass at b |
If a law has no atom at an endpoint, changing inclusion of that endpoint does not affect the probability. For a law with a density, every singleton is null, so all four endpoint choices for an ordinary finite interval agree. That convenience is a consequence of the law; it is not permission to ignore endpoints in a discrete or mixed problem.
A graph should distinguish a jump’s value from its left limit. The point at height F(a) belongs to the CDF, and an open marker can show the preceding limiting height. For accessible text, report both numbers and the difference. This makes the point mass explicit even when a narrow display makes two adjacent vertical levels hard to inspect.
Why the value belongs to the right side of a jump
The right-continuity rule follows from probability’s behavior on decreasing events. Take tₙ decreasing to t. Then the events{X≤tₙ} decrease to{X≤t}: a value above t is eventually excluded, while every value at or below t remains. Continuity of a finite probability measure from above gives limₙP(X≤tₙ)=P(X≤t), so F(tₙ) tends to F(t).
Approaching from below has a different event limit. If tₙ<t increases to t, the events{X≤tₙ} increase to{X<t}, which excludes the equality value. Their probabilities tend to F(t−). The gap between this limit and F(t) is exactly the atom at t. The distinction is an event-set fact, not a convention chosen merely to draw a tidy staircase.
Consider a proposed function equal to 0 for x<0,1/5 at x=0 and 1 for x>0. It is nondecreasing and has the correct far-left and far-right limits. Nevertheless, its right limit at zero is 1 while its value is 1/5, so it cannot be a CDF. It would imply incompatible probabilities for a decreasing sequence of events around zero.
This reasoning also explains why the CDF characterization has all its conditions. Monotonicity represents containment; the end limits represent total probability on real values; right-continuity represents decreasing-event limits. For variables allowed to take extended values such as+∞, the end behavior can differ because some mass is outside the real line. Such a model needs its value space stated separately.
You do not need to prove these properties afresh for every table or integrated density. Reuse the established construction when the new law’s inputs are valid. When a candidate CDF is supplied directly, however, test the characterization—including boundary values—before using it to assign probabilities or quantiles.
A quantile selects a threshold, with a stated convention
For 0<u<1, this lesson uses the lower quantile Q(u)=inf{x:F(x)≥u}. It selects the leftmost threshold at which cumulative probability reaches or exceeds u. The end limits ensure that this infimum is finite for a real-valued law, and right-continuity ensures F(Q(u))≥u. In general F(Q(u)−)≤u≤F(Q(u)); the CDF need not hit u exactly.
For the four-point law with cumulative levels 1/10,3/10,3/5,1 at values 0,1,2,3, Q(3/5)=2. Increasing the requested level slightly to 61/100 gives Q(61/100)=3. A jump can supply a whole interval of quantile levels at one value. A flat stretch can make the chosen endpoint depend on the inverse convention.
Lower quantile convention: Q(u)=inf{x:F(x)≥u}; 0<u<1. Open circles show left limits; filled circles show the CDF values.
| x | p(x) | F(x−) | F(x) |
|---|---|---|---|
| 0 | 1/10 | 0 | 1/10 |
| 1 | 1/5 | 1/10 | 3/10 |
| 2 | 3/10 | 3/10 | 3/5 |
| 3 | 2/5 | 3/5 | 1 |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Lower quantile Q(u) | 2 | inf{x:F(x)≥u}, with 0<u<1 |
| F(Q(u)−) | 3/10 | Left cumulative limit |
| F(Q(u)) | 3/5 | Right-continuous CDF value at the selected atom |
| P(1≤X<3) | 1/2 | Add only masses whose values lie in the interval |
The convention matters at exact boundary levels. Some sources use inf{x:F(x)>u} instead, producing a different generalized inverse at certain plateaus or jump boundaries. Do not combine that definition’s endpoint or continuity statements with the≥ definition used here. Under this lesson’s lower convention, Q is nondecreasing and left-continuous on(0,1). Definitions at u=0 or u=1 are kept separate because they can be infinite or convention-dependent.
A median can also be defined as any m satisfying P(X≤m)≥1/2 and P(X≥m)≥1/2. For a law with equal mass at 0 and 1, every m in[0,1] is a median by those inequalities, while the lower quantile Q(1/2) selects 0. Reporting “the median” without its convention can hide such nonuniqueness.
Quantiles keep the units of X: a time quantile is a time, while u is a dimensionless probability level. They summarize thresholds rather than density heights. A percentile calculation should state the CDF or mass table, the chosen convention and how any interpolation is defined. Interpolating between empirical observations is an additional reporting rule, not automatically the generalized inverse of the discrete empirical CDF.
A uniform probability level can generate the law
Let U be uniform on(0,1), and set Y=Q(U) using the lower quantile. The key relation is Q(u)≤x if and only if u≤F(x). One direction uses F(Q(u))≥u and monotonicity; the other notes that F(x)≥u makes x an eligible point in the infimum. Consequently P(Y≤x)=P(U≤F(x))=F(x), so Y has the desired law.
This inverse-transform construction works for jumps as well as smooth CDFs. For a discrete law, each value receives an interval of uniform probability levels whose length equals its mass. For the four-point example, levels in(0,1/10] map to 0, those in(1/10,3/10] to 1, those in(3/10,3/5] to 2, and those in(3/5,1) to 3. Boundary levels use the stated lower convention.
The reverse expression F(X) is not automatically uniform. In a discrete law it takes only the cumulative levels at the mass points. For an equal-mass variable on{0,1}, F(X) takes 1/2 or 1, not every value in(0,1). A continuous strictly increasing CDF supports the familiar ordinary inverse relationships; the generalized construction is what extends the forward sampling method to arbitrary real laws.
A computer’s pseudo-random output has finite precision and a defined endpoint policy. A finite grid is not an ideal continuous U. Values 0 or 1 can cause problems for inverse formulas with unbounded endpoints. Use a documented generator and transform appropriate to its range, and distinguish numerical sampling from the exact mathematical construction. Silently clipping all outputs or inventing endpoint values can change the resulting law.
Simulation is useful for exploring a validated construction and checking implementation, but a histogram is not a proof of the law. Exact preimage arguments and normalization establish the mathematical target. Numerical diagnostics then assess how a chosen finite-precision implementation approximates it, including tails, atoms and rare outcomes that a short run may barely visit.
A density assigns probability through area
An absolutely continuous law has a nonnegative density f with P(X∈A)=∫_A f(x)dx for Borel sets A and∫ℝf(x)dx=1. Nonnegativity is required almost everywhere; changing values on a length-zero set does not change the law. Its CDF is F(t)=∫_{−∞}ᵗf(x)dx. An ordinary density in this lesson means a density with respect to length on the real line, not a probability mass function.
A density height is not P(X=x). Every singleton has length zero and therefore probability zero under this law. A density may exceed one if its positive region is narrow enough. For a uniform variable on(0,1/5), the density is 5 on that interval and zero outside. Its total area is 5×1/5=1. The probability 1/20≤X≤3/25 is 5×(3/25−1/20)=7/20, while P(X=1/10)=0.
If X measures seconds, f has units of inverse seconds. Integrating over a time interval produces a dimensionless probability. Expressing the same physical time in milliseconds changes the numerical coordinate to T=1000 X. Its density is 0.005 per millisecond on(0,200). The physical interval 50 to 120 milliseconds still has probability 0.005×70=7/20. Density heights change with units while probabilities of the same physical event do not.
Uniform density on the explicitly stated interval. Changing physical units changes numerical density height, not the same physical event probability.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Density height | 5 | Probability per s, not point probability |
| Selected interval probability | 7/20 | Integrated area over the support intersection |
| Any singleton probability | 0 | An absolutely continuous law has no atoms |
| Total density area | 1 | Height times full support width |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Density height | 5 | Probability per s, not point probability |
| Selected interval probability | 7/20 | Integrated area over the support intersection |
| Any singleton probability | 0 | An absolutely continuous law has no atoms |
| Total density area | 1 | Height times full support width |
A density curve should identify both its horizontal units and its vertical density units. Shaded area represents probability; a cursor’s height does not. In numerical work, include the whole integration region, nonnegativity and normalization. A finite plotted window may omit tail mass, and a finite grid may miss a sharp peak. A picture alone cannot certify that a proposed density integrates to one.
Absolute continuity is stronger than having no point masses. Every density law has a continuous CDF, but not every continuous CDF comes from a density. The mixed and singular examples below show why these distinctions matter. Use the exact property required by a formula rather than relying on an ambiguous use of the word continuous.
From a nonconstant density to probabilities and quantiles
Suppose f(x)=cx for 0<x<2 and zero elsewhere. Normalization requires∫₀²cx dx=2 c=1, so c=1/2. Integrating from the left gives F(x)=x²/4 for 0≤x≤2, with F(x)=0 below 0 and F(x)=1 above 2. The support limits belong in the complete definition; extending x²/4 to every real x would not give a CDF.
For 1/2<X≤3/2, the probability is F(3/2)−F(1/2)=[(3/2)²−(1/2)²]/4=1/2. The increasing density places more mass in equal-width intervals farther to the right. Equal interval widths would give equal probabilities only under an appropriate uniform density, not under every continuous law.
For 0<u<1, solve u=x²/4 within 0<x<2 to obtain Q(u)=2√u. Thus Q(9/16)=3/2. Here the CDF is continuous and strictly increasing on its support interior, so ordinary inversion agrees with the lower generalized inverse. The support restriction selects the nonnegative square root; solving the algebraic equation without it would introduce an invalid branch.
The density is c x^k on (0,L) and zero elsewhere. F(x)=0 below 0, (x/L)^(k+1) on [0,L], and 1 above L.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Normalizing coefficient c | 1/2 | Checked against the integral over the full support |
| Total density integral | 1 | Must equal one before any query |
| Selected interval probability | 1/2 | CDF difference after intersecting the support |
| Lower quantile Q(u) | 3/2 | Invert the integrated CDF; symbolic roots retain an explicit approximation |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Normalizing coefficient c | 1/2 | Checked against the integral over the full support |
| Total density integral | 1 | Must equal one before any query |
| Selected interval probability | 1/2 | CDF difference after intersecting the support |
| Lower quantile Q(u) | 3/2 | Invert the integrated CDF; symbolic roots retain an explicit approximation |
Differentiating this CDF recovers f on the interior. In general, the fundamental theorem gives the density almost everywhere when F is absolutely continuous. A derivative at every point is neither required nor guaranteed. Values assigned to f at endpoints do not affect integrals. Do not infer a point probability from a density value chosen at one endpoint.
The workflow is reusable: validate the proposed density, integrate it over its stated support to obtain a CDF, then calculate event probabilities or invert the CDF with a declared convention. Numerical integration or root finding can support more complicated models, but they still need support bounds, normalization evidence and an assessment of approximation error.
A law can have a jump and a spread-out part
Let X equal zero with probability 3/10, and with the remaining probability 7/10 draw uniformly from(0,2). This is a mixture of a point mass and an absolutely continuous law. Its CDF is 0 for x<0;3/10+7 x/20 for 0≤x<2; and 1 for x≥2. The jump at zero has size 3/10, while the rising segment adds the remaining 7/10.
The ordinary density of the spread-out component, including its mixture weight, is 7/20 on(0,2). Its integral is 7/10, not one, because it does not represent the atom. Differentiating the CDF away from zero therefore misses the point mass. A density-only calculation for the full law would lose 30% of the probability.
For example, P(X=0)=3/10 and P(X>1)=(7/10)(1/2)=7/20. The lower quantile is Q(u)=0 for 0<u≤3/10 and Q(u)=(20 u−6)/7 for 3/10<u<1. A whole interval of probability levels maps to the atom; the remainder maps through the continuous part. The generalized inverse handles both without pretending that the jump is a finite-width density bar.
Uniform component on (0,2); the atom is at or below that interval. The density graph describes only the absolutely continuous component. At u equal to a positive atom plateau level, lower Q selects the atom, not the far end of the gap.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Atom probability | 3/10 | Jump at the stated atom |
| Ordinary density height | 7/20 | Only the uniform component contributes to this density |
| Ordinary density integral | 7/10 | The missing mass is the atom |
| Lower quantile Q(u) | 0 | inf{x:F(x)≥u}, including exact plateau levels |
| P(X>1) | 7/20 | Atom and continuous event portions are both included |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Atom probability | 3/10 | Jump at the stated atom |
| Ordinary density height | 7/20 | Only the uniform component contributes to this density |
| Ordinary density integral | 7/10 | The missing mass is the atom |
| Lower quantile Q(u) | 0 | inf{x:F(x)≥u}, including exact plateau levels |
| P(X>1) | 7/20 | Atom and continuous event portions are both included |
One can write the law asμ_X=(3/10)δ₀+(7/10)ν, whereδ₀ is the probability measure placing all mass at zero andν is uniform on(0,2). A Dirac point mass is a measure, not an ordinary finite density spike with respect to length. A diagram may draw a labelled arrow for the atom and a separate density curve, provided their encodings and total masses are explicit.
Such laws can model a separate no-event state together with a positive duration, a zero response plus a spread of nonzero responses, or a reporting rule that maps a range to one code. Whether a particular scientific situation fits that construction requires a measurement model. A recorded zero could mean a genuine atom, rounding, censoring or an instrument threshold; the label alone does not decide which law is appropriate.
Advanced example: a continuous CDF without a density
Take independent fair bits B₁,B₂,… and define X=Σ_{n≥1}2 Bₙ/3ⁿ. Each ternary digit is 0 or 2. The omitted tail after n terms is at mostΣ_{k>n}2/3ᵏ=3^{−n}, so the partial sums converge uniformly. Their measurable limit is a random variable in the middle-thirds Cantor set C. This construction defines a particular probability law; it is not normalization of ordinary length on C.
At construction stage n, the remaining 2ⁿ closed intervals each have length 3^{−n}, for total length(2/3)ⁿ. Since C lies inside every stage, its length is zero. Yet the variable lies in C with probability one. An ordinary integrable density would assign probability∫_C f(x)dx=0 to a length-zero set, contradicting that total mass. Therefore this law has no density with respect to length.
It also has no atoms. A specified n-bit prefix has probability 2^{−n} and confines X to its basic interval of length 3^{−n}. Any fixed point is contained in at most two such prefix intervals, so P(X=x)≤2×2^{−n} for every n. Letting n increase proves P(X=x)=0. The CDF therefore has no jumps and is continuous, despite the absence of a density. This is a singular continuous law.
For a concrete calculation, the prefix B₁=0,B₂=1 locates X in[2/9,1/3] and has probability 1/4. Endpoint ambiguities have zero mass, so P(2/9≤X≤1/3)=1/4. The first-bit event gives F(1/3)=1/2, and the middle gap gives F(2/3)=1/2. Probability accumulates on the Cantor set while the CDF stays flat across its removed open intervals.
The limiting variable is the infinite sum Σ 2B_n/3^n of independent fair bits. All displayed finite partial-sum atoms belong to a discrete approximation. The limiting support has ordinary length zero; a density would assign it zero mass, contradicting mass one.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Proven prefix probability | 1/4 | Independent fair bits, not an approximation to the prefix mass |
| Prefix interval lower endpoint | 2/9 | Partial sum of the specified prefix |
| Prefix interval upper endpoint | 1/3 | Partial sum plus the exact omitted-tail bound |
| Stage total length | 4/9 | Tends to zero as n increases |
| Omitted-series tail bound | 1/9 | Uniform bound 3^(-n) |
| Limiting singleton probability | 0 | Proved by prefix mass bounds, not read from finite stems |
| Limiting F(1/3) | 1/2 | First-bit prefix probability |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Proven prefix probability | 1/4 | Independent fair bits, not an approximation to the prefix mass |
| Prefix interval lower endpoint | 2/9 | Partial sum of the specified prefix |
| Prefix interval upper endpoint | 1/3 | Partial sum plus the exact omitted-tail bound |
| Stage total length | 4/9 | Tends to zero as n increases |
| Omitted-series tail bound | 1/9 | Uniform bound 3^(-n) |
| Limiting singleton probability | 0 | Proved by prefix mass bounds, not read from finite stems |
| Limiting F(1/3) | 1/2 | First-bit prefix probability |
On the complement of C, the CDF is locally constant, so its derivative is zero there. That complement has full length in[0,1], yet the CDF rises from zero to one overall. Integrating its almost-everywhere derivative does not reconstruct it because the CDF is not absolutely continuous. Mere continuity is insufficient for the density representation used in the previous examples.
A finite truncation Xₙ has 2ⁿ atoms and a step CDF. It is an approximation to the limiting variable, with value error at most 3^{−n}; it is not the continuous limiting law itself. A visual should label the truncation level, prefix probabilities and approximation bounds. Increasing the number of plotted points does not justify drawing a density that the limiting law cannot possess.
Support describes neighborhoods, not positive point mass
Here the topological support of a real law means the closed set of values x such that every open neighborhood of x has positive probability. This definition works for atoms, density laws, mixed laws and singular laws. It is not simply the set of points with positive singleton probability. A uniform law on(0,1) has support[0,1], even though every point, including the endpoints, has probability zero.
For a finite discrete law with positive masses at a few values, the support is that finite set. For a discrete law with dense atoms, its closed topological support can include points that are not atoms. The phrase “support of the mass function” is also often used for the countable set where p(x)>0. State which meaning is intended when the distinction matters.
A density’s integration region is another useful object. For the density x/2 on(0,2), we integrate over that interval and take the closed support[0,2]. Assigning a different density value at one endpoint changes neither the law nor its support. More generally, the literal set where one chosen density version is positive can be altered on null sets; support is a property of the law, not of arbitrary pointwise edits to a density.
The range X(Ω) of a recording also need not equal its law’s support. A continuous uniform coordinate onΩ=(0,1) has range(0,1) but support[0,1]. Changing a recording on one null outcome can add an exceptional range value without changing its law. A possible label in a function definition and a neighborhood carrying probability are different concepts.
Support matters in calculations. An inverse branch outside the original support contributes no probability. A joint density on a triangle cannot be integrated as if it filled a surrounding square. A probability model with only positive values cannot use an unmodified formula that assigns mass to negative values. Keep the event region, the law’s support and the domain of each formula visible as transformations become more complicated.
Combine all discrete inputs that reach one output
For Y=g(X) and a discrete X, the transformed mass is p_Y(y)=Σ_{x:g(x)=y}p_X(x). The formula adds all valid preimages of y. It follows directly from the disjoint event decomposition{g(X)=y}=⋃_{x:g(x)=y}{X=x}. No derivative or Jacobian is involved in a discrete transformation.
Let X be uniform on{0,1,2,3} and Y=(X−1)². The four inputs produce 1,0,1,4. Therefore p_Y(0)=1/4, p_Y(1)=1/2 and p_Y(4)=1/4. The value 1 receives two original masses. Its larger probability is a consequence of the recording map, not an instruction to make the three output labels equally likely.
The transformed event Y≤1 has preimage X∈{0,1,2}, so its probability is 3/4. This checks the mass sum 1/4+1/2. The same preimage method works for thresholds, rounded measurements, categories and many-to-one summaries. First list or characterize all inputs satisfying the output condition.
The original discrete law is validated. No derivative or Jacobian belongs in this discrete mass calculation.
| Y value | X preimages | Probability |
|---|---|---|
| 0 | 1 | 1/4 |
| 1 | 0, 2 | 1/2 |
| 4 | 3 | 1/4 |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| P(Y≤cutoff) | 3/4 | Sum all output masses at or below the cutoff |
| Total transformed mass | 1 | No source mass is dropped or duplicated |
An injective transformation merely relabels the discrete masses, while a noninjective transformation combines them. A constant transformation sends all mass to one atom. A transformation cannot create new total probability: the output preimages partition the input value set, so their masses still sum to one.
Keep the recording rule distinct from a probability reassignment. If values are rounded to bins, the bin probabilities come from the original law and the exact bin boundaries. Choosing a representative label for a bin does not make all bins equally likely. Ambiguous boundary rules can matter at atoms, so state which bin includes an endpoint.
Transform the event before transforming the density
For any measurable g, begin with F_Y(y)=P(g(X)≤y). Intersect that preimage with the original support. This CDF method remains meaningful even when g is decreasing, not one-to-one or flat on part of its domain. A density change-of-variable formula is a useful consequence under additional conditions, rather than a universal first step.
If g is continuously differentiable and one-to-one on an interval carrying the law, with nonzero derivative there, then f_Y(y)=f_X(g⁻¹(y))|(g⁻¹)′(y)| on the image. The inverse argument identifies the relevant input; the absolute derivative adjusts interval lengths and keeps the density nonnegative. Formula values at isolated boundaries are immaterial to probabilities, but the image support must be correct.
Let X have density 2 x on(0,1) and let Y=7−3 X. The map is decreasing and sends the interval to(4,7). For 4<y<7, Y≤y means X≥(7−y)/3. Thus F_Y(y)=1−((7−y)/3)² and f_Y(y)=2(7−y)/9. Extend the CDF by zero below 4 and one at or above 7. The density integrates to one over its image.
The source law has density 2x on (0,1). The display distinguishes a constant transform from a one-to-one transform.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Transformed support lower bound | 4 | Closed topological support |
| Transformed support upper bound | 7 | Closed topological support |
| F_Y(query) | 3/4 | CDF from the transformed preimage |
| Density at query | 1/3 | Natural version set to zero outside the strict support interior |
| Point mass at constant value | 0 | Nonconstant affine transforms of this law have no atoms |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Transformed support lower bound | 4 | Closed topological support |
| Transformed support upper bound | 7 | Closed topological support |
| F_Y(query) | 3/4 | CDF from the transformed preimage |
| Density at query | 1/3 | Natural version set to zero outside the strict support interior |
| Point mass at constant value | 0 | Nonconstant affine transforms of this law have no atoms |
Using f_X(y)/3 would evaluate the original density at the wrong coordinate. Omitting the absolute derivative could produce a negative density. Ignoring the reversed inequality would calculate the wrong tail. These errors are easier to detect when the derivation starts with the event rather than with a memorized formula.
For a physical unit change Y=aX+b, with a≠0, the density scales by 1/|a| and the support is mapped as well. More general nonlinear transforms can stretch some regions more than others. A transformation that is constant on an interval carrying positive probability creates an atom, so an absolutely continuous input need not produce an absolutely continuous output.
Count every inverse branch that is actually allowed
Suppose X has a density and, apart from a set of input probability zero, its support is covered by disjoint intervals on which g is continuously differentiable, one-to-one and has nonzero derivative. A transformed density sums the contributions from all valid inverse branches: f_Y(y)=Σᵢf_X(xᵢ)/|g′(xᵢ)|, where g(xᵢ)=y and each xᵢ lies in a permitted branch. The formula holds almost everywhere on the output, under these piecewise regularity conditions. The CDF remains the check for support, boundaries and any components not covered by those assumptions.
Let X be uniform on(−2,1) and Y=X². For 0≤y≤1, the preimage of Y≤y is[−√y,√y] inside the original interval, of length 2√y. Hence F_Y(y)=2√y/3. For 1<y<4, the positive root lies beyond the original upper bound, so the retained interval is[−√y,1), of length 1+√y. There F_Y(y)=(1+√y)/3.
Differentiation gives f_Y(y)=1/(3√y) on(0,1) and 1/(6√y) on(1,4), zero outside. The first interval has probability 2/3 and the second 1/3. Both roots contribute below 1, while only the negative root contributes above 1. Applying a two-root formula across the whole image would overcount the second region.
The density grows without bound as y decreases to zero, but it is integrable. There is no atom at zero: F_Y(0)=0 and P(X=0)=0. The branch formula divides by a zero derivative at the critical input x=0, so it should not be evaluated there as a finite number. A density value at that single output can be assigned by a version choice; the divergent nearby behavior and integrated probabilities are the substantive facts.
X is absolutely continuous and uniform on a support crossing zero. At y=0 the density is unbounded near the critical point; this is not an atom or a singular law. Displayed density curves are explicitly clipped above 2; no probability is computed by their clipped area.
| Candidate preimage | In strict source support? | Rule |
|---|---|---|
| −√(1/4) | yes | Each valid branch contributes 1/(2·width·√y) |
| +√(1/4) | yes | Each valid branch contributes 1/(2·width·√y) |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| F_Y(query) | 1/3 | Intersect both inverse branches with the original support |
| Density at query | 2/3 | Sum contributions from all valid noncritical inverse branches |
| Valid noncritical root count | 2 | The critical zero root is not used in a Jacobian denominator |
| P(Y=0) | 0 | Source singleton probability is zero |
| Mass before branch loss | 2/3 | The first density piece carries this probability |
| Mass after branch loss | 1/3 | The remaining one-root piece |
A graph must show this limitation honestly. It can clip the vertical display or begin the curve at a positive plotting threshold if that choice is labelled, while reporting exact interval areas and zero atom mass. Drawing an arbitrary finite spike and treating its height as a probability would confuse a singular density shape with a point mass. The CDF makes the distinction clear.
A joint law records how numerical variables move together
The vector(X,Y) induces a probability law on the plane:μ_{X,Y}(A)=P((X,Y)∈A) for Borel regions A. Its joint CDF is F_{X,Y}(a,b)=P(X≤a,Y≤b). A discrete joint mass function assigns probabilities to pairs; a joint density, when it exists, assigns probabilities by integrating over two-dimensional regions. Marginal laws alone do not supply this joint information.
A rectangle event(a,b]×(c,d] has probability F_{X,Y}(b,d)−F_{X,Y}(a,d)−F_{X,Y}(b,c)+F_{X,Y}(a,c). The four-term subtraction removes the unwanted lower strips and restores their overlap. Other endpoint choices need the corresponding left limits when atoms are present. Any candidate joint CDF must give nonnegative rectangle probabilities; being nondecreasing in each coordinate separately is not enough.
For a discrete example, let joint weights divided by 12 be row X=0:(1,2,1) and row X=1:(2,1,5), with columns Y=0,1,2. The six masses are nonnegative and sum to one. The event X=0 or Y=2 has probability(row total 4/12)+(column total 6/12)−(shared cell 1/12)=3/4. The matching intersection cell matters.
The declared table is a normalized finite joint law. Zero-mass rows need no conditional normalization to form marginals. Full cellwise independence check: fails.
| X | Y=0 | Y=1 | Y=2 | pX |
|---|---|---|---|---|
| 0 | 1/12 | 1/6 | 1/12 | 1/3 |
| 1 | 1/6 | 1/12 | 5/12 | 2/3 |
| pY | 1/4 | 1/4 | 1/2 | 1 |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| P(X=1,Y=2) | 5/12 | The matching joint table cell |
| pX(1)pY(2) | 1/3 | A necessary independence comparison |
| P(X=0 or Y=2) | 3/4 | Row mass plus column mass minus their intersection |
| pX(0) | 1/3 | Row marginal |
| pX(1) | 2/3 | Row marginal |
| pY(0) | 1/4 | Column marginal |
| pY(1) | 1/4 | Column marginal |
| pY(2) | 1/2 | Column marginal |
For a density example, take f(x,y)=2 on 0<x<y<1 and zero outside. The triangle has area 1/2, so the total probability is one. The event X+Y≤1 intersects that support in 0<x<1/2 and x<y≤1−x. Its probability is∫₀^{1/2}∫ₓ^{1−x}2 dy dx=1/2. Integrating over a convenient square instead would assign mass to unsupported pairs.
Density is zero outside 0<x<y<1; marginals are 2(1−x) and 2y. For a joint density, probabilities integrate over the support intersection. Marginal densities alone do not establish a joint density.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Selected event probability | 1/2 | Density times the exact supported polygon area |
| Supported event area | 1/4 | Exact rational polygon clipping |
| Joint density coefficient | 2 | Normalized on the actual joint support |
| Joint total probability | 1 | Full normalized joint law |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Selected event probability | 1/2 | Density times the exact supported polygon area |
| Supported event area | 1/4 | Exact rational polygon clipping |
| Joint density coefficient | 2 | Normalized on the actual joint support |
| Joint total probability | 1 | Full normalized joint law |
The event X<1/4,Y>1/2 lies entirely inside the triangular support, so its probability is 2×(1/4)×(1/2)=1/4. A region plot should distinguish the joint support from the event region and show their actual intersection. These geometric checks are especially useful before changing integration order or computing a marginal density.
Marginalize carefully, then test the joint relation
For a joint mass function, p_X(x)=Σᵧp_{X,Y}(x,y); for a joint density, f_X(x)=∫f_{X,Y}(x,y)dy, with the integration region determined by support. The other marginal is obtained similarly. A joint CDF gives F_X(a)=lim_{b→∞}F_{X,Y}(a,b). These operations collect the mass of every joint outcome sharing the recorded X value.
The two-by-three table has marginals p_X=(1/3,2/3) and p_Y=(1/4,1/4,1/2). Its joint at(1,2) is 5/12, whereas the marginal product is(2/3)(1/2)=1/3. Thus X and Y are not independent. Checking all matching products is possible for a finite table; one unequal cell is enough to disprove independence.
In general, independence means P(X∈A,Y∈B)=P(X∈A)P(Y∈B) for every pair of Borel sets A,B. Equivalently, the joint law is the product law, or the joint CDF factors for every pair of thresholds. When a joint density exists, independence is equivalent to f_{X,Y}(x,y)=f_X(x)f_Y(y) almost everywhere on the whole plane, including where the joint density is zero.
For the triangular density, f_X(x)=2(1−x) and f_Y(y)=2 y on their respective(0,1) intervals. The product would put positive density on much of the square outside the triangle, so it cannot be the joint law. The event X<1/4,Y>1/2 has joint probability 1/4 but marginal product(7/16)(3/4)=21/64, another direct dependence check.
Even two marginal densities do not guarantee a two-dimensional joint density. For(U,U), with U uniform, all joint mass lies on the area-zero diagonal. Its joint CDF inside the unit square is min(x,y), and its marginals are both uniform. A two-dimensional density would assign the diagonal zero probability, so none can represent this joint law. Conditional distributions can still be meaningful; the density-ratio shortcut is simply unavailable.
Where a discrete conditioning value has positive mass, a conditional law comes from its joint row or column divided by that marginal. In a suitable joint-density model, normalized slices supply conditional-density versions with the qualifications established in lessons 151–152. Keep unconditional laws, joint laws and conditional versions distinct. The next lesson’s moments summarize these laws, but summaries such as means or covariances will not generally determine them.
Numerical recordings connect probability to measurement, coding, simulation and scientific models. Coarsening changes mass; unit changes rescale density; thresholds can create atoms; joint laws retain dependence that marginals discard. The common method is to define the recording, translate its events through preimages, and carry the original probability law through that translation with its support and assumptions intact.
Change a recording rule, law or queried event. Figures and exact quantities update from the same calculation. Lower quantiles use inf{x:F(x)≥u} for 0<u<1.
1. Move mass through a recording rule
W1: record three values from six faces. Computed from the stated law.
The declared original law is validated; the recording does not change it. The finite event collection is the full power set.
| Recorded value | Source outcomes | Induced probability |
|---|---|---|
| -2 | 1, 2 | 1/3 |
| 0 | 3, 4, 5 | 1/2 |
| 5 | 6 | 1/6 |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Target recorded-event mass | 2/3 | Probability of the complete preimage |
| Total induced mass | 1 | The pushforward preserves normalization |
2. Read a mass function, CDF and lower quantile
W2: lower Q(3/5). Computed from the stated law.
Lower quantile convention: Q(u)=inf{x:F(x)≥u}; 0<u<1. Open circles show left limits; filled circles show the CDF values.
| x | p(x) | F(x−) | F(x) |
|---|---|---|---|
| 0 | 1/10 | 0 | 1/10 |
| 1 | 1/5 | 1/10 | 3/10 |
| 2 | 3/10 | 3/10 | 3/5 |
| 3 | 2/5 | 3/5 | 1 |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Lower quantile Q(u) | 2 | inf{x:F(x)≥u}, with 0<u<1 |
| F(Q(u)−) | 3/10 | Left cumulative limit |
| F(Q(u)) | 3/5 | Right-continuous CDF value at the selected atom |
| P(1≤X<3) | 1/2 | Add only masses whose values lie in the interval |
3. Keep CDF interval endpoints exact
W3: closed left, open right. Computed from the stated law.
The CDF is right-continuous. An open interval with equal endpoints is empty; a closed singleton may carry an atom. The finite CDF window has labelled continuation arrows for outside query bounds; probabilities use the actual unmodified bounds.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Interval probability | 1/4 | Endpoint membership is evaluated before summing |
| Left query endpoint a | -1 | Actual input; continuation arrows only bound its drawing |
| Right query endpoint b | 2 | Actual input; continuation arrows only bound its drawing |
| F(a−) | 0 | Strictly below the left endpoint |
| F(a) | 1/4 | At or below the left endpoint |
| F(b−) | 1/4 | Strictly below the right endpoint |
| F(b) | 3/4 | At or below the right endpoint |
| P(X=b) | 1/2 | Jump mass at b |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Interval probability | 1/4 | Endpoint membership is evaluated before summing |
| Left query endpoint a | -1 | Actual input; continuation arrows only bound its drawing |
| Right query endpoint b | 2 | Actual input; continuation arrows only bound its drawing |
| F(a−) | 0 | Strictly below the left endpoint |
| F(a) | 1/4 | At or below the left endpoint |
| F(b−) | 1/4 | Strictly below the right endpoint |
| F(b) | 3/4 | At or below the right endpoint |
| P(X=b) | 1/2 | Jump mass at b |
4. Integrate density with its units
W4: density five per unit. Computed from the stated law.
Uniform density on the explicitly stated interval. Changing physical units changes numerical density height, not the same physical event probability.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Density height | 5 | Probability per s, not point probability |
| Selected interval probability | 7/20 | Integrated area over the support intersection |
| Any singleton probability | 0 | An absolutely continuous law has no atoms |
| Total density area | 1 | Height times full support width |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Density height | 5 | Probability per s, not point probability |
| Selected interval probability | 7/20 | Integrated area over the support intersection |
| Any singleton probability | 0 | An absolutely continuous law has no atoms |
| Total density area | 1 | Height times full support width |
5. Integrate and invert a smooth CDF
W5: f(x)=x/2 on (0,2). Computed from the stated law.
The density is c x^k on (0,L) and zero elsewhere. F(x)=0 below 0, (x/L)^(k+1) on [0,L], and 1 above L.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Normalizing coefficient c | 1/2 | Checked against the integral over the full support |
| Total density integral | 1 | Must equal one before any query |
| Selected interval probability | 1/2 | CDF difference after intersecting the support |
| Lower quantile Q(u) | 3/2 | Invert the integrated CDF; symbolic roots retain an explicit approximation |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Normalizing coefficient c | 1/2 | Checked against the integral over the full support |
| Total density integral | 1 | Must equal one before any query |
| Selected interval probability | 1/2 | CDF difference after intersecting the support |
| Lower quantile Q(u) | 3/2 | Invert the integrated CDF; symbolic roots retain an explicit approximation |
6. Preserve an atom and continuous spread
W6: atom at zero and uniform spread. Computed from the stated law.
Uniform component on (0,2); the atom is at or below that interval. The density graph describes only the absolutely continuous component. At u equal to a positive atom plateau level, lower Q selects the atom, not the far end of the gap.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Atom probability | 3/10 | Jump at the stated atom |
| Ordinary density height | 7/20 | Only the uniform component contributes to this density |
| Ordinary density integral | 7/10 | The missing mass is the atom |
| Lower quantile Q(u) | 0 | inf{x:F(x)≥u}, including exact plateau levels |
| P(X>1) | 7/20 | Atom and continuous event portions are both included |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Atom probability | 3/10 | Jump at the stated atom |
| Ordinary density height | 7/20 | Only the uniform component contributes to this density |
| Ordinary density integral | 7/10 | The missing mass is the atom |
| Lower quantile Q(u) | 0 | inf{x:F(x)≥u}, including exact plateau levels |
| P(X>1) | 7/20 | Atom and continuous event portions are both included |
7. Separate finite approximations from a singular limit
W7: prefix 01 and stage two. Computed from the stated law.
The limiting variable is the infinite sum Σ 2B_n/3^n of independent fair bits. All displayed finite partial-sum atoms belong to a discrete approximation. The limiting support has ordinary length zero; a density would assign it zero mass, contradicting mass one.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Proven prefix probability | 1/4 | Independent fair bits, not an approximation to the prefix mass |
| Prefix interval lower endpoint | 2/9 | Partial sum of the specified prefix |
| Prefix interval upper endpoint | 1/3 | Partial sum plus the exact omitted-tail bound |
| Stage total length | 4/9 | Tends to zero as n increases |
| Omitted-series tail bound | 1/9 | Uniform bound 3^(-n) |
| Limiting singleton probability | 0 | Proved by prefix mass bounds, not read from finite stems |
| Limiting F(1/3) | 1/2 | First-bit prefix probability |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Proven prefix probability | 1/4 | Independent fair bits, not an approximation to the prefix mass |
| Prefix interval lower endpoint | 2/9 | Partial sum of the specified prefix |
| Prefix interval upper endpoint | 1/3 | Partial sum plus the exact omitted-tail bound |
| Stage total length | 4/9 | Tends to zero as n increases |
| Omitted-series tail bound | 1/9 | Uniform bound 3^(-n) |
| Limiting singleton probability | 0 | Proved by prefix mass bounds, not read from finite stems |
| Limiting F(1/3) | 1/2 | First-bit prefix probability |
8. Combine all discrete preimages
W8: Y=(X−1)². Computed from the stated law.
The original discrete law is validated. No derivative or Jacobian belongs in this discrete mass calculation.
| Y value | X preimages | Probability |
|---|---|---|
| 0 | 1 | 1/4 |
| 1 | 0, 2 | 1/2 |
| 4 | 3 | 1/4 |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| P(Y≤cutoff) | 3/4 | Sum all output masses at or below the cutoff |
| Total transformed mass | 1 | No source mass is dropped or duplicated |
9. Reverse a decreasing transformation
W9: decreasing Y=7−3X. Computed from the stated law.
The source law has density 2x on (0,1). The display distinguishes a constant transform from a one-to-one transform.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Transformed support lower bound | 4 | Closed topological support |
| Transformed support upper bound | 7 | Closed topological support |
| F_Y(query) | 3/4 | CDF from the transformed preimage |
| Density at query | 1/3 | Natural version set to zero outside the strict support interior |
| Point mass at constant value | 0 | Nonconstant affine transforms of this law have no atoms |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Transformed support lower bound | 4 | Closed topological support |
| Transformed support upper bound | 7 | Closed topological support |
| F_Y(query) | 3/4 | CDF from the transformed preimage |
| Density at query | 1/3 | Natural version set to zero outside the strict support interior |
| Point mass at constant value | 0 | Nonconstant affine transforms of this law have no atoms |
10. Count valid inverse branches
W10: both square roots are valid. Computed from the stated law.
X is absolutely continuous and uniform on a support crossing zero. At y=0 the density is unbounded near the critical point; this is not an atom or a singular law. Displayed density curves are explicitly clipped above 2; no probability is computed by their clipped area.
| Candidate preimage | In strict source support? | Rule |
|---|---|---|
| −√(1/4) | yes | Each valid branch contributes 1/(2·width·√y) |
| +√(1/4) | yes | Each valid branch contributes 1/(2·width·√y) |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| F_Y(query) | 1/3 | Intersect both inverse branches with the original support |
| Density at query | 2/3 | Sum contributions from all valid noncritical inverse branches |
| Valid noncritical root count | 2 | The critical zero root is not used in a Jacobian denominator |
| P(Y=0) | 0 | Source singleton probability is zero |
| Mass before branch loss | 2/3 | The first density piece carries this probability |
| Mass after branch loss | 1/3 | The remaining one-root piece |
11. Keep joint and marginal laws distinct
W11: a dependent joint table. Computed from the stated law.
The declared table is a normalized finite joint law. Zero-mass rows need no conditional normalization to form marginals. Full cellwise independence check: fails.
| X | Y=0 | Y=1 | Y=2 | pX |
|---|---|---|---|---|
| 0 | 1/12 | 1/6 | 1/12 | 1/3 |
| 1 | 1/6 | 1/12 | 5/12 | 2/3 |
| pY | 1/4 | 1/4 | 1/2 | 1 |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| P(X=1,Y=2) | 5/12 | The matching joint table cell |
| pX(1)pY(2) | 1/3 | A necessary independence comparison |
| P(X=0 or Y=2) | 3/4 | Row mass plus column mass minus their intersection |
| pX(0) | 1/3 | Row marginal |
| pX(1) | 2/3 | Row marginal |
| pY(0) | 1/4 | Column marginal |
| pY(1) | 1/4 | Column marginal |
| pY(2) | 1/2 | Column marginal |
12. Integrate the actual joint support
W12: triangular support, X+Y≤1. Computed from the stated law.
Density is zero outside 0<x<y<1; marginals are 2(1−x) and 2y. For a joint density, probabilities integrate over the support intersection. Marginal densities alone do not establish a joint density.
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Selected event probability | 1/2 | Density times the exact supported polygon area |
| Supported event area | 1/4 | Exact rational polygon clipping |
| Joint density coefficient | 2 | Normalized on the actual joint support |
| Joint total probability | 1 | Full normalized joint law |
| Quantity | Exact value / status | Meaning |
|---|---|---|
| Selected event probability | 1/2 | Density times the exact supported polygon area |
| Supported event area | 1/4 | Exact rational polygon clipping |
| Joint density coefficient | 2 | Normalized on the actual joint support |
| Joint total probability | 1 | Full normalized joint law |
Worked examples
Combine detailed outcomes into recorded values
Roll a fair die and record X=−2 on faces 1,2; X=0 on 3,4,5; X=5 on 6. Find its law and the probability−1<X≤6.
- Each detailed face has probability 1/6. The preimages of−2,0,5 have two,three,one faces respectively.
- The induced masses are p_X(−2)=1/3, p_X(0)=1/2 and p_X(5)=1/6. They sum to one.
- The value event(−1,6] retains 0 and 5, with mass 1/2+1/6=2/3. Its outcome preimage is{3,4,5,6}, also of probability 2/3.
- The recording produces unequal value masses from equally weighted faces. Assigning 1/3 to each output label would define another law.
The law has masses 1/3,1/2,1/6 at−2,0,5; P(−1<X≤6)=2/3.
Normalize a mass function and use its CDF
Let p(k)=c(k+1) for k=0,1,2,3. Find c, the CDF levels, lower Q(3/5), lower Q(61/100), and P(1≤X<3).
- The weights sum to 1+2+3+4=10, so c=1/10.
- The cumulative levels at 0,1,2,3 are 1/10,3/10,3/5,1. At each jump the CDF includes the mass at that value.
- The lower quantile is the first value with F≥u. Thus Q(3/5)=2 but Q(61/100)=3; the CDF need not attain 61/100 exactly.
- The interval 1≤X<3 includes values 1 and 2, with mass 2/10+3/10=1/2.
c=1/10; Q(3/5)=2; Q(61/100)=3; the interval probability is 1/2.
Change an endpoint and change the included atom
Masses at−1,2,4 are 1/4,1/2,1/4. Find F(2−), F(2), P(−1≤X<2), P(−1<X≤2) and P(X=2).
- Strictly below 2, only the mass at−1 has accumulated, giving F(2−)=1/4. Including 2 gives F(2)=3/4.
- The interval−1≤X<2 includes only−1, so its probability is 1/4. The interval−1<X≤2 includes only 2, so its probability is 1/2.
- The jump F(2)−F(2−)=1/2 is the atom at 2.
- The difference between endpoint conventions is probability mass, not geometric length. It disappears at an endpoint only when that point is null.
The left limit is 1/4, the CDF value 3/4, the two intervals have probabilities 1/4 and 1/2, and the atom at 2 is 1/2.
A height of five can integrate to a probability below one
Let X be uniform on(0,1/5), measured in seconds. Find its density, P(1/20≤X≤3/25), and P(X=1/10). Express the interval calculation in milliseconds.
- The interval width is 1/5 second, so the density is 5 per second on its interior and zero elsewhere. Its total integral is one.
- The requested width is 3/25−1/20=7/100 second. Multiplying by 5 gives 7/20.
- An exact time has probability zero under this law, so P(X=1/10)=0. Its density height is not that probability.
- In milliseconds the support is(0,200), density 0.005 per millisecond and requested interval 50 to 120. The area 0.005×70 remains 7/20.
Density 5 per second; interval probability 7/20; point probability 0. A unit change preserves the interval probability.
Integrate a density before inverting it
For f(x)=cx on 0<x<2, zero outside, normalize the law and find its CDF, P(1/2<X≤3/2) and lower Q(9/16).
- Normalization gives∫₀²cx dx=2 c=1, hence c=1/2.
- The CDF is 0 below 0,x²/4 on[0,2], and 1 above 2.
- The interval probability is[(3/2)²−(1/2)²]/4=1/2.
- On the support, solving u=x²/4 gives Q(u)=2√u. Therefore Q(9/16)=3/2; the negative square root is outside the support.
c=1/2, interval probability 1/2 and Q(9/16)=3/2, with the stated piecewise CDF.
Retain both the atom and the continuous component
A law has mass 3/10 at zero and distributes 7/10 uniformly on(0,2). Find its CDF, P(X=0), P(X>1), and lower Q(3/10) and Q(13/20).
- The spread-out density is(7/10)(1/2)=7/20 on(0,2). Its total mass is 7/10; the separate atom supplies 3/10.
- The CDF is 0 for x<0,3/10+7 x/20 for 0≤x<2, and 1 for x≥2.
- P(X=0)=3/10 and P(X>1)=(7/20)(1)=7/20.
- The lower quantile at 3/10 is 0, the jump location. Above that level solve u=3/10+7 x/20. At u=13/20 the result is x=1. Integrating only the ordinary density would omit the atom.
The atom is 3/10; the upper-tail probability is 7/20; Q(3/10)=0 and Q(13/20)=1.
Calculate a prefix mass without inventing a density
Optional: X=Σ_{n≥1}2 Bₙ/3ⁿ for independent fair bits. Find the mass of[2/9,1/3], F(1/3), and explain why this law is atomless yet has no ordinary density.
- The prefix B₁=0,B₂=1 gives the initial sum 2/9, with remaining tail at most 1/9, locating X in[2/9,1/3]. Its prefix probability is 1/4; boundary points are null.
- The first-bit-zero half lies in[0,1/3], so F(1/3)=1/2.
- Every fixed point has probability at most 2×2^{−n} for every prefix length n, hence probability zero. Thus the CDF has no jumps.
- The Cantor set has length zero but carries probability one, which contradicts an ordinary density representation. Finite truncations have atoms; they approximate rather than duplicate the limiting law.
The interval mass is 1/4 and F(1/3)=1/2. The limiting law is singular continuous.
Count both inputs that reach the same output
Let X be uniform on{0,1,2,3} and Y=(X−1)². Find the law of Y and P(Y≤1).
- Inputs 0,1,2,3 produce outputs 1,0,1,4 respectively, each detailed input with mass 1/4.
- The preimage of 0 contains one input, that of 1 contains two, and that of 4 contains one. Thus the masses are 1/4,1/2,1/4.
- The event Y≤1 has preimage{0,1,2}, with probability 3/4.
- No derivative is needed in a discrete transformation. The repeated output label receives the sum of its input masses.
p_Y(0)=1/4, p_Y(1)=1/2, p_Y(4)=1/4 and P(Y≤1)=3/4.
Reverse the inequality and transform the density
X has density 2 x on(0,1), and Y=7−3 X. Find the support, CDF and density of Y.
- The image of(0,1) is(4,7), with closed topological support[4,7].
- For 4<y<7, the event Y≤y is X≥(7−y)/3. The X CDF is x², so F_Y(y)=1−((7−y)/3)².
- Differentiate on that interval to obtain f_Y(y)=2(7−y)/9. It is nonnegative and integrates to one.
- Extend the CDF by 0 at or below 4 and 1 at or above 7, with density zero outside the interior. The inverse argument and absolute Jacobian both matter.
Support[4,7]; interior CDF 1−((7−y)/3)² and density 2(7−y)/9.
Use two roots only while both are in support
X is uniform on(−2,1), and Y=X². Find the piecewise CDF and density, and decide whether Y has an atom at zero.
- For 0≤y≤1, the allowed preimage interval has length 2√y, so F_Y(y)=2√y/3.
- For 1<y<4, the positive root is outside the original support and the allowed length is 1+√y, so F_Y(y)=(1+√y)/3. The CDF is 0 below 0 and 1 at or above 4.
- The densities are 1/(3√y) on(0,1) and 1/(6√y) on(1,4), carrying masses 2/3 and 1/3.
- There is no atom at zero because P(X=0)=0. The divergent density limit near zero is integrable; the critical-point branch formula itself is not evaluated as a finite value at y=0.
The two interior CDF pieces are 2√y/3 and(1+√y)/3, with the corresponding densities above and zero atom mass at 0.
Keep the joint table when computing a marginal or union
Joint weights divided by 12 are X=0:(1,2,1), X=1:(2,1,5), for columns Y=0,1,2. Find both marginals, test independence and calculate P(X=0 or Y=2).
- Row sums give p_X(0)=4/12=1/3 and p_X(1)=8/12=2/3. Column sums give p_Y=(3/12,3/12,6/12)=(1/4,1/4,1/2).
- At(1,2), the joint is 5/12 but the marginal product is(2/3)(1/2)=1/3. This one mismatch disproves independence.
- For the union, add the row and column probabilities and subtract their shared cell:(4+6−1)/12=3/4.
- Marginal sums preserve the contribution of every joint pair. Reconstructing a product table from these marginals would replace the given dependence model with another law.
Marginals are(1/3,2/3) and(1/4,1/4,1/2); independence fails; the union probability is 3/4.
Intersect an event with its joint support
The joint density is 2 on 0<x<y<1, zero elsewhere. Find its marginals, P(X+Y≤1), and P(X<1/4,Y>1/2).
- The triangular area 1/2 normalizes the constant density 2. For a fixed x in(0,1), integrate y from x to 1 to get f_X(x)=2(1−x). For fixed y, integrate x from 0 to y to get f_Y(y)=2 y.
- For X+Y≤1 inside the triangle,0<x<1/2 and x<y≤1−x. The integral∫₀^{1/2}2(1−2 x)dx is 1/2.
- The event X<1/4,Y>1/2 is a rectangle entirely inside the triangle. Its probability is 2×(1/4)×(1/2)=1/4.
- The marginal product for that rectangle is(7/16)(3/4)=21/64, different from 1/4. The triangular law is dependent; its support is part of that joint structure.
Marginals 2(1−x) and 2 y on(0,1); the two requested probabilities are 1/2 and 1/4.
Try it yourself
LetΩ={a,b,c,d} andℱ={∅,Ω,{a,b},{c,d}}. Set X(a)=X(c)=0 and X(b)=X(d)=1. Is X a random variable on this event space?
Show the answer and reasoning
No; this recording is not measurable on the stated event space.
The preimage{X≤1/2}={a,c} is not inℱ. A numerical map is insufficient unless its value events have probabilities in the model. Changing the event space would require an explicit probability extension.
Outcomes a,b,c have probabilities 1/5,3/10,1/2. Record X(a)=X(c)=7 and X(b)=−1. Find the law.
Show the answer and reasoning
p_X(7)=7/10 and p_X(−1)=3/10.
The two outcomes mapped to 7 have combined mass 1/5+1/2=7/10. Preimages, rather than the number of output labels, determine the induced weights.
Let p(k)=c 2^{−k} for k=1,2,… . Find c and P(X≥3).
Show the answer and reasoning
c=1 and P(X≥3)=1/4.
The geometric seriesΣ_{k≥1}2^{−k}=1 gives normalization. The tail beginning at 3 sums to 1/4. A countably infinite law needs a convergent nonnegative mass sum.
Masses at−1,0,2 are 1/5,3/10,1/2. Give the complete CDF.
Show the answer and reasoning
F is 0 below−1;1/5 on[−1,0);1/2 on[0,2);1 on[2,∞).
Accumulate each mass at its included≤ endpoint. The CDF is right-continuous at each jump and has limits 0 and 1.
If F(a)=7/10 and F(a−)=2/5, find P(X=a).
Show the answer and reasoning
The atom has probability 3/10.
Subtract the left limit from the included CDF value:7/10−4/10=3/10. The jump is the exact point mass.
Suppose F(5)=9/10, F(2)=2/5 and F(2−)=1/4. Compare P(2<X≤5) and P(2≤X≤5).
Show the answer and reasoning
The probabilities are 1/2 and 13/20, respectively.
Subtract F(2) for the open-left interval and F(2−) for the closed-left interval. Their difference 3/20 is the atom at 2.
A proposed function is 0 for x<0,1/5 at x=0 and 1 for x>0. Is it a CDF?
Show the answer and reasoning
No. It fails right-continuity at zero.
Its right-hand limit is 1, but its stated value is 1/5. Monotonicity and the correct extreme limits do not compensate for that incompatible boundary value.
X is uniform on(4,17/4). Find its density height and P(41/10<X<21/5).
Show the answer and reasoning
The density height is 4 and the interval probability is 2/5.
The support width is 1/4. The event lies inside it and has width 21/5−41/10=1/10; area 4×1/10=2/5. A density height above one is allowed.
For density 3 x² on(0,1), find its CDF and lower Q(1/8).
Show the answer and reasoning
The CDF is x³ on[0,1], extended by 0 and 1 outside; Q(1/8)=1/2.
Integrating the density gives x³ and total mass one. Invert the increasing CDF on its support to obtain the cube root, not a transformation of the density height.
A law puts 1/4 at−1 and 3/4 uniformly on(0,1). Find the lower quantiles Q(1/4) and Q(1/2).
Show the answer and reasoning
Q(1/4)=−1 and Q(1/2)=1/3.
The CDF first reaches 1/4 at the atom−1, then stays flat until 0. Above the plateau, solve 1/4+(3/4)x=1/2. The≥ lower-quantile convention matters at the exact plateau level.
A law puts probability one on a set C of ordinary length zero. Can it have an ordinary density? What if it also has no atoms?
Show the answer and reasoning
It cannot have a density with respect to length. If atomless, it is singular continuous.
Every integrable density has integral zero over C, contradicting probability one. No atoms means no CDF jumps, so the CDF is continuous without being absolutely continuous.
X is uniform on{−2,−1,1,2}. Find the law of X².
Show the answer and reasoning
The squared values 1 and 4 each have probability 1/2.
Each output has two equally weighted preimages. Squaring the values does not square their probabilities.
X has density 2 x on(0,1); define Y=√X. Find the density of Y.
Show the answer and reasoning
The density is 4 y³ on(0,1), zero outside.
For 0≤y≤1, F_Y(y)=P(X≤y²)=(y²)²=y⁴. Differentiate on the interior. Taking a square root of the density would not transform the event law.
X is uniform on(1,3) and Y=1/X. Find its support, density and P(Y>1/2).
Show the answer and reasoning
Support[1/3,1]; density 1/(2 y²) on its interior; probability 1/2.
The inverse map is 1/y with absolute derivative 1/y², multiplied by original density 1/2. The event Y>1/2 is X<2, half of the uniform interval. The reciprocal reverses the inequality.
A joint density is constant on 0<x<2,0<y<3 and zero elsewhere. Normalize it and find the marginals. Are the variables independent?
Show the answer and reasoning
The constant is 1/6; marginals are 1/2 on(0,2) and 1/3 on(0,3). They are independent.
The rectangle has area 6. Integrating over the other coordinate gives the marginals. Their product equals the joint density almost everywhere on the whole plane, including zero outside the rectangular support.
For joint density 2 on 0<x<y<1, find P(Y≤1/2).
Show the answer and reasoning
The probability is 1/4.
The marginal density is 2 y on(0,1), so integrate∫₀^{1/2}2 y dy. Counting the surrounding square would include pairs outside the support.
Let U be uniform on(0,1). Compare P(U≤1/5,V≤1/5) for V=U and V=1−U. What does this show?
Show the answer and reasoning
The probabilities are 1/5 and 0. Equal marginal laws do not determine the joint law.
In the first model both restrictions reduce to U≤1/5. In the second they require U≤1/5 and U≥4/5 simultaneously. Both V variables still have uniform marginals.
For(U,U), with U uniform on(0,1), find the joint CDF inside the unit square and decide whether a two-dimensional density exists.
Show the answer and reasoning
F(x,y)=min(x,y) for 0≤x,y≤1; no two-dimensional density exists.
Both threshold conditions reduce to U≤min(x,y). All joint mass lies on a diagonal with area zero, so an ordinary joint density would give the wrong total mass there. Each marginal nevertheless has a density.
What to carry forward
- A random variable is a measurable numerical recording; its law is the probability carried to value sets through preimages.
- Equal laws do not imply identical variables or independent recordings. Joint laws retain dependence that marginals omit.
- A mass function sums point probabilities. A CDF describes every real law and records atoms through jumps and endpoint limits.
- Quantiles need a convention. The lower generalized inverse samples a target law from an ideal uniform probability level, including at jumps.
- Density height is not point probability, and density units are reciprocal variable units. Absolute continuity is stronger than a continuous CDF.
- Mixed and singular laws need representations that preserve their atoms or length-zero concentration; differentiating a CDF can lose essential mass.
- Transformations carry all valid preimages and support restrictions. Continuous branch formulas require their regularity and Jacobian conditions.
- Marginalization and independence must be checked against the full joint law, which may be singular even when each marginal has a density.
References
Sources for the concepts and teaching approaches in this article.
Massachusetts Institute of Technology3 sources
- Random VariablesMIT OpenCourseWare; 6.436J/15.085J, Fall 2018Course notes · PDF
- Random variables and distributionsScott Sheffield; MIT OpenCourseWareCourse notes · PDF
- Probabilistic Systems Analysis and Applied Probability, Lecture 5MIT OpenCourseWare; Munther DahlehCourse notes · PDFDiscrete Random Variables; Probability Mass Functions; ExpectationsContinuous Random Variables IMultiple Random VariablesContinuous Random Variables and Derived Distributions
- A note on generalized inversesPaul Embrechts and Marius Hofert; ETH Zurich author-hosted paperResearch paper
- Related DistributionsNIST/SEMATECH e-HandbookOfficial reference