Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Volume of a partially filled sphere

  1. Jan 27, 2008 #1
    Hi i need help finding the volume of a partially filled sphere. I know that there is an equation to do this but i actually need to learn how to do this. Here it goes.

    Its pretty straight forward no number. Sphere with radius R find the volume of liquid at height h. I know the total valume is just 4/3 pi r^3 but how do you set a relationship with total volume and a volume at a certain height

  2. jcsd
  3. Jan 27, 2008 #2


    User Avatar
    Science Advisor
    Gold Member

    I think you're starting with the wrong approach. Ask first how you get that volume formula using calculus. Then how to modify it to the case of a partial sphere.

    Start with the general procedure for finding the volume of a solid, i.e. slicing it up and writing a Riemann sum representing an approximate volume which in the limit becomes an integral. Then try it for the whole sphere to be sure you get [itex]\frac{4}{3}\pi r^3[/itex] and then modify it for the partial sphere.
  4. Jan 27, 2008 #3


    User Avatar
    Science Advisor
    Gold Member

    Further Hint: Try horizontal slices which are approximately thin cylinders of height [itex]\Delta x[/itex] and circular base area a function of the height of the slice.
  5. Jan 27, 2008 #4
    I did what you told me using calc but it gets me the volume of the total sphere. i did horizontal slicing using dx to form a triangle which gave me the area of the cross section. from that i just took the integral from -r to r to get the total volume. I just dont know how to modify it to get the volume at a particular height. Or the relationship between total volume and partial volume.

    the answer is like pi* (rh^2 - h/3)
    r= radius of the whole sphere
    h= height for the volume to be calculated

    Last edited: Jan 27, 2008
  6. Jan 27, 2008 #5


    User Avatar
    Science Advisor
    Gold Member

    OK! Now all you got to do is rethink the limits of integration...follow all the steps in the setup:
    Draw a picture,
    find the cross sectional area, write the integral
    [tex] \int_?^? A(z)dz[/tex]
    (z = whatever variable you're using)
    determine your limits of integration,
    check your work.

    I am confused about you getting triangles. The cross sections should be circles.
    [Edit: Oh I think I understand. But you don't need to do this. Just use whatever variable is perpendicular to the cross sectional area, either of x,y, or z. Think of the dz being the thickness of the cross section so Adz is the volume of a slice.]
    Last edited: Jan 27, 2008
  7. Jan 27, 2008 #6
    yup did that. as well. Here let me try to explain again (sry im new to forums dont know how to use the coding)

    (this is not from my question but makes it easier for me to explain)

    Im only given the radius as R and they want me to calculate the volume of the sphere that is filled with liquid (point h on the z axis). since there is no numbers the answer is going to be a formula. so when i integrate the area of the cross section (using the element of dz as you mentioned) i get the "theoretical" volume equation for the entire sphere which us 4/3 pi r^3 (which is just deriving the formula itself).

    For my question, how can i find the partial volume of the sphere given only the height (point at z axis).

    There are sites that do this for you (http://www.onlineconversion.com/object_volume_partial_sphere.htm), but i need to derive the formula using calc but i cant :(

    thanks for your help man, i hope this is more clear
    Last edited: Jan 27, 2008
  8. Jan 27, 2008 #7
    hmm maybe the equation for the volume of spherical cap? since thats what it really is. but i need to know how to derive it
  9. Jan 28, 2008 #8


    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    I can see where it would be difficult to get the answer you want in Spherical coordinates. The geometry of your problem lends itself to a rectangular coordinate system. Try an integral in terms of x,y, and z. You can now easily specify the limits along one axis from the bottom to some height h.
  10. Jan 28, 2008 #9


    User Avatar
    Science Advisor
    Gold Member

    Draw your picture!!!!
    Pick a sphere filled to height 0<h<2R centered at the origin with z the up axis. Its equation is x^2 + y^2 + z^2 = R^2. The cross sectional areas will be circles and you'll have to figure their area as a function of z indicating the vertical position at which you slice.

    You'll integrate A(z)dz with limits chosen so the z-coordinate spans the part of the sphere filled. You still must do this yourself, I'm not going to give you the limits of integration.

    You say you've done this for the whole sphere. Look at your picture for the partially filled sphere. At what z-value is its top sliced off?
  11. Jan 28, 2008 #10


    User Avatar
    Science Advisor
    Homework Helper
    2015 Award

    archimedes solved this problem. inscribe the sphere in a cylinder. then inscribe in the same cylinder a (double) cone, vertex at center.

    then show that the area of each horizontal slice of the cylinder is the sum of the areas of the cone plus that of th sphere. then by cavalieri's principle the same is true for the volumes.

    hence by subtracting the volume of the truncated cone from that of the truncated cylinder, you get the volume of the truncated sphere.
  12. Jan 28, 2008 #11
    Limits of integration is just from 0 to h. So if i can a function that represents the area of the cross sections as a function of z i can just solve it.

    I thought about using ur formula x^2 + y^2 + z^2 = R^2 so the area function would be pi(x^2+y^2+z^2) and y^2=R^2-x^2-z^2 and x^2=R^2-y^2-z^2 when i add it i get pi(2R^2-z^2). As you can see i got to nowhere with this calculation.

    Any suggestions? Do i have the right thinking?

    Thanks a bunch guys
  13. Jan 28, 2008 #12


    User Avatar
    Science Advisor
    Gold Member

    Nope. The sphere centered at the origin won't start at z=0 but rather at z=-R. Then note that it won't end at z=h but at z = a value h above the bottom.

    My equation tells you the position of the sphere, i.e. centered at the origin and then the limits of z for the whole sphere, i.e. where x and y are zero z = +/- R.
    But that big R is not the radius of your disks. The disks will be circles of the form x^2 + y^2 = r^2 for a different radius r. So in terms of z, r = sqrt(R^2 - z^2). Which you should have gotten if you did the whole sphere.

    You're almost there. Just get the limits right on the same integral you used to do the whole sphere. When you evaluate you'll get the correct formula.
  14. Jan 28, 2008 #13
    omg i think i got it !!! I cant believe it was that simple. so the limits of integration from -R to h - R and the same equation i use to get the whole volume. I didn't actually do it yet i need to get to class but this makes SO much sense (i think at least)

    thanks a bunch
  15. Jan 28, 2008 #14


    User Avatar
    Science Advisor
    Homework Helper
    2015 Award

    if you consider the top half of a sphere inscribed in a cylinder, and an inverted cone inscribed in the same cylinder, then pythagoras says that the area of a horizontal slice of the cone at height h is (pi)(R^2 - h^2). on the other hand the area of the same slice of the cone is pi h^2. so these add up to pi R^2, the area of the same slice of the cylinder.

    thus the volumes satisfy the same relationship, so thew volume of the portion of the hemisphere up to height h, equals the difference between the volumes of the cylinder and cone up to that height = pi R^2 h - (1/3)pi h^3.

    is that what you got? (you will have to add in the volume of the bottom hemisphere, to get the volume of a sphere from the south pole up to height h above the equator.)
  16. Jan 28, 2008 #15


    User Avatar
    Science Advisor
    Gold Member

    All right! Sounds like you've closed the gap. I hated to be cryptic but you need to go through the steps yourself and the less help the better (provided you get it right) as you're practicing the method you'll need for other problems. Good luck.
  17. Jan 28, 2008 #16
    yup did the calculation, works! Believe this way thought me alot more than somebody spoon feeding me the answer. I actually get the concept.

    I just started calc2 and i feel like im step ahead of everyone, because everyone just ditched this question and i was going crazy to find the answer.

    Thanks for your hints. Appreciate the help
  18. May 5, 2009 #17
    Boy am I rusty.


    For a sphere with radius = r

    Let h be the height of liquid in the sphere.

    If we subdivide the height into thin segments by dh, let x be the radius at height h.

    So when h is 0, then x is 0 (empty sphere)
    and when h is r, then x is r (1/2 full sphere {known to be 2/3 PH r^3}

    We know that the circumfrential area for any little dh, is CA = PI * x^2

    We need the relationship between x and h.

    As h increases, the remaining distance from the center of the sphere to the top of the liquid is r-h.

    The length of the line from the center of the sphere to the edge of the liquid is r

    So we can find x using x^2 + (r-h)^2 = r^2
    x^2 = r^2 - {r^2 -hr -hr + h^2}
    x^2 = r^2 - {r^2 -2hr + h^2}
    x^2 = r^2 - r^2 + 2hr - h^2
    x^2 = + 2hr - h^2
    x = {2hr -h^2}^(1/2)

    To find the volume of liquid in the sphere

    Volume = int (PI x^2) dh from 0 to h
    V = PI int (2hr - h^2) dh from 0 to h
    V = PI { int (2rh) dh - int (h^2) dh from 0 to h
    V = PI { (rh^2) - ((1/3) h^3) } from 0 to h

    so when h is 0, V is 0 as both terms collapse

    when h is r, V is
    V = PI { (r^3) - ((1/3) r^3) } from 0 to h
    V = (2/3) PI { (r^3)

    and when h is 2r, V is
    V = PI { (rh^2) - ((1/3) h^3) } from 0 to h
    V = PI { (4r^3) - ((8/3) r^3) }
    V = (1/3) PI { (12-8) r^3}
    V = (4/3) PI r^3
  19. May 20, 2009 #18
    I think its straightforward enough just map the sphere(x2+y2+z2=r2) map it into the xy-plane(x2+y2=r2)solve in terms of y(sqrt(r2-x2)) now applied disk method of integrating solids of revolution to obtain:


    see simple
    Last edited: May 20, 2009
  20. May 20, 2009 #19

    Simple? Have you actually integrated that expression you posted? Ick !!!

    The integration I posted is simpler.

    Volume of segment = PI*0h(x2)dh

    Then as x2 = 2hr -h2, we can replace the x2 with this expression so that we can integrate for dh:

    Volume of segment = PI*0h(2hr-h2)dh

    This can be rearranged as so:

    Volume of segment = PI*[0h(2hr)dh -0h(h2)dh]

    The integration of each part is very simple.

    Volume of segment = PI*[(h2r)|0h -(h3/3) |0h]

    And since the integration is from 0 to h, the subtraction terms are all zero and don't have to be written !!! So we only have to write out the h terms. VOILA:

    Volume of segment = PI*[(h2r) -(h3/3)]

    Now with your equation, the integration is over -r to (h-r). So you will not only have to write out the subtraction terms, you will be putting (h-r) into a cubed term !!!

    Now you have a LOT of nasty math to get from here to the final answer.

    The square root and the square term from your integral cancel, so your integral is actually:

    Volume of segment = PI*-rh-r(r2-x2)dx

    The integration is very simple and comes up with the same general result as mine:

    Volume of segment = PI*(r2x-(x3/3)) |-rh-r

    However, unless now you have a very nasty mess when you integrate from (-r) to (h-r). As in:

    Volume of segment = PI*[r2(h-r)-((h-r)3/3)-r2(-r)-((-r)3/3)]

    We have an the cubed (h-r)3 term to deal with !!!
    And we have the minus r terms to deal with !!!

    (h-r)(h-r)(h-r) goes to
    (h2-rh-rh+r2)(h-r) goes to
    h3-2rh2+r2h-h2r+2r2h-r3 goes to

    Plug it all in and we get eventually get ... (after double and triple checking to eliminate the sign errors)

    Volume of segment = PI*[r2h-r3-h3/3+rh2-r2h+r3/3+r3-r3/3]


    Now the first term cancels with the 5th term
    The second term cancels with the 7th term
    and the 6th term cancels with the 8th term
    so we are left with only the third and fourth terms in the equation.


    Finally, after much painful math, the answer.

    Volume of segment = PI*[-h3/3+rh2]

    It is far better and quicker to redefine the integral range to be from 0 to h !!!
    Last edited: May 20, 2009
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?

Similar Discussions: Volume of a partially filled sphere
  1. Volume of a sphere (Replies: 5)