# Triple Integral and finding the average

1. Dec 27, 2011

### gipc

Solve the Integral in cylindrical coordinates
∫∫∫ dxdydz/(sqrt( x^2 + y^2 + (h-z)^2)
B

Where B is the Ball with a Radius R around (0,0,0), and the parameter h is greater than R.

And then infer the average on that ball B with radius R of the distance opposite to the point (0,0,h).

I have these so far:
Using Cylindrical Coordinates,
∫∫∫B dV/√(x² + y² + (h-z)²)
= ∫(θ = 0 to 2π) ∫(z = 0 to R) ∫(r = -√(R² - z²) to √(R² - z²)) (r dr dz dθ) / √(r² + (h-z)²)
= 2π ∫(z = 0 to R) ∫(r = -√(R² - z²) to √(R² - z²)) r dr dz / √(r² + (h-z)²)
= 2 * 2π ∫(z = 0 to R) ∫(r = 0 to √(R² - z²)) r dr dz / √(r² + (h-z)²), by evenness
= 4π ∫(z = 0 to R) √(r² + (h - z)²) {for r = 0 to √(R² - z²)} dz
= 4π ∫(z = 0 to R) [√((R² - z²) + (h - z)²) - √(h - z)²] dz
= 4π ∫(z = 0 to R) [√((R² - z²) + (h - z)²) - (h - z)] dz, since h > R > r
= 4π ∫(z = 0 to R) [√(R² + h² - 2hz) - h + z] dz
= 4π [(-1/(3h)) (R² + h² - 2hz)^(3/2) - hz + z²/2] {for z = 0 to R}
= 4π {[(-1/(3h)) (R² + h² - 2hR)^(3/2) - hR + R²/2] - (-1/(3h)) (R² + h²)^(3/2)}
= 4π [(-1/(3h)) (h - R)³ - hR + R²/2 + (1/(3h)) (R² + h²)^(3/2)].

Now, is that solution correct? Is there a way so simplify things? And from there, how do I find the average?

2. Dec 27, 2011

### Simon Bridge

Isn't $\sqrt{x^2+y^2+z^2}$ the distance from the origin to the point (x,y,z)?
So $\sqrt{x^2+y^2+(h-z)^2}$ would be the distance from (x,y,z) to (0,0,h)?
So your integral is just summing all these distances ... how do you find an average value by integration?

Same kind of problem, slightly different way:
http://www.mathpages.com/home/kmath324/kmath324.htm

3. Dec 27, 2011

### SammyS

Staff Emeritus
It looks like you have only integrated over the top half of the Ball.

The limits on z should go from -R to R .

4. Dec 27, 2011

### gipc

I think the final answer is still correct, no?