# Computing a conditional joint density

Given the joint density $f_{12}(x_1,x_2)$ of two (dependent) random variables $X_1$ and $X_2$, each defined on $\mathbb{R}$. Suppose that $f_{12}$ is differentiable everywhere on $\mathbb{R}^2$. Now define the event

$Y=\{(x_1,x_2) : x_2 - x_1 \leq d\}$

for some real $d$.

What is the conditional density $f_{12}(x_1,x_2|Y )$ ?

In other words, I need the joint density when event points are restricted to the subspace $Y$ of $\mathbb{R}^2$.

More generally, given a $Y \subsetneq \mathbb{R}^2$, defined by one or more "algebraic" constraints (like the one given above), is there an algorithm to compute the conditional joint density?

I don't know if "conditional joint density" is the right term. I'd also appreciate any references on this.

## 1 Answer

If a random vector $X$ has density $f$, and $A=\{\omega:X(\omega)\in B_0\}$, for some fixed Borel set $B_0$, supposing that $P(A)>0$, we can define a conditional density $f(\;\cdot\mid A)$ as a function that satisfies $$P(X\in B\mid A) =\int_B f(x\mid A)\,dx \, , \qquad\qquad (*)$$ for every Borel set $B$. It is easy to prove that $$f(x\mid A) = \frac{f(x)}{P(A)} I_{B_0}(x)$$ satisfies $(*)$; just use that $P(X\in B\mid A)=P(X\in B\cap B_0) / P(A)$. If you need help with any details of the proof, just ask.

• Well, I'm trying to understand "Borel set" from Wikipedia ;-). Could you name a textbook that talks about this? – PKG Nov 27 '13 at 18:21
• I learned it from Billingsley, but it's probably too advanced for beginers. If I were you I would study "Basic Probability Theory" by Prof. Robert Ash. He's one of the clearest expositors ever and gives intuition about the measure theoretic ideas without going into the technicalities. This little book is a gem. – Zen Nov 27 '13 at 18:30
• My earlier comment was unclear. I meant can you name a textbook that talks about your derivation and related matters? – PKG Nov 27 '13 at 18:31
• Little Ash has a whole chapter on conditional probability and expectation. – Zen Nov 27 '13 at 18:33
• much obliged! Maybe Little Ash is the Zen of Probability Theory ;-) – PKG Nov 27 '13 at 18:35