# Cylinder Calculator - Volume Area Radius Height

1. ### wolf1728

10
Maybe I'm plugging my website but I just finished writing a versatile cylinder calculator.

If you know two variables (Volume Area Radius Height), it calculates the other two.
http://www.1728.org/diam.htm

It was a little tricky deriving the formulas but I'm glad I did.
(Yes, I know if you only know the area and volume it can't calculate the radius and height but it can solve the other 5 combinations).

2. ### Mentallic

3,648
Why can't you specify the radius and height given volume and area?

3. ### SSWheels

17
You should be able to come up with 2 possibilities for the radius and height, given the volume and the area...

4. ### wolf1728

10
That's an interesting question you both raised.
The same volume can be stated in an infinite number of ways.
(Example: A cylinder with a height of 13 cm and a radius of 6 cm has the exact same volume (about 1,470 cubic centimeters) as a cylinder with a height of 15 cm and a radius of 5.585 cm. and so on).
So I thought knowing the volume and area would not narrow things down.
However, those 1,470 cubic centimeter cylinders would have different areas and this might be a way to narrow things down.

5. ### Mentallic

3,648
Well of course, using that same logic you'd be able to find an infinite number of cylinders with a given radius r. It's only until we also restrict h that we get a specific result.

As SSWheels mentioned, you can find two values for r and h given a specific V and A.

What also might interest you is that solving this problem will lead you to find a certain bound on what A must at least be given some V. For example, you can't possibly have an area of 10 given a volume of 100.

6. ### wolf1728

10
I can see that by setting up two simultaneous equations:

Area = (2•Pi•r²) + (2•Pi•r•height)
Volume = (2•r²•height)

I could use Cramer's Rule https://en.wikipedia.org/wiki/Cramer's_rule to set up determinants and solve for radius and height.

The only problem with that is Cramer's rule can only be applied to linear equations.
If you have any suggestions to solve this I would greatly appreciate it.
Thanks.

7. ### jbriggs444

One classical way of solving two simultaneous equations in two unknowns is to rearrange one of the equations so that it expresses one of the unknowns as a formula in terms of the other. You then substitute the resulting formula into the other equation and see what you get.

8. ### SSWheels

17
You mis-typed the volume equation. It should read $V = \pi r^2h$

Well, you have 2 equations with 2 unknowns, $r$ & $h$ (height).
So, rearrange (solve) one equation in terms of one variable and substitute in the other equation.
That will give you 1 equation with 1 unknown, which can then be solved.

I found it easiest to solve the volume equation in terms of $h$ (solving in terms of $r$ would result in a square root, which would make things messier).

So, $h = \frac{V}{\pi r^2}$

Substitute this into the Area equation:
$$A=(2\pi r^2)+(2\pi rh)\\ A=(2\pi r^2)+(2\pi r\cdot\frac{V}{\pi r^2})\\ A=(2\pi r^2)+(\frac{2V}{r})$$
Then, solve for $r$

This will result in a cubic equation that will yield 3 real numbers as possibilities for $r$, however one of those real numbers will be negative. Since we can't have a negative radius, that leaves 2 possibilities for $r$.

1 person likes this.
9. ### wolf1728

10
Thanks SSWheels !!
I'll see what I can set up in that cylinder calculator I wrote.