I had downtime at a library and looked into this a little. - Even if you don’t have a cnc sewing machine, you can do the cutting with a die cutter device like a cricut and make the sewing very easy and clear. - I websearched sewing a cap, and the example I found used four panels sewn flat with curved proportions such that they fit a head when expanded. The fabric cuts are offset from the theoretical edges to leave room for sewing. The example used whole ellipse-like segments bonded at the edges. This made a spheroid-like final result, which was inverted once to hide the sewing, then the bottom inverted again into the top to make two layers. - You could calculate the proportions of these panels for an individual head via measurement or medical imagery. I started by assuming a mathematical spheroid with two unique dimensions. - I think that panels that cover a spheroid are elliptical shapes where the height equals the height of the spheroid (possible mistake, reconsider?), and the width of each is the circumference of the spheroid divided by the number of panels. It took me a while to realize this again. - Scratch code at https://www.kaggle.com/code/superjunk/notebookfdb0c5e39b uses matplotlib to draw a parametrically-designed sewing pattern for a spheroid. The larger curve is offset to cut. The curve inside it is to fold adjacent parts and sew. It looks as if you could actually do it with only one panel if desired, unsure. - ellipse width = circumference / panel count - ellipse height = height # i think this is a mistake and instead should be the vertical arclength - ellipse-like arclengths are calculated using a function called the “incomplete elliptic integral of the second kind” or E, where if a and b are the ellipse radii in either order, then between angle a1 and a2 it’s something like arclength = b(E(a2|1-(a/b)^2)-E(a1|1-(a/b)^2)) - I didn’t readily find an inverse for E, so finding angle ranges to tesselate to a specific resolution precisely would mean new numeric solutions, but the result looks reasonable if a circle of average radius (r = (a+b)/2) is used. - it looks like a die cutter can generally both cut fabric as well as mark a pattern on it by placing a pen rather than a knife in it. most of the time was spent slowly realizing that the panels are exact ellipses maybe it was cool to realize you could sew 3d shapes flat by breaking them into convex surfaces and calculating the bounds ! you could sew any shape by doing this and stuffing it. Parametrically creating the design lets one place things at precise points on the surface later.