Date: Tue, 14 Nov 95 13:03:20 CST From: rusin (Dave Rusin) To: darylb@bnr.ca Subject: Re: Dividing Ellipse (a real life problem) Newsgroups: sci.math In article you write: >I am attempting to make elliptical gears. I can turn the blanks using an >elliptical turning attachment for a lathe. This unit keeps the center of >turning a constant distance from the cutting edge (hence thats how the >ellipse is turned) by moving the rotational center back and forth in rythm >with the ellipse major/minor axis. Its the same principle as the ellipse >drawing trammel (two sliders in tracks fixed at 90 deg). I can't really picture the device, which is a pity since it sounds clever. ASCII art is out, but have you got a GIF or something? >I would like to also mount this unit in a dividing head to divide the >ellipse. > >What I'm trying to figure is how much I must rotate my blank of >eccentricity E each time if I want to divide the perimeter of an ellipse >into X number of parts. Perhaps I can help here. As part of your problem you'll need to know where on the ellipse are the points whose distance around the ellipse is 1/X-th of the total distance around. Mathematically, this is a known difficulty: there is no closed form expression which can determine the distance around the perimeter on an ellipse -- not even all the way around (that is, there is no "simple" function giving the perimeter of a non-circular ellipse). The answers are all given in terms of what are called (prepare to be shocked) "elliptic integrals". But numerically, you can find this easily enough. If the ellipse is the set of points in the plane given by (x/a)^2 + (y/b)^2=1 then the distance between two points, say both above the horizontal axis, is the line length integral L = integral( sqrt(1+(dy/dx)^2), x=x1..x2 ) described in calculus classes to give the length along any curve. In your case, dy/dx = (b/a)^2*(x/y), so that you must integrate sqrt[ 1 + (b/a)^4 * x^2/(b^2-b^2x^2/a^2) ] from one x-coordinate to the next. Computers and even scientific calculators can give you as many digits of accuracy as you require of this. If you first integrate from x1=-a to x1=+a, you'll get the length of the half-ellipse, i.e., half the perimeter. Double and divide by your X to find out what the distances between the points are supposed to be, say D. Then you need to find the points x2 where integral( sqrt(1+(dy/dx)^2), x=-a .. x2 ) comes out to D, 2D, 3D, ... (up to X/2 times D). There are more reasonable (to a mathematician) ways to do this, but for your purposes, it's probably easiest just to make a chart of lots of values of this function (for lots of x2's varying from -a to a) and just look up on the chart to find out where the x2's are which give the values D, 2D, 3D, ... If it's angles you want, you can then get them from standard trig: the angle between the lines from the center (0,0) to the two points (-a, 0) and (x2, y) is the arctangent of y/x2. (Remember, the y-coordinates can be calculated from the x2: y = b sqrt(1-(x/a)^2). ) dave ============================================================================== Date: Tue, 14 Nov 1995 22:05:00 -0500 From: "daryl (d.a.) bender" To: rusin@math.niu.edu Subject: Re: Dividing Ellipse (a real life problem) I will try to digest your reply as to whether its applicable to the turning attachment but just for the record... I have studied that elliptical turning mechanism in Fine Woodworking's Lathes and Lathe Techniques (concept hundreds of years old). It didn't make sense to me so I made it out of wood to understand it. It was then that I realized the offset part of the mechanism is meant to be stationary (not explained in the book). Then it all made sense. I put it in my lathe and set it for max offset (0.750" [you set the offset for the difference between semi-major and semi-minor axis]). The end (faceplate) was a blurr of spinning and oscillating wood. So I put a pencil tip into the "faceplate" end then shut off the lathe. Sure enough I had drawn an ellipse on the "faceplate". It really is a zowie mechanism to watch and it does work. 1) The mechanism keeps the edge of the ellipse blank at a constant distance from the cutter as it rotates. It does this by moving the "back" of the ellipse away. Draw an ellipse, hold the paper so one side of the ellipse is closer to you, pretend you are the cutter. Now rotate the drawing (ellipse) so that the distance from the leading edge to your eye remains constant. The only way you will be able to do it is to alternately move the center of the ellipse close then far from you while you are rotating. That is how the mechanism works. ********************************************************************* 2) Draw an ellipse with a major axis. Draw a circle centered within the ellipse with a radius equal to the difference between semi-major and semi-minor axis lengths. Erase the major axis outside this circle. Call the remaining line the "Slide Line". Now, a simpler way of looking at it is picture an ellipse rolling (wobbling) on a table (the table is the cutter). As you roll you also move rigid stick between the table contact point at one end keeping the other end along the "Slide Line". This other end on the "Slide Line" represents the lathe center or indexing center. With this approach you will see that the stick is not always at right angles to the table. ********************************************************************* When I tried indexing, the divisions seem closer at the tips. The finer pitch at the tips seems to be that the mechanism AT THAT POINT is changing directions as it is also revolving the blank. This is hard to explain but simply put more things go on when it is at the tips and hence more time is spent there and hence finer divisions. The sides being "straighter" move fast as they revolve. Like I said, hard to explain. It is truely a wierd mechanism. All I need is some formula to put in, say, Excel and get my sequential list of angles I'd have to rotate. If you are wondering what I'm trying to do it is to make a mechanised geocentric armillary sphere, a 13th century looking thing. The sphere is to be driven by an accurate mechanical clock. As for my sphere it represents the stars. The Sun, the Moon are on rotating arms. In the center is a fixed Earth. All is adjustable for latitude. Its all I could manage in my design and still keep a fairly open sphere look. I do try to represent these bodies with accuracy (the sun also moves according to the equation of time). If I put planets in it would have overcrowded the sphere, I think you know what that would look like. So the idea came up why not do deDondi style planetary clock faces below the sphere and have all driven by the same mechanical clock. These planetary clock faces are mechanical representations of Ptolemy's epicycle/deferent/equant theory. This is where the elliptical gears came in. Murcury for example is rotating on an epicylce which is rotating at the end of the deferent. The center Murcury's deferent is rotating about its equant while its equant is off center. The elliptical gears would be used to set up the in/out, and speed rate change of the deferent without actually being used to set the orbital period of the deferent. If you can understand that you're doing good! 8^) ============================================================================== Date: Sat, 18 Nov 1995 15:12:00 -0500 From: "daryl (d.a.) bender" To: rusin@math.niu.edu Subject: Re: Dividing Ellipse (a real life problem) Hi Dave I have looked at your response (its been extremely busy here in the last week, sorry) and except for "In your case, dy/dx = (b/a)^2*(x/y)" I can actually follow what your saying and the method looks really good. It just lacks relating the angles (at the end) to the moving center but I think this is just a "sin x" function (moves back and forth sinusoidally). All I have to do now is figure out what an integral is and how to get Excel to do it 8^) BIG THANKS Daryl ============================================================================== Date: Mon, 27 Nov 95 16:56:24 CST From: rusin (Dave Rusin) To: darylb@bnr.ca Subject: Re: Dividing Ellipse (a real life problem) >I have looked at your response (its been extremely busy here in the last >week, sorry) and except for "In your case, dy/dx = (b/a)^2*(x/y)" I can >actually follow what your saying and the method looks really good. It >just lacks relating the angles (at the end) to the moving center but I >think this is just a "sin x" function (moves back and forth >sinusoidally). All I have to do now is figure out what an integral is >and how to get Excel to do it 8^) The derivative comes from implicit differentiation (see a calc text) applied to x^2/a^2 + y^2/b^2 = 1, except that there should be a minus sign in there, which (fortunately) disappears when you square this in the arc-length integral. You could also solve the equation for y to get y=b*sqrt(1-x^2/a^2), and then differentiate directly. An integral is the subject of whole calculus courses, but for your purposes we have length-of-curve-from-(x0,y0)-to-(x1,y1) equals integral sqrt(1 + (dy/dx)^2)dx from x0 to x1. Let me just write this as [integral f(x) from x0 to x1], where in your case f(x) = sqrt(1+(b/a)^2*(x^2/(a^2-x^2))) (whew!). This thing in brackets is actually a limit but for practical purposes it means h * Sum f( x0 + n*h ) for n=1 to N where h=(x1-x0)/N and N can be any huge number. (OK, technically it's the limit of this expression as N grows without bound.) What you want is something like this (sorry, I know nothing of Excel): Fix h (say, h=0.0001) Start counter at zero starting with n=1, keep adding h*f(-a+n*h) into the counter. Stop when -a+nh > +a. The counter now holds a number (roughly) equal to the arclength L of the top half of the ellipse. To divide this into T equal parts, Fix h (say, h=0.0001) Start counter at zero starting with n=1, keep adding h*f(-a+n*h) into the counter. Stop whenever the counter passes another multiple of L/T and record the value -a+n*h just used. These numbers tell you the x-coordinates of the points on the ellipse which divide the perimeter into T equal parts. For each such x, you can compute the y coordinate as b*sqrt(1-(x/a)^2) as above. If you want the angle marked by this point, the center of the ellipse, and the horizontal axis, that angle is the arctangent of y/x. (I'm not really confident that Excel will have this function available. Possibly it has a direct conversion into polar coordinates, which is just what you would use arctan for anyway.) I mentioned your problem to my calculus class. They were delighted to know there was an application to integration (which they are just beginning). Incidentally, if you are not tied to Excel, you can get numerical integrals out of graphing calculators like the TI-82; this is what our students use. dave ============================================================================== Date: Thu, 30 Nov 1995 11:06:00 -0500 From: "daryl (d.a.) bender" To: rusin@math.niu.edu Subject: Re: Dividing Ellipse (a real life problem) Dave Sorry to get back after so long, have been offsite and sick. First I should appologize in that in fact I do know what an integral is, it was just some twisted humor on my part. Secondly it appears there is a person with Mathcad around here I just have to get my hands on a copy. I must admit as soon as I saw integration was involved I new Excel was out. I should also inform you that I will NOT be doing the dividing with the elliptical turning attachment since in explaining it to you I realized that the cutter is not always at right angles to the ellipse surface. This is a must for gear cutting. Therefore I have decided that I will follow your solution for dividing, then get the points, then figure out a schedule of cutter movements (up/down, in/out) for each CENTRAL rotation. This is OK since making a real elliptical turning attachment (not my clumbsy wood model for conceptualization) would take considerable time that could be better spent cutting gears (and integrating) 8^) I would like to thank you immensely for all your help and I'm glad this was of some use to your students. I think you should inform them that if they go on in this endevour they will in fact find out that "life is an integral" or at least all things in it can be described with one. 8^) Cheers (& BIG THANKS) Daryl