How to find the number of intervals containing a point when given a static set of intervals?
It is a very strong assumption that the time it takes to preprocess is not a concern.

Assume each given interval contains both of its endpoints. Otherwise, the solution below can be adapted easily. 

Sort all $b_i$ and $r_i$ into an increasing sequence $A=(a_1, \cdots, a_{2n})$. 

Let $c_1=1$. For $i$ from 2 to $2n-1$, let 
$$c_{i}=\begin{cases}
c_{i-1}+1&amp;\text{ if } a_{i}\text{ is a starting point of a given interval,}\\
c_{i-1}-1&amp;\text{ if } a_{i}\text{ is an ending point of a given interval.}
\end{cases}$$ 
$c_i$ is the number of the given intervals that contain the open interval $(a_i, a_{i+1})$ for $1\le i\le 2n-1$. Let $C$ be the sequence $(c_1, \cdots, c_{2n-1})$. The combination of $A$ and $C$ is what we wanted from preprocessing.

Given any number $p$, if $p \gt a_1$ and  $p\lt a_{2n}$, we can find the largest index $i$ such that $p\ge a_{i}$ by binary search in $O(\log n)$ time. Then the number of given intervals that contain $p$ is given by 
$$\begin{cases}
0&amp;\text{ if } p&lt;a_1,\\
1&amp;\text{ if } p= a_1,\\
c_{i}&amp;\text{ if } a_i&lt;p\lt a_{i+1}\text{ or } p=a_i\text{ and } c_i&gt;c_{i-1},\\
c_{i}+1&amp;\text{ if } p=a_i\text{ and } c_i&lt;c_{i-1},\\
1&amp;\text{ if } p=a_{2n},\\
0&amp;\text{ if } p&gt;a_{2n},\\
\end{cases}$$ 
In other words, we can get the answer in $O(\log n)$ time once $A$ and $C$ are known.