patternMinor
Bundle diameter calculation algorithm with different wire sizes?
Viewed 0 times
calculationbundlewithsizesalgorithmdifferentdiameterwire
Problem
I would like to ask if anyone happens to know an algorithm or idea how to implement a way to calculate the bundle diameter given a multiple wires with different sizes. Something similar to graphical solution below
Solution
Your problem is studied under the terminology of "circle packing." Specifically, packing unequal circles in a circle.
Beware that many resources that study 'circle packing' in a circle often consider just the problem of uniform-sized circles (as this problem is hard enough!) rather than your more general framework of unequal circles. See, for example, the Wikipedia page on circle packing: https://en.wikipedia.org/wiki/Circle_packing
This mostly refers to uniform circles in a circle, but it does link to a page on packing unequal spheres (which is different than just your circular cross-section).
Here is a presentation that surveys a number of algorithms/strategies for packing circles in bounded spaces: https://www.math.uwaterloo.ca/~ervrscay/talks/Jiang-AMMCS-CAIMS-2015.pdf
Here is a Python implementation of unequal circle packing in a circle: https://scipython.com/blog/packing-circles-in-a-circle/
This solution produces a set of random circles, so if you have a specific problem instance with your wire widths, you would use those as input instead of the randomly-generated circles it creates. The algorithm works by sorting the circles by their size and placing the largest circles first.
Beware that many resources that study 'circle packing' in a circle often consider just the problem of uniform-sized circles (as this problem is hard enough!) rather than your more general framework of unequal circles. See, for example, the Wikipedia page on circle packing: https://en.wikipedia.org/wiki/Circle_packing
This mostly refers to uniform circles in a circle, but it does link to a page on packing unequal spheres (which is different than just your circular cross-section).
Here is a presentation that surveys a number of algorithms/strategies for packing circles in bounded spaces: https://www.math.uwaterloo.ca/~ervrscay/talks/Jiang-AMMCS-CAIMS-2015.pdf
Here is a Python implementation of unequal circle packing in a circle: https://scipython.com/blog/packing-circles-in-a-circle/
This solution produces a set of random circles, so if you have a specific problem instance with your wire widths, you would use those as input instead of the randomly-generated circles it creates. The algorithm works by sorting the circles by their size and placing the largest circles first.
Context
StackExchange Computer Science Q#159955, answer score: 4
Revisions (0)
No revisions yet.