The reason I intended to learn Geometric Algebra was to see if it could solve this geometry problem I have. I would like to be able to parametrically draw or place curves on a sphere\'s surface with the sphere\'s center as my knife or pencil point orientation. This way if the sphere is thick shelled, I can cut curves whose sides or edges remain oriented to the center; otherwise, I would project my curve on the surface and cut straight down in plan. The edges of the thick-shell slices would all be parallel to the polar axis assuming the cut projection was made in plan. Anyone know of any way to use a vector fixed at the center and the surface (radius) of this sphere and then parametrically run a cut with these constraints? Sorry if this sounds obtuse, but I am working with tunnel vision over many hour on this. Thanks.
Well, I just thought of part of the solution. After the curve is drawn on the sphere, calculating the normal at this point and making it negative will give me a vector that points towards the sphere\'s center. Now, I just need to figure out how to draw smooth curves on the surface of the sphere to begin.
I am familiar with spherical mapping or texture mapping to a sphere. I am also familiar with the formula for splines, but I am trying to figure out an algorithmic way of making sure my spline stays constrained to a sphere of known radius.
Do what Davean said. It\'s not a matter of taste, it\'s a matter of you asking for something that physically doesn\'t exist: there is no polynomial curve with coefficients in R^n that shares more than a finite number of points with a sphere in R^n.
For the sake of an example, start with the quadratic p(t) = a t^2 + b t + c. Let\'s say at least a part of it is constrained to the unit sphere, so |a t^2 + b t + c|^2 = 1 holds for all values of t in some interval. This is a fourth degree polynomial, so there are no more than four roots, t = (+- sqrt(b^2 +- 4a - 4ac) - b) / 2a. In other words, whatever the choice of a, b and c, the best you\'re going to get for a quadratic curve is four intersections with the sphere. Generalization: an nth degree polynomial curve and a sphere share at most 2n points, since |a_n t^n + ... + a_1 t + a_0|^2 - 1 = 0 will have at most 2n real roots.
Thanks, Goltrpoat. I understand what you are saying. My maths are probably not at your level. Here\'s a paper I thought described my problem (it\'s in power point ppt format): www.cs.berkeley.edu/~sequin/TALKS/SIAM01_CSplines.ppt and here\'s a paper on cirlce blending on a sphere as well using GA: http://www.citebase.org/cgi-bin/fulltext?format=application/pdf&identifier=oai:arXiv.org:cs/0310017
I guess I am going to just project the curve from plan view and then slice it with the normal at each point to create the edge surface I need. Thanks.
The slides describe something that isn't a spline, at least not in the sense that many (most?) people are used to. That notwithstanding, the CSplines paper seems to describe the following. Take some set of control points, p_1, p_2, ..., p_n. Take the first three control points -- these uniquely define a circle, and, more specifically, a circular arc that joins p_1 and p_3 (and passes through p_2). Take the next three points, p_2 through p_4, and define a circular arc in the same manner. We now have two arcs that join p_2 and p_3, call them A_1 and A_2 -- one from the first circle, one from the second circle (the remaining adjacent points are joined by single arcs). We need to blend those into a single arc that preserves tangent vectors at p_2 and p_3 to come up with a curve containing p_1, p_2, p_3 and p_4 (and the process repeats for any number of points).
To do the blend, the paper picks n circular arcs between p_2 and p_3 (enclosed between A_1 and A_2), with equal angle increments between adjacent arcs, starts at p_2 and skips across arcs (by sampling them n times along the length, say) to give a smooth transition to p_3. This sounds dodgy at best, which I assume is why you started looking into doing this continuously. There is any number of ways to get rid of discrete sampling and write a continuous expression for the blend -- one is given in the second paper you cited, page 10. Alternatively, see the slerp article on the wiki.
In any case, the idea here seems to be that whether or not the control points are 2d (defined in a sphere parametrization) or 3d, as long as the control points are confined to a sphere, the entire curve will be confined to a sphere. To see why that's the case for 3d control points, pick a non-degenerate set of three points on a sphere and fit a plane through them. The intersection of the plane with the sphere is a circle that passes through the three points. But there's exactly one circle with that property -- so given three points on a sphere, a circle through them will be entirely on the sphere.
I still maintain that a polynomial spline with coefficients taken from any reasonable sphere parametrization will be faster to evaluate, easier to control, and you're not forced into any particular continuity class :).
-goltrpoat
EDIT: I mentioned the slerp article, but this might be misleading. The slerp is NOT applied to the endpoints directly, as this doesn't preserve tangency conditions (it'll generate the same circular arc whatever the rest of the curve looks like). One way to preserve tangency conditions is to look at the endpoint vectors as rotations about an axis -- the axis being the vector itself, and the angle being determined by the direction of the tangent.
Let the two endpoints be given (on a unit radius sphere centered at the origin), p_1 = cos(t_1) u_1 + sin(t_1) v_1 and p_2 = cos(t_2) u_2 + sin(t_2) v_2 (i.e. we know they came from a circular arc). The tangents are
d_1 = d(p_1)/dt = cos(t_1) v_1 - sin(t_1) u_1
d_2 = d(p_2)/dt = cos(t_2) v_2 - sin(t_2) u_2.
We want to interpolate between two rotations; one has the axis p_1 and zero angle, and the other has the axis p_2 and the angle between d_1 and d_2. So, set those up as two quaternions, do a slerp between them, and simplify the resulting expression. You should get a function of two endpoints and the cosine of the angle between the planes of the two circles.
WOW! Thanks. I need a little time to digest your post. I have stepped back from the GA book and purchased, "Mathematics : Its Content, Methods and Meaning". It is a single Dover publication from an original three volume set from the 1960's. Since I am self taught, it is helping understand, or fill in the holes of my informal knowledge. Back on topic: If I project a visual 2d curve onto the sphere in my cad software and generate a solid or surface, and I can get the points on the curve, could I pareametrize the data into a formula?
BTW, what is your background in understanding these issues? Also, if you have any recommendations for books that treat algebra, geometry and computer graphics for someone with a college undergraduate's understanding of mathematics, I would surely appreciate it. Thanks.
More specific? Theres a LOT of levels of college undergrade, I for example expect you to have taken some Analysis class when you say that, and probibly graph theory and a few Modern Algebra courses ...
You didn't even list if you where in a technical field.