<!--
SPDX-License-Identifier: LicenseRef-PD-hp OR CC0-1.0 OR 0BSD OR MIT-0 OR MIT
-->

This is a project to develop a 3d printable storage unit for storing different
types of cards in separate boxes attached to each other in a circular
configuration. Different size boxes are allowed. It is planned to be
easily configurable for different games.

There is a minimum of three boxes and the size of the front of one box can 
not be bigger than the total size of all the other boxes, or else they can't
be arranged in a circle.

The plan is to set up the boxes so there inside facing sides are chords
of a circle and touch those of the neighboring boxes. This forms a
cyclic polygon which will have the maximum area for a given list of
side lengths. Closed forms calculations for this quickly become
intractable, so numerical calculations need to be used instead. There
are three cases depending on whether the center of the circumscribed
circle is inside, on the border or outside of the cyclic polygon and the 
calculation method needs to be tweaked for each case.

I'm using Halley's irrational method to iterate to the circumradius.

The boxes are held together interally be their base, so the base will need
some real thickness. This is so there can be a gap for extracting cards
easily. Externally there will be a curved connection between the sides
of adjacent boxes, the height of the lower box. This will also need some
real thickness to hold things together.

The default box settings will probably end up being what I use for
Dragons Down, since that use is what inspired this project.

The source is for use with Openscad, which can output an stl file to be used 
by a slicer to produce gcode for a 3d printer.

For example:
`openscad -o card-storer.stl card-storer.scad`

You can also get a 2d preview, using for example:
`openscad -o card-storer.png card-storer.scad`

I split the Dragons Down boxes into two rings. To render the second ring use:
`openscad -Ddd=2 -o card-storer.stl card-storer.scad`

Note that radius.pl was used only for development (testing the approach
to calculate he circumradius) and is not used to build any artifacts.
