[metapost] turningnumber revisited

laurent at math.toronto.edu laurent at math.toronto.edu
Tue Jul 19 08:40:53 CEST 2011




Hi all,

     Today I will provide more details on my proposed
"mathematical" calculation of the turning number of a
cyclic piecewise bezier path p : S^1 --> R^2 that lies in
the class \C++ of those paths that nowhere backtrack. Nor
stagnate -- ie they never stop for some interval of
time. Equivalently, p \in \C++ is locally injective in the
sense that there is some  small e > 0 such that, for all t
\in S^1,  the mapping p is 1-to-1 on the closed time
interval [t-e,t+e] \subset S^1. (This equivalence and
related properties seem to have come to light as part of
triangulation theory for real algebraic varieties; they are
easily proved for our paths.)

(**) WARNING.  The concrete determination of a sufficiently
small  e > 0 is still a troublesome matter (for me ;-)  ---
when certain sorts of "thorny singularity" occur. I should
return to this point --- to explain how, in many cases,
Casteljau polygons can be used to neatly determine the
needed  e > 0.


     A path p in \C++ has several types of 'times'


 (TYPE 1) "Geometrically smooth times" (= G^1 smooth) when
there is a unique oriented tangent line \tau(t) passing
through p(t).

All other times are are called *singular*; there are only
finitely many of them in S^1.  At any singular time t, it
is known that there are exactly two distinct oriented
tangent lines \tau^-(t) and \tau^+(t):

 ---  \tau^-(t) is the limit (well defined!) of \tau(t') for
t' in (t-e,t) approaching t.

 ---  \tau^+(t) is defined similarly replacing "-" by "+".

Furthermore, for sufficiently small e > 0, the path p
embeds both arcs [t-e,t] and [t,t+e] G^1 smoothly onto arcs
whose tangents at time t are \tau^-(t) and \tau^+(t)
respectively. Also, there is a modulus of G^1 continuity on
each of these intervals; it is not difficult to calculate in
terms of Casteljau polygons.

At every singular point t, there is a well-defined rotation
r = \rot(t) of R^2 fixing p(t) such that:

             \rot(t) o \tau^-(t) = \tau^+(t)

where o indicates composition of mappings.



 (TYPE 2) "Corner times" are those t when \rot(t) is
neither the identity, nor induced by the antipodal
involution fixing p(t). Note that r(t) = (identity)  means
that t is geometrically a smooth (= nonsingular) time.

 To \rot(t) we can in this case uniquely associate its
non-zero angle denoted \angle(t) in the open interval
(-180,180) --- our angle unit being the usual degree.



(TYPE 3) "Thorn times": those singular times when \rot(t)
is the antipodal involution on the set of oriented lines
through p(t).

     To each thorn time t, is attached a turning angle
\turningangle(t) of -180 or +180 degrees according as the
"tip of the thorn" lies locally on the left or on the right
of the path p as time progresses through value t. I now pause
for ample clarifications.




Consider orthogonal projection q : R^2 --> \tau^+(t). Since
t is a thorny time, \tau^-(t) = - \tau^+(t); call this
oriented line L for short.

Using a modulus of G^1 continuity for p on the interval
[t,t+e], one readily shows that, after a possible
diminution of e > 0, the image p[t,t+e] projects preserving
order onto the interval [ p(t), q p(t+e) ] of the oriented
line L. Likewise, the image p[t-e,t] projects injectively
reversing  order onto the interval [p(t), q p(t-e)] in L.

Now, re-coordinatizing R^2 so that L is the x-axis, p(t)
is the origin, and q^{-1}(p(t)) is the y-axis, the images
p[t-e,t] and p[t,t-e] are seen to be graphs of two C^1
smooth real-valued functions f^+, f^- defined respectively
on the the two intervals  q p[t,t+e] = [0, q p(t+e)]  and
 q p[t-e,t] = [0, q p(t-e)] of the positive x-axis L.
View the figure below using a constant width font.

      |                           p(t-e)
      |                            .
      |             p(t+e)       .
      |                .       .
      |              . | J   .
      |           .    | .      Here the thorn tip lies on the
      |         .      .        right side of p near p(t).
      |       .    .
      |    .   .
------o----------------o-------------------> L
    p(t)               e'             = the tangent line
                                        at time t


Let e' be  \min \{ q p(t-e), q p(t+e) \}. Write J for the
compact interval of the line q^{-1}(e') that connects
p[t-e,t] to p[t-e,t]. The topological circle:

    JJ :=  f^+ [0,e'] \cup  f^- [0,e']  \cup  J  \subset R^2

bounds a compact region between the two graphs that is
canonically homeomorphic, by h say, to the the convex
hull in R^2 of the triangle

    \Delta :=   (0,0) = p(t) -- f^+(e') -- f^-(e') -- cycle

Its connected interior includes the tip of the 'thorn'
near p(t) on either the left or the right side
of the immersion p : S^1 ---> R^2.  But which side? To
decide which, draw a short oriented linear path K that
crosses  h(\Delta - J)  \subset  p(S^1)  at a single
point and transversally, moving from left to right as we
move foreward along p. If h\Delta has non-zero winding
number about the positive boundary point k of K then
define the turning angle of the thorn time singularity t
to be +180 degrees.  Otherwise define it to be -180 degrees.

     Having defined a turning angle in the interval
[-180,180] for every singular time t in S^1 of the given
cyclic piecewise bezier path p : S^1 ---> R^2 , we can give
an explicit formula for the integer turning number
\TurningNumber(p):

360 * \TurningNumber(p) :=
     (The Total curvature in degrees of p outside of
     the finitely many singular times.)
    +
     (The sum over all singular times t of the turning
     angle in [-180,180] at time t.)


     I have not yet mentioned a famous property of turning
number for all topological immersions p : S^1 --> R^2: Tt
classifies such an immersion up to topological regular
homootopy.

     S. Smale first became famous for having proved that this
classification does NOT generalize naively to dimension 3 since one
can turn the standard 2-sphere inside out under a
suitable smooth regular homotopy. One says that S^2 can be
smoothly "everted" in R^3.  But S^1 cannot be everted in R^2 because of
properties the of turning number that I have already mentioned
(and follow from the above formula). Smale's thesis also proved a
*correct* generalization.

Cheers

Laurent S.




More information about the metapost mailing list