USEFUL math this time
So suppose you were trying to make the curved-top sleeve of a 14th-15th-century shirt, smock, dress, pourpoint, etc. (And how many of my friends-list aren't doing that this week?) You've got a measurement from the top of the sleeve to the wrist, and a measurement from the armpit to the wrist, and the difference between these measurements is the height (trough to peak, i.e. twice the amplitude) of the curve. You've also got an armscye that the sleeve needs to fit into, which means the length of the curved top (after deducting seam allowances) has to match the length of the armscye (ditto). So, given the width of the fabric and the height of the curve, how long will the curved top be? Even better, given the height of the curve and the length of the armscye, how wide should the sleeve top be?
For simplicity, let's assume the curve is a sine wave. Its amplitude is h/2, and its wavelength is w (the width of the fabric). In computing the length of the curve, we don't care whether the whole thing is raised up, or lowered, or rotated, or any of that, so I'll just say
f(x) = -(h/2) cos(2 π x/w)
To find the length of a curve, you compute the definite integral of sqrt(1 + f'(x)) (check Wikipedia... yes, I remembered that formula right, yay.)
f'(x) = π h/w sin(2 π x/w)
So we need the integral of sqrt(1 + π2 (h2)/(w2) sin2(2 π x/w))
which is almost certainly non-integrable. That's what numeric methods are for. Now, I know the RIGHT ways to compute integrals numerically involve Simpson's rule and stuff like that, but I don't remember any of the details from twenty years ago, so I'll use brute force and do a Monte Carlo integration: generate a gazillion random (x,y) points in a rectangle that encloses the curve in question, and see what fraction of the points are under the curve.
Wait, that's stupid: if I'm computing f(x) anyway in order to tell whether the random (x,y) is below it, why not use the full f(x) information rather than just that one bit?
On testing, this does seem to give me more-accurate answers, slightly faster, for the same number of points.
In fact, it's a little spooky: multiple tests of the same arc-length computation give me EXACTLY the same answer, to 17 places. That can't be right... no, wait, those tests are for a triangular-topped sleeve, whose derivative takes on only two values, and they're negations of one another, so (sqrt (+ 1 (sqr (fprime x)))) is actually a constant. Try it again on a real function, like the sine curve that started this whole thing, and the answers are NOT exactly equal, just close, as one would expect. Whew!
So, I plug in h=4" and w=13" (since I happen to be holding a piece of 13"-wide linen). If the sleeve top were just angled straight lines, the answer would come out 2*sqrt(h2 + w2/4) = 15.26". With the sine curve and the Monte Carlo simulation for 100000 points, it comes out... 15.64". In other words, using a sine curve rather than straight lines makes less than a half-inch difference, which is comparable to the error in cutting and the bias stretch.
So now I know that, and next time I can just use the straight-line approximation.
For simplicity, let's assume the curve is a sine wave. Its amplitude is h/2, and its wavelength is w (the width of the fabric). In computing the length of the curve, we don't care whether the whole thing is raised up, or lowered, or rotated, or any of that, so I'll just say
f(x) = -(h/2) cos(2 π x/w)
To find the length of a curve, you compute the definite integral of sqrt(1 + f'(x)) (check Wikipedia... yes, I remembered that formula right, yay.)
f'(x) = π h/w sin(2 π x/w)
So we need the integral of sqrt(1 + π2 (h2)/(w2) sin2(2 π x/w))
which is almost certainly non-integrable. That's what numeric methods are for. Now, I know the RIGHT ways to compute integrals numerically involve Simpson's rule and stuff like that, but I don't remember any of the details from twenty years ago, so I'll use brute force and do a Monte Carlo integration: generate a gazillion random (x,y) points in a rectangle that encloses the curve in question, and see what fraction of the points are under the curve.
(define (points-below f xmin xmax ymin ymax points-left answer)
(if (<= points-left 0)
answer
(local [(define x (+ xmin (* (- xmax xmin) (random))))
(define y (+ ymin (* (- ymax ymin) (random))))]
(if (< y (f x))
(points-below f xmin xmax ymin ymax (- points-left 1) (+ 1 answer))
(points-below f xmin xmax ymin ymax (- points-left 1) answer))))
)
(define (integrate f xmin xmax ymin ymax points)
(* (- xmax xmin) (- ymax ymin) (/ (points-below f xmin xmax ymin ymax points 0) points))
)
(define (arc-length fprime xmin xmax ymax points)
(integrate (lambda (x) (sqrt (+ 1 (sqr (fprime x)))))
xmin xmax 0 (+ 1 ymax) points))
Wait, that's stupid: if I'm computing f(x) anyway in order to tell whether the random (x,y) is below it, why not use the full f(x) information rather than just that one bit?
(define (add-f-values f xmin xmax points-left answer)
(if (<= points-left 0)
answer
(local [(define x (+ xmin (* (- xmax xmin) (random))))]
(add-f-values f xmin xmax (- points-left 1) (+ (f x) answer)))))
(define (integrate f xmin xmax ymin ymax points)
(* (- xmax xmin) (/ (add-f-values f xmin xmax points 0) points)))
On testing, this does seem to give me more-accurate answers, slightly faster, for the same number of points.
In fact, it's a little spooky: multiple tests of the same arc-length computation give me EXACTLY the same answer, to 17 places. That can't be right... no, wait, those tests are for a triangular-topped sleeve, whose derivative takes on only two values, and they're negations of one another, so (sqrt (+ 1 (sqr (fprime x)))) is actually a constant. Try it again on a real function, like the sine curve that started this whole thing, and the answers are NOT exactly equal, just close, as one would expect. Whew!
So, I plug in h=4" and w=13" (since I happen to be holding a piece of 13"-wide linen). If the sleeve top were just angled straight lines, the answer would come out 2*sqrt(h2 + w2/4) = 15.26". With the sine curve and the Monte Carlo simulation for 100000 points, it comes out... 15.64". In other words, using a sine curve rather than straight lines makes less than a half-inch difference, which is comparable to the error in cutting and the bias stretch.
So now I know that, and next time I can just use the straight-line approximation.

no subject
no subject
no subject
But if the curve is too steep, I fix it and add a flare or gusset. Remember - wrinkles in the armpit are period!
no subject
no subject
no subject
I use a length of string with two knots in it. Quantitative sewing is for sissies. Also, did they even use rulers in 15th cen. tailoring?
no subject
It would have been nice to get a general formula that tells me how the fabric width, the curve height, and the seam length all co-vary. It would have been nice to solve explicitly for any one of the three in terms of the others. But that's not the cards we were dealt....
no subject
I have a textbook on flat pattern drafting that shows how to make slopers from measurements for everything except sleeves. That gets handwaved away. It recommends draping.
no subject
P.S. O.o >.< o.O >.< O.O
no subject
no subject
no subject
no subject
Bad Coppartner this time :-DP.S.
no subject
Me, the token Viking.
But when I have these kinds of problems, I usually just eyeball it, or use a string to measure. I save the higher math for food plan calculations!
no subject
no subject
What stringlady said...
Da hubby may appreciate it more...
no subject
This makes me think of the day you came over to teach me reed making. Yours were coming out best when you measured within a millimeter of life, and mine worked when I did rough measuring and then eyeballed it. (Gotta order reeds and a new kit!) I sew the same way, though it would be 16th century :-)
You do know that you bring geekdom to knew levels--and I say that with all love as a complete compliment. I mean, come on, my idea of a kickin' good time is an afternoon with a Schantz and some Duruffle or Vierne.