Augmented Lagrangian Formulation Geometrical

Embed Size (px)

Citation preview

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    1/19

    Multibody System Dynamics 8: 141159, 2002.

    2002 Kluwer Academic Publishers. Printed in the Netherlands.141

    Augmented Lagrangian Formulation: GeometricalInterpretation and Application to Systems with

    Singularities and Redundancy

    WOJCIECH BLAJERInstitute of Applied Mechanics, Technical University of Radom, ul. Krasickiego 54, PL-26-600

    Radom, Poland; E-mail: [email protected]

    (Received: 28 November 2000; accepted in revised form: 2 October 2001)

    Abstract. A geometric interpretation of the augmented Lagrangian formulation of Bayo et al. (Com-

    put. Methods Appl. Mech. Engrg. 71, 1988, 183195), applied to equations of motion in relative andCartesian coordinates, is presented. Instead of imposing constraints on a system in the traditional

    sense, large artificial masses resisting in the constrained directions are added, and the system motion

    is enforced to evolve primarily in the directions with smaller masses (in the unconstrained directions).

    Then, the residual motion in the constrained directions is removed by applying the constraint reac-

    tions to the system, estimated effectively in few iterations. The formulation is comparatively simple

    and leads to computationally efficient numerical codes. Useful applications of the formulation to the

    dynamic analysis of constrained multibody systems with possible singular configurations, massless

    links and redundant constraints are shown. The theoretical background is followed by some remarks

    on the modeling precautions and assisted computational peculiarities of the method. The results of

    numerical simulation of motion of a parallel five-bar and a parallel four-bar linkage are reported.

    Key words: constrained multibody systems, redundant constraints, singularities.

    1. Introduction

    Multibody systems are often modeled by using a non-minimal set of, say n, de-

    pendent coordinates q, interrelated through l kinematic constraints. Assumed the

    constraints are holonomic and scleronomic, the constraint equations are

    (q) = 0. (1)

    Then, after differentiating with respect to time the original constraint equations (1)

    at position level, the constraint conditions at velocity and acceleration levels follow

    consecutively as:

    C(q)q = 0, (2)

    C(q)q (q, q) = 0, (3)

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    2/19

    142 W. BLAJER

    where C = /q is the l n constraint matrix, and = Cq is the l-vector of

    constraint induced accelerations. The dynamic equations of the system arise then

    in the form of Lagranges equations of the first type

    M(q)q + d(q, q) = f(q, q, t) CT(q), (4)

    where M is the generalized mass matrix, the n-vector d represents the centrifugal,

    Coriolis and gyroscopic dynamic terms, f is the n-vector of generalized applied

    forces, are l Lagrange multipliers associated with the constraints (1), and t is the

    time. Handled together, (4) and (3) form n + l Differential-Algebraic Equations

    (DAEs) in q and , which can be solved directly or, prior to the numerical integ-

    ration, transformed to a smaller set of Ordinary Differential Equations (ODEs). A

    variety of the DAE/ODE multibody formulations have so far been developed and

    widespread in the literature, see e.g. [15].

    There are two basic requirements that condition applicability of many of the

    classical multibody codes [1] in the whole configuration range of a system:

    M must be nonsingular (it is usually assumed to be positive definite), which

    excludes the modeling of some of the system links as massless,

    C must be of maximal row-rank, rank(C) = l, which yields

    no redundant constraints on the system,

    no singular positions encountered.

    Special procedures must also be followed to model/simulate systems in the pres-

    ence of constraint addition/deletion and/or changing topologies, which may be

    especially cumbersome in the case of ODE formulations.

    A variant method for constrained multibody systems, called augmented Lag-rangian formulation, was proposed in [6] and then succeeded e.g. in [79]. Accord-

    ing to the geometrical interpretation provided in the following, instead of imposing

    constraints on a system in the conventional sense, large artificial masses resisting

    in the constrained directions are added, which enforce the system motion to evolve

    primarily in the directions with smaller masses (unconstrained directions). Then,

    the residual motion in the constrained directions is removed by applying the con-

    straint reactions to the system, which are estimated effectively in few iterations.

    The formulation is comparatively simple and leads to computationally efficient

    numerical codes. As compared to [6-9], the main contributions and amendments of

    this paper to this formulation can be itemized as follows:

    an insightful geometrical/physical interpretation of the method is given, whichexpounds the formulation as an augmented mass method;

    a simple derivation of the formulation is demonstrated;

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    3/19

    AUGMENTED LAGRANGIAN FORMULATION 143

    Figure 1. The physical interpretation of Arnolds/penalty formulation.

    an application of the formulation to equations of motion in any set of com-

    monly used dependent coordinates q is shown (the original applications the

    method are restricted to the so-called natural coordinates [2]);

    the algorithm for efficient determination of q(t), q(t), and (T ) is recon-sidered;

    the method is shown applicable to systems with redundant constraints, chan-

    ging topologies, and, with precautions, singular positions and/or massless

    members;

    some peculiarities concerned with the modeling and computational treatment

    of the singularities and redundancy are emphasized;

    some remarks on the computational applications of the method, its effective-

    ness and accuracy, are incorporated.

    As said, the method presented in this paper is not genuinely novel it coincides

    with the augmented Lagrangian formulation [2, 69]. It is rather a more physicallyinsightful reformulation/interpretation of the previous approach, and an extension

    of its application range. In fact, the original formulation is closely related to the

    natural coordinates [2], ingenious but specific coordinates to describe a system

    configuration. The present contribution is then an application of the approach to

    systems described in the more commonly used coordinates, e.g. absolute and/or

    joint coordinates.

    2. The Physical Background

    Instead of thinking about constraints in terms of hard surfaces, rigid links, slipless

    rolling contacts, etc., a legitimate and old treatment, motivated then by Arnold [10],is to replace the stiff constraints by a strong force field in a neighborhood of the

    manifold (q) = 0, directed towards the manifold. The effect can be interpreted

    as the action of l elastic forces pointed in the constrained directions towards the

    respective constraints and proportional to the constraint violations (Figure 1). As-

    sumed the same stiffness coefficient k in the all constrained directions, the elastic

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    4/19

    144 W. BLAJER

    forces are k, and their projection onto the directions of q is CTk [4]. The

    dynamic equation (4) can then be modified to

    Mq = f d CTk, (5)

    which can also be seen as the scantiest penalty formulation [2, 6]. For the penalty

    factor k large enough, the moving system will always be close to the constraint

    manifold (q) = 0, and in the limit case of an infinite force field ( k ), the

    system must remain on the manifold. The latter case is equivalent to constraints (1)

    put on the system [10].

    While approved theoretically, the infinite (very large) increase ofk always leads

    to instability in computations. More strictly, for a given integration time step t,

    moderate values of k allow usually an unacceptable constraint violation, while

    increasing k leads first to the oscillating and then unstable numerical solutions.

    The situation can be improved by adding some damping and inertia along the

    constrained directions the forces proportional to the violations of constraints

    at the velocity and acceleration levels. The arising penalty forces that resist the

    constraint violations are then + c + k, where stands for the value of

    the constraining masses and c is the damping coefficient. The effect can also be

    rewritten in a more familiar form ( + 2 + 2), where 2 = c/ and

    2 = k/, and the condition of critical or over-critical damping is advisable.

    It may be worth noting that the penalty factors, in this formulation taken identical

    for each constraint, can possibly be different, e.g. , c and k can be replaced by

    appropriate diagonal matrices of separate factors. Moreover, depending on the j-th

    constraint j (j = 1, . . . , l) denotes the restricted relative translation or rotation

    in a joint, the units of the penalty factors , c and k should respectively be: [kg]

    or [kg m2], [kg s1] or [kg m2 s1], and [kg s2] or [kg m2 s2]. The latter aspects

    can however be concealed in computations, and unified penalty factors are usuallychosen for simplicity. In the following we will therefore refer only to the values of

    , c and k, granting that the units of, c and k are appropriately adjusted.

    After applying Equation (3), the final (full) penalty formulation is (see also [2,

    6])

    (M + CTC)q = f d + CT( 2 2). (6)

    Irrespective of some advantageous peculiarities of the leading matrix M + CTC

    (which will be discussed in more detail in the following sections), the formulation

    still shows a tendency to instability in the numerical solutions for very large pen-

    alty factors , c and k. More specifically, referring to the modified penalty form

    of constraint conditions, ( + 2

    +

    2

    ), for given values of and suchthat , setting (very large), and keeping the integration time step t

    constant, always leads to computational instability. The value of must then be

    limited to a certain (case dependent) value, usually ranging from 106 to 107 (see

    also [69]). On the other hand, the penalty formulation (6) is very close related to

    Baumgartes constraint violation stabilization method [11], with all its advantages

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    5/19

    AUGMENTED LAGRANGIAN FORMULATION 145

    Figure 2. The physical interpretation of the method.

    and disadvantages. The solution to (6) will remain close but not exactly on the

    constraint manifold (q) = 0.

    The augmented Lagrangian formulation exploits the advantageous peculiarit-

    ies of the leading matrix M + CTC (shown in the following) and removes the

    drawbacks of limited accuracy and/or instability of the penalty formulation.

    3. The Present Method

    For a mechanical system as described in Section 1, the physical interpretation of

    the present formulation can be summarized in the following three steps:

    1. Start from the unconstrained system whose dynamic equations are Mq+d = f.

    2. Add to the system l artificial masses of value , which resist only in the

    constrained directions with respect to (1). Assuming that are large enough

    compared to the actual masses of the system represented in M (in Figure 2denoted symbolically by m), the motion of the system (of the mass m) will

    evolve primarily in the unconstrained directions, while the whole modified

    system (both the masses and m) will tend to drift slightly in the constrained

    directions as well.

    3. Stop the residual motion in the constrained directions by imposing appropriate

    forces in these directions (applied to ); see Figure 2. Once the constraint

    drift tendency is removed, the applied additional forces are equivalent to the

    constraint reactions in the classical sense.

    Due to the above physical interpretation, the code can be referred to as an aug-

    mented mass method. Resembling mass-orthogonal projections of the augmentedLagrangian formulation were previously observed in [9].

    In order to introduce the mathematical formulation of the method, let us first

    reconsider the constraint equations (3) at the acceleration level using the geomet-

    rical interpretation provided in [4]. The equality Cq = means that the projections

    of the system acceleration on the constrained directions, Cq, are equal to the con-

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    6/19

    146 W. BLAJER

    straint induced accelerations in these directions. By assumption, the motion of

    the constraining masses must be consistent with this constraint condition. The

    dynamic generalized forces (in the constrained directions) related to the masses

    are then Cq = , and the projection of the dynamic forces into the directions of

    q is finally CTCq = CT. The latter equality can be seen as the mathematical

    representation of the imposition of the constraining masses on the unconstrained

    system, as mentioned in step 2 above. The representation of step 3 can simply be

    written as CT added to right-hand side of the arisen motion equations, where

    are the l forces added in the constrained directions to resist the constraint drift

    tendency. In sum, starting from the unconstrained dynamics (step 1) and following

    steps 2 and 3, we obtain

    Mq = f d

    CTCq = CT

    = CT

    (M + CTC)q = f d + CT CT (7)

    The result (7) can also be obtained from the penalty formulation (6) after removing

    the elastic and damping constraining forces, and adding the additional forces

    of step 3, where = if the system acceleration satisfies the constraint condition

    Cq = . Also, the result is equivalent to the augmented Lagrangian formulation

    with projections [8, 9].

    4. The Numerical Code

    Assumed q0 and q0 satisfy the constraint conditions (1) and (2), for the

    solution to (7) will tend to be consistent with the constraints even though =

    0 the motion in the constrained directions will be excluded due to the infinite

    constraining masses. In computations must be limited to a certain value, however,

    and the residual motion in the constrained directions can be removed by applying

    some additional forces . Since are not known a priori, the determination of the

    constraint-consistent accelerations q and adequate values of must be performed

    iteratively. Denoting in Equation (7) H(q) = M + CTC and h(q, q, t) = f d +

    CT, at a given simulation time t, the iteration process is (setting 0 = 0).

    qi+1 = H1(q)(h(q, q, t) CT(q)i );

    i+1 = i + i+1; i = 0, 1, 2, . . . , (8)

    where i+1 = C(q)qi+1 (q, q). For ranging from 105 to 107 usually only

    13 iterations suffice to achieve |qi+1 qi| , where is the required numerical

    accuracy.

    The numerical code can be explained as follows. For the current state variables

    q and q that satisfy the constraints (1) and (2), initially (i = 0) we set 0 = 0 to

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    7/19

    AUGMENTED LAGRANGIAN FORMULATION 147

    Figure 3. The physical interpretation of the numerical code.

    obtain q1 = H1h in the first (i = 1) step. Evidently q1 may not be consistent with

    the constraint condition (3), and the inconsistency measure is 1 = Cq1 , which

    denotes the difference between the actual and the constraint induced accelerations

    in the constrained directions. To resist the constraint drift tendency the forces 1 =1 are applied on the system, equal to the inertial forces of the masses due to

    the drift accelerations 1. The acceleration estimated in the next (i = 2) iteration,

    q2 = H1(h CT1), is then much more consistent with the constraint condition

    (3). The consistency is not exact however since both the masses and m (Figure 3)

    are affected by the drift accelerations, while only the inertial forces of the masses

    are resisted by 1 = 1. The consistency is then improved by correcting the

    reaction force to 2 = 1 + 2, where 2 = Cq2 , which follows in still

    more consistent accelerations q3 = H1(h CT2) in the next (i = 3) step. Then

    3 = 2 + 3, . . . , etc. Note that for much larger than the actual masses of

    the system (for m), the iteration process converges very quickly. Note also

    that all the used quantities H1

    , h, C and remain constant in the iteration process(are determined only once for the current state of the system). To illustrate how the

    method works, let us investigate the following simple example.

    4.1. ILLUSTRATIVE EXAMPLE

    A particle of mass m moves on a circle of radius . The constraint equation and its

    first and second time-derivatives are:

    =

    x2 + y2 = 0; =xx

    +

    yy

    = 0;

    =

    xx

    +

    yy

    +

    x2 + y2

    = 0,

    which yields the constraint matrix C = [x / y /] and the constraint induced

    acceleration = (x2 + y2)/. The arising formulation (7) of the method is then

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    8/19

    148 W. BLAJER

    Figure 4. The illustrative example.

    m + x2

    2

    xy

    2

    xy

    2m +

    y2

    2

    x

    y

    =

    Fx x(x2+y2)

    2

    Fy y(x2+y2)

    2

    x

    y

    ,

    where Fx and Fy are the components of the external force on the particle.

    For simplicity, let us assume that the current particle position is on the axis Ox

    (Figure 4). The above formulation of the method simplifies then to

    m + 0

    0 m

    x

    y

    =

    Fx

    y2

    Fy

    1

    0

    .

    The iteration process at this position is demonstrated in Table I. As seen, assumed

    m, the acceleration xi of mass m and the force i that resists the constraint

    drift, both in the constrained direction, converge very quickly respectively to the

    constraint consistent acceleration y2/ and the constraint reaction Fx + my2/.

    5. The Range of Applications and Computational Aspects

    The dependent coordinates q of the present formulation (7) can be any set of the

    coordinates that are commonly used to describe a multibody system configura-

    tion, namely the absolute (Cartesian) and joint (relative) coordinates [2, 3, 12],

    or mixed. For a slider-crank mechanism shown in Figures 5a, 5b, and 5c, these

    coordinates are:

    qa = [x1 y1 1 x2 y2 2 x3 y3]T; qb = [1 2 s]

    T;

    qc

    = [ x2 y2 2 s]T

    .

    In all the three cases, the constraints = [1 . . . l ]T on the respective systems

    can be modeled so that to express the prohibited relative translations/rotations in

    the cut joints. The corresponding constraint reactions = [1 . . . l]T will then

    be the physical forces/moments in the joints, i counteracting i , which is stated

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    9/19

    AUGMENTED LAGRANGIAN FORMULATION 149

    Table I. The illustration of iteration process.

    i = 0 0

    = 0

    i = 1x1 =

    Fx

    m +

    m +

    y2

    y1 =Fy

    m

    1 =

    m +

    Fx +

    my2

    i = 2

    x2 =mFx

    (m + )2

    (m + )2 m2

    (m + )2

    y2

    y2 =Fym

    2 =(m + )2 m2

    (m + )2

    Fx +

    my2

    i = 3x3 =

    m2Fx

    (m + )3

    (m + )3 m3

    (m + )3

    y2

    y3 =Fym

    3 =(m + )3 m3

    (m + )3

    Fx +

    my2

    (. . .) (. . .) (. . .)

    i

    ( m)

    x = y2

    y =Fy

    m

    = Fx +my2

    Figure 5. A slider-crank mechanism modeled with (a) absolute, (b) joint, (c) mixed

    (joint-absolute), and (d) natural coordinates.

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    10/19

    150 W. BLAJER

    in the classical formulation (4). Though the drift resisting forces in the present

    formulation (7) have notionally different meaning from , after some N iterations

    described in Equation (9), N are equal to with a required numerical accuracy.

    More strictly, N

    are applied to the augmented masses . However, since the drift

    of the augmented system (both and m masses) in the constrained directions is

    removed, i.e. the acceleration of the actual system (mass m) is consistent with the

    constraint condition (3), the constraint reactions are the reactions between the

    actual system (mass m) and the augmented masses (mass ), and therefore = N.

    The determination of constraint reactions as physical forces/moments in the

    joints is an important advantage of such setting the constraint equations (1) to ex-

    press the prohibited relative translations/rotations in the cut joints, and this relates

    the present application of the formulation (7) to equations of motion in abso-

    lute/joint coordinates. The situation is different when the so-called natural co-

    ordinates [2] are used. For the slider-crank mechanism seen in Figure 5d these

    are

    qd = [x1 y1 x2 y2]T,

    which are the coordinates of points 1 and 2, to which, followed a legitimated pro-

    cedure [2], the kinematical and inertial properties of the system are transferred.

    While the arising constraint equations(x1 xA)

    2 + (y1 yA)2 l1 = 0;

    (x2 x1)2 + (y2 y1)2 l2 = 0; y2 = 0

    have evident physical meaning, the associated constraint reactions N, due to the

    artificiality of the mass points 1 and 2, do not express any physical forces in the

    system joints. Therefore, though the natural coordinates have many advantageous

    peculiarities, the loss of the physical insight may be discouraging. Moreover, theaugmented Lagrangian formulation is usually introduced together with these spe-

    cific coordinates [2] (the examples are so restricted), and this is why this interesting

    and useful method of dynamics seems to be hidden behind the natural coordinate

    formulation. The application of the approach to systems described in the more

    commonly used absolute/joint coordinates is shown in the following.

    Irrespectively of the coordinate type used, the intrinsic advantages of formu-

    lation (8) are due to the inherent features of the leading matrix M + CTC. The

    matrix remains invertible even in the presence of

    changing topologies (varying number of constraints),

    redundant constraints, singular positions encountered,

    possible singularity ofM.

    For any (possibly varying) number of constraints on the system, including the case

    m n (redundant constraints), the dimension of CTC is n n. Of paramount

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    11/19

    AUGMENTED LAGRANGIAN FORMULATION 151

    importance is that the diagonal elements of this matrix are either positive or equal

    to zero (they are never negative). This holds true also in those cases when the

    maximal row-rank of the constraint matrix C is lost, either permanently (redundant

    constraints) or occasionally (at singular positions). As a consequence, the matrix

    M + CTC remains positive definite even in the presence of changing topologies,

    redundant constraints and singular positions. Moreover, some singularity of the

    mass matrix M is admissible as well. More strictly, selected links of a multibody

    system modeled with the present method can be set massless. The correspond-

    ing null diagonal entries of M must then be completed with the positive definite

    diagonal entries of CTC. This excludes the last links of open chains from being

    modeled as massless. Moreover, the internal massless links must first be entirely cut

    off from the system, and then modeled in absolute coordinates. This excludes the

    modeling of mass singular systems in joint coordinates, and absolute coordinates

    of (at least) massless links must be used. As an illustration, massless can be any

    link in Figure 5a (absolute coordinate formulation), and the link 2 in Figure 5c

    (mixed joint-absolute formulation).An important virtue of the present formulation applied to systems with redund-

    ant constraints is that the iterated values N involve the correct values of reactions

    of all the constraints on the system, including the redundant constraints. Many

    of the existing multibody codes are unable neither to analyze the systems with

    redundant constraints nor to determine the redundant constraint reactions.

    Singular positions are encountered when the motion cannot continue beyond

    some particular configurations of the system (the lockup configurations) or when

    the system reaches a configuration in which there is a sudden change in the number

    of degrees of freedom [3]. In the following we will limit ourselves only to the latter

    singularities. Depending on the nature of the driving input, the system motion in

    such singular positions may proceed non-smoothly and/or more than one possiblemotion can occur. For the slider-crank mechanism shown in Figure 5, and designed

    so that l1 = l2 and b = 0, a singular position is reached when the two links are in

    vertical position.

    A singular position is mathematically detected by an instantaneous fall of rank

    of the constraint matrix C. The simulation may then crash not because of the

    physics of the problem but because of the inability of the dynamics formulations to

    overcome the rank change. This is not the case of the present formulation, however.

    The leading matrix M + CTC in Equation (7) can be invertible irrespective of

    the rank of C. The mathematical impact of the singularities is thus removed. The

    physical reasons of the singularity may still remain, however. Getting through the

    singular configurations smoothly is then conditioned upon the additionally arising

    degrees of freedom are activated or not. If it is so, the iteration procedure (8) forthe constraint consistent accelerations may not converge, and special algorithms

    have to be used. Moreover, the closed loops of the singular position mechanisms

    analyzed with the present method should not be cut in the joints but must be disjoint

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    12/19

    152 W. BLAJER

    by rending off the whole members, modeled then as free bodies. These problems

    will be illustrated in the next section.

    It may be worth comparing the present formulation (7) with the standard DAE

    formulation [1, 2, 4, 12] of equations of motion,M CT

    C 0

    q

    =

    f d

    , (9)

    where both the n dynamic equations (4) and k constraint equations (3) are explicitly

    involved. Both the formulations are simple to obtain and then implement in digital

    computations. In the case of DAEs (9), the n + l leading matrix has to be inverted

    (or an equivalent numerical code has to be applied) to solve the DAEs for the

    exact accelerations and constraint forces at the consistent position and velocity

    of the system. By contrast, in formulation (7) only n differential equations are

    solved, while the constraint equations (3) are involved in the iteration process (8)

    for the determination of the consistent accelerations and reaction forces. In fact,

    the same number of unknowns and equations is thus used in both formulations, thenumerical efficiency of both the codes seem to be similar. The solvability of DAEs

    (9) is however dependent on det(CM1CT) = 0, or more strictly: det(M) = 0 and

    rank(C) = l = max, which excludes the direct analysis of systems with massless

    links and redundant constraints, and difficulties may arise at the singular positions.

    The iteration process (8) usually converges very quickly (in 2 or 3 steps), and

    H1(q), h(q, q, t), C(q) and (q, q) used in the process are determined only once

    for the current state variables. In principle, the bigger the better convergence

    of the code (8). Too large s usually cause numerical instability, however, which

    limits to a certain case dependent maximal value. The source of the instability

    are the random errors due to the cancellation of leading digits in subtraction of

    numbers of the same order of magnitude. The computations of terms like [1 /(m + )] are involved, and increasing above a certain level may not only

    enlarge the random errors but lead to incorrectness in computations as well. The

    value of[1/(m+)], which should always be smaller then one, for very large

    and a moderate m, may be computed as larger than one. These computational

    phenomena lead to instability of the present code. The authors experience is that

    for many typical applications and calculations performed in FORTRAN (double

    precision), the reasonable values of range from 105 to 107 (see also [2, 69]).

    As in the case of the DAE formulation (9), the solution to (7) may suffer from

    the constraint violation problem. The constraint violations = (q) = 0 and

    = (q, q) = 0 and for the current state values q and q obtained from the

    numerical integration can be eliminated by correcting the state variables according

    to the following schemes [8, 9]:

    q = H1CT; q = H1CT, (10)

    where q = q q and q = q q, and q and q are the corrected state variables.

    This is also an iterative process, converging usually in 2 or 3 steps to achieve

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    13/19

    AUGMENTED LAGRANGIAN FORMULATION 153

    Figure 6. The parallel five-bar linkage with one redundant constraint.

    = 0 and = 0 with a numerical accuracy. Using the correction scheme

    after each integration step (or a sequence of steps), constant H1 and C, used

    previously in the integration, can be applied. The variant correction schemes are

    q = M1CT(CM1CT)1 and q = M1CT(CM1CT)1, which are

    motivated in [4, 13]. These, however, depend on det(CM1CT) = 0, and as such

    do not apply to systems with massless links, redundant constraints and singular

    positions.

    6. The Case Studies

    Consider a planar parallel five-bar linkage (Figure 6a) with one redundant con-straint (the kinematics of the mechanism is unaffected by the removal of one of the

    links 2 or 4). Opening the closed loops by rending off the links 2 and 4, the eight

    mixed Lagrangian and Cartesian coordinates are q = [1 x2 y2 2 3 x4 y4 4]T.

    The eight constraint equations, the 8 8 constraint matrix C, and the 8-vector of

    the constraint accelerations are:

    1 = x2 0.5l cos 2 l cos 1 = 0,

    2 = y2 0.5l sin 2 l sin 1 = 0,

    3 = x2 + 0.5l cos 2 l cos 3 = 0,

    4 = y2 + 0.5l sin 2 l sin 3 = 0,

    5 = x4 0.5l cos 4 0.5l cos 1 = 0,

    6 = y4 0.5l cos 4 0.5l sin 1 = 0,

    7 = x4 + 0.5l cos 4 0.5l cos 3 = 0,

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    14/19

    154 W. BLAJER

    8 = y4 + 0.5l sin 4 0.5l sin 3 = 0,

    =

    0.5l22 cos 2 l21 cos 1

    0.5l2

    2

    sin 2 l2

    1

    sin 1

    0.5l22 cos 2 l23 cos 3

    0.5l22 sin 2 l23 sin 3

    0.5l24 cos 4 0.5l21 cos 1

    0.5l24 sin 4 0.5l21 sin 1

    0.5l24 cos 4 0.5l23 cos 3

    0.5l24 cos 4 0.5l23 cos 3

    ,

    C =

    l sin 1 1 0 0.5l sin 2 0 0 0 0

    l cos 1 0 1 0.5l cos 2 0 0 0 0

    0 1 0 0.5l sin 2 l sin 3 0 0 0

    0 0 1 0.5l cos 2 l cos 3 0 0 0

    0.5l sin 1 0 0 0 0 1 0 0.5l sin 4

    0.5l cos 1 0 0 0 0 0 1 0.5l cos 4

    0 0 0 0 0.5l sin 3 1 0 0.5l sin 4

    0 0 0 0 0.5l cos 3 0 1 0.5l cos 4

    .

    The maintenance of the constraints yields then 2 = 4 = 0 and 1 = 2. For

    1 = 3 = n (n = 0, 1, . . .) the rank of the matrix C is equal to seven (one

    redundant constraint), while for the singular positions 1 = 3 = n the rank

    of C decreases to six the number of degrees of freedom of the system switches

    from one to two. Assuming the links are thin and homogeneous bars, and that theapplied forces on the system are only the gravity forces, the dynamics of the system

    is defined by:

    M = diag

    m1l

    2

    3, m2, m2,

    m2l2

    12,

    m3l2

    3, m4, m4,

    m4l2

    12

    ; d = 0,

    f =

    m1gl cos 1

    20 m2g 0

    m3gl cos 4

    20 m4g 0

    T.

    Using the data m1 = m2 = m4 = 1 kg, l = 1 m, = 106 kg (as all

    the constraints express the prohibited relative translations in the joints, the unit

    of can be stated in kg), and the initial state values defined by 10 = 0 deg(singular position) and 10 = 2 s1, the obtained results of numerical simula-

    tion are shown in Figure 7 (solid lines). The dashed lines in the graphs illustrate

    the results obtained for the case m2 = 0 kg. A standard ODE solver based on

    RungeKutta fourth-order algorithm was used, and the integration time step was

    t = 0.02 s. As seen, the simulated motion goes smoothly through the singular

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    15/19

    AUGMENTED LAGRANGIAN FORMULATION 155

    Figure 7. The parallel five-bar linkage time-variations of the state variables and constraint

    reactions.

    positions, and the singularity of the mass matrix M does not affects the solution

    attainability. In calculations, throughout the whole simulation time, at most threeiterations according to the scheme (9) were required to achieve numerical accuracy

    |qi+1 qi| 1015 m s2, and at most two iterations according to the algorithm

    (10), used after each integration step, were required to keep the constraint viola-

    tions || 1015 m and || 1015 m s1. It may also be worth noting that

    the reactions of all constraints are determined, including the redundant constraints.

    These are obtained for the idealized case, however, when all the link lengths are

    exactly the same. In reality, even small variations in the link lengths may cause

    large deviations in the joint reactions. On the other hand, assumed the link length

    variations are negligible compared to the joint allowances, and the impact and

    stick-slip phenomena can be omitted due to the viscous lubrication, the present

    approach provides one with a method for at least estimation of the reaction forcesin an over-constrained rigid-body model.

    The smooth motion through the singular positions is possible since the addi-

    tional degree of freedom occurring in these positions (the rank ofC decreases from

    seven to six) is not activated. More strictly, the applied gravitational forces do not

    cause any difference between the accelerations 1 and 3 at the singular positions,

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    16/19

    156 W. BLAJER

    Figure 8. The parallel four-bar linkage.

    even though the links 1 and 3 are not for a moment constrained from accelerating

    independently. The physical singularity is thus not revealed, and the mathematical

    singularity (the rank loss ofC) is removed by the present formulation. The situation

    is different when applying a driving torque to the link 1 that is discussed in the

    sequel.

    Let us focus on the problem of the physical singularity referring to a simplified

    version of the hitherto mechanism, the parallel four-bar linkage shown in Figure 8a.The torque causes interim 1 = 3 when going through the singular positions

    1 = 3 = n (n = 0, 1, . . .), and this yields 1 = 3 and 1 = 3 at the next

    instant of time (Figure 8c). The state of the system just after the singular positions

    will thus be in conflict with the constraints on the system (at the singular positions

    the constraints vanish and allow 1 = 3, and then immediately retrieve and restrict

    from 1 = 3). As a consequence, when encountered a singular position in numer-

    ical simulation (or for a position very close to the singular position), the iteration

    process described in Equation (9) may not converge (or may converge very slowly).

    The lack of converge was also observed in [9], provided an explanation in terms of

    time step.

    To proceed with the numerical simulation through the singular positions whenthe arising additional degrees of freedom are activated, the following procedure

    is proposed. When encountered the physical singularity, which is detected by di-

    vergence of the iteration process (8) (or a large number of required iterations), the

    process is stopped after some reasonable number of iterations (for example, five),

    and Equations (7) are integrated to pass the singular position using the inconsist-

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    17/19

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    18/19

    158 W. BLAJER

    refer to [2, 69] for details), redundant constraints and singular positions. Some

    of the bodies of the system can also be modeled massless. The physical constraint

    reactions, including the reactions of redundant constraints, can also be estimated.

    The formulation can be applied without any restrictions to systems modeled

    in absolute coordinates. Either open-loop or closed-loop systems, with possible

    redundant constraints and/or singular configurations can be treated this way. When

    modeling a closed-loop system in a smaller set of coordinates, it is recommen-

    ded to open the loops by rending off the whole bodies instead of cutting off the

    joints, which leads to a mixed join/absolute coordinate formulations of constrained

    systems (illustrated in Figure 5c). This is especially important for systems with

    redundant constraints and/or singular positions. The bodies modeled massless must

    also be first rent off from the other links, and modeled as free bodies in absolute

    coordinates. These cannot be the last links of the open chains, however. There are

    also some numerical precautions in proceeding the motion through the singular

    positions.

    Acknowledgments

    The bulk part of the work was prepared during the authors stay in the Institute B of

    Mechanics, University of Stuttgart, Germany, on behalf of the Alexander von Hum-

    boldt Fellowship. The research has also been supported by the State Committee for

    Scientific Research, Poland, under grant 9 T12C 060 17.

    References

    1. Schiehlen, W. (ed.), Multibody Systems Handbook, Springer-Verlag, Berlin, 1990.

    2. Garca de Jaln, J. and Bayo, E., Kinematic and Dynamic Simulation of Multibody Systems:The Real Time Challenge, Springer-Verlag, New York, 1994.

    3. Shabana, A.A., Computational Dynamics, John Wiley & Sons, New York, 1994.

    4. Blajer, W., A geometric unification of constrained system dynamics, Multibody System

    Dynamics 1, 1997, 321.

    5. Schiehlen, W., Multibody system dynamics: Roots and perspectives, Multibody System

    Dynamics 1, 1997, 149188.

    6. Bayo, E., Garca de Jaln, J. and Serna, M.A., A modified Lagrangian formulation for the dy-

    namic analysis of constrained mechanical systems, Computer Methods in Applied Mechanics

    and Engineering 71, 1988, 183195.

    7. Bayo, E. and Avello, A., Singularity free augmented Lagrangian algorithms for constrained

    multibody dynamics, Nonlinear Dynamics 5, 1994, 247255.

    8. Bayo, E. and Ledesma, R., Augmented Lagrangian and mass-orthogonal projection methods

    for constrained multibody dynamics, Nonlinear Dynamics 9, 1996, 113130.

    9. Cuadrado, J., Cardenal, J. and Bayo, E., Modeling and solution methods for efficient real-time

    simulation of multibody dynamics, Multibody System Dynamics 1, 1997, 259280.

    10. Arnold, V.I., Mathematical Methods of Classical Mechanics, 2nd edn., Springer-Verlag, New

    York, 1989.

    11. Baumgarte, J., Stabilization of constraints and integrals of motion in dynamical systems,

    Computer Methods in Applied Mechanics and Engineering 1, 1972, 116.

  • 7/28/2019 Augmented Lagrangian Formulation Geometrical

    19/19

    AUGMENTED LAGRANGIAN FORMULATION 159

    12. Nikravesh, P.E., Computer-Aided Analysis of Mechanical Systems, Prentice-Hall, Englewood

    Cliffs, NJ, 1988.

    13. Blajer, W., State and energy stabilization in multibody system simulations, Mechanics

    Research Communications 26, 1999, 261268.