Beruflich Dokumente
Kultur Dokumente
Pythagorean-
including algorithms for their construction and examples of their practical applications.
Special features include an emphasis on the interplay of ideas from algebra and geometry
and their historical origins, detailed algorithm descriptions, and many figures and worked
Pythagorean-Hodograph Curves
examples. The book may appeal, in whole or in part, to mathematicians, computer scientists,
and engineers.
Rida T. Farouki
Hodograph Curves
Algebra and Geometry Inseparable
Department of Mechanical & Aeronautical Engineering,
University of California, Davis
ISBN 978-3-540-73397-3
R. T. Farouki and T. Sakkalis (2007), Rational space curves are not “unit speed,”
May 17, 1990 . . . . . . . . . . . . . . . May 17, 2010 Comput. Aided Geom. Design 24, 238–240
X(t) Y (t)
rational parameterization arc–length parameterization x(t) = , y(t) = with gcd(W, X, Y ) = 1 , W (t) �= constant
W (t) W (t)
� � �
+∞
f (t) f (t) �� parametric speed of curve r(ξ)
dt = 2πi residue
−∞ g(t) g(t) �t=zi
Im(zi )>0 ds
σ(ξ) = |r�(ξ)| = = derivative of arc length s w.r.t. parameter ξ
dξ
�
rational indefinite integral ⇐⇒ zero definite integral = x�2(ξ) + y �2(ξ) for plane curve
�
� � = x�2(ξ) + y �2(ξ) + z �2(ξ) for space curve
u2 − v 2 2uv
proof by contradiction: x(t) = dt , y(t) = dt
u2 + v 2 u2 + v 2 σ(ξ) ≡ 1 — i.e., s ≡ ξ — for arc-length or “natural” parameterization,
assume both rational with u(t), v(t) �≡ 0 and gcd(u, v) = 1 but impossible for any polynomial or rational curve except a straight line
choose α, β so that deg(αu + βv)2 < deg(u2 + v 2) irrational nature of σ(ξ) has unfortunate computational implications:
�
(αu + βv)2 • arc length must be computed approximately by numerical quadrature
dt = 21 (α2 − β 2) x(t) + αβ y(t) + 12 (α2 + β 2) t is rational
u2 + v 2
• unit tangent t, normal n, curvature κ, etc, not rational functions of ξ
� +∞
(αu + βv)2 [ α u(t) + β v(t) ]2
⇒ dt = 0 ⇒ ≡ 0 • offset curve rd(ξ) = r(ξ) + d n(ξ) at distance d must be approximated
−∞ u2 + v 2 u2(t) + v 2(t)
• requires approximate real-time CNC interpolator algorithms, for motion
contradicts u(t), v(t) �≡ 0 or gcd(u, v) = 1 along r(ξ) with given speed (feedrate) V = ds/dt
curves with “simple” parametric speed
c
b
Although σ(ξ) = 1 is impossible, we can gain significant
� advantages a
by considering curves for which the argument of x �2 (ξ) + y �2 (ξ) or
�
x�2(ξ) + y �2(ξ) + z �2(ξ) is a perfect square — i.e., polynomial curves
a, b, c = real numbers
whose hodograph components satisfy the Pythagorean conditions
�
choose any a, b → c = a2 + b2
x (ξ) + y (ξ) = σ (ξ)
�2 �2 2
or x (ξ) + y (ξ) + z (ξ) = σ (ξ)
�2 �2 �2 2
a, b, c = integers
for some polynomial σ(ξ). To achieve this, the Pythagorean structure 2 2
must be built into the hodograph a priori, by a suitable algebraic model. a = (u − v )w
2 2 2
a +b =c ⇐⇒ b = 2uvw
c = (u2 + v 2 )w
2 2
a(t) = [ u (t) − v (t) ] w(t)
spatial PH curves — Pythagorean structure of r�(t) achieved through 2 2 2
a (t) + b (t) ≡ c (t) ⇐⇒ b(t) = 2 u(t)v(t)w(t)
quaternion or Hopf map models c(t) = [ u2 (t) + v 2 (t) ] w(t)
K. K. Kubota, Amer. Math. Monthly 79, 503 (1972)
higher dimenions or Minkowski metric — Clifford algebra formulation
� 1
• closed-form evaluation of energy integral E = κ2 ds
hodograph 0
rational curves
• defines center–line tool path, in order to cut a desired profile
polynomial curves
• defines tolerance zone characterizing allowed variations in part shape
PH curves
• defines erosion & dilation operators in mathematical morphology,
image processing, geometrical smoothing procedures, etc.
y = x4
polynomial arc length function s(ξ) The cumulative arc length s(ξ) is then the polynomial function
� ξ n
� � �
for a planar PH curve of degree n = 2m + 1 specified by n
s(ξ) = σ(τ ) dτ = sk (1 − ξ)n−k ξ k ,
k
r�(ξ) = (x�(ξ), y �(ξ)) = (u2(ξ) − v 2(ξ), 2u(ξ)v(ξ)) where 0 k=0
m
� � � m
� � � of the curve parameter ξ, with Bernstein coefficients given by
m m
u(ξ) = uk (1 − ξ)m−k ξ k , v(ξ) = vk (1 − ξ)m−k ξ k ,
k k k−1
k=0 k=0
1�
s0 = 0 and sk = σj , k = 1, . . . , n .
n j=0
the parametric speed can be expressed in Bernstein form as
s(ξ∗) = s∗
s(ξk ) = k ∆s , k = 1, . . . , N .
(0)
With initial approximation ξk = ξk−1 + ∆s/σ(ξk−1), use Newton iteration
(r) S = 22/3
(r+1) (r) s(ξk ) ∆t = constant
ξk = ξk − (r)
, r = 0, 1, . . .
σ(ξk )
exact arc lengths uniform arc–length rendering
Values ξ1, . . . , ξN define motion at uniform speed along a curve
— simplest case of a broader class of problems addressed by
real–time interpolator algorithms for digital motion controllers.
gcd(u(t), v(t)) = 1 ⇐⇒ gcd(x�(t), y �(t)) = 1 • planar PH quintics are excellent design tools — can inflect, and match
first–order Hermite data by solving system of three quadratic equations
if deg(u(t), v(t)) = m, defines planar PH curve of odd degree n = 2m + 1
• select “good” interpolant from multiple solutions using shape measure
— arc length, absolute rotation index, elastic bending energy
planar PH condition automatically satisfied using complex polynomials
• generalizes to C 2 PH quintic splines smoothly interpolating sequence
w(t) = u(t) + i v(t) maps to r�(t) = w2(t) = u2(t) − v 2(t) + i 2 u(t)v(t) of points p0, . . . , pN — efficient complex arithmetic algorithms
• theory & algorithms for planar PH curves have attained a mature stage
→ formulation of efficient complex arithmetic algorithms
of development
for the construction and analysis of planar PH curves
curves with two-sided rational offsets
W. Lü (1995), Offset-rational parametric plane curves, Comput. Aided Geom. Design 12, 601–616 offset is algebraic curve of degree 6 with implicit equation
R. Dietz, J. Hoschek, and B. Jüttler, An algebraic approach to curves and surfaces on the sphere
h(t) = 1 and w(t) = 1 → parabola and on other quadrics, Computer Aided Geometric Design 10, 211–229 (1993)
H. I. Choi, D. S. Lee, and H. P. Moon, Clifford algebra, spin representation, and rational
h(t) linear and w(t) = 1 → cuspidal cubic parameterization of curves and surfaces, Advances in Computational Mathematics 17, 5-48 (2002)
k = 0 and h(t) = 1 → regular PH curve
x�(t) = u2(t) + v 2(t) − p2(t) − q 2(t)
�
y (t) = 2 [ u(t)q(t) + v(t)p(t) ]
x�2(t) + y �2(t) + z �2(t) = σ 2(t) ⇐⇒
z �(t) = 2 [ v(t)q(t) − u(t)p(t) ]
describes all polynomial curves with rational offsets
σ(t) = u2(t) + v 2(t) + p2(t) + q 2(t)
spatial PH curves — quaternion & Hopf map models summary of spatial PH curve properties
quaternion model (H → R3) A(t) = u(t) + v(t) i + p(t) j + q(t) k • all spatial PH cubics are helical curves — satisfy a · t = cos α
(where a = axis of helix, α = pitch angle) and κ/τ = constant
→ r�(t) = A(t) i A∗(t) = [ u2(t) + v 2(t) − p2(t) − q 2(t) ] i
• spatial PH cubics characterized by intuitive geometrical constraints
+ 2 [ u(t)q(t) + v(t)p(t) ] j + 2 [ v(t)q(t) − u(t)p(t) ] k on Bézier control polygons
→ (x�(t), y �(t), z �(t)) = (|α(t)|2 − |β(t)|2, 2 Re(α(t)β(t)), 2 Im(α(t)β(t))) • optimal choice of free parameters is a rather subtle problem
— one parameter controls curve shape, the other total arc length
equivalence — identify “i” with “i” and set A(t) = α(t) + k β(t) • generalization to spatial C 2 PH quintic splines is problematic
— too many free parameters!
both forms invariant under general spatial rotation by θ about axis n • many interesting subspecies — helical polynomial curves,
“double” PH curves, rational rotation-minimizing frame curves, etc.
all helical polynomial curves are PH curves (implied by a · t = cos α) useful in spatial motion planning and rigid–body orientation control
all spatial PH cubics are helical, but not all PH curves of degree ≥ 5
Frenet
all helical polynomial curves are DPH — not just PH — curves
all DPH quintics are helical, but not all DPH curves of degree ≥ 7
� �
rational Pythagorean-hodograph curves X(t) Y (t)
rational unit normal to planar curve r(t) = ,
W (t) W (t)
J. C. Fiorot and T. Gensane (1994), Characterizations of the set of rational parametric curves with rational
offsets, in Curves and Surfaces in Geometric Design AK Peters, 153–160 2a(t)b(t) a2(t) − b2(t)
nx(t) = , ny (t) =
H. Pottmann (1995), Rational curves and surfaces with rational offsets, Comput. Aided Geom. Design a2(t)
+ b2(t) a2(t) + b2(t)
12, 175–192
• employs dual representation — plane curve regarded as envelope equation of tangent line at point (x, y) on rational curve
of tangent lines, rather than point locus
f (t)
�(x, y, t) = nx(t) x + ny (t) y − = 0
• offsets to a rational PH curve are of the same degree as that curve g(t)
dual representation in line coordinates K(t), L(t), M (t) is simpler medial axis transform of planar domain
line coordinates are given in terms a(t), b(t) and f (t), g(t) by
H. P. Moon (1999), Minkowski Pythagorean hodographs, Comput. Aided Geom. Design 16, 739–753 x�2(t) + y �2(t) − r�2(t) = σ 2(t)
(x(t), y(t), r(t)) = medial axis transform (MAT) of planar domain D — this is a Pythagorean condition in the Minkowski space R(2,1)
characterizes domain D as union of one-parameter family metric of Minkowski space R(2,1) has signature + + − rather
of circular disks C(t) with centers (x(t), y(t)) and radii r(t) than usual signature + + + for metric of Euclidean space R3
distance between circles (x1, y1, r1) and (x2, y2, r2) as points in R(2,1)
r y
d2 = (x2 − x1)2 + (y2 − y1)2 − (r2 − r1)2
d=0
d imaginary
closure
• motivation for Hermite & spline interpolation algorithms • only cubic PH curves characterizable by simple constraints
on Bézier control polygons
• planar PH quintic Hermite interpolants (four solutions)
• planar PH cubics = Tschirnhausen’s cubic,
• computing absolute rotation index & elastic bending energy spatial PH cubics = { helical cubic space curves }
— too limited for general free–form design applications
• a priori identification of “good” Hermite interpolant
• construct quintic PH curves “geometrically” by interpolation
• planar C 2 PH quintic splines — numerical methods
of discrete data — points, tangents, etc.
• spatial PH quintic Hermite interpolants (2 free parameters)
• non–linear interpolation equations made tractable by
• spatial PH quintics — taxonomy of special types complex number model for planar PH curves, and
quaternion or Hopf map model for spatial PH curves
• spatial C 2 PH quintic splines — residual freedoms
• efficient algorithms allow interactive design of PH curves
Pythagorean triples of polynomials planar PH quintic Hermite interpolants
r�(t) = k [ (t − a)(t − b) ]2
solve for k, a, b instead of w0, w1, w2
locations of a, b relative to [ 0, 1 ] gives Rabs : Computation of absolute rotation index Rabs from locations of the complex
hodograph roots a, b relative to t ∈ [ 0, 1 ]. The best interpolant arises
∠ 0a1 + ∠ 0b1 when a, b lie on opposite sides of (and are not close to) this interval.
Rabs = (no inflections)
π
N
1 �
Rabs = | ∠ tk a tk+1 − ∠ tk b tk+1 |
π
k=0
choosing the “good” interpolant — bending energy compare PH quintic & “ordinary” cubic interpolants
� �
|r� × r��|2
U = κ2 ds = dt
σ5
use complex form r�(t) = w2(t) with w(t) = k(t − a)(t − b) again
a1, b1, a2, b2, a3, b3 = coefficients in partial fraction expansion of integrand C 2 spatial Hermite interpolants:
B. Jüttler, C 2 Hermite interpolation by Pythagorean hodograph curves of degree seven,
total bending energy of PH quintic E = U (1) − U (0) Mathematics of Computation 70, 1089–1111 (2001)
monotone–curvature PH quintic segments a priori identification of “good” interpolant
D. J. Walton and D. S. Meek, A Pythagorean–hodograph quintic spiral, Computer Aided Design H. P. Moon, R. T. Farouki, and H. I. Choi, Construction and shape analysis of PH quintic Hermite
28, 943–950 (1996) interpolants, Computer Aided Geometric Design 18, 93–115 (2001)
R. T. Farouki, Pythagorean–hodograph quintic transition curves of monotone curvature, H. I. Choi, R. T. Farouki, S. H. Kwon, and H. P. Moon, Topological criterion for selection of quintic
Computer Aided Design 29, 601–606 (1997) Pythagorean–hodograph Hermite interpolants, Computer Aided Geometric Design 25, 411–433 (2008)
• both require specification of end conditions to complete the equations using complex representation of planar PH quintics, write hodograph of
segment ri(t) between pi−1 and pi, as square of a complex quadratic:
• equations for “ordinary” cubic splines arise from C 2 continuity condition
at each interior node, while equations for PH quintic splines arise from r�i(t) = [ 21 (zi−1 + zi)(1 − t)2 + zi 2(1 − t)t + 12 (zi + zi+1)t2 ]2
interpolating consecutive points pi, pi+1
• “ordinary” cubic splines incur linear equations in real variables, but ⇒ ri(t) and ri+1(t) automatically satisfy C 1 and C 2 conditions at their
PH quintic splines incur quadratic equations in complex variables juncture pi = ri(1) = ri+1(0) — namely,
• coordinate components of “ordinary” cubic splines weakly coupled
r�i(1) = r�i+1(0) = 14 (zi + zi+1)2, r��i (1) = r��i+1(0) = (zi+1 − zi)(zi + zi+1)
through nodal parameter values; components of PH quintic splines
strongly coupled through PH property
writing ∆pi = pi − pi−1, the end–point interpolation condition
• linearity of “ordinary” cubic splines ⇒ unique interpolant and
� 1
spline basis methods, but non–linear nature of PH quintic splines
r�i(t) dt = ∆pi
⇒ multiplicity of solutions and no linear superposition 0
yields for i = 1, . . . , N the equations solution method #1 — homotopy scheme
fi(z1, . . . , zN ) = 3 z2i−1 + 27 z2i + 3 z2i+1 + zi−1zi+1 G. Albrecht and R. T. Farouki, Construction of C 2 Pythagorean–hodograph interpolating splines by
the homotopy method , Advances in Computational Mathematics 5, 417–442 (1996)
+ 13 zi−1zi + 13 zizi+1 − 60 ∆pi = 0
in the N complex variables z1, . . . zN . First & last equations modified using the non–linear system to be solved: fi(z1, . . . , zN ) = 0 , 1 ≤ i ≤ N
chosen end conditions to avoid reference to undefined variables z0, zN +1.
“initial” system with known solutions: gi(z1, . . . , zN ) = 0 , 1 ≤ i ≤ N
possible choices for end conditions
600
500
trace from λ = 0 to 1 loci defined by hi(z1, . . . , zN , λ) = 0, 1 ≤ i ≤ N
400
∂hi 300
tridiagonal Jacobian matrix: Mij = , 1 ≤ i, j ≤ N 200
∂zj
100
0
predictor step : motion along tangent directions to solution loci 0.0 0.2 0.4 0.6 0.8 1.0
λ
N
�
Mij ∆zj = (eiφ gi − fi) ∆λ , i = 1, . . . , N typical behavior of �f �2, �g�2, �h�2 norms in predictor–corrector scheme
j=1
N
� • better shape (curvature distribution) than “ordinary” C 2 cubic spline
(r) (r)
until | hi(z1 , . . . , zN , λ + ∆λ) |2 ≤ �2
i=1 • becomes computationally very expensive for large N
complete set of PH quintic spline interpolants comparison of PH quintic & “ordinary” cubic splines
20
16
12
κ 8
solution method #2 — Newton-Raphson iteration writing z = (z1, . . . , zN )T and f = (f1, . . . , fN )T , the Newton–Raphson
iterations may be expressed as
R. T. Farouki, B. K. Kuspa, C. Manni, and A. Sestini, Efficient solution of the complex quadratic
tridiagonal system for C 2 PH quintic splines, Numerical Algorithms 27, 35–60 (2001) z(r+1) = z(r) + δz(r) , r = 0, 1, 2, . . .
(r) (r)
in applications, we want to compute only the “good” PH quintic spline where δz(r) = (δz1 , . . . , δzN )T is the solution of the linear system
critical to successful Kanotorovich test & rapid convergence of iterations tridiagonal equations for NR increments δz(r) — O(N ) solution cost —
and quadratic convergence of the NR iterations =⇒ extremely efficient
construction of large–N PH quintic splines
strategy: equate mid–point derivatives of PH quintic spline to (known)
mid–point derivatives of “ordinary” cubic spline that interpolates the same
data points p0, . . . , pN
shape N +1 homotopy method Newton–Raphson
kidney 10 8.09 sec 0.11 sec
yields a tridiagonal linear system for starting values z1, . . . , zN
squiggly 15 656.21 sec 0.12 sec
� quirky 19 1128.97 sec 0.23 sec
zi−1 + 6zi + zi+1 = 4 6∆pi − (di−1 + di) , i = 1, . . . , N
big open 35 0.40 sec
big closed 38 0.43 sec
where d0, . . . , dN are the nodal derivatives of the “ordinary” cubic spline,
and equations i = 1 and i = N are adjusted for the chosen end conditions Timing comparisons for C 2 PH quintic spline test curves
F. Pelosi, M. L. Sampoli, R. T. Farouki, and C. Manni, A control polygon scheme for design of planar
C 2 PH quintic spline curves, Computer Aided Geometric Design 24, 28–52 (2007)
linear precision & local modification capability possible with double knots
H. I. Choi, D. S. Lee, and H. P. Moon, Clifford algebra, spin representation, and rational
+ (aby + bay + az bx − axbz ) j
parameterization of curves and surfaces, Advances in Computational Mathematics 17, 5-48 (2002) + (abz + baz + axby − ay bx) k
modulus : |A |2 = A∗A = AA∗ = a2 + |a|2 here v is short-hand for a “pure vector” quaternion V = (0, v)
note that |A B | = |A | |B| and (A B)∗ = B ∗A∗ unit quaternions U form a (non-commutative) group under multiplication
i + v̂
where exp(φ i) = cos φ + sin φ i and n = = bisector of i, v̂
| i + v̂ |
spatial PH quintic Hermite interpolants examples of spatial PH quintic Hermite interpolants
all spatial PH cubics are helical, but not all PH curves of degree ≥ 5
components of both r�(t) & r�(t) × r��(t) satisfy Pythagorean conditions RMF
DPH curves have rational Frenet frames (t, n, b) and curvatures κ Frenet
all DPH quintics are helical, but not all DPH curves of degree ≥ 7
R. T. Farouki, C. Giannelli, C. Manni, A. Sestini (2010), Design of rational rotation–minimizing rigid body
motions by Hermite interpolation, Math. Comp., submitted • quaternion and Hopf map models for spatial C 2 PH quintic spline
curves interpolating sequence of points p0, . . . , pN ∈ R3 both incur
one residual freedom per spline segment
• interpolate end points pi, pf and frames (ti, ui, vi) and (tf , uf , vf ) by
PH quintic r(ξ) with rational rotation-minimizing frame (t(ξ), u(ξ), v(ξ))
• shape of spline interpolant sensitive to choice of free parameters
• RRMF condition for spatial PH quintics: A1 i A∗1 = A0 i A∗2 + A2 i A∗0
• early study — fix freedoms using “quaternion matching” condition
• satisfying RRMF condition & end frame interpolation always possible
• optimize shape measure — e.g., proximity to a single PH cubic —
— end point interpolation requires positive root of degree 6 equation
to provide control-polygon-based design scheme
• diverse applications — to robotics, animation, spatial path planning,
• specify arc lengths of spline segments as multiples of chord lengths,
geometric sweeping operations, etc.
∆sk = γk | pk − pk−1| — for γ1 = · · · = γN (= γ, say) we can use γ
as a single tension parameter to alter interpolant shape
closure
• for planar PH curves, efficient & robust Hermite and spline interpolation Rida T. Farouki
algorithms are available for practical use
Department of Mechanical & Aeronautical Engineering,
• for spatial PH curves, basic Hermite interpolation algorithm available University of California, Davis
with methods for “optimal” selection of two free parameters
• rotation-minimizing frames (RMFs) on space curves • an adapted frame (e1, e2, e3) on a space curve r(ξ) is a system of
three orthonormal vectors, such that e1 = r�/|r�| is the curve tangent
• applications of RMFs — “defects” of the Frenet frame and (e2, e3) span the curve normal plane at each point
• RMFs for spatial Pythagorean–hodograph (PH) curves • on any given space curve, there are infinitely many adapted frames
— the Frenet frame is perhaps the most familiar
• characterization of PH curves with exact rational RMFs R. L. Bishop (1975), There is more than one way to frame a curve, Amer. Math. Monthly 82, 246–251
• a “philosophical” interlude — theory versus practice • for a rotation–minimizing frame (RMF), the normal–plane vectors
(e2, e3) exhibit no instantaneous rotation about e1
• directed frames — camera orientation control F. Klok (1986), Two moving coordinate frames for sweeping along a 3D trajectory,
computation of rotation-minimizing directed frames Comput. Aided Geom. Design 3, 217–229
• polar differential geometry — anti-hodograph, • angular orientation of RMF relative to Frenet frame = integral of
Frenet directed frame, polar curvature and torsion curve torsion w.r.t. arc length ( ⇒ one–parameter family of RMFs)
H. Guggenheimer (1989), Computing frames along a trajectory,
• conclusions and practical advice on standard answers Comput. Aided Geom. Design 6, 77–78
to questions asked at conferences
• “implicit” algebraic condition for rational RMFs on spatial PH curves
— no rational RMFs for non–degenerate cubics
• spatial PH curves admit exact evaluation of torsion integral, C. Y. Han (2008), Nonexistence of rational rotation–minimizing frames on cubic curves,
Comput. Aided Geom. Design 25, 298–304
but expression for RMF contains transcendental terms
R. T. Farouki (2002), Exact rotation–minimizing frames for spatial Pythagorean–hodograph curves,
Graphical Models 64, 382–395 • sufficient–and–necessary conditions on Hopf map coefficients of
spatial PH quintics for rational RMF
R. T. Farouki, C. Giannelli, C. Manni, A. Sestini (2009), Quintic space curves with rational
• piecewise–rational RMF approximation on polynomial & rational curves rotation–minimizing frames, Comput. Aided Geom. Design 26, 580–592
B. Jüttler and C. Mäurer (1999), Rational approximation of rotation minimizing frames using
Pythagorean–hodograph cubics, J. Geom. Graphics 3, 141–159
R. T. Farouki and C. Y. Han (2003), Rational approximation schemes for rotation–minimizing frames
• simplified (quadratic) RRMF conditions for quaternion and Hopf map
on Pythagorean–hodograph curves, Comput. Aided Geom. Design 20, 435–454 representations of spatial PH quintics
R. T. Farouki (2010), Quaternion and Hopf map characterizations for the existence of rational
rotation–minimizing frames on quintic space curves, Adv. Comp. Math., to appear
• Euler–Rodrigues frame (ERF) is better reference than Frenet frame
for identifying curves with rational RMFs (RRMF curves)
• general RRMF conditions for spatial PH curves of any degree
H. I. Choi and C. Y. Han (2002), Euler–Rodrigues frames on spatial Pythagorean–hodograph curves,
R. T. Farouki and T. Sakkalis (2010), Rational rotation–minimizing frames on polynomial
Comput. Aided Geom. Design 19, 603–620
space curves of arbitrary degree, J. Symb. Comp., to appear
ERF = rational adapted frame defined on spatial PH curves that is
non–singular at inflection points • spatial motion design by RRMF quintic Hermite interpolation
R. T. Farouki, C. Giannelli, C. Manni, A. Sestini (2010), Design of rational rotation–minimizing
rigid body motions by Hermite interpolation, Math. Comp., submitted
elementary differential geometry of space curves variation of frame (t(ξ), n(ξ), b(ξ)) along curve r(ξ)
specified in terms of parametric speed, curvature, torsion functions
Frenet frame (t(ξ), n(ξ), b(ξ)) on space curve r(ξ) defined by
| r� × r��| (r� × r��) · r���
r� r� × r�� r� × r�� σ = |r�| , κ = , τ =
t = � , n = � × t, b = � |r�|3 | r� × r��|2
|r | |r × r��| |r × r��|
by Frenet–Serret equations
z
t� 0 κ 0 t
n� = σ −κ 0 τ n
b� 0 −τ 0 b
Darboux vector d = κ b + τ t = Frenet frame rotation rate → rotation–minimizing frame much better than Frenet frame for
applications in animation, path planning, swept surface constructions, etc.
component τ t describes instantaneous rotation in normal plane
(unnecessary for “smoothly varying” adapted orthonormal frame) among all adapted frames on a space curve, the RMF identifies
least elastic energy associated with twisting (as distinct from bending)
0
0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 ERF is not intrinsic (depends on chosen basis (i, j, k) for R3)
t
— but is inherently rational and non–singular at inflection points
compared with the rotation-minimizing frame (t, u, v), the Frenet frame
(t, n, b) exhibits a lot of “unnecessary” rotation (in the curve normal plane) RMF vectors (u, v) must be obtainable from ERF vectors (p, q)
through rational rotation in curve normal plane at each point of r(ξ)
seek rational rotation ERF → RMF “implicit” algebraic condition for RRMF curves
Farouki, Giannelli, Manni, Sestini (2009): use Hopf map form with Proposition 1. A PH quintic has a rational rotation–minimizing frame if
and only if the coefficients α0, α1, α2 and β 0, β 1, β 2 of the two quadratic
α(t) = α0 (1 − t)2 + α1 2(1 − t)t + α2 t2 , complex polynomials α(t) and β(t) satisfy the constraints
β(t) = β 0 (1 − t)2 + β 1 2(1 − t)t + β 2 t2 .
(|α0|2 + |β 0|2) |α1α2 + β 1β 2|2 = (|α2|2 + |β 2|2) |α0α1 + β 0β 1|2 ,
defines RRMF quintic ⇐⇒ w0, w1, w2 ∈ C, γ ∈ R exist such that
(|α0|2 + |β 0|2) (α0β 2 − α2β 0) = 2 (α0α1 + β 0β 1)(α0β 1 − α1β 0) .
|α0|2 + |β 0|2 = γ |w0|2 ,
α0α1 + β 0β 1 = γ w0w1 ,
α0α2 + β 0β 2 + 2 (|α1|2 + |β 1|2) = γ (w0w2 + 2 |w1|2) , one real + one complex constraint on α0, α1, α2 and β 0, β 1, β 2
α1α2 + β 1β 2 = γ w1w2 , ⇒ RRMF quintics have three less freedoms than general PH quintics
|α2|2 + |β 2|2 = γ |w2|2 .
Algorithm to construct RRMF quintics: freely choose α0, α2 and β 0, β 2
NOTE: can take w0 = 1 without loss of generality & obtain α1, β 1 in terms of one free parameter, from RRMF constraints
RMF
ERF
3
angular speed ω
2
ERF RMF
1
0
0.0 0.2 0.4 0.6 0.8 1.0
Frenet
t
• constraints are of rather high degree — 4 and 6 Proposition 2. A spatial PH quintic defined by the quaternion polynomial
A0(1 − ξ)2 + A12(1 − ξ)ξ + A2 ξ 2 has a rational RMF if and only if
• not invariant when “0” and “2” subscripts swapped
A0 i A∗2 + A2 i A∗0 = 2 A1 i A∗1 .
(corresponds to the re–parameterization t → 1 − t)
problem revisited in Farouki (2010), to appear Re(α0α2 − β 0β 2) = |α1|2 − |β 1|2 , α0β 2 + α2β 0 = 2 α1β 1 .
• to avoid asymmetry, do not assume w0 = 1 • new conditions are only quadratic in coefficients
• consider PH quintics in canonical form with r�(0) = (1, 0, 0) • easy transformation quaternion � Hopf map forms
• strategic switching between quaternion & Hopf map forms • obvious invariance on swapping “0” and “2” subscripts
RRMF quintics constructed from new conditions rational RMFs on space curves of any degree
RMF R. T. Farouki and T. Sakkalis (2010), Rational rotation–minimizing frames on polynomial space curves
of arbitrary degree, Journal of Symbolic Computation, to appear
ERF
Frenet
Proposition 4. For A(t) = u(t) + v(t) i + p(t) j + q(t) k, the condition
RMF can be satisfied if and only if a polynomial h(t) exists, such that
ERF
Frenet
(uv � − u�v − pq � + p�q)2 + (uq � − u�q − vp� + v �p)2 = h(u2 + v 2 + p2 + q 2) .
adapted & directed frames on space curve r(ξ) rotation-minimizing directed frames — applications
R. T. Farouki and C. Giannelli (2009), Spatial camera orientation control by rotation–minimizing directed
frames, Computer Animation and Virtual Worlds 20, 457–472
• adapted frame (e1, e2, e3) ⇒ e1 is the unit curve tangent, t = r�/|r�|
• infinitely many choices of normal plane vectors e2, e3 orthogonal to t • camera orientation planning for cinematography,
video inspection, computer games, virtual reality, etc.
• angular velocity ω of rotation-minimizing adapted frame (e1, e2, e3)
is characterized by ω · t ≡ 0
• minimize surgeon disorientation in endoscopic surgery
�
properties of “anti-hodograph” — s(ξ) = r(ξ) dξ polar differential geometry of space curve r(ξ)
• curve hodographs (derivatives) r�(ξ) are widely used in CAGD | r × r� | (r × r�) · r��
ρ = |r|, λ = , υ =
| r |3 | r × r� |2
�
• anti-derivative of function f (ξ) is indefinite integral, s(ξ) = f (ξ) dξ
polar distance, polar curvature, polar torsion of r(ξ)
�
• infinitely many anti-hodographs — just translates of each other = parametric speed, curvature, torsion of anti-hodograph, s(ξ) = r(ξ)
• s(ξ∗) is a cusp of anti-hodograph ⇒ r(ξ) traverses origin at ξ = ξ∗ • polar curvature λ(ξ) ≡ 0 ⇐⇒ r(ξ) = line through origin
• s(ξ∗) is an inflection of anti-hodograph ⇒ tangent line to r(ξ) • polar torsion υ(ξ) ≡ 0 ⇐⇒ r(ξ) = in plane through origin
goes through origin for ξ = ξ∗
• hence, λ(ξ) ≡ 0 ⇒ κ(ξ) ≡ 0 and υ(ξ) ≡ 0 ⇒ τ (ξ) ≡ 0
• polynomial curve ⇐⇒ polynomial anti-hodograph, but this
correspondence does not extend to rational anti-hodographs • λ = 0 identifies polar inflection — r and r� linearly dependent
(integral of rational function may incur transcendental terms)
λ(ξ)
• polar helix = constant ⇐⇒ r(ξ) = on cone with apex at origin
υ(ξ)
Frenet-Serret equations for directed frame (o, u, v) corresponding properties of the Frenet
adapted and directed frames on space curves
o� 0 λ 0 o
u = ρ −λ 0
�
υ u Frenet adapted frame Frenet directed frame
v� 0 −υ 0 v
tangent vector t polar vector o
principal normal n principal axis u
polar distance, polar curvature, polar torsion of r(ξ)
binormal vector b bi-axis vector v
| r × r� | (r × r�) · r��
ρ = |r|, λ = , υ = normal plane = span(n, b) image plane = span(u, v)
| r |3 | r × r� |2
osculating plane = span(t, n) motion plane = span(o, u)
rectifying plane = span(b, t) orthogonal plane = span(v, o)
arc-length derivatives of (o, u, v)
parametric speed σ polar distance ρ
do du dv curvature κ polar curvature λ
= e × o, = e × u, = e×v.
ds ds ds torsion τ polar torsion υ
ρ
polar Darboux vector e =
(λ v + υ o)
σ each property of the Frenet directed frame of r(ξ) coincides
ρ� 2 with the corresponding property of the Frenet
� adapted frame
angular velocity of directed frame ω = | e | = λ + υ2 of its anti-hodograph, s(ξ) = r(ξ) dξ
σ
connection between Frenet adapted & directed frames computation of rotation-minimizing directed frames
(t, n, b) and (o, u, v) are both orthonormal frames for R3 let (o, p, q) be rotation-minimizing directed frame on r(ξ)
elements of matrix M ∈ SO(3) in terms of r, r�, r��, ρ = |r|, σ = |r�| : (i.e., integral of polar torsion w.r.t. anti-hodograph arc length)
| r × r� | r · r� (r × r� ) · (r� × r�� ) (r · r� ) (r × r� ) · r�� • infinitely many directed RMFs, corresponding to different integration
u·t = , u·n = , u·b = − ,
ρσ ρ σ | r × r� | | r� × r�� | ρ | r × r� | | r� × r�� | constants (maintain fixed angles relative to each other)
σ (r × r� ) · r�� (r × r� ) · (r� × r�� )
v · t = 0, v·n =
| r × r� | | r� × r�� |
, v·b =
| r × r� | | r� × r�� |
. • angle function ψ(ξ) can be determined exactly for spatial P curves
by rational function integration
example: circular camera path r(θ) = (r cos θ, r sin θ, h) directed frames on circular path, r(θ) = (r cos θ, r sin θ, h)
� r h
ρ = r r 2 + h2 , λ = , υ = 2 .
r 2 + h2 r + h2
polar distance, polar curvature, polar torsion — all constant
Left: polar vectors. Center: image-plane vectors for directed Frenet frame.
Right: image-plane vectors for the rotation-minimizing directed frame.
θ
ψ = −� .
1 + (r/h)2
RMDF orientation relative to Frenet directed frame — linear in θ
views of ellipsoid with camera image plane example: helical path r(θ) = (r cos θ, r sin θ, kθ) with c = k/r
oriented using Frenet directed frame (upper)
(cos θ, sin θ, c θ)
and rotation-minimizing directed frame (lower) o = √ ,
1 + c2θ2
√
� 1 + c2 + c2θ2 cθ
ρ = r 1 + c2θ2 , λ = , υ = .
r(1 + c2θ2)3/2 r(1 + c2 + c2θ2)
polar distance, polar curvature, polar torsion
√ √
1 + c2θ2 −1 1 1 + c2θ2 − 1
ψ = tan −1
− tan − .
c c c
RMDF orientation relative to Frenet directed frame
directed frames on helical path, r(θ) = (r cos θ, r sin θ, kθ) views of ellipsoid with camera image plane
oriented using Frenet directed frame (upper)
and rotation-minimizing directed frame (lower)
Left: polar vectors. Center: image-plane vectors for Frenet directed frame.
Right: image-plane vectors for the rotation-minimizing directed frame.
• theory, algorithms, applications for rotation-minimizing frames It is better to ask a simple question, and perhaps seem like
a fool for a moment, than to be a fool for the rest of your life.
• RRMF curves = PH curves with rational rotation–minimizing frames
old Chinese proverb
• quaternion and Hopf map characterizations of RRMF quintics
• anti-hodograph and polar differential geometry of space curves Answers to all questions will be given
exclusively in the form of Yogi Berra quotations.
some famous Yogi Berra responses
• fundamentals of CNC machines & real–time interpolators • linear x, y, z axes driven by independent DC electric motors
• experimental performance — PH curves versus G codes • sampling frequency of software controller: f = 1 − 10 kHz
→ sampling interval ∆t = 1/f = 0.1 − 1.0 millisecond
• variable feedrates for constant material removal rate
• position encoders measure actual location of each axis
• inverse dynamics problem for minimization of path error → resolution = basic length unit (BLU) = 0.01 − 0.1 mm
• basic P controller — motor current proportional to position error • zero-backlash precision ball screws
• PID controller — motor current proportional to position error, its • linear encoders, ± 0.001” accuracy
integral, and its derivative (zero steady–state error & fast response)
• MDSI OpenCNC control software
• choice of controller gains (proportionality constants) must ensure
stability of feedback control system • custom real-time interpolators
Suppose ξ(t) specifies time variation of the parameter along r(ξ) when
• computer numerical control (CNC) machine: digital control system
traversed with (constant or variable) feedrate V .
• in each sampling interval (∆t ∼ 10−3 sec) of servo system, Reference–point parameter value ξk+1 obtained from preceding value ξk
compares actual position (measured by encoders on machine axes) by Taylor–series expansion
with reference point (computed by real-time interpolator)
˙ k )∆t +
ξk+1 = ξk + ξ(t 1 ¨ k ) (∆t)2 + · · ·
ξ(t
• real-time CNC interpolator algorithm — given parametric curve r(ξ) 2
Time derivatives can be converted to parametric derivatives using For variable feedrate, must express V �, V ��, . . . in terms of derivatives
with respect to variable that V is specified as a function of
d ds dξ d V d
= =
dt dt ds dξ σ dξ time-dependent feedrate: V (t) — acceleration/deceleration rates
r� · r�� r� · r��� + |r��|2 − σ �2 curvature-dependent feedrate: V (κ) — control material removal rate
σ� = , σ �� = , etc.
σ σ � � � �2
dκ dV dκ d2κ dV dκ d2V
V� = σ , V �� = σ� + σ2 2 + σ
ds dκ ds ds dκ ds dκ2
V (κ) case requires arc–length derivatives of curvature: Pythagorean-hodograph (PH) curves
d2κ (r�� × r��� + r� × r����) · z − 3σ(2σ �2 + σσ ��)κ − 7σ 3σ �(dκ/ds) PH curves exhibit special algebraic structures in their hodographs
= .
ds2 σ5
R. Dietz, J. Hoschek, and B. Jüttler, An algebraic approach to curves and surfaces on the sphere
and on other quadrics, Computer Aided Geometric Design 10, 211–229 (1993)
H. I. Choi, D. S. Lee, and H. P. Moon, Clifford algebra, spin representation, and rational
parameterization of curves and surfaces, Advances in Computational Mathematics 17, 5-48 (2002)
planar PH curves have rational offset curves for use as tool paths spatial Pythagorean hodograph — r�(t) = (x�(t), y �(t), z �(t)) = A(t) i A∗(t)
p0
2
◦ extend to spatial C PH quintic splines — selection of many p4
4
free parameters still an open problem
100 segments
! = 0.0006
0 4 8 12 16
feedrate (ipm)
feedrate (ipm)
150 600
100 400
50 200
0 0
feedrate (ipm)
150 600
100 400
50 200
0 0
0 1 2 3 4 5 6 7 8 0 1 2 3 4 5 6 7 8 0 1 2 3 0 1 2 3
time (sec) time (sec) time (sec) time (sec)
The G code and PH curve interpolators both give excellent performance At 400 & 800 ipm, the PH curve interpolator continues to yield impeccable
(red) at 100 and 200 ipm. The “staircase” nature of the x and y feedrate performance – but the performance of the G code interpolator is severely
components (blue and green) for the G codes indicate faithful reproduction degraded by “aliasing” effects, incurred by the finite sampling frequency
of the piecewise-linear path, while the PH curve yields smooth variations. and discrete nature of the piecewise-linear path description.
repertoire of feedrate variations for PH curves constant, linear, quadratic arc length dependence
real-time CNC interpolator: given parametric curve r(ξ) and feedrate
variation V , compute reference-point parameter values ξ1, ξ2, . . . from
� ξk �
|r (ξ)| dξ
= k∆t
0 V
c
V0 δ
a
rd(ξ) d
r(ξ)
r r
b
V0
2.0 c
V0
feedrate variation V / V0
1.5
d
Volume removed (yellow area) by a cylindrical tool of radius d moving with 0.0
0.0 0.2 0.4 0.6 0.8 1.0
feedrate V0 through depth of cut δ for: a clockwise circular path of radius r 1.25
fractional arc length s / S
0.25
V0 250 Hz sampling
V (ξ) = . 0.00
1 + κ(ξ) (d − 21 δ) 4 8 12 16 20 24 28 32 36
curve arc length (mm)
40 44 48 52 56 60
800 linear 4800 X,Y = target point, F & U,V,W = variable feedrate type & parameters
feedrate (ipm)
600 3600
400 2400
N05 G05 H5 F0 U37200
200 1200
N10 G05 X1092 Y-294 A-31.026 B-38.537 C-31.481 P16.934 Q-16.436 R13.062
0 0 N15 G05 X1470 Y-1386 A-31.481 B-24.426 C-28.476 P13.062 Q42.560 R2.794
acceleration (ipm/sec)
800 cubic 4800 N20 G05 X2226 Y-294 A-28.476 B-32.526 C-36.896 P2.794 Q-36.972 R-14.887
feedrate (ipm)
600 3600 N25 G05 X3444 Y504 A-36.896 B-41.267 C-32.579 P-14.887 Q7.197 R-25.365
400 2400 N30 G05 X2226 Y1722 A-32.579 B-23.892 C8.378 P-25.365 Q-57.927 R-36.389
200 1200
N35 G05 X2100 Y504 A8.378 B40.647 C21.987 P-36.389 Q-14.851 R-28.356
0 0
N40 G05 X1134 Y252 A21.987 B3.326 C-13.761 P-28.356 Q-41.861 R-28.525
N45 G05 X756 Y1050 A-13.761 B-30.849 C-3.668 P-28.525 Q-15.189 R-32.746
acceleration (ipm/sec)
600 3600
400 2400
200 1200 R. T. Farouki, J. Manjunathaiah, G–F. Yuan, G codes for the specification of Pythagorean–hodograph
0 0 tool paths and associated feedrate functions on open–architecture CNC machines, International Journal
1.0 1.1 1.2 1.3 1.4 1.5 1.0 1.1 1.2 1.3 1.4 1.5
time (sec) time (sec)
of Machine Tools & Manufacture 39, 123–142 (1999)
machine/controller dynamics If ξ(t) specifies time variation of parameter when (X(ξ), Y (ξ)) is traversed
with (constant or variable) feedrate V , its time derivatives are
CNC machine executes actual path (x(t), y(t)) determined from
V σV � − σ �V ˙ ... σV � − 3σ �V ¨ σV �� − σ ��V ˙2
commanded path (X(t), Y (t)) by differential equations of the form ξ˙ = , ξ¨ = ξ, ξ = ξ + ξ , etc.
σ σ2 σ2 σ2
...
ax x + bx ẍ + cx ẋ + x = dx Ẍ + ex Ẋ + X , and we have
...
ay y + by ÿ + cy ẏ + y = dy Ÿ + ey Ẏ + Y ,
d d d2 d2 d d3 d3 d2 ... d
= ξ˙ , = ξ˙2 2 + ξ¨ , = ξ˙3 3 + 3 ξ˙ ξ¨ 2 + ξ , etc.
where dots indicate time derivatives, constant coefficients ax, bx, . . . dt dξ dt2 dξ dξ dt3 dξ dξ dξ
depend on the machine/controller physical parameters.
Hence transformed differential equations become
But commanded path (X(ξ), Y (ξ)) specified by general parameter ξ,
rather than time t. αx(ξ) x��� + βx(ξ) x�� + γx(ξ) x� + δx(ξ) x = λx(ξ) X �� + µx(ξ) X � + νx(ξ) X ,
Transform independent variable: time t → curve parameter ξ αy (ξ) y ��� + βy (ξ) y �� + γy (ξ) y � + δy (ξ) y = λy (ξ) Y �� + µy (ξ) Y � + νy (ξ) Y ,
Must solve initial value problem for linear ODEs in X̂(ξ), Ŷ (ξ) with known Need good numerical method to approximate solutions on ξ ∈ [ 0, 1 ] by
polynomials in ξ as coefficients and right–hand sides. polynomial or piecewise–polynomial functions:
example: quintic PH curve and P controller comparison of output for original and modified paths
Left: quintic PH curve defining desired path (X(ξ), Y (ξ)). Right: modified
path (X̂(ξ), Ŷ (ξ)) that compensates for the machine/controller dynamics,
for a P controller with gain kp = 10 and constant feedrate V = 0.12 m/s.
commanded executed commanded executed
4 0
parametric speed σ
3
–20
Comparison of commanded and executed motions for original (left) and
2
–40 modified (right) paths. In the former case, the executed motion deviates
1
–60 curvature κ
significantly from the desired path. In the latter case, the executed motion
0
0.0 0.25 0.50 0.75 1.0 0.0 0.25 0.50 0.75 1.0
is essentially indistinguishable from the original commanded path.
arc length s arc length s
0.8
0.2
original path modified path
0.6
modified path 0.0
0.2 –0.4
original path
0.0 –0.6
modified path
–0.2 –0.8
–0.4
0 1 2 3 4 5 6 7 8 9 10
–1.0
0 1 2 3 4 5 6 7 8 9 10
commanded executed commanded executed
time (sec) time (sec)
Comparison of x and y axis accelerations for original and modified paths. Commanded and executed motions for original (left) and modified (right)
The modified path incurs greater peak accelerations, requiring a higher paths, using a PI controller with gains kp = ki = 10 and constant feedrate
motor torque capacity. V = 0.12 m/s. Modified path is approximated by a degree 30 polynomial,
constructed by interpolation at the Chebyshev nodes on ξ ∈ [ 0, 1 ].
ru × rv
n = , (u, v) ∈ [ 0, 1 ] × [ 0, 1 ] .
|ru × rv |
In other words, N should be “as far as possible” from the set { n } of all
normals to the surface r(u, v).
strategy for optimal orientation N of section planes parabolic lines on free-form surfaces
Gauss map computation for free-form surfaces medial axis transform for complement of Gauss map
closure