Singularity of Geometric Constraint System

Document Sample
Singularity of Geometric Constraint System Powered By Docstoc
					                               Singularity Analysis of Geometric Constraint System

                                   Peng Xi aobo*      Chen Li ping         Zhou Fanli    Zhou Ji
                           CAD Center, Huazhong Univ. of Sci. & Tech., Wuhan, P.R.China 430074

Abstract Singularity analysis is an important subject of geometric constraint satisfact ion problem. In this paper, three
kinds of singularity are described and corresponding identificat ion methods are presented for both under-constrained
system and over-constrained system. Another special but common singularity for under-constrained geometric system,
pseudo-singularity, is analy zed. Pseudo-singularity is caused by the variety of constraint matching for an under-constrained
system and can be removed by improving constraint distribution. To avoid pseudo-singularity and decide redundant
constraints adaptively, a d ifferentiation algorith m is proposed in the paper. Its correctness and efficiency have been
validated through practical applications in a 2D/ 3D geometric constraint solver CBA.

Keywords     Geo metric Constraint Satisfaction, Paramet ric Des ign, Singularity, Redundant Constraint

                                                                     are co mprehensively analy zed and, further, three types of
1 Instruction                                                        singularity and corresponding judging methods are
     Singularity analysis of constraint is a key technology
for Geo met ric Constraint Satisfaction Problems(GCSP).              2 Ba sic concepts
However, so far most researches and papers on GCSP have
been focused on constraint solving planning[1,2,3,4,5,6,8],                  A geometric constraint system can be described with
i.e. constraint matching, sorting, and decomposition , with          a directed graph G[4], in wh ich a directed arc a uniquely
only few papers involv ing singularity analysis . DCM                stands for a constraint c, and c matches with the head
2D/ 3D is one of the best constraint solvers in the world.           vertex of a. The process of creating a directed graph is in
But according to our experiences, definition of constraints          fact an iterat ive process of finding matching vertex for
and dimensions in DCM is affected by operation order in              every constraint. It is essentially the bipart ite matching of
under-constrained system. It seems that DCM has not                  <c ,e>, where e is geo metric element. Fo llo wing are
perfectly   resolved     the    singularity   problem     for        several important concepts used in the paper:
under-constrained system. Light[1] tried to differentiate                    Compound Vertex: In directed graph G, a strongly
the redundancy of a constraint according to the singularity          connected sub-graph can be reduced to a single vertex
of its Jacobian mat rix. Wang Bo xing[7] indicated that if           called co mpound vertex.
there is redundant constraint, the Jacobian matrix o f the                   Residual DOF(RDOF): The d ifference between the
system must be singular.                                             Degree of Freedo m(DOF) of a vertex and the number of
     Our research work is based on constraint directed               its matching constraints is called its RDOF; RDOF of a
graph. Generally, graph-based singularity analysis is fit for        compound vertex is the sum of RDOF of all the vertices in
well-constrained system and over-constrained system. In              it.     If the RDOF of a vertex is more than 0, it is free.
this paper, singularity analysis method is extended to                       Propagati on Set and Predeterminati on Set: In a
under-constrained system. The reasons leading to a                   DA G(d irected acyclic graph), the vertex set found by
singular Jacobian matrix of a geo metric constraint system           DFE(depth first ergodicity) fro m vertex v is called the
                                                                     propagation set of v. While the vertex set found by inverse
*Corresponding author.
                                                                     DFE fro m v is called its predetermination set.
 E-mail: (Peng Xiaobo); (Chen Liping);
     Transiti ve path: Constraints c 1 and c 2 correspond to                   c3 = PntOn Line(p 1 ,l3 );                c4 = PntOn Line(p 3 ,l3 );
an in-arc and an out-arc of vertex v1 respectively. The
                                                                               c5 = PntOn Line(p 2 , l2 );               c6 = PntOn Line(p 3 ,l2 );
explicit parameter sets in algebra expressions of c 1 and c 2
                                                                               c7 = DistPP(p 1 ,p 2 ,d 1 );              c8 = DistPP(p 2 ,p 3 ,d 2 );
are P 1 and P 2 respectively. If P 1 ∩P 2 ≠Ф, then c 1 and c 2 are
transitive at v1 and any change of either one will affect the                  c9 = DistPP(p 1 ,p 3 ,d 3 )
                                                                               If add a new height constraint c 10 =Height(p 2 ,l3 ,h)
other. If all the constraints along a path are transitive and
                                                                          between p 2 and l3 , c10 will cause saturated singularity.
the end vertex is free, then the path is transitive.
     The remainder of this paper is organized as fo llo ws:
Section 3 describes three types of singularity and analyzes
pseudo-singularity for under-constrained system; Section 4
advances the symbol method and the numerical method for
singularity differentiat ion. In the section, a singularity
differentiat ion algorith m is presented and some examp les
are illustrated; Section 5 gives a conclusion.

3 Singularity type s
                                                                                                     c2         c10}:0      c5         l2{c5,
     A geometric constraint system can be expressed as a                                                                               c6}:0

set of non-linear equations. Based on the algorithm for the                                                                c8

blocking triangular form of sparse matrix, many divid ing
methods[1,3,4,5,8]        were      proposed        to    decompose                        p1{c9                   c9                    ,c4}:0

                                                                                            }:1            c3
geometric constraint system so that a geometric system is                                                                l3{c3}
reduced to a set of sub-systems that can be solved orderly.
In these methods, singularity analysis of constraints is a                                                        (b)
key subject.                                                                                 Fig.1 Saturated singularity

3.1 Saturated singularity                                                 3.2 Embranchment singularity

     Chen Liping[3] p resented the concept of Saturated Set:                   According to mechanism kinemat ics, if at the t ime of
if under geometric constraint set C in which there is no                  t* there is a position q* for the system where the Jacobian
redundant constraint, relative DOF between any two                        matrix q (q*,t*) is not singular, then according to the
geometric entit ies in entity set E is zero, then E is called a           Implicit Function Theorem, for δ>0, the system has a
Saturated Set under C. A saturated set can be regarded as a               stable unique solution q(t) near q* in the period of |t-t*|<δ.
rig id body composed of its inner geometric entities.                     Solution 1 and Solution 2 in Fig.2(b ) are t wo examp les o f
     Any constraint c added into a saturated set will cause               q*. On the other hand, if there exists locking or
a singular Jacobian matrix and thus is called saturated                   embranch ment at the t ime of t*, then when t →t* there is
redundant constraint. In this case, the b ipartite matching               no solution and the motion of the system loses its certainty.
operation of c, which is to find its matching vertex in the               For examp le, at the position showed in Fig.2(a), the next
directed graph, will fail.                                                moving direct ion of the system can not be decided and the
     In Fig.1, when the lengths of the three sides of                     system becomes singular. In the research of mult i-body
triangle P1 P2 P3 are decided, P1 P2 P3 is also decided. It can           system, E.J Haug[9] and Hong Jiazhen[10] considered
be regarded as a rigid body. The constraints are as follo ws:             that this kind of singularity occurs only at isolated points,
     Geo metric entity set: E = {p 1 ,p 2 ,p 3 ,l1 ,l2 ,l3 };             e.g. position q* in Fig.2(a), and called it isolated
     Constraint set: C = {c i | i=1,9}                                    singularity.

     c1 =PntOnLine(p 1 ,l1 );         c2 =PntOnLine(p 2 ,l1 );                 This case also occurs in geometric constraint

satisfaction      problems           such     as    parametric        design.                                                                                                         Solution 1
Considering that two curves are constrained by tangency                                                    Embranchment
                                                                                              6              分支点bb
                                                                                                              Point                                                                      5
constraint. The constraint system is non-linear and the                                                                                          3
Jacobian matrix q is dependent on the orientation                                      3
parameter vector q of the system[12]. The system is                                                        8.5                                                            8.5
singular. Obviously the singularity occurs only when                                                                                                  Solution 2
tangency constraint exists or rather at the isolated points.                                            (a)                                                           (b)

That is to say, tangent point can be considered as the
isolated point of the system.
       There is only one d ifference between embranch ment
singularity of mechanism analysis and that of geometric
constraint satisfaction problems: Kinemat ics analysis can
be considered as geometric constraint problem based on
time sequence. While for static GCSP like parametric
design, when we say a system is of embranch ment
                                                                                            Fig.3 Emb ranchment singularity caused by tangency
singularity, we mean that the system is at a position where
there are constraints leading to isolated singular points for
                                                                                                                       l1{c3,                                    c{c12,
the system. For examp le, if the influence of time is not                                               c3
                                                                                                                       c5}:0                                     c6,c13
                                                                                                                                                         c7        }:0

considered in Fig.2(a), when some constraints make the                                       p1{c1,
                                                                                                                       c11                           p3{c7,
                                                                                              c2}:0                                                  c11}:0      c8
quadrilateral to be a triangle, the system is of isolated


singularity. Similarly, in Fig.3, p 1 is fixed, l1 and l2 are                                                c10
horizontal, c is tangent with l1 and l2 . The constraints can
be written as follows:

       c1 =FixX(p 1 );     c2 =FixY(p 1 );         c3 =PntOnLine(p 1 ,l1 );                 Fig. 4 A directed graph of embranchment singularity
       c4 =PntOnLine(p 2 ,l1 );             c5 =Horizontal(l1 );
       c6 = PntOnCircle(p 2 ,c);            c7 =PntOnCircle(p 3 ,c);
       c8 =PntOnLine(p 3 ,l2 );             c9 =Horizontal(l2 );
       c10 =DistPP(p 1 ,p 2 ,d1 );          c11 =DistPP(p 1 ,p 3 ,d 2 );
       c12 =TanLC(l1 ,c);        c13 =TanLC(l2 ,c);
       Fig.4 is the d irected graph o f Fig.3. The strongly
connected sub-graph SC={p 3 ,l2 ,c} corresponds to a 7×7
Jacobian matrix q . q is singular and rank(q )=5. Its
rank deficit is 2, being equal to the number of tangent                                                                l2{c2,
                                                                                                                        c9 }
                                                                                                                                          c6            p0{c4,
points. Obviously, there is no redundant constraint here                                          l1{c1}                 :0
                                                                                                    :1                                                  c6}:0
and the singularity comes fro m the tangencies between c



and l1 , l2 .

                                                                                                                                     c8               c7,c5}
3.3 Redundancy singularity                                                                                                      (c)

       There is no essential difference between redundancy                                              Fig. 5 Redundancy singularity

singularity and saturated singularity, wh ich are both                              singularity. Redundancy singularity often produced by the
caused by redundant constraints. When a redundant                                   existence of equivalent geometric constraints.
constraint can be decided by a symbol method, it is called                               Unlike saturated singularity, this type of singularity is
saturated singularity; Otherwise, it is called redundancy                           common when system is under-constrained, especially

                                                                                                       A                                                 D
during the initial phase of design. For an under-constrained                                                                   l4
vertex, symbol method can not be used to judge its                                               l1                                                 l3
singularity by simply calculat ing its RDOF, because in this                                           60°
                                                                                            B                           l2                   C
case, singularity might still exist even if the vertex is free.
For instance, when a vertex of DOF 3 is constrained by                                                                       (a)
two geometrically equal constraints, the vertex is free and                                                                    c6
                                                                                                                      l4                     D
the directed graph is normal, but singularity occurs.                                                  c7                                                c5
Considering the constrained geometry in Fig.5(a):                                               A
     c1 =Horizontal(l1 );    c2 =Vert ical(l2 );                                           c0           c11           c9                                      c4
     c3 =PntOnLine(p 1 ,l1 ); c4 =Cent_X(p 0 ,c);
                                                                                            l1                                         c10                    C
     c5 =Cent_Y(p 0 ,c);     c6 =PntOnLine(p 0 ,l2 );
     c7 =Tangent(l1 ,c);     c8 =PntOnCircle(p 1 ,c);                                            c1                                                     c3
                                                                                                                  B                          l2
     c9 =PntOnLine(p 1 ,l2 );                                                                                                  c2

    Fig.5(c) is the directed graph of Fig.5(a). It can be                                                                    (b)
seen that circle c and its center point p 0 constitute a                                        Fig.6 Redundancy singularity
strongly connected component SC. A lthough the RDOF of
                                                                      Here it is also impossible to judge the singularity by
SC seems to be zero in the graph, when the radius of c
                                                                      calculating the DOF of ve rtices. In fact, constraints
changes, all the constraints can still be satisfied(Fig.5(b)).
                                                                      AB//DC and AD//BC are equivalent to |AB|=|CD|, which
That is to say, SC is not fixed and the system is singular.
                                                                      leads to the singularity.
This singularity is just caused by the existence of
equivalent geometric constraints. This kind of singularity
                                                                      3.4 Pesudo-singularity
can not be decided by symbol method and numerical
method should be adopted.                                                  For an under-constrained system, the matching
    Fig.6(a) is another example of redundancy singularity:            modes between constraints and entities are various .
AB//DC, A D//BC, |A B|=|CD|, ∠ B=60 °, |A B|=5. The                   Different constraint matching modes produce different
constraint set is:                                                    solving sequences. Part of these solving sequences may
    c0 =PntOnLine(A,l1);           c1 =PntOnLine(B,l2);               contain singular units and are called ill-conditioned
    c2 =PntOnLine(B,l2);           c3 =PntOnLine(C,l2);               solving sequence. However, this kind of singularity can be
    c4 =PntOnLine(C,l3);           c5 =PntOnLine(D,l3);
    c6 =PntOnLine(A,l4);           c7 =PntOnLine(D,l4);                                                                      Absolute constraint:
    c8 =AngBtLine(l1,l2,60);       c9 =ParalLL(l1,l3);                               A                                              l1 is horizontal and fixed;
    c10 =ParalLL(l2,l4);           c11 =DistPP(A,B,5);                        l1                                             c1=OnLine(p,l1);
    c12 =EqualLen((A,B),(C,D));                                                                                              c2=OnLine(p,l2);
    ABCD is a parallelogram. Fig.6(b) is the directed                                             c1                                               c1
                                                                                   v(l1)                          v(p)               v(l1)                    v(p)
graph of fig.6(a). Three dashed arcs in Fig.6(b) denote the
                                                                                                                   c2                                             c2
four-element constraint c 12 =EqualLen((A,B),(C,D)), which
                                                                                                    v(l2)                                           v(l2)
is different to binary constraints. Three arcs of c 12 mean
that c12 involves 4 vertices. But the three arcs work as a                                 (a-1)                                                  (b-1)

single one and reduce the DOF o f the vertex D by 1. It can                                      c1                                                 c1
                                                                               v(l1)                             v(p)                v(l1)                    v(p)
be seen that the total RDOF of the system is 3 and there is
                                                                                     c3                          c2                     c3                        c2
no local over-constraint in the graph. The system seems to
                                                                                                 v(l2)                                              v(l2)
be well-constrained. Ho wever, it is obvious that CD can
move along AD. That is to say, the system is not                                           (a-2)                                                  (b-2)

under-constrained. So in the system there exists singularity.                        Fig.7 An examp le of pseudo-singularity

removed by improving the constraint distribution. If a kind           constraint directed graph. There must be a matching vertex
of singularity can be eliminated by adjusting constraint              for a normal constraint. Otherwise, the directed graph can
distribution, it is called pseudo-singularity.                        not be created correctly.
     In the examp le of Fig.7, l1 is horizontal and fixed. p               Property 2: If constraint c is redundant, then the
is the intersection point of l1 and l2 . A is the angle between       Jacobian matrix q o f the matching vertex of c is singular.
l1 and l2 . This under-constrained system has two possible            That is, in our research, q has row rank deficit.
directed graphs(Fig.7(a-1) and Fig.7(b-1)). No w add an                    Any redundant constraint belongs to an interrelated
angle constraint c3 =AngLL(l1 ,l2 ,180) between l1 and l 2 .          constraint set. In our research, each row vector of the
Then (a-1) and (b-1) develop to (a-2) and (b-2)                       Jacobian matrix o f the interrelated constraint set is
respectively. In the case of (b-2), intersection point p can          composed of the partial derivatives of orientation
not be solved from two superposed lines l1 and l2 . The               parameters of one constraint equation in the set. Because
system is singular. Ho wever, for the same system, the                of the relativity of the constraint set, the row vectors of its
solving sequence in (a-2) is normal. This situation is call           Jacobian matrix are also relat ive and there must be deficit
pseudo-singularity. To avoid the pseudo-singularity in                of row rank of the Jacobian matrix.
(b-2), ad just constraint c2 and let it be matched with v(l2 ),            Property 3 : Assume that vs is a compound vertex and
then the directed graph is optimized to (a-2) and the                 there is no unary constraint that describes absolute position
solving sequence v(l 1 )v(p)v(l 2 ) becomes normal.                 in vs , if (i) the predetermination set of vs is empty and the
     So we can conclude that: (1) For under-constrained               RDOF of vs is less than that of a rigid body or (ii) the
system, singularity of a constraint can not be simply                 predetermination set of vs contains only one vertex P, the
determined by the singularity of a single vertex; (2) For             RDOF of vs is zero and nu mber of the out-arcs fro m P to
under-constrained system, if a constraint has at least a              vs is mo re than the DOF of P, then there must be saturated
normal solving sequence, then it is normal.                           singularity.
     We adopt the steps as follows trying to eliminate                     Generally, there are t wo methods to position vs : one
pseudo-singularity: Once an ill-conditioned vertex v ss is            is using unary constraints that describe absolute position
obtained, constraint matching adjustment[8] will be                   such as fixed position, horizontal, vertical and so on. This
implemented on the non-propagation set of v ss to search              situation is excluded by property 3. The other method is to
for a inverse transitive path P. Reverse the arcs along P to
move the constraint matched with v ss so that the                                                                                     c6}:0

propagation set of v ss is enlarged and a new solving                                c2}:0         c2       p2{c7

sequence is obtained. To ensure the new solving sequence

                                                                                                                      c8         p3{c8
is normal, the algorith m needs to check all the vertices in


                                                                                              p1{c9               c9
the new solving sequence. Readers please refer to                                              }:1

reference[8] for details.                                                                                              l3{c3}
4 Singularity differentiation
                                                                                 c2}:0                                     c5
4.1 Graph di fferentiati on method


                                                                                              c1                 c8             p3{c8
     A geometric constraint system has fo llo wing three                                                                        ,c4}:0

properties:                                                                                                              0                  c4
     Property 1: If constraint c is not redundant, then                                                 ,c3}:1                  c3
there must be a geo metric entity e in the system,
DOF(e)>0 and c can be matched with e(<c,e>|e ∈E ).
     This property comes fro m the definit ion of geometric                  Fig.8 Graph character of saturated singularity

position by its predetermination set P. If P is empty or                perturbation direction; F is the constraint equation. Then
there is only one geometric entity whose DOF is less than
                                                                        compute with the iteration formu la
that of vs , obviously it is impossible fo r vs to be positioned
and there must be saturated singularity among the
                                                                              q j 1  q j   j  Fj ,

constraints of vs .                                                     Where q is the orientation parameter vector of v i ,   is

      Property 1 and 2 are two necessary conditions for a               the general inverse of q . Because the perturbation is
normal constraint. Property 3 indicates the graph character             small, after few steps of iteration can we determine if there
of saturated singularity and becomes an efficient symbol                is a solution or not. If there is a solution for either
differentiat ion method for this kind of singularity. For
                                                                        perturbation direction for ci and row ran k deficit of q
instance, Fig.8(a) is the strongly connected graph of
                                                                        decreases, the singularity caused by ci is embranch ment, or
Fig.1(b), in which the only strongly connected sub-graph
                                                                        it is redundancy. By this means, the types of singularity of
SC has 4 entities and its RDOF is 2×4-6 = 2. After the
optimal matching adjustment[8], wh ich can ensure the                   all the constraints in Cr can be decided.
RDOF of any compound vertex v i Dof(v i )→0, SC contains                     In Fig.5, there is redundancy among the constraints
3 entit ies Vs={p 1 ,p 2 ,p 3 } and RDOF=2×3-6 = 0(Fig.8 (b)).          between compound vertex Vs and c6 ,c7 ,c8 . When Cr={c6 },
The predetermination set of Vs is P={l3 }. The DOF of l3 is             the perturbation is:
2. However, it can be seen that there are three arcs from l3                 a2 x0 + b 2 y 0 + c2 = ,
to Vs, corresponding to constraints c 3 , c4 , c10 , which means        where a2 ,b 2 ,c2 are parameters of l2 . A fter perturbation, l2
rig id body Vs whose DOF is 3 is fu lly determined by l3                will have a slight translation and then the intersection
whose DOF is 2. It is obviously impossible. According to                point of l1 and l2 can not be on circle c(Fig.9(a)). There is
Property 3, there must be saturated singularity in SC.                  no solution for this perturbation. If Cr={c7 }, the
                                                                        perturbation is:
4.2 Constraint Resi due Perturbation Method                                  a1 xc + b 1 y c + c1  r = ,
                                                                        where a1 ,b 1 ,c1 are parameters of l1 . It means that l1 moves
      For redundancy singularity and emb ranchment
singularity, nu merical judging method should be applied.                       l1                     l1                  l1
                                                                                       p1                   p1                     p1
To decide singular points, E.J.Haug[9] presented a variable
perturbation method. This method is efficient. Ho wever, it                            p0         c         p0         c            p0      c

applies perturbation to all the entit ies in the system                                l2                   l2                      l2
indiscriminately and the scope of perturbation does not                                                                                   Perturbation
                                                                                                                           l1      p1
vary for different entities, which increases the expense of                                                                                 solution
                                                                               No solution            No solution
time of the method.                                                               无解                                                p0      c
      Considering that singularity is caused by redundant
                                                                                                                 扰动解                l2
constraints,     we   advance     the    Constraint    Residue
                                                                               ( a) (a)                 (b)             (c)
Perturbation Method(CRPM) which only involves the
                                                                                            Fig. 9 Redundancy singularity
redundant constraint set:
     If Jacobian matrix q of a solving unit v i is singular,
then redundant constrain set C r  C can be found easily                                                                                 Perturbation

using Gaussian Eliminat ion Method. Here C is the                                                 l                l                l     soloution

constraint set of v i . Set a perturbing value  for each              Perturbation
                                                                                                        p                  p              p
constraint ci ∈ Cr and then adopt Newton-Raphson                        soloution
iteration. For
                                                                                            c               c                  c
      ci ∈Cr  Fi = Fi ,
                                                                                                (a)              (b)               (c)
where > ,  is the iteration precision;  means                                     Fig.10 Embranchment singularity

along l2 (Fig.9(b)). Obviously, the perturbing result also                                     singularity) then c is redundant and return
makes p 1 not on circle c, which is inconsistent to c8 and                                     FALSE;
there is also no solution. When Cr={c8 }, perturbation is                                      else if (there is v∈S and v is of redundancy
                                                                                               singularity) then {search for reverse transitive
         ( x c  x1 ) 2  ( y c  y1 ) 2  r   .
                                                                                               paths P on the non-propagation set of v;}
It means that the radius of circle c changes for the                                           else {print(“c is normal constraint”) output the
perturbation. Fro m Fig.9(c), it can be seen that after                                        solving sequence; return TRUE;}
perturbation, all the constraints are still satisfied and                           step5      If (P is empty) c is redundant; return FALSE;
perturbing solution can be easily obtained. The Jacobian                                       else{apply reverse operation on P; reset the
matrix q of Vs is:                                                                            solving sequence S; goto Step2;}
                 x0    y0          xc                 yc              r
        c4 :     1     0           1                 0               0                  In Algorith m 1, step 4 needs to judge the singularity
         c5     0      1            0                1               0             type of vertex v. A lgorith m 2 gives this judging method:
         c6     a2     b2           0                0                0             Algorithm 2: Judging the singularity type of vertex v
         c7      0     0           a1                 b1              1             step1      if (v satisfies Property 3)
         c8      0     0      ( xc  x1 ) / R ( y c  y1 ) / R  1                                  return “v is of saturated singularity”;
where           E  { p 0 , c}     ,      C  {c4 , c5 , c6 , c7 , c8 , }   ,       step2      Co mpute the Jacobian matrix q of v;
                                                                                    step3      If (q is normal) return “v is normal”
q  x0 , y0 , xc , yc , r , R  ( x c  x1 ) 2  ( y c  y1 ) 2 .

                                                                                    step4      Co mpute dependant constraint set Cr in v by
Because p 0 and p 1 are always on l2 before and after                                          Gaussian Elimination Method.
perturbation and the values of (xc-x1 )/ R and (y c-y 1 )/R do                      Step5      i = 1, r is the number of constraints in Cr.
not change, the row rank deficit of q is unaltered.                                Step6      ci∈Cr, r0=rank(q );
According to CRPM, c8 causes redundancy singularity.                                Step7      Add a perturbation δ on ci;
      Similarly, in Fig.10(b), line l is tangent with circle c .                    Step8      Solve v;
The system is singular. After either perturbation shown in                          Step9      If (there is no solution)
Fig.10(a) or Fig.10(c), the row ran k deficit of the Jacobian                                       return “v is of redundancy singularity”;
matrix of the system decreases to 0, which shows the                                           else if(r1=rank(q)≤r0)
system has embranchment singularity.                                                                return “v is of embranch ment singularity”;
      The algorith m of singularity d ifferentiation can be                         step10     If (i<r) {i+1, go to step5};
summed up as follows:                                                               step11     return “v is normal”;
Algorithm 1: Globally judging the redundancy of
constraint c in an under-constrained system                                              Algorith m 1 adaptively enlarges the propagation set
step1          If the bipartite matching of c fails, c is                           of constraint c according to the singularity types of the
               redundant; return FALSE;                                             vertices in the solving sequence SC and eliminates the
step2          Initialize directed graph G; Get the propagation                     singularity. Because the repeat of Step2 is limited, the
               set PS of c.                                                         complexity of the algorith m is approximately equal to that
step3          Adopt optimal adjustment algorith m[8] to                            of DFE: O(n+e)[11]. The algorithm works well for
               obtain the strongly connected sub-graphs on PS                       under-constrained systems. Ho wever, it is also efficient for
               and make G a d irected non-loop graph. Then the                      well-constrained and over-constrained systems.
               solving sequence S={vi} fro m c can be obtained
               along the our-arcs of c.
step4          if (there is v ∈ S and v is of saturated

                           CBA classes                    CbaObject

                         CbaModel                           CbaBody

                            CbaModel2D             CbaBody2D                   CbaDim2D            CbaConstraint2D

                            CbaModel3D             CbaBody3D
                                                                               CbaDim3D            CbaConstraint3D

                            CbaPoint2D             CbaPoint3D                   CbaRelation
                             CbaLine2D             CbaLine3D
                            CbaCircle2D            CbaPlane3D
                            CbaEllipse2D              ..........                CbaDiEdge

                                                      Fig.11 the hiberarchy of CBA

                                           Fig.12 An examp le of constraint identification

                               1                                                               1

                               2                                                                    2

                                             (a)                                                        (b)

                                                      Fig.13 Assembling a t ripod
                                                                            constraints in these constraints. Finally, 2n+1 horizontal
4.3 Some examples                                                           constraints, 2 vertical constraints, 4+3(n-1)=3n+1 tangent
                                                                            constraints and 3 point-on-line constraints are obtained by
     Using O-O method we presented a united modeling
                                                                            CBA2D. In this examp le, all the types of singularity
method for both 2D and 3D geo metric constraints and
                                                                            mentioned above occur. Particu larly, after the constraint
developed    a   2D/3D     geo metric       constraint             solver
                                                                            identification, labeling some d imensions (e.g. Fig.12(b ))
CBA(Constraint     Broadcasting       Automation).            Fig.11
                                                                            will lead to sophisticated embranchment singularity.
illustrates the hiberarchy of CBA.
                                                                            CBA2D also can deal with such kind of problems .
     The module o f constraint identificat ion in CBA2D
                                                                                    In another 3D examp le in Fig.13(a), pole 2 mates
transforms general engineering graphs to parametric ones
                                                                            with pole 1 and pole 3 by two co-axis relat ions. Each
and identifies geo metric constraints according to relative
                                                                            co-axis relation includes 4 constraints. If add another
positions of geometric entit ies. Fig.12(a) is a keyway that
                                                                            co-axis relation between pole 1 and pole 3, CBA3D will
has n loops. By geometric detection, 2n+1 horizontal
                                                                            close     the     tripod          and     find    out   two   redundant
constraints, 2 vertical constraints, 4n tangent constraints
                                                                            constraints(Fig.13(b)).               (Readers      please    refer   to
and 4n+4 point-on-line constraints are made out. The
                                                                            reference[12] fo r our research of geometric constraint
algorith m identifies successfully that there are n-1
                                                                            expression and decomposition). Practice has proven the
redundant tangency and 4n+1 redundant point-on-line
                                                                            differentiat ion method presented in this paper fast and
efficient.                                                                perturbation    method     are   advanced     to   differentiate
                                                                          efficiently singular constraints. All the algorith ms and
5 Conclusi on                                                             methods proposed in this paper can also be applied to 3D
                                                                          geometric constraint system and has proved efficient and
     Singularity is an important factor that affects directly
                                                                          fast in CBA 3D.
the solving ability of geometric constraint solver. In this
paper, three types of singularity are presented and                       6 Acknowledgement
pseudo-singularity,     which       is       very   common       in
under-constrained systems, is analyzed. As one part of the                     This work was supported by the National “863”
kernel of our geo metric constraint solver CBA, the graph                 Project under grant 9842-003 in the field of automation.
differentiat ion   method     and      the     constraint   residue


1    Light           ,
             R, Lin V Gossard D. Variational geometry in CAD.                  key technologies of geometric constraint driven function in
     Computer Graphics, 1981,15(3)171-177                                      traditional drafting systems. Chinese Computer Research &
2    Kramer G.A. A geometric constraint engine, Artificial                     Development, Vol.35, No.10, pp935-940,1998.
     intelligence, 1992, 58: 327-360                                      8    Chen Liping, Wang Boxing, An Optimal method of Bipartite
3    Chen liping, Zhou Ji. Research of geometric constraint                    Graph M atching for Underconstrained Geometry Solving.
     system reasoning. Journal of Huazhong Univ. of Sci &                                                    ol.
                                                                               Chinese Journal of Computers V 23, No. 5, M ay 2000:
     Tech,1995, 6:70-74.                                                       pp523-530.
4    Dong jinxiang. A new thought of constraint solving in                9    Haug E.J, Computer Aided Kinematics and Dynamics of
     variable drawing system. Journal of computer-aided design                                       ol.
                                                                               M echanical Systems, V I Basic M ethod, 1989.
     & computer graphics, 1997, 9(6):513-519.                             10   Hong Jiazhen, Computational Dynamics of M ultibody
5    Jae Yael Lee, Kwangsoo Kim. A 2-D geometric constraint                    System. Advanced Education Press, China, 1996(4):70.
     solver using DOF-based graph reduction. Computer-Aided               11   Yan Weimin, Wu Weiming, Data Structure, Tsinghua
     Design, 1998,30(11):883-896                                               University Press, China, 1992.
6    Xiao-Shan Gao,Shang-Ching Chou, Solving geometric                    12   Chen Liping, Peng Xiaobo, Proceedings of ASM E
     constraint systems. A symbolic approach and decision of                   DETC’00, Baltimore, M aryland, September 10-13, 2000.
     Rc-constructibility. Computer-Aided Design Vol.30,No.20.
7    Wang Boxing, Chen Liping, Zhou Ji, Study and practice of


Shared By: