A h ierarch ical data structu re for representing assemblies: part 1 Kunwoo Lee and David C Gossard* A data structure representing assemblies in a database can be divided into two parts. The first part is the data structure used to store topological and geometric information on each component in an assembly. The second part Is the data structure used to store information on how all the components in an assembly are connected. Any existing 'boundary representation' scheme can be used to represent each component. In this paper, a wingededge data representation with extensions to handle multiplyconnected faces is recommended. A tree structure using the concept o f 'virtual link' is created to represent the relationships between the components in an assembly. database, assembly modelling, data structure
Most research in the area of CAD has been performed on individual components. However, in practice, the designer must often consider an assembly rather than individual components. Thus there is a need to develop a data structure which stores information on how all the components are connected in an assembly, in addition to the topological and geometrical information on each component. Many representation schemes for individual components have been developed and are widely used. Currently, available data structures for representing components may be divided into two main types. One is the data structure used by CSG (constructive solid geometry) modelling systems ~. In the CSG data structure, what is stored is the procedure by which an object was created, rather than the information on the final object, ie the sequence of set operations such as union, difference, and intersection of the primitives is stored. The other type of data structure is boundary representation 2-s, in which the faces, edges, and vertices of an object are stored, together with the connections between them. Some representation schemes for storing assemblies have been developed 6-s, but these are not suitable for easy user interface because of the difficulty in providing assembly data interactively. The objective of this work is to generate a data structure in which any assembly can be represented in a hierarchical manner and created interactively.
components and assemblies are represented by nodes in a graph structure. The branches of the graph represent relationships among components such as 'part-of', 'attachment', 'constraint', and 'assembly'. Also, for each branch, an associated homogeneous transformation matrix is stored, to specify the relative orientation and location of one with respect to the other. The nodes also store physical properties such as material type. The data structure in AUTOPASS is very similar to the CSG representation for a component, ie the relationships correspond to the set operations, and the components correspond to the primitives. The graph for a support bracket assembly is illustrated in Figure 1 as an example, where P denotes 'part-of'; A denotes 'attachment'; C denotes 'constraint'; and AS denotes 'assembly'. Eastman s created a graph called the 'location graph' which stores the relative location between each component in a hierarchical manner. Every branch in the location graph has a corresponding homogeneous transformation matrix 9. As an example, the location graph of the assembly shown in Figure 2 is given in Figure 3.
APPROACH As described in the previous section, either Lieberman and Wesley's data structure or Eastman's structure requires the transformation matrix of each component as an input to constrain the location and the orientation of each component in an assembly. Interactive assignment of transformation matrices is difficult and prone to mistakes. In this investigation, an assembly data structure which requires more basic information such as mating features
RELATED WORK Lieberman 6 and Wesley 7 described a geometric modelling system, AUTOPASS, that generates a database in which Department of Mechanical and Industrial Engineering, University of Illinois at Urbana-Champalgn, Urbana, IL, USA *Department of Mechanical Engineering, MassachusettsInstitute of Technology, Cambridge, MA, USA
volume 17 number I jan/feb 1985
Figure Io Graph structure o f support bracket assembly
0010-4485/85/010015-05 $03.00 © 1985 Butterworth & Co (Publishers) Ltd
15
Machine
/
Mount
connected by a virtual link. If more than two components are mutually related, several virtual links can be used so that every pair of mating components occupies one virtual link. A virtual link is the complete set of information required to describe the relationship (eg rigid attachment, conditional attachment, translational constraint, and rotational constraint*) and the mating features between the mating pair. In Figure 4, an assembly located at the top node is composed of one or more pairs of subassemblies, where every pair is connected by a virtual link. A subassembly may be composed of several pairs of subassemblies and components which are connected into pairs by virtual links, and so on. In this way, the terminal nodes of the assembly graph will be the components of the assembly and component data for each component should be connected to these terminal nodes. If many identical components appear in an assembly, data for only one component is stored, by using the concept of instance. In this case, virtual links point to the instances of the components rather than the components. Even though our assembly data structure can use any boundary representation for each component, a wingededge data structure with extensions to handle multiplyconnected faces4's is recommended for the following reasons. First, topology and geometry are completely separated so that a wide range of surfaces can be handled by modifying the data structure of the geometry side only. Second, small changes to an object cause small changes to the data structure; that is, local changes in the data structure are possible without affecting the whole structure. This fact enables easy insertion and deletion of entities such as vertices, edges, and faces. Third, the redundancy in the
Frame Figure 2. Example of an assembly Transformation
Frame
Figure 3. Location graph (eg mating faces, collinear centrelines) between components is created. As shown in Figure 4, an assembly may be composed of many subassemblies and components in a hierarchy, and can be stored in a graph structure using the concept of a 'virtual link' created by the authors. In the assembly data structure, any mating pair of two subassemblies, two components, or one subassembly and one component is
*Rigid attachment has no relative motion. Conditional attachment may have a relative motion if the applied force is greater than the threshold. Translational constraint allows only translational relative motion. Rotational constraint allows only rotational relative motion,
A,,e.0,v
q
//
l
V,rtu,,,ink k-----q
Virtual link
I
Subassembly
I /
-
~
Virtual link
Subassembly
] ~.~........~
/ . J "
I
t
/\
I
Component I
I
I
Su =.m0, I
Com0oneotI
Virtual link
Component I
Virtuallink
Component
I
I!
ri
Virtual link
~
....
oo.n, ~
~'
I ]~
Virtuallink
V
l.....0o=0on.n,llcom0onon' Virtuallink
~o=0onon, I I Oo=0oo~otI I ComponentI I Component]
Figure 4. Tree structure for assembly
16
computer-aided design
structure eliminates the need for searching, which makes most operations fast enough for interactive response. Finally, the data can be arranged sothat each record is of constant length, which enables the effective use of memory. By introducing the virtual link concept, assembly data can be stored hierarchically. The transformation matrix for each component and subassembly need not be assigned, since it can be derived from the mating feature information carried by virtual links 1°. In an assembly structured created by Lieberman and Wesley, or in one created by Eastman, the transformation matrices had to be provided, a difficult task in an interactive operation. However, mating feature information can be provided interactively with ease, because mating features are simply graphic entities. Therefore, the assembly data can be provided interactively in our data structure. A byproduct of computing transformation matrices from the mating feature information is the determination of whether the components in an assembly can in fact be assembled. If some components cannot be assembled, transformation matrices which satisfy all the mating conditions do not exist, and the computation routine for transformation matrices will diverge. In this way, only possible assemblies can be stored in the database.
\\\\\\\\\\\\\\\\"
.\\\\\\\\\\\\\\\\ Figure 6. 'Fits' condition
\\\\ \ \ \ \
\ \ \ \
\ \ \ \
\ \ \ \
\XX\ \ \ \ \ \ \ \ \ \%\%
\\\\ \X%\
\XX\ \\\\
A R R A Y S AND THEIR CONTENTS
Assembly 'Container'
The following arrays are created to store the tree structure shown in Figure 4, and the relevant information for each array is described. ASSEMBLY: Name of the assembly Pointer to the first virtual link of the immediate lower level VI RTUAL-LI N K: Pointer to the next virtual link Pointer to an assembly or a subassembly of the immediate upper level Pointer to the starting location in MATING-FEATURE Number of records in MATING-FEATURE related to the virtual link
Component 'Cap' Centreline - - ~
C2, bottom \ \ \ \
\\\-, \\\\ \\\\ ix----', \\\\ \\\\ \N\\ \ \\\ \\\ \ \\\.,
Centreline
C1.bottom j
Component 'Bottom'
FaceF1. bottom f
~
~\\\ .... \\\~
Face F1, bolt ~
Centreline C1, bolt
Component 'Bolt'
Figure 7. An example assembly
•
Figure 5. 'Against' condition
volume 1 7 number I january/february 1985
Pointer to a component or a subassembly of the pair Pointer to the other component or the other subassembly of the pair Relationship provided by this virtual link, eg rigid attachment, conditional attachment, translational constraint, and rotational constraint SUBASSEMBLY: Name of subassembly Pointer to subassembly or assembly of the immediate upper level Pointer to the first virtual link of the immediate lower level Stores the derived transformation from the assembly or the subassembly of the immediate upper level Mass properties of the subassembly
17
,/•
Container
t Virtual link 1
-
Virtual link 2
Virtual link 3
Figure 8. Tree structure for on example assembly
• MATING-FEATURE: Type of mating, eg 'against' and 'fits'* Mating feature (planar face or centreline) Mating feature (planar face or centreline) Clearance between mating features • COMPONENT: Name of the component Pointer to subassembly or assembly of the immediate upper level Stores the derived transformation from the subassembly or the assembly of the immediate upper level Material type of the component Material properties of the component Mass properties of the component Consider the example assembly shown in Figure 7. The arrays described earlier are filled for this example assembly. The tree structure for the assembly can be obtained as shown in Figure 8, and the arrays and their contents are shown in Figure 9.
CONCLUSIONS The data structure described in this paper has the following advantages. First, it derives the transformation matrices of components in an assembly from mating feature information between the components. Thus, the assembly can be
*'Against' applies between planar faces, and 'fits' applies between a solid cyclinder and a hole. See Figures 5 and 6.
automatically updated for modifications in the size of any component in the assembly, in contrast to other structures which require explicit modification on transformation matrices according to the size change of some components. With this advantage, this data structure enables the study of auto-scaling 11. Second, the structure stores only possible assemblies. If an assembly of components which cannot be assembled together is stored in the data structure, there is not a set of transformation matrices of all the components which satisfies all the mating conditions. This can be detected when the transformation matrices are computed from mating conditions. Third, the assembly data structure has a hierarchy very similar to that of assembly procedures for components. Therefore, it is expected that the simulation of assembly procedures can be achieved with this structure. Finally, dimension chains in an assembly can be derived from mating feature information so that tolerance analysis on the assembly can be performed.
ACKNOWLEDGEMENTS The authors wish to thank the Control Data Corporation for its financial support for the project.
REFERENCES 1
Requicha, A A G 'Representations for rigid solids: theory, methods, and systems' ACM Comput. 5urv. Vo112 No A (December 1980)
2
Bare, A, Eastman, C and Henrion, M 'Geometric modelling: a survey' Comput.-Aided Des Vol 11 No 5 (September 1979)
3
Baumgart, B G 'Geometric modelling for computer vision' PhD thesis, Stanford University, USA (August 1979)
4
Braid I C 'A new shape design system' CAD Group Document 89, University of Cambridge Computer Laboratory, UK (March 1976)
5
Braid, I C and Hillyard, R C 'Geometric modelling in
Component
Virtual Link \ ~
Container
I ~ V? 2
For other assemblies
J
CAP
2 O~//~ ~Rotati~nnalconstant ~
.b
~ ~
1 e~, ~
!
Rotationalconstant constantj
Transformation
BOTTOMr? Transformation . ~ L T j ,~! Transformation
Material type Material type Material type
Material properties Material properties
Material properties
Mass properties Mass properties Mass properties
Mating- Feature
'
AGAINST
F1, cap
F1, bolt
Clearance
FITS
C2, cap
Cl, bolt
Clearance
AGAINST
F2, cap
F1, bottom
Clearance
FITS
C1, cap
C1, bottom
Clearance
FITS
C1, bolt
C2, bottom
Clearance
Figure 9. Arrays and their contents for an example assembly
18
computer-aided design
ALGOL 68' University of Cambridge Computer Laboratory, UK 6
Lieberman, L I and Wesley, M A 'AUTOPASS: an automatic program system for computer controlled mechanical assembly' IBMJ. Res. Dev. (July 1977) pp 321-333
7
Wesley,M A, Lozano-Perez, T, Lieberman, L I, Lavin, M A and Grossman, C D 'A geometric modelling system for automated mechanical assembly' IBM ]. Res. Dev. Vol 24 No 1 (January 1980) pp 64-74
8
Eastman,C M The design of assemblies SAE Technical
volume 1 7 number I january/february 1985
Paper Series, Society of Automotive Engineers, Inc., USA (1981) 9
Newman,W M and Sproull, R F Principles of interactive computergrephics McGraw-Hill Book Company, New York, NY, USA (1979)
I0 Lee, K 'Shape optimization of assemblies using geometric properties' PhD thesis Massachusetts Institute of Technology (December 1983) 11 Chang, D 'Automatic scaling of assemblies for comPuter-aided design' MSc thesis Massachusetts Institute of Technology, MA, USA (May 1983)
19