Solid of Revolution

Author

Eric W. Weisstein
May 4, 2006

This notebook downloaded from http://mathworld.wolfram.com/notebooks/SolidGeometry/SolidofRevolution.nb.

For more information, see Eric's MathWorld entry http://mathworld.wolfram.com/SolidofRevolution.html.

©2006 Wolfram Research, Inc. except for portions noted otherwise

Code

VolumeByCylinders[{f_,g_},{x_,a_,b_},opts___]:=2Pi Integrate[(f-g) x,{x,a,b},opts]
VolumeByCylinders[f_,{x_,a_,b_},opts___]:=VolumeByCylinders[{f,0},{x,a,b},opts]

VolumeByWashers[{f_,g_},{z_,a_,b_},opts___]:=Pi Integrate[(f^2)-(g^2),{z,a,b},opts]
VolumeByWashers[f_,{z_,a_,b_},opts___]:=VolumeByWashers[{f,0},{z,a,b},opts]

Figures

With[{h=1,r=.5,n=10},
Show[
Graphics3D[{
Table[Cylinder[{0,0,0},{0,0,h(1-(x/r))},x,PlotPoints->{1+Ceiling[2r],20}],{x,0,r(1-1/n),r/n}]
}],Boxed->False,PlotRange->All]
]

With[{h=1,r=.5,n=10},
Show[
Graphics3D[{
Table[{
Polygon[Table[{((x/r))Cos[2π i/20]/2,((x/r))Sin[2π i/20]/2,(1-(x/r))+.1},{i,0,19}]],
Cylinder[{0,0,(1-(x/r))},{0,0,(1-(x/r))+.1},x,PlotPoints->{1+Ceiling[2r],20}]},{x,0,r(1-1/n),r/n}]
}],Boxed->False,PlotRange->All]
]

Shapes

Barrell (Elliptical)

VolumeByCylinders[]

VolumeByWashers[(Sqrt[((Subscript[r, 2])^2)+((((Subscript[r, 1])-(Subscript[r, 2]))((Subscript[r, 1])+(Subscript[r, 2]))(((h-2z))^2))/(h^2))]),{z,0,h}]//Factor

Barrel (Parabolic)

VolumeByCylinders[]

VolumeByWashers[(Subscript[r, 2])+((((Subscript[r, 1])-(Subscript[r, 2]))(((h-2z))^2))/(h^2)),{z,0,h}]//Factor

Cone

VolumeByCylinders[h(1-(x/r)),{x,0,r},Assumptions->r>0]

VolumeByWashers[r(1-(z/h)),{z,0,h}]

Conical Frustum

Solve[R1+(R2-R1)(z/h)==#,z]&/@{0,R2,R1}

VolumeByCylinders[If[x<R2,h,h(1-((x-R2)/(R1-R2)))],{x,0,R1},Assumptions->0<R2<R1]//Factor

VolumeByWashers[R1+(R2-R1)(z/h),{z,0,h}]//Simplify

Cylinder

VolumeByCylinders[h,{x,0,r}]

VolumeByWashers[r,{z,0,h}]

Oblate Spheroid

VolumeByCylinders[{c(Sqrt[1-((x^2)/(a^2))]),-c(Sqrt[1-((x^2)/(a^2))])},{x,0,a},Assumptions->a>0]

VolumeByWashers[a(Sqrt[1-((z^2)/(c^2))]),{z,-c,c}]

Prolate Spheroid

VolumeByCylinders[{c(Sqrt[1-((x^2)/(a^2))]),-c(Sqrt[1-((x^2)/(a^2))])},{x,0,a},Assumptions->a>0]

VolumeByWashers[a(Sqrt[1-((z^2)/(c^2))]),{z,-c,c}]

Sphere

VolumeByCylinders[{(Sqrt[(r^2)-(x^2)]),-(Sqrt[(r^2)-(x^2)])},{x,0,r},Assumptions->r>0]

VolumeByWashers[(Sqrt[(r^2)-(z^2)]),{z,-r,r}]

Torus

VolumeByCylinders[{(Sqrt[(a^2)-(((x-c))^2)]),-(Sqrt[(a^2)-(((x-c))^2)])},{x,c-a,c+a},Assumptions->a>0]

VolumeByWashers[{c+(Sqrt[(a^2)-(z^2)]),c-(Sqrt[(a^2)-(z^2)])},{z,-a,a},Assumptions->a>0]

Spherical Segment

v=Expand[(1/6)π h(3(a^2)+3(b^2)+(h^2))/.h->(Sqrt[(R^2)-(b^2)])-(Sqrt[(R^2)-(a^2)])]

Simplify[v/.R->(Sqrt[((((a^2)-2 a b+(b^2)+(h^2)) ((a^2)+2 a b+(b^2)+(h^2)))/(4 (h^2)))]),0<b<a&&h>0]

Simplify[a^2>b^2+h^2/.{a^2->R^2-d^2,b^2->R^2-(d+h)^2},d>0&&h>0]

VolumeByCylinders[{If[x<b,h+d,(Sqrt[(R^2)-(x^2)])],d},{x,0,a},Assumptions->0<b<a≤R]

%/.d->(Sqrt[(R^2)-(a^2)])/.h->(Sqrt[(R^2)-(b^2)])-(Sqrt[(R^2)-(a^2)])//Expand

VolumeByWashers[(Sqrt[(R^2)-(z^2)]),{z,d,d+h}]/.d->(Sqrt[(R^2)-(a^2)])/.h->(Sqrt[(R^2)-(b^2)])-(Sqrt[(R^2)-(a^2)])//Expand

Torispherical Dome

Factor[Simplify[Expand[(FullSimplify[(Sqrt[(R^2)-(x^2)])-(Sqrt[(a-c-R) (a+c-R)])/.x->c(1+((((R/a)-1))^(-1))),R>0])^2],0<R<a+c&&0<a<c&&R>a]]

Factor[Expand[(FullSimplify[(Sqrt[(a^2)-(((x-c))^2)])/.x->c(1+((((R/a)-1))^(-1))),R>0&&a>0])^2]]

v=VolumeByCylinders[If[x<c(1+((((R/a)-1))^(-1))),(Sqrt[(R^2)-(x^2)])-(R-h),(Sqrt[(a^2)-(((x-c))^2)])],{x,0,a+c},Assumptions->0<a+c<R&&0<a<c]

FullSimplify[FullSimplify[v,0<a+c<R&&0<a<c<R]/.(Sqrt[-(c^2)+(((a-R))^2)])->R-h]

Expand[(6/π)FullSimplify[FullSimplify[v,0<a+c<R&&0<a<c<R]/.(Sqrt[-(c^2)+(((a-R))^2)])->R-h/.h->R-(Sqrt[(a+c-R)(a-c-R)])]]

(Sqrt[(a+c-R)(a-c-R)])Factor[(-4a^2-2c^2-4a R-4R^2)]+3a^2c π+4 (R^3)+6 (a^2) c ArcSin[(c/(a-R))]

With[{R=1,c=.6,a=.3},
With[{h=R-(Sqrt[(a-c-R) (a+c-R)])},
{
NIntegrate[Boole[((x^2)+(y^2)<(((c(1+(a/(R-a)))))^2)&&x^2+y^2+z^2<R^2||((x^2)+(y^2)>(((c(1+(a/(R-a)))))^2)&&(((c-(Sqrt[(x^2)+(y^2)])))^2)<(a^2)-(((z-(R-h)))^2)))&&z>R-h],{x,-∞,∞},{y,-∞,∞},{z,-∞,∞},Method->QuasiMonteCarlo,MaxPoints-> 10^5,SymbolicPreprocessing->False],
2π NIntegrate[x If[x<c(1+((((R/a)-1))^(-1))),(Sqrt[(R^2)-(x^2)])-(R-h),(Sqrt[(a^2)-(((x-c))^2)])],{x,0,a+c}],
(π/6)(3 (a^2) c π+4 (R^3)-2 (Sqrt[(a-c-R) (a+c-R)]) (2 (a^2)+(c^2)+2 a R+2 (R^2))+6 (a^2) c ArcSin[(c/(a-R))]),
(1/6) π ((a^2) (4 h+3 c π-4 R)+2 (c^2) (h-R)+4 a (h-R) R+4 h (R^2)+6 (a^2) c ArcSin[(c/(a-R))])
}]]//Timing

FullSimplify[Expand[(((c+(Sqrt[(a^2)-(z^2)])/.z->a((R-h)/(R-a))))^2)/.h->R-(Sqrt[(a-c-R) (a+c-R)])],0<a<c<R]

FullSimplify[Expand[((((Sqrt[(R^2)-(((z+(R-h)))^2)])/.z->a((R-h)/(R-a))))^2)/.h->R-(Sqrt[(a-c-R) (a+c-R)])],0<a<c<R&&R>a+c]

(v=VolumeByWashers[If[z<a((R-h)/(R-a)),c+(Sqrt[(a^2)-(z^2)]),(Sqrt[(R^2)-(((z+(R-h)))^2)])],{z,0,h},Assumptions->0<a+c<R&&0<a<c<R&&0<a<h<R])//Timing

FullSimplify[v/.h->R-(Sqrt[(a+c-R)(a-c-R)]),0<a+c<R&&0<a<c<R]

%8/.(Sqrt[-(c^2)+(((a-R))^2)])->(R-h)

-(1/3) π ((2 (a^2)+(c^2)+2R a) (-h+R)-2h (R^2)+3 (a^2) c ArcCsc[((a-R)/(Sqrt[-(c^2)+(((a-R))^2)]))])

With[{R=1,c=.5,a=.35},
With[{h=R-(Sqrt[(a-c-R) (a+c-R)])},
{
(π/6)(3 (a^2) c π+4 (R^3)-2 (Sqrt[(a-c-R) (a+c-R)]) (2 (a^2)+(c^2)+2 a R+2 (R^2))+6 (a^2) c ArcSin[(c/(a-R))]),
(1/6) π ((a^2) (4 h+3 c π-4 R)+2 (c^2) (h-R)+4 a (h-R) R+4 h (R^2)+6 (a^2) c ArcSin[(c/(a-R))]),
(1/3) π (2h (R^2)-(2 (a^2)+(c^2)+2R a) (R-h)+3 (a^2) c ArcSin[((R-h)/(R-a))])
}]]//Timing