How to find the minimum height and width of a cylinder containing n identical spheres?
Here is a 2012 paper whose references (and its now [Aug 2017] 26 subsequent citations) will lead you to literature on this topic:
A. Mughal, H. K. Chan, D. Weaire, and S. Hutzler. "Dense packings of spheres in cylinders: Simulations" Phys. Rev. E 85, 051305 (2012). (Journal link)