## Pattern Generator

This tool will generate a PDF file with a pattern that can be used to sew a spherical shape. Enter the radius of the sphere and the number of segments the sphere will have. Using more segments will result in a better approximation of a sphere but will also be more complex to sew

inches

## About

I created this page the second time I needed to sew a large dome covering and was unable to find a satisfactory hemisphere pattern anywhere. There were several sewing sites that had patterns however most were low quality and in specific sizes and number of slices.

Some sites tried so give DIY steps that involved lots of measurements and drafting to create the shape but could not explain the math behind so that I could automate the process

Finding the math was hard because I didn't know what I should be searching for. Finally I realized all I wanted was some equation that would tell me the distance between two longitudinal lines on a sphere. A few google searches later and I discovered the "haversine" formula. For measuring the distance between two longitudinal lines the formula simplifies a bit as the latitude is the same:

R = Radius of the sphere p = Latitude in radians d = Distance between longitudinal lines at the current latitude p d = 2 ⋅ R ⋅ atan2( √(cos²(p) ⋅ sin²(pi/12)), √(1−(cos²(p) ⋅ sin²(pi/12))) )