Dimensions of cylinder of a constant surface area but changing volume

Hi there! I'm new around so please feel free to correct me on forum ettiquete here!

I am modelling a cylinder that changes volume but retains a constant surface area across a range of dimensions. With an increase in volume the cylinder decreases in length and increases in radius and vice versa for a decrease in volume.

So far:

S=2pi*r(r+h) - Surface area of a cylinder (eq1)

V=pi*r^{2}h - Volume of cylinder (eq2)

Rearanging volume for height: h=V/(pi*r^2) (eq3)

Substituting eq3 into eq1 yields:

S=2pi*r(r+V/(pi*r^{2}) = 2pi*r^{2}+2/(V*r) = 2(V*pi*r^{3}+1)/(V*r) (eq4)

After failed attempts to rearrange eq4 and solve for r, I have tried a symbolic solve with matlab but the result is incredibly messy!

Would anyone be able to offer any help as to how I may solve this problem as I expect that the method that I am trying to use is not the best for the job!

Thanks in advance!

Re: Dimensions of cylinder of a constant surface area but changing volume

Re: Dimensions of cylinder of a constant surface area but changing volume

Could you explain how these equations can help me please? I need a equation solving for *r* in terms of *V* and *S*. Again, rearrangement produces a messy result.

Thanks.

Re: Dimensions of cylinder of a constant surface area but changing volume

well ... you have the cubic equation

how are you at using the cubic formula?

Re: Dimensions of cylinder of a constant surface area but changing volume

Thats great. Thankyou for your help! Now to implement it!