Redundancies in Multibody Systems and Automatic Coupling of CATIA and Modelica



Similar documents
EQUATIONS OF LINES AND PLANES

Appendix D: Completing the Square and the Quadratic Formula. In Appendix A, two special cases of expanding brackets were considered:

Or more simply put, when adding or subtracting quantities, their uncertainties add.

Section 7-4 Translation of Axes

Reasoning to Solve Equations and Inequalities

FAULT TREES AND RELIABILITY BLOCK DIAGRAMS. Harry G. Kwatny. Department of Mechanical Engineering & Mechanics Drexel University

CS99S Laboratory 2 Preparation Copyright W. J. Dally 2001 October 1, 2001

Vectors. The magnitude of a vector is its length, which can be determined by Pythagoras Theorem. The magnitude of a is written as a.

. At first sight a! b seems an unwieldy formula but use of the following mnemonic will possibly help. a 1 a 2 a 3 a 1 a 2

Pentominoes. Pentominoes. Bruce Baguley Cascade Math Systems, LLC. The pentominoes are a simple-looking set of objects through which some powerful

Graphs on Logarithmic and Semilogarithmic Paper

Pure C4. Revision Notes

P.3 Polynomials and Factoring. P.3 an 1. Polynomial STUDY TIP. Example 1 Writing Polynomials in Standard Form. What you should learn

Unit 6: Exponents and Radicals

Use Geometry Expressions to create a more complex locus of points. Find evidence for equivalence using Geometry Expressions.

A.7.1 Trigonometric interpretation of dot product A.7.2 Geometric interpretation of dot product

Experiment 6: Friction

Multiplication and Division - Left to Right. Addition and Subtraction - Left to Right.

Summary: Vectors. This theorem is used to find any points (or position vectors) on a given line (direction vector). Two ways RT can be applied:

Homework 3 Solutions

5 a LAN 6 a gateway 7 a modem

LINEAR TRANSFORMATIONS AND THEIR REPRESENTING MATRICES

Operations with Polynomials

9 CONTINUOUS DISTRIBUTIONS

AREA OF A SURFACE OF REVOLUTION

5.2. LINE INTEGRALS 265. Let us quickly review the kind of integrals we have studied so far before we introduce a new one.

Vector differentiation. Chapters 6, 7

Polynomial Functions. Polynomial functions in one variable can be written in expanded form as ( )

AntiSpyware Enterprise Module 8.5

Vectors Recap of vectors

Binary Representation of Numbers Autar Kaw

Mathematics. Vectors. hsn.uk.net. Higher. Contents. Vectors 128 HSN23100

PROF. BOYAN KOSTADINOV NEW YORK CITY COLLEGE OF TECHNOLOGY, CUNY

Sensorless Force Estimation for Robots with Friction

4.5 Signal Flow Graphs

e.g. f(x) = x domain x 0 (cannot find the square root of negative values)

Section 5.2, Commands for Configuring ISDN Protocols. Section 5.3, Configuring ISDN Signaling. Section 5.4, Configuring ISDN LAPD and Call Control

Bayesian Updating with Continuous Priors Class 13, 18.05, Spring 2014 Jeremy Orloff and Jonathan Bloom

2 DIODE CLIPPING and CLAMPING CIRCUITS

Exponential and Logarithmic Functions

Space Vector Pulse Width Modulation Based Induction Motor with V/F Control

Module 2. Analysis of Statically Indeterminate Structures by the Matrix Force Method. Version 2 CE IIT, Kharagpur

SPECIAL PRODUCTS AND FACTORIZATION

Section 5-4 Trigonometric Functions

Vectors and dyadics. Chapter 2. Summary. 2.1 Examples of scalars, vectors, and dyadics

Solenoid Operated Proportional Directional Control Valve (with Pressure Compensation, Multiple Valve Series)

Regular Sets and Expressions

LECTURE #05. Learning Objective. To describe the geometry in and around a unit cell in terms of directions and planes.

Rotating DC Motors Part I

Rotational Equilibrium: A Question of Balance

Applications to Physics and Engineering

Learning Outcomes. Computer Systems - Architecture Lecture 4 - Boolean Logic. What is Logic? Boolean Logic 10/28/2010

Vectors and dyadics. Chapter 2. Summary. 2.1 Examples of scalars, vectors, and dyadics

Cypress Creek High School IB Physics SL/AP Physics B MP2 Test 1 Newton s Laws. Name: SOLUTIONS Date: Period:

** Dpt. Chemical Engineering, Kasetsart University, Bangkok 10900, Thailand

Module Summary Sheets. C3, Methods for Advanced Mathematics (Version B reference to new book) Topic 2: Natural Logarithms and Exponentials

Example 27.1 Draw a Venn diagram to show the relationship between counting numbers, whole numbers, integers, and rational numbers.

Project 6 Aircraft static stability and control

Answer, Key Homework 10 David McIntyre 1

Outline of the Lecture. Software Testing. Unit & Integration Testing. Components. Lecture Notes 3 (of 4)

ORBITAL MANEUVERS USING LOW-THRUST

Review guide for the final exam in Math 233

MA Lesson 16 Notes Summer 2016 Properties of Logarithms. Remember: A logarithm is an exponent! It behaves like an exponent!

The Velocity Factor of an Insulated Two-Wire Transmission Line

Physics 43 Homework Set 9 Chapter 40 Key

Scalar and Vector Quantities. A scalar is a quantity having only magnitude (and possibly phase). LECTURE 2a: VECTOR ANALYSIS Vector Algebra

Math 314, Homework Assignment Prove that two nonvertical lines are perpendicular if and only if the product of their slopes is 1.

New Internet Radio Feature

6.2 Volumes of Revolution: The Disk Method

PHY 222 Lab 8 MOTION OF ELECTRONS IN ELECTRIC AND MAGNETIC FIELDS

Simulation of operation modes of isochronous cyclotron by a new interative method

0.1 Basic Set Theory and Interval Notation

Concept Formation Using Graph Grammars

1. Find the zeros Find roots. Set function = 0, factor or use quadratic equation if quadratic, graph to find zeros on calculator

Section 1: Crystal Structure

Quick Reference Guide: One-time Account Update

Scalable Mining of Large Disk-based Graph Databases

4.11 Inner Product Spaces

Modular Generic Verification of LTL Properties for Aspects

Network Configuration Independence Mechanism

Warm-up for Differential Calculus

Math 135 Circles and Completing the Square Examples

BUSINESS OWNERS PACKAGE INSURANCE APPLICATION

Vendor Rating for Service Desk Selection

9.3. The Scalar Product. Introduction. Prerequisites. Learning Outcomes

Introduction to Integration Part 2: The Definite Integral

Power consumption In operation At rest For wire sizing. Rated impulse voltage Control pollution degree 3. Non-operating temperature

1.00/1.001 Introduction to Computers and Engineering Problem Solving Fall Final Exam

Power consumption In operation At rest For wire sizing. Auxiliary switch

RTL Power Optimization with Gate-level Accuracy

Small Businesses Decisions to Offer Health Insurance to Employees

Radius of the Earth - Radii Used in Geodesy James R. Clynch February 2006

Euler Euler Everywhere Using the Euler-Lagrange Equation to Solve Calculus of Variation Problems

Factoring Polynomials

Rotating DC Motors Part II

GENERALIZED QUATERNIONS SERRET-FRENET AND BISHOP FRAMES SERRET-FRENET VE BISHOP ÇATILARI

Econ 4721 Money and Banking Problem Set 2 Answer Key

Multimedia Communications

According to Webster s, the

Transcription:

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 Redundncies in Multiod Sstems nd Automtic Coupling of CATIA nd Modelic Hilding Elmqvist 1, Sven Erik Mttsson 1, Christophe Chpuis 2 1 Dssult Sstèmes, Lund, Sweden (Dnsim) 2 Dssult Sstèmes, Veliz Villcoul, Frnce {Hilding.Elmqvist, SvenErik.Mttsson, Christophe.Chpuis}@3ds.com Astrct Trditionll, multiod sstems hve een defined in Modelic connecting odies nd joints in model digrm. Additionll the user must enter vlues for prmeters defining msses, inertis nd three dimensionl vectors of positions nd orienttions. More convenient definition of multiod sstems cn e mde using 3D editor ville, for emple, in CATIA from Dssult Sstèmes with immedite 3D viewing. A tool hs een developed tht trnsltes CA- TIA model to Modelic trversing the internl CATIA structure to get informtion out prts nd joints nd how the re relted. This informtion is then used to generte corresponding Modelic model. The trversl provides informtion out the reference coordinte sstem, the center of mss in the locl coordinte sstem, the mss, the inerti, the shpe nd color of the od eported in VRML formt for nimtion purposes nd the icon eported s PNG file to e used in the Modelic digrms. The Modelic digrm lout is utomticll generted nd is sed on the spnning tree structure of the mechnism. Models otined in this w often contin redundnt constrints. A new method hs een developed for Dmol to fcilitte simultion of such models, i.e. the model reduction is performed utomticll. An importnt propert of the trnslted model is the possiilit to use Modelic etends (inheritnce) for dding controllers nd other fetures of the model for dnmic simultion. For instnce, the engine model cn e etended introducing models of the gs forces of the comustion cting on the clindricl joints of the pistons. In tht w, the trnslted model is seprted nd cn e chnged independentl of the dded models. Kewords: MultiBod sstems, Modelic, CATIA 1 Introduction Trditionll, multiod sstems hve een defined in Modelic connecting odies nd joints from the MultiBod lirr (Otter et.l., 2004) in model digrm. More convenient definition of multiod sstems cn e mde using 3D editor, ville, for emple, in CATIA with immedite 3D viewing. See for emple the CAD model with kinemtic definition of four clinder engine in Figure 1. Figure 1. CATIA V5 model of engine This pper discusses how to utomticll derive corresponding Modelic model to enle dnmic simultion of the mechnism. The first prt of the pper descries Modelic code genertion, lout genertion nd how mechnicl model cn e etended for multi-domin dnmic simultion. The lst prt discusses how redundncies in the kinemtic definition re hndled. Engelson (2000) discusses utomtic trnsltion of SolidWorks models to n erlier version of the Modelic MultiBod lirr. However, this work did not consider utomtic hndling of kinemtic loops, utomtic selection of sttes nor elimintion of redundncies in the kinemtic definitions. Bowles et.l. (2000) present converter from ADAMS to Modelic. This converter mde utomtic lout of the Modelic code in similr w s to wht is descried in this pper. Cut joints were inserted uto- The Modelic Assocition, 2009 551 DOI: 10.3384/ecp09430113

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 mticll. However, plnr loops nd redundnt joints were not hndled. There re lso other simultion softwre vendors tht provide tools for conversion of CAD models to Modelic or similr formlisms. However, the require mnul modifiction fter the conversion to derive vlid model. This is complicted nd error prone tsk nd lso mkes mintennce of models hrder. 2 Modelic code genertion A tool hs een developed tht trnsltes CATIA V5 nd V6 models to Modelic trversing the internl CATIA structure to get informtion out prts nd joints nd how the re relted. This informtion is then used to generte corresponding Modelic model. Bodies nd joints re mpped to Modelic models from CATIA lirr written in Modelic. This lirr is wrpper lirr tht mps the models to Modelic.Mechnics.Multiod lirr or to specill written models. The CATIA prts re mpped to model clled BodShpe. The trversl provides informtion out the reference coordinte sstem, the center of mss in the locl coordinte sstem, the mss, the inerti, the shpe nd color of the od eported in VRML formt for nimtion purposes nd the icon eported s PNG file to e used in the Modelic digrms. The connector of the BodShpe od represents the center of mss of the od. The joints re mpped to models in the CA- TIA.Joints pckge, see Figure 2. Figure 2. CATIA pckge structure nd Kinemtics Joints toolr in CATIA V5. There is one to one mpping from the Modelic Joints to the corresponding Joints in CATIA. The joints include the necessr trnsltions nd rottions from the MultiBod joint frmes to the center of mss of the respective odies which the joint is ttched to. In ddition to the MultiBod joints, some new joint tpes such s point on curve were developed. The curve dt re retrieved from CATIA nd tle lookup is used in the joint model. The Modelic model corresponding to the CA- TIA model in Figure 1 is shown elow. It consist of 30 odies, 9 Revolute, 4 Clindricl (one for ech The Modelic Assocition, Modelic 2009 digrm for engine model 552

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 clinder), 8 Prismtic, 2 Ger (to drive the cmshfts), 8 PointCurve (one for ech vlve) nd 10 Rigid joints. In ddition, the trnsltor introduced 14 CutJoints, one for ech kinemtic loop. As n emple, the Modelic code for the crnkshft is shown elow: CATIA.Prts.BodShpe 'crnkshft 1'( m = 0.861027543288454, r_0_strt = {-0.182833605157492, 0.00863258496368804,-0.0978102539095819}, R_strt=MBS.Frmes.Orienttion( T=[ 0,-0.847538988037033, 0.530733137986643; 0.0199597528990819, -0.530627407596764, -0.84737014496106; 0.999800784288643, 0.0105933028037161, 0.0169166684516004], w={0,0,0}), r_cm = {-0.0584560176906743,0,0}, I_11 = 0.0116473560180544, I_21 = 0.000299454247697959, I_31 = -0.000193283295897208, I_22 = 0.00484290739689144, I_32 = 0.00442125657996889, I_33 = 0.00911887589804025, shpenme = "2", iconnme = "./crnkshft 1.png") nnottion (Plcement(trnsformtion(etent= {{-120,460},{-60,520}}))); The intil position, r_0_strt, nd orienttion, R_strt, re retrieved for consistent initil configurtion of the entire mechnism. Mss, m, nd inerti, I_11,, I_33 re clculted for the densit given in CATIA. The prmeter shpenme refers to the nme of VRML file (2.wrl) eported CATIA representing the shpe nd color of the od. The prmeter iconnme is the nme of PNG-file contining 2D projection of the od. It is used for the icons in the odies in the model digrm. A joint instnce is shown elow. It contins the is of rottion, n, nd fied trnsltions, r nd r, nd rottions, fiedrottion_ nd fiedrottion_, from the joint to the center of mss of the connected odies. In ddition, the joint instnce contins the initil configurtion, phi_strt, of the joint. CATIA.Joints.Revolute 'Revolute 5'( n = {0,0,1}, r = {0,0,0.124000000000001}, r = {0,0,0}, fiedrottion_( R_rel=MBS.Frmes.Orienttion( T=[0,0.907781470137235,-0.41944344371495; 0,0.419443443714955,0.907781470137245; 0.999999999999986,0,0], w={0,0,0})), fiedrottion_( R_rel=MBS.Frmes.Orienttion( T=[0,0.81704961687189,-0.576567362560056; 0,0.57656736256006,0.817049616871915; 0.999999999999979,0,0], w={0,0,0})), phi_strt = 1.07387718370489e-008) nnottion (Plcement(trnsformtion(etent= {{-70,660},{-50,680}}, rottion = 90))); Figure 3 shows the CATIA V5 representtion of kinemtic joints, i.e. Revolute.5 is connected in etween connecting rod_2.1 nd pin.2. Figure 3. CATIA V5 representtion of kinemtic joints in engine The corresponding Modelic representtion is two connections: connect('pin 2'.frme_, 'Revolute 5'.frme_ ); connect('connecting_rod_2 1'.frme_, 'Revolute 5'.frme_ ); 3 Lout Genertion The Modelic digrm lout is utomticll generted nd is sed on the spnning tree structure of the mechnism otined the clssicl depth-first serch lgorithm of grph theor. See the lout of the engine four clinders in the Modelic digrm for engine model ove nd in Figure 4 which shows the 4 clinders zoomed in. In this w, loops re generted nd plced side of the min rnches. Notice tht the closing of the loops re presented red connections. For the Engine, it is possile to see the four clinders nd the longest possile loop is strting t the crnk cse, pssing though clinder to the crnk shft nd then ck through nother clinder to the crnk cse. Then the other two clinders re detected s loops from the crnk shft to the lred-detected crnk cse nd plced correspondingl. Other loops re the snchroniztion elts nd vlve shfts. The root of the tree is the fied od present on the CATIA model. The Modelic Assocition, 2009 553

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 The possil etended generted Modelic model is smolicll trnslted to ODE form in the usul w involving finding sstems of simultneous equtions, mking inde reduction nd utomtic stte vrile selection. For detils, see Otter et.l. (2007) nd Mttsson et.l. (2000). The engine model contins point on curve joints. This mens constrint descried tulr dt. The inde reduction requires the constrints to e differentited twice. The impliction ws tht the tulr dt ws used for genertion of splines which could e differentited twice. In ddition, the engine model contins redundnt joints. Specil methods were developed to hndle those, See section 6. In fct the model hs onl one degree of freedom, the crnk ngle. The utomticll generted model ws etended nd constnt torque genertor ws dded to drive the crnk shft. Figure 5 shows plots of torque, ccelertion nd the position of ech of the clinders. It cn e seen tht the inerti is not constnt since ccelertion is time vring. In fct the mplitude of inerti vritions increses for higher ngulr speeds. Figure 4. The four clinders zoomed in. 4 Incorporting dnmics etending An importnt propert of the trnslted model is the possiilit to use Modelic etends (inheritnce) for dding controllers nd other fetures of the model for dnmic simultion. For instnce, the engine model cn e etended introducing models of the gs forces of the comustion cting on the clindricl joints of the pistons. In tht w, the trnslted model is seprted nd cn e chnged independentl of the dded models. CATIA models do not contin force spects. This mens tht springs, dmpers, friction nd other force elements hve to e dded in the Modelic ler. Actutors such s electricl motors or hdrulic sstems s well s sensors nd control sstems re lso dded to the Modelic ler. Figure 5. Simultions results. The results cn e nimted since ll odies re represented VRML. The nimtion in Dmol cn e seen in Figure 6. 5 Simulting engine The Modelic Assocition, 2009 554

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 It is true tht joints constrin the sme motion in the model. From kinemtics point of view this model is equivlent to the model Door1 in Figure 8. door 20 hinge1 Figure 6. Dmol nimtion of dnmic ehvior. 6 Redundncies in MultiBod Sstems The pproimtion or ideliztion tht odies of multiod sstems re rigid implies, unfortuntel, tht it is not possile to determine forces cting on the memers of n structure. As sic emple, let us model door with two hinges the simple model Door1 in Figure 7. frme hinge2 hinge1 Figure 7. The model Door1 rod2 door The oject door represents the door s one rigid od. The house nd the door frme re represented the ojects nd frme. Ech of the two hinges is represented revolute llowing the door to rotte long verticl is, the -is. This model does not trnslte, ecuse it is singulr. The error dignosis from Dmol contins the following messge: The model includes the following hints: All Forces cnnot e uniquel clculted. The reson could e tht the mechnism contins plnr loop or tht joints constrin the sme motion. 20 Figure 8. The model Door1 which is kinemtics equivlent to the model Door1. In other words, the door in the two models cn onl rotte round the verticl is, the -is. When it comes to forces, the two models re different. The model Door1, requires hinge1 tke ll lods, while the model Door1 llows the lod to e shred two hinges. Wh do doors hve t lest two hinges? The hinges not onl lnce the verticl force due to grvit, ut the need lso lnce the torque due to grvit. When hving just one hinge, this hinge hs to provide rective torques in the nd directions. There will lws e some pl in rel hinge nd such door would not ehve s desired. When using two hinges, the lncing torque cn e relized force pir. When hving two hinges more relistic model could e to use sphericl joints to descrie the hinge. A sphericl joint does not produce n rection torque nd we cn view s w of tking the pl into ccount. The lncing torque must e produced force pir from the two sphericl hinges. Unfortuntel, such model is still singulr. In rel life, we know tht it is importnt to mount the hinge prts in the frme in the door with good ccurc. If not, the verticl lod will not e shred, ut one of the hinges hs to tke ll verticl lods. To mke the model non-singulr, one of the hinges hs to include prismtic joint in the verticl direction, which mens tht the other hinge hs to tke ll verticl lods. You could think of letting oth hinges hve two ctuted prismtic joints nd use springs nd dmpers to split the verticl lods. However, if we just wnt to know how the door moves due to eternl forces, such model would e unnecessr comple. When the desire is to model the dnmic ehvior of the door, it is just necessr to get the ccelertion correct. For rigid od, we need then to get the to- The Modelic Assocition, 2009 555

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 tl forces nd torques cting on it correct. We need not consider how the forces nd torques cting on the od re distriuted over the od. For the door, we need onl the sum of the forces nd torques cting on the od with respect to some common point, s, the center of inerti. We cn in fct prescrie n vlue of the verticl rection torque from hinge2, ecuse, hinge1, will utomticll counter lnce it nd the sum will e correct. The technique to rel redundnt position or orienttion constrints prescried forces nd torques is to introduce cut joints. Below we will introduce the concept of cut joints nd how Dmol hndles selection of constrints within cut joints utomticll. 6.1 Introducing cut joints in kinemtic loops Redundncies in multiod sstems cn onl pper when there re kinemtic loops. The model Door1 hs the loop: frme, hinge2, rod2, door, hinge1, nd ck to frme. When trversing the CATIA model structure to generte the Modelic model, the tool keeps trck of kinemtic loops nd introduces cut joint in ech kinemtic loop. Thus the model of the door, cll it Door2, will include cut joint. Let us plce it etween hinge2 nd rod2 s shown in Figure 9. Actutors hve lso een introduced for testing purposes. trpetzoid2 period=100 trpetzoid1 period=100 tu tu torque2 torque1 frme Figure 9. The model Door2. hinge2 hinge1 rod2 door 20 The sic mening of the cut-joint is tht the position nd orienttion should e the sme. However, it cn hndle the fct tht these constrints might e redundnt, i.e., the might e deduced without considering the cut-joint constrints. The cut joint does this giving epressions for the reltive positions nd orienttions of the two connector frmes. The constrint sing tht these should e zero is given specil function with the interfce function conditionlconstrint( input Boolen condition; input Rel u1; input Rel u2; output Rel ; end conditionlconstrint; The sic mening is = if condition then u1 else u2; It is used vectorized in the cut joint s fill(0, 6) = conditionlconstrint( conditions, {r_rel_[1], r_rel_[2], r_rel_[3], phi[1], phi[2], phi[3]}, {f_c[1], f_c[2], f_c[3], t_c[1], t_c[2], t_c[3]}); The first ctul rgument is Boolen vector with 6 elements. The second rgument includes the reltive positions nd rottions, while the third rgument includes the forces nd torques in the corresponding directions. A user could set elements of conditions to flse to replce redundnt position or orienttion conditions postulting corresponding forces or torques to zero. Unfortuntel, relistic pplictions hve mn loops nd since there 2 6 = 64 ws of setting the vector conditions for ech loop, there is comintoril eplosion. It is not fesile to set cutjoints mnull. Dmol supports utomtic selection of which of the constrints to use in order to hve well-posed prolem. In simple cses this cn e done stticll t trnsltion otherwise it is done dnmicll t simultion. Initiliztion of models with kinemtics loop m e non-trivil issue; in prticulr when there re conditionl constrints to select. Fortuntel, CATIA hs powerful kinemtics solver, which mens tht the Modelic models generted from CATIA model structure cn e provided with consistent initil vlues, so there is no need for generting code for initiliztion. Dmol llows plotting of the Boolen conditions vector in the usul w during nd fter simultion. Dmol lso reports the finl selection s new model etending from the model simulted with modifiers setting the condition vector of ll conditionlconstrint functions: The Modelic Assocition, 2009 556

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 model Door2_Fied_Constrints etends Door2(cutJoint.conditions= {flse, flse, flse, flse, true, flse}); end Door2_Fied_Constrints; Note tht ll elements re flse ut the fifth. It mens tht Dmol hs rell cut the loop. The fifth element represents rottion long the -is. In this respect the cut joint is in series with hinge1 tht llow this rottion. Two revolute joints with the sme is of rottion without inerti in etween impl miguit etween the rottion ngles of the two revolute joints nd such model would thus e singulr. Tpicll ou need just to simulte the model to hve it initilized, i.e., simulte with strttime = stoptime. A model otined in this w cn e used s sis for further model development nd simultion where Dmol s utomtic selection is disled. For emple, initiliztion equtions re now supported in usul w. We hve presented generl cut joint with conditionl constrints. It cn e plced nwhere in loop with one importnt eception. It cnnot e plced in series with sphericl joint if there is no inerti in etween. A sphericl joint puts no constrints on the orienttion. It is hs no Connections.rnch( ) defined etween its frme connectors to hndle the over determined connectors descriing the orienttion. The sme pplies for the cut joint. It mens tht the prt etween the sphericl joint nd the cut joint hs no root defined to hndle the normliztion of the overdetermined prt of orienttion description. To solve this prolem, we hve introduced specil sphericl cut joint. Such joint onl hs the position constrints conditionl. 6.2 Emple: The door model revisited Let us consider the door model once more nd put the cut joint t nother plce in the loop, nmel etween rod2 nd door s shown in Figure 10. trpetzoid2 period=100 trpetzoid1 period=100 tu tu torque2 torque1 Figure 10. The model Door3. hinge2 hinge1 rod2 rod3 door Assume tht the cut-joint would rek the loop completel, i.e, ll conditions re flse. It mens tht hinge2 llows rod2 to rotte in plne prllel to the -z plne. It mens tht cut joint cnnot rek the loop completel, ut hs to select one constrint. There re two possiilities. First, s for Door2, it cn lock the rottion in the direction of the verticl is. Cll this ngle φ nd thus the ctive constrint will e φ = 0. Secondl, the motion cn e prevented requiring the reltive displcement of the cut joint in the z direction, Δz = rod2.r sin φ to e zero, thus requiring φ = 0. The selection of constrints is sed on nlzing the Jcoin of the constrints. For φ 0, we hve Δz rod2.r φ. It mens tht if rod2.r < 1, the condition, φ = 0 will e selected. Otherwise the conditions Δz = 0 will e selected. The two will give the sme ccelertions nd the door will move in ectl the sme w. However, the torques nd forces t the connector frmes of the cut joint will e different. Choosing φ = 0 s the ctive constrint in the cut joint, will set ll forces nd torques of the cut joint to zero, ecept for the torque in the direction, cutjoint.frme_.t[2], which will propgte the torque due to the ctution of hinge2. Choosing Δz = 0 s the ctive constrint in the cut joint, will set ll forces nd torques of the cut joint to zero, ecept for the force in the z direction, cutjoint.frme_.f[3], which will propgte the effects of the ctution of hinge2. Putting cut joint close to hinge2 does not influence the possiilities to hve ctution on it. This is etter lterntive thn removing it completel s done in model Door1. 1 6.3 Plnr kinemtics loops The door model is n emple of model hving redundnt joints, i.e., joints constrining the sme The Modelic Assocition, 2009 557

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 motion. The error messge for the model Door1 indicted nother possiilit, nmel possiilit of the loop eing plnr. Consider the sstem PlnrLoop1 in Figure 11. cutjoint.conditions[5] = flse; The model PlnrLoop1 is uilt nicel in coordinte plne z = 0. Fr from ll Modelic models generted from the CATIA models structure is tht wellehved. Dmol must e le to find n plnr loop independent of which plne it eists in. Let us define the mechnism in the plne -sin()* + cos()*z = 0 It mens tilting of the mechnism long the -is n ngle,, s shown in Figure 13. Figure 11. The sstem PlnrLoop1. The sstem is uilt rs ling in - plne nd connected revolute joints with their es of rottion prllel with the z is. A model is shown in Figure 12. r1 r={0,0.5,0} n={0,0,1} r2 n={0,0,1} rod2 odshpe 1 r={0.6,0,0} r4 n={0,0,1} Figure 12. The model PlnrLoop1. r3 n={0,0,1} rod3 r={0.1,0.5,0} od Dmol selects the constrints in the following w: model PlnrLoop1_Fied_Constrints etends PlnrLoop1(cutJoint.conditions= {true, true, flse, flse, flse, true}); end PlnrLoop1_Fied_Constrints; Since the third rgument is selected to flse, the loop is cut in the z-direction, i.e., the position constrint in the z direction is redundnt. First, the sstem cnnot move in the z direction t ll, ecuse ll joints re revolute joints with their es of rottion prllel with the z is. Strting from going the pth rod2, r4 we cn deduce tht the left end of the cut joint hs lws cutjoint.frme_.r[3] = 0. Going the other w from we find in similr w tht cutjoint.frme_.r[3]. This mens tht the position constrint in z-direction of the cutjoint is redundnt. The components cnnot rotte long n es in the - plne. This eplins wh Dmol selected cutjoint.conditions[4] = flse; m=1 Figure 13. The sstem PlnrLoop2 in two positions. The model is shown in Figure 14. r1 r=nr1 n=nrev r2 n=nrev rod2 odshpe 1 r={0.6,0,0} r4 n=nrev Figure 14. The model PlnrLoop2. r3 n=nrev rod3 r=nr1 + {0.1,0,0} od The model PlnrLoop2 is n etension of Plnr- Loop1, introducing the prmeters, nrev = {0, - sin(), cos()} nd nr1 = 0.5*{0, cos(), sin()}, nd modifing the es of rottions of the revolute joints nd the es of nd rod3. When the ngle is smll i.e., -45º< <45º, Dmol selects the constrints s for the model Plnr- Loop1, which is the specil cse =0. For -90º< <- 45º or 45º< <90º for Dmol selects the constrints in the following w: model PlnrLoop2_Fied_Constrints etends PlnrLoop1(cutJoint.conditions= {true, flse, true, flse, true, flse}); end PlnrLoop2_Fied_Constrints; Simpl sid, ou get the selection of the coordinte plne to which ou hve lest tilt ngle. m=1 The Modelic Assocition, 2009 558

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 6.4 Emple: A crnk shft, piston nd clinder mechnism. Consider the model Engine1, which is found in Modelic.Mechnics.MultiBod.Emples.Loops. see Figure 15 nd 16.. Figure 15. An nimtion of Engine1. component clinder t the top is not clindricl joint s might e epected, ut prismtic joint. This joint does not llow the piston to rotte. If B1 hd een rel revolute joint then the crnk mechnism hd prevented rottion of the piston long its length is. Unfortuntel, when B1 is plnr cut joint, then the piston cn rotte. The component Clinder eing just prismtic joint fies tht. The new universl cut joint nd the utomtic constrint selection of Dmol relives the user from such comple fiing of the model. Let us mke more nturl, strightforwrd model, cll it Engine. It is similr to Engine1, ut B1 is n ordinr revolute joint nd Clinder is clindricl joint. Additionl we dd cutjoint etween clposition nd Clinder, ecuse there is kinemtics loop. Dmol trnsltes nd simultes this model without n prolems. Dmol reports the following selection of constrints for cutjoint: model Engine_Fied_Constrints etends Engine(cutJoint.conditions= {flse, true, true, true, true, flse}); end Engine_Fied_Constrints; Note, tht the conditions vector hs onl two elements selected to e flse. Reconsider the model Engine1. The revolute cut-joint B1 mens selecting the condition vector to e {flse, true, true, true, flse, flse} The fifth element is here flse. It mens tht the revolute plnr cut joint is cutting the loop it too much. If Clinder in model Engine1 would hve een clindricl joint, the prt etween B1 nd Clinder hd een free to rotte long the is. Selecting Clinder to e prismtic joint prevents the rottion long the -is. 7 Conclusions A method for coupling kinemtic CAD models, in prticulr CATIA models, to Modelic hs een descried. Since such models often contin redundnt joints, new comined structurl, smolic nd numericl technique hs een developed for Dmol to hndle such models. Detils were given out tpicl such redundnt kinemtic definitions nd how the new method hndles those. Figure 16. The model Engine1. The model is intricte. First, the revolute joint B1 is revolute plnr cut joint indicting tht it is prt of plnr loop. This is m e not tht difficult to understnd when looking t Figure 15. However, the 8 Acknowledgements The uthors would like to thnk Mrtin Otter (DLR) nd Hns Olsson (Dnsim) for their contriutions. The Modelic Assocition, 2009 559

Proceedings 7th Modelic Conference, Como, Itl, Sep. 20-22, 2009 References Bowles P., Tiller M., Elmqvist H., Brûck D., Mttsson S.E., Möller A., Olsson H., Otter M (2000).: Fesiilit of Detiled Vehicle Modeling. SAE World Congress 2000. Dmol (2009). Dmol Version 7.3. Dssult Sstèmes, Lund, Sweden (Dnsim). Homepge: www.dmol.com. Engelson V. (2000): Tools for Design, Interctive Simultion, nd Visuliztion of Oject-Oriented Models in Scientific Computing. Deprtment of Computer nd Informtion Science, Linköping Universit, Sweden. Mttsson S.E., Elmqvist H., nd Olsson H. (2000): Dnmic Selection of Sttes in Dmol. Proceedings of Modelic Workshop 2000, pp. 61-67. Downlod: http://www.modelic.org/events/workshop2000/p roceedings/mttsson.pdf Otter M., Elmqvist H., Mttsson S.E. (2003): The New Modelic MultiBod Lirr. Proceedings of Modelic 2003, ed. P. Fritzson, pp. 311-330. Downlod: http://www.modelic.org/events/conference2003 /ppers/h37_otter_multiod.pdf Otter M., Elmqvist H., Mttsson S.E. (2007): Multidomin Modeling with Modelic. Hndook of Dnmic Sstem Modeling, Chpter 36, Ed. P. Fishwick, Tlor & Frncis Group LCC. The Modelic Assocition, 2009 560