I have a list of arbitrary spheres, what I want to end up with is that list separated into a number of groups, where spheres in each group all fit into thier specific larger sphere. The limitation is, the radius of the larger spheres cannot exceed the maximum specified radius.
I can think of a brute force algorithm: loop the list, start building a larger sphere untill it reaches the maxumum radius, check if there are nearer spheres with smaller radiuses that can create a better large sphere, etc. But I need an efficient algorithm, so I wonder if it's a standard problem and has a standard solution I can read about?
P.S. I forgot to mention: spheres are not physical objects, they are abstract concepts with fixed position and radius, but they can be located inside one another or intersect one another.