cumulative distribution function problem Here is an excerpt from my textbook that I am having trouble understanding:
The cumulative distribution function F of the random variable X is defined for any real number x by
$$F(x) = P\{X\leqslant x \} $$
That is, F(x) is the probability that the random variable X takes on a value that is less than or equal to x. 
All probability questions about X can be answered in terms of its distribution function F
Suppose we want to compute $ P\{a < X \leqslant \ b\} $
This can be accomplished by first noting that the event $\{X \leqslant b\}$ can be expressed as the union of the two mutually exclusive events $\{X  \leqslant a \} $ and $ \{a < X \leqslant \ b\} $
I don't see how this could be because $a$ is smaller than $X$ in one, and bigger or equal in the other
 A: The contradictory nature is intentional. The two events $\{X\le a\}$ and $\{a< X \le b\}$ are mutually exclusive. In other words, it's impossible for the two events to both be true. What we are saying is: "If $X$ is less than or equal to $b$, then either $X$ is less than or equal to $a$, or $X$ is between $a$ and $b$, but not both." (Can't argue with that, assuming $a<b$.) Since the events are mutually exclusive,  we can now write the probability
$$P(X\le b)$$
as the sum of the probs of the two events
$$P(X\le a) + P(a< X\le b)$$
and rearrange to obtain
$$P(a<X\le b) = P(X\le b) - P(X\le a)\;.
$$
The point of the calculation is to show how you can get other probabilities from the cumulative distribution function.
A: The answer is that the point you are worrying about is precisely the point that allows you to easily add the probabilities. That is, you have two different types of events:  $X$ has some property (A), and $X$ has some other property (B).  And in our case, properties (A) and (B) are mutually exlusive.  Yes, any given $X$ either has property (A), or property (B) (or has neither property).  So it is fine that $a\geq X$ if (A) holds and $a<x$ if (B) holds; they don't both have to hold at once.
Since the events (A) and (B) are mutually exclusive, we can find the probability of the union of (A) and (B) by adding the two individual event probabilities. From there, the problem is easy:
$$F(a) = P(X \leq a) \\
F(b) = P(X \leq b) = P(X \leq a) + P(a < X \leq B) = F(a) + P(a < X \leq B) \\
F(b) = F(a) + P(a < X \leq B) \implies P(a < X \leq B) =F(b) - F(a)
$$
