MathGroup Archive 2002

[Date Index] [Thread Index] [Author Index]

Search the Archive

Trouble calculating a volume


Respected Colleagues:

I am attempting to calculate the volume of the frustum of a cone.
I have been able to calculate the volume of a cone using a triple
integral as follows:

Integrate[1, {x, 0, h}, {y, (-r)*(x/h), r*(x/h)},
   {z, -Sqrt[(r*(x/h))^2 - y^2], Sqrt[(r*(x/h))^2 - y^2]}]

This integral does evaluate to the correct answer

(1/3)*h*Pi*r^2

where r is the base diameter and h is the height.

In order to calculate the volume of the frustum of a cone, I have used the
following equation :

Simplify[Integrate[1, {x, 0, h},
    {y, -(r1 + ((r2 - r1)*x)/h), r1 + ((r2 - r1)*x)/h},
    {z, -Sqrt[(r1 + ((r2 - r1)*x)/h)^2 - y^2],
     Sqrt[(r1 + ((r2 - r1)*x)/h)^2 - y^2]}]]


where r1 and r2 are the top and bottom radii of the section and h
is the height. This integral evaluates to include Logarithms and
imaginary numbers

(I*Sqrt[h^2*r2]*(r1^2 + r1*r2 + r2^2)*
    (Log[-2*I*h*r2] - Log[2*I*h*r2]))/(3*Sqrt[r2])

when the solution should be

(1/3)*h*Pi*(r1^2+r1*r2+r2^2)

Which, if you substitute r1=0 and r2=r you get the volume of
a cone.

I am using Mathematica Version 4.1.2.0
running on Windows 2000

Thank you for any help

Jay Martin

PS: what I am ultimately after are the moments of inertia of the section
That is why I am using the triple integral in terms of x, y, and z


  • Prev by Date: Detecting where errors occurred in a Table[ ] calculation?
  • Next by Date: Re: Memory problems
  • Previous by thread: Detecting where errors occurred in a Table[ ] calculation?
  • Next by thread: Re: Trouble calculating a volume