A Uni ed Model for Physically based Animation and Simulation Remi Cozot IRISA Campus de Beaulieu 35042 Rennes Cedex FRANCE
[email protected]
Bruno Arnaldi IRISA Campus de Beaulieu 35042 Rennes Cedex FRANCE
[email protected]
Abstract This paper presents the design of an expandable animation system in which rigid and deformable multibody systems are animated from the high-level model of physical objects. This new model called dream (Deformable and Rigid objects Ecient for Animation Modelling) makes the simulation of rigid and deformable interconnected objects easy to design and to implement. dream is based on a uni ed abstracted model described by an entity relationship formalism. Traditionnal physically based models such as rigid solids and deformable objects (described by nite elements or by punctual mass-spring meshes) come from this common formalism. That is why our system integrates and uni es the physical models used in computer animation. Then the motion equations are automatically computed in a symbolic form by applying the principle of virtual works and Lagrange's equations. Theoretical, numerical and practical aspects of the model implementation and some experimental results are presented. Finally, the applicability of our animation system to scienti c simulation is discussed. Key Words: Modelling, Physically based animation, Multibody systems simulation.
1 Introduction Object animation requires motion coordination. Traditional animation systems, where the animator explicitly controls motions and deformations, become inadequate when the scene contains many objects whose motions due to physical properties. For this reason, the use of simulation methods in animation has been considerably investigated. Simulations models, called generative models, make the auto-
Georges Dumont ENS Cachan antenne de Bretagne Campus de Kerlann 35170 Bruz FRANCE
matic computation of motion and deformation possible. These mechanical simulations require a physical object model, a motion equation computation tool and a motion equation solver. Amstrong and Green rst introduced physically based animation to animate articulated rigid objects. Since, two main approaches are commonlyused to automatically build the motion equations : the rst one is based on a newtonian formalism [1] while the second relies on D'Alembert's principle of virtual works [2]. A lot of materials are deformable and cannot be modelled as rigid objects. Two main classes of deformable object models are commonly used in computer graphic animation : models based on the continuous mechanical equations and substitution models based on masses-springs meshes. The models based on the continuous mechanical equations are derived from the general equations of continuum mechanics [8]. To solve the motion equations, one has to apply a spatial discretisation scheme (the nite dierence or the nite element method). In order to reduce the computation complexity for such material, one can use a substitution model as the one based on punctual mass-spring meshes [5]. The masses are concentrated on the nodes of the mesh while the structural behavior is represented by the springs linking the nodes. Such simulators become intractable when only one material model cannot accurately express the complex behavior of natural phenomena [3]. That is why the modelling and the simulation of objects having dierent materials behaviors are necessary. We want to spe cy a new model called dream which provides both easy building of mixed model objects and simulation of physical interactions between the physical models. For this purpose, dream is described
by an high-level entity-relationship formalism and an internal homogeneous representation. In Section 2, we propose our model : dream. Section 3 describes a rst implementation. The automatic derivation of symbolic motion equations is explained. The simulation of car of which rear suspension is composed of deformable beams illustrates the implementation of dream. The last section discusses the capability of our system to perform simulations and nally indicates the directions of ours future works.
2 DREAM A review of previous works points out the four most important physically based models in computer animation : rigid solids, nite elements, nite dierences and punctual mass-spring meshes. Most present physically based animation systems account for only one of these models, that is why the users cannot easily model the behaviors of other material models. But, most of the natural materials or objects integrate dierent material behaviors : solid and deformable. Our goal is to enable the homogeneous integration of these dierent models into a uniform data structure. In addition, we want to design and implement the algorithm which computes and simulates our abstracted model.
2.1 Uni ed abstracted model
We consider that all physically based models can be described by a common entity-relationship formalism. Indeed, each model is composed of a set of entities and a set of relationships. The relationships link entities together. Thus, rigid solids are composed of rigid solid entities and joint relationships ; mass-spring meshes are composed of punctual mass entities and spring relationships ; and nally nite elements model are composed of element's node entities and element relationships. This formalism provides the user with new tools to model and create complex objects : any rigid and deformable interconnected multibody object is a graph in which the nodes are entities and the links are relationships . The entityrelationship formalism enables to naturally manipulate, integrate dierent models and so to easily create mixed models objects. Now, we describe the internal uni ed description of the dierent entities and relationships.
Three elements describe the internal dream's description : - motion frame describes the degrees of freedom of an entity according to a coordinate system. Each motion frame is de ned according to a reference motion frame by a frame to frame transformation matrix. - motion links are symbolic expressions which express the relationships between the entities degrees of freedom. They are attached to the motion frame de ning the relevant entity degrees of freedom. - attributes of the entities and the relationships are relative to physical data. Each attribute is associated with a motion frame or with a motion link. On the one hand, our uni ed abstract model accurately describes mechanical systems. This description is directly understandable by the algorithm. This model constitutes the low level description. On the other hand, the entity relationship formalism allows a user to manipulate macro components : solid rigids, nite elements, springs, joints, etc... It is the high level description. Table 2.1 gives the description of the dream's entities and relationships into the low level representation. Entity rigid solid
Low level Description motion frame inertial attributes punctual mass motion frame mass attribute element node motion frame Relationship Low level Description joint constraint motion link spring motion link of deformation energy stiness attribute element motion link of deformation energy density, elasticity attributes interpolation functions attributes
Table 1: High level and low level descriptions
2.2 Algorithm
The algorithm automatically builds the motion equations from the low-level description of the scene by applying a lagrangian formalism which can deal with general multibody systems [6, 7]. The following list describes the computation scheme : - rstly, the algorithm traverses the motion frame graph and creates the kinematic tree ; - secondly, it computes the kinetic energies C of each
element using the kinematic tree ; these elements are either the mass and inertial matrices (attached to motion frames) or density of nite elements (attached to motion links) ; - then, on one side the deformation and potential energies W of the springs and of the nite elements are computed ; on the other side the works of given forces are calculated ; - afterwards the Lagrange formula for the kinetic, deformation and potential energies is applied and the generalized given actions are built : this leads to a rst set of motion equations ; - we have to take into account the constraints acting on the system ; for this purpose, the jacobian matrix of the constraints and the Lagrange multipliers are computed. Finally, as a result we obtain the complete motion equation system :
3 A detailled Example 3.1 Analysis of the example
In this section, we illustrate the implementation of dream by the simulation of a new car prototype of which rear suspension is made up of a deformable beam instead of rigid bodies, springs and dampers. The bending of the girder gives the wheel degree of freedom. Two spin joints connect the beam to the car body and two dampers (between the car body and the wheels) absorb the vibrations (Cf Figure 1). damper
8 Q ? d @ + @ + @ + l @hl + m @nm = 0 < k dt @qk @qk @qk @qk @ qk h (q; t) = 0 : nlm (q; q;_ t) = 0 C
C
W
_
spin joint
0
deformable beam
_
(1) where : Qk is a generalized given eect related to the parameter qk ; k 2 [1; N], l is a Lagrange's multiplier associated with the holonomic constraints hl l 2 [1; p], m is a Lagrange's multiplier associated to the non-holonomic constraints nm m 2 [1; p ]. At this step, a nite dierence scheme is applied to discretize the equation with respect to time. For each time step, a numerical resolution of the nonlinear obtained system f(q) = 0 is performed by using a Newton Raphson algorithm. 0
0
2.3 DREAM's prototype The actual dream prototype is composed of two parts. The rst one takes a le which contains the dream high level description as input. This part is written in caml language [4]. It computes the high level description and creates a le which contains the symbolic expressions of the kinematic energies, the deformation energies, the potential energies and the force works. This le is the input for our simulator (nmecam) [2] which symbolically builds the motion equations using a lagrangian formalism. Then the motion equations are solved to give the simulation results.
Figure 1: Car prototype Once the car prototype has been described by mean of entities and relationships, the system converts it into the low level description (table 2.1 shows the correspondance between the high level description and the low level description). Figure 2 illustrates partial dream low level descriptions of car prototype rear suspension. Then, the algorithm described in section 3.2 computes the dream low level description to automatically build the motion equations of the system. F. E. Node Motion Frame pin joint
density interpolating fonction
Rear Suspension
finite element
inertial matrix
F. E. Node Motion Frame
elasticity
mass
density interpolating fonction
finite element
pin joint Body Motion Frame
elasticity F. E. Node Motion Frame
damper
viscosity
pin joint constraint
inertial matrix inertial matrix attribute
Wheel Motion Frame
motion frame
Ground Motion Frame
reference motion frame
Absolute Motion Frame motion link
Figure 2: Partial low level descriptions
3.2 Results
Two experiments were carried-out for validating a new design of car suspension system. In the rst one, a car tted with a classical suspension system was simulated and the results were compared to the trajectories obtained from a real vehicle. Good matching between the simulated results and the real measurements was observed. In the second experiment, the simulated car model is tted with a new kind of suspension system (described in the previous section). dream was used to simulate the two cars on a sine wave road with phase opposition between the right and the left wheels. Qualitative performance of the new design could be assessed by the simulation (Cf gure 3).
4 Conclusion
animation and simulation tool. It can compute the motions of articulated rigid or deformable bodies, exploiting methods widely used in simulation. Then simulation and animation tools share some model representations and computation methods. But the goals are quite dierent. The accuracy of the values obtained by simulation application makes necessary to use more complex structures to represent the objects. In computer animation, some simpli cations are made on the mechanical model itself and on the numerical solving step to achieve the computation with a maximal time rate. In fact, the mechanical model in animation application is often simpler that the eective geometrical model displayed on the screen. Our futur works will be concerned the animation of large scenes. The aims of this research are, on the one hand, to automatically infer automatically lacking interactions in a incomplete low level description and, on the other hand, to nd heuristic to reduce the complexity of such scenes.
We have validated the dream's model using the current prototype. dream provides an homogeneous integration of the physical models for computer animation and so enables the user to easily create interconnected rigid and deformable multibody systems. Our new model is based on an high level entity-relation [1] W.W. Armstrong and M.W. Green. The dynamics of articulated rigid bodies for the purposes of animation. formalism and on an low level uni ed abstracted deThe Visual Computer, 1(4):231{240, December 1985. scription of the physical models.
References
0.5
[2] B. Arnaldi, G. Dumont, and G. Hegron. Animation of physical systems from geometric, kinematic and dynamic models. In T. L. Kunii, editor, Proc. of Working Conference on Modeling in Computer Graphics, pages 37{53, IFIP TC 5/WG 5.10, Springer Verlag, Tokyo, Japan, April 1991. [3] N. Badler, C. Phillips, and B. Webber. Simulating Humans. Oxford University Press, Inc, 200 Madison Avenue, New York, New York 10016, 1993. [4] X. Leroy. The Caml Light system. Documentation and user's manuel. Technical Report, INRIA, 1993. Included in CAML light 0.6 distribution. [5] M. P. Moore. A Flexible Object Animation System. Technical Report UCSC-CRL-87-19, Baskin Center for Computer Engineering & Information Sciences, University of California, Santa Cruz, September 1987. [6] W.O. Schielen. Computer generation of equations of motion. In E.J. Haug, editor, Computer Aided Analysis and Optimisation of Mechanical System Dynamics, pages 183{215, Springer-Verlag, 1984. [7] Ahmed A. Shabana. Dynamics of Multibody Systems. Wiley Interscience, 1989. Figure 3: Comparaison between two cars [8] Demetri Terzopoulos. New Trends in Animation and Visualization, chapter Deformable Models: Formulations and Applications. John Wiley Sons, 1992. Indeed, dream is a physically based computer ’rigid bodies suspension classical car’ ’deformable suspension car prototype’
height
0.48
0.46
0.44
0.42
0.4
0.38
0
100
200
300
400
500
600
700
800
0.2 0.15 0.1 0.05 0 -0.05 -0.1
900
1000
time
Body’s height
rigid bodies suspension classical car deformable suspension car prototype
roll
-0.15 -0.2
0
100
200
300
400
500
Body’s roll
600
700
800
900
time
1000