Random Variables that aren't measurable I've been reading through a math. stats. book, and I'm a little confused with the concept of measurable random variables.  The book states:

Let $(E, \mathcal{E})$ and $(F,\mathcal{F})$ be two measurable spaces. A random variable $X : E → F$ is called measurable (relative to $\mathcal{E}$ and $\mathcal{F}$) if $X^{−1}(\Lambda) \in \mathcal{E}$ for all $\Lambda \in \mathcal{F}$.

Now, here's my question: If it says "$X:(\Omega,\mathcal{A}) → (\mathbb{R}, \mathcal{B})$" without defining $\mathcal{B}$, then I can assume $\mathcal{B}$ is just the image of $X$, right?  But, with this assumption, wouldn't all random variables be measurable?  It seems like all random variables would be measurable, then, unless $\mathcal{B}$ was constructed in such a way that $X$ would not map onto $\mathcal{B}$.  Is that true?  Can anyone give me an example of a meaningful scenario where we'd have non-measurable random variables?
The reason I ask is because I'm working on this homework problem:

Given $(\Omega,\mathcal{A}, P)$, let $\mathcal{A}'=\{A ∪ N:A ∈ \mathcal{A},N ∈ \mathcal{N}\}$, where $\mathcal{N}$ are the null sets (as in Theorem 6.4). Suppose $X = Y$ almost surely where $X$ and $Y$ are two real-valued functions on $Ω$. Show that $X: (Ω,\mathcal{A}') → (\mathbb{R}, \mathcal{B})$ is measurable if and only if $Y : (Ω,\mathcal{A}') → (\mathbb{R}, \mathcal{B})$ is measurable.

But, if these two $\mathcal{B}$'s are just defined as the images of the functions, isn't this trivial?
 A: In your counterexample I guess you mean that the probability of the interval is one and the rest of the line has measure zero. If that is what you mean then X and Y are equal almost surely.
A: First of all, if you have the same $\cal B$ in two places within the same context then they represent the same object. So it is probably safe to assume it is not something defined by $X$ itself (then $Y$ would have to define something slightly different, which would be weird).
Secondly in the context of probability and measure theory, it is usually the case that $\cal B$ denotes the Borel $\sigma$-algebra of the space, in this case $\Bbb R$.
Lastly it seems that you have taken this from some text somewhere. Look in the text preceding your quote and find out what does $\cal B$ stands for. If this was taken from a homework assignment, send an email to your TA or professor and ask for clarification.
A: Definition(Measurable function): Let $f$ be a function from a measurable space $(\Omega , \mathcal F)$ into the real numbers. We say that the function $f$ is measurable if for each Borel set $B \in \mathcal B$ , the set $\{\omega; f(\omega) \in B\} ∈ \mathcal F$.
Definition( random variable): A random variable $X$ is a measurable function from a probability space $(\Omega , \mathcal F, \mathbb P)$ into $(\mathbb R, \mathcal B(\mathcal R), \lambda)$, where $\lambda$ is the Lebesgue measure.
