Finding the average distance between bounces of an object randomly bouncing on the inside of a sphere I have a sphere or radius r that has a small point like object moving at a constant velocity inside it. Each time it hits the side it bounces in a random direction but always away from the tangent plane at the contact point. The longest distance it can travel is through the center to the other side $2r$ if it bounces at $45^\circ$) ($\alpha  =\pi/4 $) it will hit the sphere a point on the sphere that is on the intersection of the tangent plane if moved to the center. The distance would be $2 \pi \cos(\alpha) $. I assume this works for all bounce directions for $0 < a \leq \pi$
I need to find the average distance traveled between bounces, but I am somewhat at a loss as to how find the solution. I assume its an integral of some type?? This should be a fixed value in terms as a simple multiple of the radius and the same not matter the value of $r$, and would be happy with that number.
But I would be very happy if I could get a detailed method, as I would like to be able to express the angle of reflection in terms of a curve. As the question is asked above that curve is a flat line (uniform distribution). $\alpha = \operatorname{random}(0\;\text{to}\;\pi)p(x)$ where $p(x) = 1$ but $p(x)$ could be any function. Is this possible?
Update
To clarify the angle of reflection $(\alpha_x)$ is expressed as the angle from the axis that is the line from the point of contact through the center and conforms to $0 < \alpha_x \leq \pi$  where  pi  is traveling through the center to the opposite side. The second angle around that axis ($\alpha_y$) can be $0 < \alpha_y < 2\pi $
Sorry I have very little knowledge of the vernacular used to express math concepts.
The random function should return an evenly distributed random value. 
 A: Here's my restatement of your problem, and a general answer:
Q1: "A ray leaves the south pole in a direction $d$ such that the angle between $d$ and the south-to-north diameter of the sphere is chosen uniformly randomly from $0$ to $\pi/2$. What is the expected length of the part of the ray within the sphere?"
First assume the sphere has radius $1$. 
For angle $a$, the length $L(a)$ of the ray is $2 \cos(a)$. (This is an elementary fact from geometry). 
The expected value of $L$ is computed as 
$$
E[L] = \int_0^{\pi/2} L(a) p(a) da,
$$
where $p(a) = \frac{2}{\pi}$ is the probability density at angle $a$. This evaluates to 
\begin{align}
E[L] 
&= \int_0^{\pi/2} L(a) p(a) da\\
&= \frac{4}{\pi} \int_0^{\pi/2} \cos(a)~ da\\
&= \frac{4}{\pi} \left. \sin(a)\right|_0^{\pi/2}\\
&= \frac{4}{\pi} (1 - 0)\\
&= \frac{4}{\pi}.
\end{align}
Q2: "A ray leaves the south pole in a direction $d$ such that the angle  $a$ between $d$ and the south-to-north diameter of the sphere is chosen according to some distribution $a \mapsto u(a)$ on the interval $[0, \pi/2]$. What is the expected length of the part of the ray within the sphere?" 
The formula for the expected value is 
$$
E[L] = \int_0^{\pi/2} L(a) p(a)~ da = 
 = \int_0^{\pi/2} 2 \cos(a) p(a)~ da. 
$$
Without knowing $p$, however, this as far as we can go. 
