It's actually all done in MS Excel. I then take a screen capture and manipulate the image in Photoshop. The code is spaghetti and not commented (alpha version), and it's not currently working very well, but I'll gladly share it with anyone. You can find it here:
After I get the kinks out, I plan on transferring the code to VB.NET. If I ever get around to it, I'll distribute the code and executable.
To use the Excel version (Assuming you have MS Excel installed):
1) Open sheet 1, and delete all the coordinates you see.
2) For as many circles as you want to play with, put in dummy coordinates. For example, if you want to play with 5 circles, put '1' in for the x and y of all circles radius 1-5.
3) Double click on 'Draw Circles'
4) Use your mouse and drag the circles around and place anywhere you like.
5) Once you have them positioned appropriately, click on 'Save Coordinates' (or something like that)
6) Then click on 'Draw Circles' again. You may have to click it several times to get the container circle to shrink down appropriately.
That's it. Cheesy, but a fun experiment.
Since I know the coordinates of all circles, I wonder if I could imagine the points as a polygon. Not a polygon in the traditional sense, but the algorithm to find the center of a polygon (centroid) may still work. Or do you think the intersecting lines would cause the algorithm to fail?
The more I think about it, the more I think it would fail due to the vaarying radius sizes....
That is only true on smaller n's, and only if the two circles are touching. But, the circles could have any coordinates. Basically I need to find a container circle with it's center at origin, and it's radius large enough to contain all circles 1 -> n.
Yes... now you are seeing why this is tripping me up....
I am just starting to investige the wonderful world of circle packing and am trying to figure out how to find the smallest circle which will contain multiple smaller circles. The smaller circles range in radius from 1 to n. I've found a way to get real close, but no cigar. My trig skills are a bit rusty, but still intact.
I wish this forum allowed files to be uploaded so I could show an image. If anyone needs further clarification or an image, just let me know.
Thanks in advance.