You are on page 1of 13

Computer-Aided Design, Vol. 30, No. 9, pp.

727–739, 1998
q 1998 Elsevier Science Ltd. All rights reserved
Printed in Great Britain
PII: S0010-4485(98)00033-5 0010-4485/98/$19.00+0.00

Automatic recognition of
interacting machining features
based on minimal condition
subgraph
S Gao† and J J Shah‡*

Convex hull the smallest convex polyhedron


This paper presents a methodology for efficiently recognizing both containing all points in a part
isolated and interacting features in a uniform way. The conventional, Extended attributed adjacency an AAG with 5 arc attributes and 5
graph (EAAG) node attributes
graph-based recognition method is combined with hint-based feature Feature interaction intersections between feature
recognition to recognize and extract alternative interpretations of boundaries that result in altering their
interacting features. First, all isolated (non-intersecting) features are characteristic topology and/or
recognized based on a Manufacturing Face Adjacency Graph. geometry
Interacting features are then recognized based on the feature’s Feature stereotypical geometric shapes
associated with some engineering
minimal condition subgraph (MCSG) that is used as a feature hint. significance
Unlike previous hint-based recognition methods, the MCSGs of all General feature those types of features whose
features are defined, generated and completed in a uniform way, topological entity numbers are not
independent of the feature type. Hints are defined by an Extended fixed
Hint a feature’s topological and/or
Attributed Adjacency graph, generated by graph decomposition and geometric entities left in the nominal
completed by adding virtual links, corresponding to entities lost by geometry of a part after an interaction
interactions. An efficient algorithm for generating virtual links is Interacting feature a feature intersected with some other
developed. A new classification of feature interactions is also feature
presented. q 1998 Elsevier Science Ltd. All rights reserved Isolated feature a feature without any interaction with
other features
Isolated island a protrusion put on the bottom face of
Keywords: feature recognition, feature interaction, graph a feature, not touching any other
matching, machining feature feature faces except the bottom face
of the feature
Machining feature a continuous volume that can be
removed by a single machining
Definitions and nomenclature operation in a single set-up
Manufacturing face adjacency an AAG without any node
Access direction direction from which a cutter can graph (MFAG) corresponding to a convex hull or
access a machining volume in order stock face
to cut it Merged face a face shared by more than one
Attributed adjacency graph (AAG) a graph whose nodes are faces, arcs feature
are face adjacencies, and arc attri- Minimal condition subgraph the maximal sub EAAG of a feature
butes are edge convexity flags (MCSG) which remains in the EAAG of the
CH-face a face common to the part and its part
convex hull Obstacle face the closest face to a feature that
Concave adjacency graph (CAG) a connected subgraph of PCAG in prevents a cutter from accessing the
which all arcs are concave feature along its locally accessible
Concave edge an edge,is concave if the solid angle direction
between its incident faces is greater Open pocket a pocket with more than one acces-
than 1808. The incident faces may be sible direction
planar or quadric Partly concave adjacency graph a concavely connected subgraph of
(PCAG) MFAG
*To whom correspondence should be addressed. Tel: 001 602 965 6145; Predefined feature one that has a fixed topology and has
Fax: 001 602 965 2412; e-mail: jami.shah@asu.edu been defined in a library
†State Key Laboratory of CAD and CG, Zhejiang University, Hangzliou, Stock face a face of the part coincident with
People’s Republic of China some face of the stock of the part
‡Mechanical and Aerospace Engineering, Arizona State University, Stock raw material from which a part is
Tempe, AZ 85287, USA machined out
Paper Received: 15 September 1997. Revised: 20 April 1998. Accepted: 20 Support surface the surface to which the face is
April 1998 attached

727
Automatic recognition of interacting machining features: S Gao and J J Shah

Unproductive edge extension of such an edge will either LITERATURE REVIEW


generate no virtual link or an
unusable one
Unusable virtual link a virtual link that can only be used to
In the area of feature recognition, many techniques have
extend a predefined feature into a been proposed and implemented. For a comprehensive
larger open pocket or nonsense review of feature recognition the reader is referred to
feature Refs 1–4. Here, we focus on the work that is more closely
Virtual link (VL) a face adjacency relationship related to our approach, namely, the recognition of
representing an edge deleted by
feature interaction interacting features, particularly graph-based and hint-
based recognition.
The approach presented by Joshi and Chang in Ref. 6, can
INTRODUCTION be considered typical of graph-based feature recognition
methods, in which both the part and the features are repre-
Seamless and effective integration of CAD, CAPP and sented by attributed adjacency graphs (AAG). Features are
CAM is increasingly demanded by manufacturing indus- recognized by matching feature patterns to patterns in the
tries. To realize this, an intelligent interface between CAD part’s AAG. The approach given in Ref. 6 can break down a
and CAPP is imperative, since CAPP expects part large search space by graph decomposition and can deal
representation in terms of manufacturing features, whereas with two specific types of feature interactions by heuristics.
CAD describes parts by their solid model or design features. However, their graph decomposition is not always correct
Feature recognition enables such an interface between CAD and it may lead to the loss of some types of features like
and CAPP. Feature recognition can be used to find chamfers and T-slots.
manufacturing features of a part from its solid model. Marefat and Kashyap 7,8 developed a graph-based recog-
Much research has been conducted in this area and many nition technique, which is the first attempt to treat general
feature recognition approaches have been proposed 1–4. feature interactions based on the generate-and-test paradigm
One important type of feature recognition method, called and the virtual link concept. They define features by cavity
graph-based recognition, recognizes features by matching a graphs, which extend a feature’s AAG to include some geo-
feature graph to the appropriate subgraph, in a graph repre- metric constraints on the orientations of the feature faces.
sentation of the part. The advantages of graph-based recog- To recognize interacting features, they first recover virtual
nition are: (1) it is applicable to many domains not just links using an AI technique and add them into the cavity
machining; (2) it allows the user to add new feature types graph of the part, then they generate all hypothesized fea-
without changing the code; (3) it is suitable for incremental tures by subgraph matching. The incorrect hypotheses are
feature modeling 5; and (4) it can recognize isolated features then eliminated by rule-based experts. Some problems with
effectively. On the negative side, feature interaction and this method include: (1) it does not always find all the
multiple interpretations of features cannot be handled well necessary virtual links, and sometimes determines incorrect
with graph-based recognition. virtual links 9; (2) there are many incorrect feature hypoth-
The major objective of this paper is to develop a new eses that need to be eliminated. Although the geometric
graph-based recognition method which can satisfy the constraints in the feature’s cavity graph can effectively
following three conditions: recognize features in several eliminate many incorrect feature hypotheses, the cavity
common situations, involving a variety of feature inter- graph representation of the feature limits the method to
actions with one general purpose algorithm; produce alter- polyhedral objects; and (3) there is no evidence that the
native feature interpretations; and provide reasonable method can be extended to generate volumetric features
computational efficiency. To satisfy these conditions, we and multiple interpretations of features.
combine the conventional graph-based recognition method Trika and Kashyap 9 extended Marefat’s work in the gen-
with the hint-based feature recognition. To recognize inter- eration of virtual links and the verification of feature
acting features we use the minimal condition subgraph hypothesis. They generated virtual links by exact geometric
(MCSG) as a feature hint. The MCSGs for features are computation rather than uncertainty reasoning, and verified
defined by an extended attributed adjacency graph feature hypotheses satisfying the feature’s cavity graph by
(EAAG), which is generated by graph decomposition and checking the regularized intersection of the feature volume
completed by adding related virtual links in a uniform way, and the part. They demonstrated that their method is tract-
independent of feature type. The concept of a manufacturing able and complete over seven basic classes of features and
face adjacency graph (MFAG) is introduced to improve the iso-oriented polyhedral parts. However, both the part
efficiency of recognizing isolated features and to reduce the domain and the feature classes are limited to iso-oriented
search space for virtual links, unifiable faces and features. polyhedral parts and seven basic machining feature classes
Also, an algorithm is devised to speed up the generation of (step, blind step, slot, blind slot, prismatic hole, pocket and
virtual links. enclosed box). Only single interpretations of features can be
The paper is organized as follows. In the second section extracted. The virtual link generation algorithm is not effi-
we review the previous work in manufacturing feature cient, as observed from the execution times given in Ref. 9.
recognition. The third section introduces some new con- Vandenbrande and Requicha 10 proposed the hint-based
cepts used in our work and gives an overview of our feature recognition approach. A feature hint is defined as
approach. The fourth and fifth sections give details of the a feature’s geometric entities left in the nominal geometry of
recognition procedure for isolated and interacting features, a part after an interaction. For example, a pair of parallel
respectively. The generation of alternative interpretations of opposing faces is a hint that a slot may be present. To
interacting features is described in the sixth section. The recognize arbitrarily interacting features, they first extract
implementation and testing are given in seventh section. all the feature hints by searching the B-reps of the part, then
Finally, the advantages and limitations of our approach test them for validity through geometric completion proce-
are discussed in the eighth section. dures, that attempt to construct the largest volumetric

728
Automatic recognition of interacting machining features: S Gao and J J Shah

Figure 1 A part and its EAAG

feature based on a variety of AI and computational geometry Floriani in Refs 6,19,20. The nodes of an AAG represent
techniques. Finally, they represent a feature’s interaction with faces, arcs represent edges, and the attribute of the arcs is a
others by segmenting the feature into optional and required Boolean variable to represent edge convexity. A part and its
volumes. This approach deals with feature interactions in a AAG are shown in Figure 1. The AAG of a pan can be
general manner. However, since the hint generation and com- easily derived from the part’s B-reps, and is more suitable
pletion algorithms in this approach are not general, but for feature recognition than the raw B-reps.
depend on the specific feature type, new algorithms need to
be developed and added to the system in order to recognize Extended attributed adjacency graph (EAAG)
new, user-defined feature classes. Usually, many hints need In order to enable an AAG to support feature recognition
to be explored for almost every feature class, which may more effectively, we need to extend the AAG by adding
become cumbersome for some feature classes like a dovetail several edge and face attributes. The new edge attributes are
slot. Han and Requicha extended Vandenbrande’s work in associated with the graph arcs and the face attributes with
Refs 4,11. A reasoning method for rating and prioritizing the the nodes of the graph, as shown in Table 1. These
hints was added to further reduce the possibilities to be attributes, like the convexity attribute, are Boolean vari-
explored and the order in which to explore them. ables. The extended attribute adjacency graph contains five
The hint-based feature recognition method has also been attributes: convexity, existence, loop, geometry and blend
investigated by Regli and Nau 12,13. Their approach type. These are defined in Table 1. The definition of a
addresses a class of machinable features expressible as smooth edge is that its incident faces must have C 1
MRSEV (material removal shape element volumes). The continuity. The face attributes stored with the nodes are of
problem is that all the prismatic cavities are classified as five types, as listed in Table 1. The source attribute of the
pockets in this method, which makes it difficult to machine node represents whether the face coincides with a face of the
some types of features such as T-slots with methods parti- stock or not. Since stock faces are not machined, they are
cularly efficient for them. As with Vandenbrande’s work, eliminated. The convex hull (CH) attribute specifies
there are also many hints needed. whether the given face coincides with a face of the
The volume decomposition method is also popular 3,14–18. convex hull of the part or not. Since we have aimed our
It generally decomposes the removal (machining) volume approach at machining features. the B-reps of both the part
into convex cells first, then combines the cells to generate and its stock are used as the input to our program. Also, note
machining features based on some rules. This method is that the stock is not necessarily the convex hull of the part.
good at dealing with arbitrary feature interactions and gen- The other node attributes include: number of loops in the
erating multiple interpretations of features. However, it also face; split status, which signifies whether the node
has some disadvantages, such as computational complexity represents a unifiable face; and face geometry, whether
and, in some cases, inability to generate nonconvex delta planar or non-planar. As will be explained throughout this
machining features. paper, these attributes play a role in either ‘‘repairing’’ the
effects of interactions, or recognizing specific feature types.

BASIC CONCEPTS AND OVERVIEW OF


APPROACH
Table 1 Attributes stored in EAAG

Before outlining our minimal condition subgraph approach, Arc (edge) attributes Node (face) attributes
we need to define some basic concepts.
Convexity: convex or concave Source: stock or part face
Existence: real edge or a virtual Convex hull: CH-face or nonCH-face
Subgraph definitions edge
Loop type: edge is on an inner or No. of loops: single or multiple
Attributed adjacency graph an outer loop
Geometry: curved or straight edge Split status: unifiable or not
The idea of attributed adjacency graphs (AAG) was Blend type: smooth or sharp Geometry: planar or nonplanar
proposed by Joshi and Chang, and Falcidieno and De

729
Automatic recognition of interacting machining features: S Gao and J J Shah

Table 2 Attribute values for selected entities of Figure 1

Face no. Source CH No. of loops Split Geom. Edge no. Convex Exist. o_loop Blend
f0 T T 1 T P f 0 –f 1 T F T T
fl T T 1 T P f 2 –f 3 F F T T
f2 F F 1 F P f 3 –f 6 F T T T
f… — — — — — f…–f… — — — —

Figure 2 Two MFAGs contained in the part in Figure 1

For example, the existence and the split status attributes are Therefore, we will use PCAGs in MFAGs as hints of
used in repairing; the number of loops and loop type help these kinds of features. Two PCAGs contained in the MFAG
identify islands; edge blend type and edge/face geometry of Figure 2b are shown in Figure 3.
help classify feature types. Table 2 gives attribute instances
for a few of the faces and edges of the model of Figure 1. Concave adjaceny graph (CAG)
Although the illustrations of EAAG in this paper only show The concave adjaceny graph (CAG) is defined as a
the convexity attribute for simplicity of drawing, the other connected subgraph of PCAG, in which all arcs between
EAAG attributes are equally important for our algorithm. the nodes of the subgraph are concave. Obviously, a SFG is
a also a special CAG. It can be readily observed that the
Manufacturing face adjacency graph EAAGs of almost all basic machining features, including a
The manufacturing face adjacency graph (MFAG) is defined step, blind step, slot, blind slot, hole, convex pocket,
as a connected subgraph of the EAAG of a part, in which no chamfer, etc., are CAGs. Therefore, it is prudent to use
node represents either a stock face or a CH-face. It can be CAGs in MFAGs as hints of pre-defined features. The two
easily observed that a part’s EAAG usually contains more PCAGs shown in Figure 3 also happen to be CAGs, but the
than one MFAG, and all MFAGs of the part can be derived PCAG shown later in Figure 7b is not a CAG. Note that the
by simply deleting all the stock faces, all the CH-face nodes, difference between CAG and PCAG is that PCAG may
and all the incident arcs to them from the part’s EAAG. Two contain convex arcs, while CAG cannot.
MFAGs contained in the part EAAG of Figure 1 are shown
in Figure 2. In this example, the stock of the part is assumed Minimal condition subgraph
to be the convex hull. The EAAG contains 16 faces; there The MCSG (minimal condition subgraph) of a feature is
are seven faces that are coincident with the stock/CH (f 0, f 1, defined as the maximal sub-EAAG of a feature which
f 7, f 12 –f 15); when these seven are removed we obtain two remains in the EAAG of the part. An example MCSG is
disjointed graphs, as shown in Figure 2. These are the shown in Figure 4b for the slot (f 2, f 3, f 6) of Figure 1a. Also
MFAGs of the part. The significance of MFAG is that it can shown are the EAAG before and after the interaction; the
be used to reduce the search space for depression features lost concave edge is shown by a dotted line in Figure 4c.
effectively. Specifically, searching for depression features The feature MCSG defined above have the following
can be restricted in each MFAG, according to the properties:
observation that the EAAG of depression features of a
part is always contained in one and only one MFAG of the • Every feature of the part has at least one non-empty
part, because the depression feature consists of a set of MCSG.
connected nonstock and non-CH faces of the part. It should • MCSGs of different feature instances of the same feature
be pointed out that when the stock of the part is larger than class may be very different, depending on how they
the convex hull of the part, there must be some faces that are interact with other features. If a feature instance does
CH-face but not stock face of the part. Since each CH-face not interact with any other features, its MCSG is the
that is not a stock face forms a single face feature and is easy same as its EAAG. In the worst case, if a feature instance
to recognize, we exclude them from MFAGs with the help interacts with many features, its MCSG may degenerate
of the CH-face attribute. to one EAAG node.
• Feature MCSG is defined independent of the feature
type, which provides the possibility of dealing with the
Partly concave adjacency graph
MCSGs of all kinds of features with the same procedures.
The partly concave adjacency graph (PCAG) is defined as a
concavely connected subgraph of MFAG, which means that
for every pair of vertices in the subgraph, there is a path
between them, and every arc of the path is concave. Note
that a single node which has only convex arcs is a special
PCAG, according to the definition of PCAGs; we will refer
to it as a single face graph (SFG). In addition, we can easily
observe that the EAAGs of non-convex pockets, open
pockets and some interacting features, are PCAGs. Figure 3 Two PCAGs contained in the NIFAG shown in Figure 2b

730
Automatic recognition of interacting machining features: S Gao and J J Shah

Figure 4 Illustration of the MCSG of the slot (f 2, f 3, f 6) contained in the part in Figure 1a

Figure 5 Feature interaction classification

Interacting features Type (b): let f 1 and f 2 be two planar faces of the part. If
both f 1 and f 2 are completely in the positive half space
Two volumetric features are defined as interacting features of each other, and the extensions of f 1 and f 2 intersect
if their boundaries intersect, so that they share a non-empty, each other, as shown in Figure 5c, then we set up a
common volume. More than two volumetric features are virtual link between f 1 and f 2 and define this link as
called interacting features if every one of them interacts type (b).
with at least another one and all of them form a connected Type (c): let f 1 be the face shared by two different
volume. We classify feature interactions into six categories features. Then, f 1 is split into two faces f 1 and f9 1 by
according to three types of topology variations caused by virtual edges, so that f 1 and f9 1 are completely contained
feature interaction: merging of faces, loss of concave edges, in different features, as shown in Figure 5d. For each
and splitting of faces. Merged faces are those that are shared virtual edge we set up a corresponding virtual link
by more than one feature. To completely cover all between f 1 and f9 1 and define this link as type (c).
combinations of the above three conditions would require Type (d): let f 1 and f 2 be two planar faces of the part. If
eight types of feature interactions. However, two combina- both f 1 and f 2 are adjacent to the same cylindrical face
tions are impossible because both split face and lost concave along two smoothly concave arcs (the cylindrical face
edge cannot be true simultaneously; this reduces the here is a fillet feature), then we set up a virtual link
possible types to six, as shown in Figure 5 and Table 3. It between f l and f 2 and define this link as type (d).
should be noted that there is no direct correspondence
between our six interaction classes and the two interaction
Unifiable faces
types identified by Joshi and Chang 1.
Unifiable faces are a set of faces satisfying the following
Virtual links two conditions: (1) all faces are on the same surface and
with the same orientation, and (2) each face of the set can be
A Virtual link (VL) is defined as a face adjacency extended along one of its edges to touch an edge of another
relationship not contained in the part’s B-reps as a result face of the set without intersecting any face not in the set. As
of feature interaction. Such links are useful for recognizing an example, f 1 and f 2 in Figure 5b are unifiable faces. It
interacting features by the graph-based method. Four types should be pointed out that although some commercial solid
of VLs were identified and used in this work. modelers can unify the faces, satisfying the first condition
Type (a): let f 1 be a planar or cylindrical face and f 2 be a mentioned above, they do not check if these faces satisfy the
planar face of the part. If f 1 is completely in the positive second condition. An algorithm for searching unifiable faces
half space of f 2, while f 2 is just partly in the positive half is developed based on similar techniques used in the virtual
space of f 1, and the extension of f 1 intersects f 2, as link generation algorithm (see Recognizing Interacting
shown in Figure 5e, then we set up a virtual link Features section).
between f 1 and f 2 and define it as type (a). In addition,
f 1 is called the extension face of the virtual link. Minimal condition subgraph approach: overview

Based on the above concepts, we present a new approach for


Table 3 Classification of feature interactions automatic recognition of machining features from the B-rep
solid models. The part domain consists of parts with planar
Feature type Merged faces Lost concave edge Split faces and quadric surfaces. In our approach, features are divided
I N N N into two groups: predefined and general. Predefined features
II N N Y include step, blind step, slot, blind slot, T-slot, hole, blind
III N Y N hole, chamfer, etc. These are stored in the library of
IV Y N N predefined features. The general features group comprises
V Y Y N
VI Y N Y
compound features, general pocket, through pocket and
open pocket; these are stored in a heuristic rule library. The

731
Automatic recognition of interacting machining features: S Gao and J J Shah

• Decompose the part EAAG into separate MFAGs by


deleting all the stock face nodes and all their incident
arcs from the part’s EAAG.
• For each MFAG, check if there are type (d) virtual links;
if so, set up the virtual links first, then mark all corre-
sponding cylindrical face nodes as fillets and exclude
them from the MFAG.
• Check each MFAG to see if it matches the EAAG of a
certain feature; if so, mark it as a MCSG of the isolated
feature.
We first match the MFAG with the EAAG of every fea-
ture in the predefined feature library one by one. If it does
not match any of them, it is checked further by every rule in
the heuristic rule library sequentially, to determine if it has
the characteristic pattern corresponding to one of the gen-
eral features. Owing to space limitations, we will only
describe the heuristic rule for a pocket as an example. The
characteristic rule is as follows:
if there exists a node in the MFAG, each arc of which is
concave, and all other nodes of the MFAG are adjacent
to it, then this MFAG corresponds to a pocket.
Since isolated features are completely determined by
Figure 6 Overview of recognition algorithm their MCSGs, the MCSG completion makes no sense for
them. Therefore, we can set up their feature representation
as soon as their MCSGs are generated. In this way, all types
feature representation consists of the feature’s EAAG, of isolated features, including compound features, general
feature parameters, access directions, obstacle faces, pocket, chamfer, T-slot, etc., can be recognized first in a
isolated islands, parameter extraction methods, interacting more efficient manner, which is consistent with human per-
features, etc. As the specific EAAG of each feature is ception. Multiple interpretations of isolated general features
defined in a similar way to that in Ref. 6 (except for the are produced by heuristic rules for general features. Since
additional attributes), they are not discussed further. isolated general features are special cases of interacting
The major steps in our approach are shown in Figure 6. features, they may sometimes be machined as single
The inputs to the program are the B-reps of the part and the features.
stock to be used. In our current implementation, these are
ACIS 2.0 ‘‘.sat’’ files. The program can be conceptually
thought of as consisting of six main phases:
RECOGNIZING INTERACTING FEATURES
(1) Pre-processing: constructing AAG, finding the edge and
face attributes and constructing EAAG; splitting them If a MFAG does not correspond to an isolated feature, it is
into a set of MFAGs. assumed to represent a group of interacting features; the
(2) Recognizing isolated features. MFAG may contain more than one feature’s MCSG. We
(3) Recognizing interacting features. generate these MCSGs by graph decomposition. This is
(4) Completing interacting features. followed by completion of the interacting feature by adding
(5) Determining one interpretation for each set of interact- ‘‘lost’’ entities back.
ing features; producing alternative interpretations on
demand.
(6) Creating the feature model (data structure) of the part. Generation of MCSGs

In order to generate all the interacting feature MCSGs


contained in a MFAG, we decompose the MFAG into
RECOGNIZING ISOLATED FEATURES separate PCAGs first. This is based on the observation that
interacting features’ MCSGs are always PCAGs (in some
An isolated feature is a feature instance that does not cases, a PCAG could itself be a CAG). Before decomposi-
interact with other features except the CH-face feature tion, all unifiable faces in the MFAG are determined, and
instance. If a general feature, such as a compound slot, does each of them is treated as one node of the MFAG, to ensure
not interact with any other feature, it is also considered an that the maximal MCSGs can be found. The specific
isolated feature, called an isolated general feature. Accord- decomposition method is simple. The PCAG partition of the
ing to the MCSG definition and the properties of the isolated MFAG is obtained as follows: (1) choose an arbitrary node
feature, it can be easily observed that the MCSG of the of the MFAG as the first node of the first PCAG, and
isolated feature has two characteristics. One is that it is the complete the PCAG by iteratively extending it to include all
same as its feature’s EAAG. The other is that it is separated those nodes of the MFAG which have at least one concave
from other nodes of the part’s EAAG by the convex arcs arc with one node of the PCAG; and (2) construct other
linking its nodes and stock face nodes. Based on these two PCAGs similarly until the union of all PCAGs is equal to the
observations, we generate the MCSGs of all isolated MFAG. It can be easily observed that the above PCAG
features of the part in three steps: partition of the MFAG is unique. After decomposition, each

732
Automatic recognition of interacting machining features: S Gao and J J Shah

Figure 7 A part with merged faces and its MFAG and PCAG

PCAG of the MFAG is checked to see if it is a CAG or if it or F9 i and intersect the S is support surface. Note that those
corresponds to a general feature. If any of these is true, it is a tetrads having the same F i and S i with a previous tetrad are
feature MCSG and pushed on the MCSG stack; otherwise it ignored.
is not a feature MCSG. We observe that a PCAG is not a For our example, either F 5 or F 6 can be selected as a
feature MCSG when it contains one or more merged faces proper split face. Suppose we choose F 5 as the split face,
caused by type IV–VI feature interactions. Therefore, we then F 3, F 4 and F 2 are split, as shown in Figure 8a.
decompose such a PCAG into separate CAGs by splitting
relevant merged faces, so as to generate all the feature
MCSGs involved. The specific algorithm consists of Modify the PCAG
following four steps. Here, we take the part as well as its After a face F of the PCAG is split, a new node F9
MFAG and PCAG shown in Figure 7 as an example to corresponding to the new generated face is inserted into the
illustrate the algorithm. PCAG, together with a convex virtual link [type (c) VL]
between F and F9. All the old arcs between F and other faces
Find the primary merged faces of the PCAG are rebuilt according to the new adjacency relationship
between F, F9 and those faces. In addition, a concave virtual
We first find all the convex arcs between the nodes of the
link [type (a) VL] is set up between the split face and the
PCAG. As the given PCAG is not a CAG, there exists at
nonprimary merged face split by it.
least one such convex arc, similar to e in Figure 7a. Denote
After this step, the PCAG shown in Figure 7b is changed
each convex arc by C i, and let f i and f9 i be the two adjacent
to the graph depicted in Figure 8b.
faces of C i. Let F i and F9 i be the faces having concave arcs
with both f i and f9 i. Note that both F i and F9i may not exist.
Check if F i and F9 i do exist; if one of them exists, we call Obtain CAG
{fi , f9 i, F i, F9i } the tetrad of Ci and store it; otherwise Ci is At this stage, the PCAG should be the union of separate
not taken into account. All of the existing F i and F9 i CAGs. Now all the CAGs of the PCAG can be obtained
comprise primary merged faces. readily with a method similar to that of obtaining PCAGs
In the example, e is a convex arc, primary merged faces from MFAG. Figure 9 shows two CAGs derived from the
consist of F 3 and F 4, and the tetrad of e is {F 5, F 6, F 3, F 4}. PCAG of Figure 7b.

Split all related merged faces of the PCAG MCSG completion


To split F i and F9 i effectively, we first choose the split face,
S i, between f i and f9 i, based on the following two principles: The interacting feature MCSGs generated by the algorithm
given in the last section, need to be completed. By
• S i is involved in more tetrads of the PCAG.
completion we mean finding and adding the lost parts of
• S i has more faces of the PCAG intersecting its support
the EAAG caused by feature interactions. The lost part of an
surface.
interacted feature’s EAAG consists of lost nodes and lost
All the relevant merged faces are split, including F i and concave arcs [type (a) or (b) virtual links]; that is, there are
F9 i, as well as those faces which have concave arcs with F i no such arcs in the part’s EAAG. These lost arcs have to be

Figure 8 Splitting of the merged faces in Figure 7

733
Automatic recognition of interacting machining features: S Gao and J J Shah

belongs to be (M j, j ¼ 1,n}. First we assume m . 1, we will


discuss the case of m ¼ 1 later. We present now on the
algorithm for generating all virtual links related to a given
face of the MCSG, since all virtual links of the MCSG are
just the sum of the virtual links of all its faces. Assume F i to
be a given face of the MCSG, and let {E k, k ¼ 1,N} be the
set of all convex edges shared by another nonstock face of
F i. Suppose F ik is the adjacent face of F i along E
Figure 9 Two CAGs derived by decomposing PCAG of Figure 7b k. To find all virtual links of F i, we extend it along each
useful E k and determine the first face it can intersect. The
algorithm is divided into two steps.
recovered. The lost nodes are just disconnected with the
MCSG and can be easily found after lost concave arcs are Eliminate all unproductive E k. Firstly, a convex edge E k is
recovered. The MCSG completion algorithm consists of two considered unproductive if no virtual link, or only unusable
stages: generate all virtual links, and construct the virtual links, can be obtained by extending F i along E k (see
completed feature for the MCSG. Each of these is discussed previous paragraphs for a definition of unusable VL). Every
in this section. E k in {E k, k ¼ 1, N} is checked as follows to see if it is
unproductive or not.
Phase 1 — generate all virtual links of the MCSG
Trika and Kashyap 9 have shown that those, and only those • If F i is a unifiable face along E k, or E k has been used in
face pairs that satisfy the following two conditions can form generating this MCSG, or E k smoothly convex, then E k
type (a) or (b) virtual links: is unproductive and eliminated from {E k, k ¼ 1,N} for
no virtual link can be generated based on the E k.
• Condition 1: the two faces are not connected and can be • If E k coincides with a concave edge between F i and
extended to intersect each other. another face, say F j, then the only usable virtual link
• Condition 2: the two faces are, at least partly, in the that might be generated by extending E k must be the
positive half space of the each other. adjacency relationship between F i and F j, which is
Therefore, to generate all virtual links we simply need to obviously not a virtual link. Therefore, E k is unproduc-
find all face pairs that satisfy the above two conditions. tive and eliminated from (E k, k ¼ 1,N}.
Determining whether two faces can be extended to intersect
each other is time-consuming. Therefore, it is advisable to Determine the first face that F i can intersect by extending F i
reduce the search space. Instead of taking the set of all along each useful E k. Secondly, to illustrate this algorithm,
nonparallel face pairs of the part that are not concavely we use the part in Figure 1 as an example. Take f 11 as F i,
connected, as the search space for virtual links used in take e as E k, then f 10 corresponds to F ik.
Ref. 9, we achieved reduction by adding another two neces-
sary conditions: • First, every M j (j ¼ 1,n) is checked to see if both Mj and
F ik are in the positive half space of the other face; if so,
• Condition 3: both faces must be nonstock faces and in the M j is pushed onto a stack S.In the example, after this
the same MFAG. step, the stack S contains three faces, i.e. f 2, f 4 and f 8.
• Condition 4: at least one of the two faces contains one or • Next, all faces in S are sorted according to their distance
more convex edges shared with another nonstock face. to F ik. Here, the distance between F ik and the face in S is
In addition, we also exclude, in advance, all face pairs defined as follows: if two faces are parallel, it is the
which can only form unusable virtual links, which are defined normal distance between two faces. Otherwise, it
as those that will only extend a predefined feature to a larger refers to the distance between the midpoint of E k and
open pocket or a nonsense feature. The virtual link (VL) the intersection point between an auxiliary line and the
between F 1 and F 5 in Figure 10 is an example. Obviously, face in S. If F i is a planar face, the auxiliary line takes the
it can be only used to extend the blind slot {F 1, F 2, F 3, F 4} to midpoint of E k as its root point and the cross product of
a larger open pocket. The specific algorithm for generating all the direction of E k, and the normal of F i as its direction;
virtual links of the MCSG is described below. if F i is a cylindrical face, the auxiliary line is the same as
Assume the face set of the given MCSG to be {F i, i ¼ the axis line of F i.The stack S of the example is now
1,m} and the face set of the MFAG to which the MCSG sorted as f 8, f 4, f 2.
• Next, starting from the face closest to F ik, each face S i in
S is checked in order to see if it can be intersected by the
extension of F i along E k. If both S i and Fi are planar, we
first project them on the intersection line between their
corresponding surfaces, then check if the two projec-
tions share a common segment. If F i is a cylindrical
face, we check if the intersection between S i and the
surface of F i exists. If so, and S i is not adjacent to F i,
a virtual link n between F and S i is determined. If there is
no such virtual link in the current virtual link list, then it
is added into the virtual link list and its data structure is
set up. The VL data structure consists of its type and two
face pointers. Finally, the type of n is determined. If S i is
totally in the positive half space of F i, n is a type (b)
Figure 10 Virtual link generation virtual link; otherwise it is a type (a) virtual link. After n

734
Automatic recognition of interacting machining features: S Gao and J J Shah

extension face is a node of the MCSG, then V together


with its other face node is added to the MCSG; if V is a
type (b) virtual link, then if both its face nodes are nodes
of the MCSG, just V itself is added to the MCSG; other-
wise, another MCSG which contains another face node
of V is merged with the current MCSG. This extended
MCSG is equal to the EAAG of the corresponding fea-
ture of the MCSG. Taking the slot (f 2, f 3, f 6) in Figure 1a
as an example, its MCSG is shown in Figure 4a, and the
extended MCSG is the same EAAG as shown in Figure
Figure 11 The extended MCSG of an one node NICSG
4c, which corresponds exactly to a slot.
• Determine the type of the corresponding feature of the
is determined, all the faces left in S need not be checked
MCSG by sequentially matching the extended MCSG
further.In this step, only f 8 in S of the example is
with all predefined features and heuristic rules.
checked, and a type (a) virtual link between f 11 and f 8
• Generate the volume of the corresponding feature by
is added to the virtual link list.
directly invoking the volume generation procedure of
• Finally, if n is a type a virtual link, by the coherence,
the feature. For each generic predefined feature, the fea-
those virtual links between the S i and those faces in {F j,
ture volume is generated by simply intersecting the
j! ¼ i} that have convex arc with F ik are also determined
stock using the positive half space of every feature
without going through the above process. Observe that,
face. Note that the volume generated in this way is the
after all virtual links of the MCSG have been generated,
maximal volume of the feature; the volumes of the
every type (b) virtual link among them needs to be
interacting features may share some common volume,
checked further, because it still may be an unusable
which is not good for manufacturing efficiency if, for
virtual link and should be eliminated. The specific
example, NC tool paths are generated for each interact-
method is simple, so we do not describe it here.
ing feature separately. However, this is not a real con-
To illustrate this step, it is better to take the part in cern because these volumes are just the intermediate
Figure 10 as an example. Suppose a type (a) virtual link result. The final feature model of the part is generated
between F 1 and F 4 in Figure 10 has been identified. Then by the procedure described in the following section.
the virtual links between F 4, F 2 and F 3 will be identified by
For degenerate MCSG (only one face node), the differ-
coherence without any calculation.
ence with the general case is that its corresponding feature is
not completely determined by its extended MCSG. An
Degenerate MCSG. Now we consider the special case of an example is shown in Figure 11, where F 1 is a MCSG; its
MCSG comprising of only one face node F with m ¼ 1. extended MCSG consists of F 1 and F 2, while its correspond-
Since it is reasonab1e for it to correspond to an open pocket, ing feature is a slot comprising of F 1, F 2 and F 3. To solve
all its virtual links are useful and need to be found in order to this problem, we continue to extend the MCSG to include all
complete it correctly. First we find a virtual link between F those MCSGs which contain a face node having a virtual
and another face, F9 by extending F along one of its convex link with the original MCSG. Then we find the maximal
edges by the same method described above. Next, we valid feature containing the original extended MCSG by
continue to look for other possible virtual links between F searching the new extended MCSG. This maximal volume
and other faces based on coherence. We check all the faces feature is the corresponding feature of the MCSG.
adjacent to F9 to find those faces that are adjacent to F9
along an edge intersecting the support surface of F. We
then set up virtual links between these faces and F. This
process is repeated until all the faces having virtual links GENERATION OF ALTERNATIVE
with F have been processed. INTERPRETATIONS

Generally, interacting features can be interpreted in many


Phase 2 — construct the corresponding feature for the different ways. In this work, we use the approach of
MCSG Sakurai 14, with some modifications, to generate alternative
After all virtual links of an MCSG have been generated, we interpretations of interacting features.
start to construct its corresponding feature, based on our Assume all the features generated by completing MCSGs
virtual link classification. Assume that the MCSG contains involved in a MFAG to be {FT i, i ¼ 1,n}. We call this
more than one face node. The construction process consists feature set the initial interpretation of the interacting fea-
of three steps: tures. Set N ¼ n.
• Extend the MCSG based on all its virtual links as fol- (1) Choose one feature from {FT i, i ¼ 1,N} arbitrarily, say
lows. For each virtual link V, if it is type (a) and its FT N; push it on a stack. Then subtract the volume of

Figure 12 An example of interacting features and alternative interpretations

735
Automatic recognition of interacting machining features: S Gao and J J Shah

the stack represent one interpretation of the interacting


features.
(3) Set up the final feature representation of each feature in
the stack. First, the type of the feature is determined
again according to its updated EAAG. If feature type
is changed, then a new feature of the new type is cre-
ated. The parameters of the new feature are derived
based on the updated volume of the original feature
before the original feature is deleted. Observe that the
new feature here differs from the normal feature of the
same type in accessible directions. As an example, FT 3
in Figure 12c is considered to be a step in that inter-
pretation, but obviously the direction n cannot be used
as the normal accessible direction of the step when
Figure 13 Test part 1 and its recognized features machining FT 3. To reflect this distinction, which is
useful for CAPP, we introduce an obstacle face set
into the feature representation, each face of which indi-
FT N from the volumes of some other FT i (i ¼ 1,N ¹ 1). cates a forbidden access direction of the feature. All the
Note that, unlike Ref. 14, we do not subtract FT N from faces corresponding to the useless nodes in the original
all FT i(i ¼ 1,N ¹ 1) because some FT i may become EAAG of the original feature form the obstacle face set
invalid after subtraction. Figure 5c shows an example of the new feature. For example, F 1 forms the obstacle
part in which the result of subtracting a step from a hole face set of FT 3.
is no longer a predefined feature. In our approach, such
FT i is checked by analyzing the interaction relationship Since there are N ways to choose a feature in the first step
between FT i and FT N, and no subtraction performed of the algorithm, at most N! different interpretations of the
between it and FT N. After the subtraction operation, interacting features with N features as its initial interpreta-
both the volume and the EAAG of FT i are updated. tion can be generated by the above algorithm. This is illu-
We update the EAAG of such FT i by marking those strated by Figure 12. Since generating exhaustive sets of
nodes that are shared by FT N as useless nodes. Finally, interpretations is unrealistic, we decided to generate only
N is set as N ¹ 1. one desirable interpretation initially based on heuristics for
(2) Repeat (1) until N ¼ 1. At that point, all the features in efficient machining, similar to those used in Ref. 14.

Figure 14 Test part 2 and features recognized by the system (highlighted)

736
Automatic recognition of interacting machining features: S Gao and J J Shah

Figure 15 Test part 3

However, if the user does not like the initial feature set, blind holes, one slot, two blind slots and one T-slot, as
alternative interpretations will be produced as and when shown in Figure 13. There are several groups of interacting
the user demands. features in this set, like the slot and two holes in the mid-
section of the part. The execution time was 0.2 s on the HP
C180 workstation.
Figure 14(a) shows test part no. 2, the so-called CAM-I
IMPLEMENTATION AND TESTING ANC101 test part. In this example, the stock is taken as the
bounding box of the part, observe that the stock is not the
The proposed algorithm has been implemented using the same as the convex hull of the part. A total of 28 features
ACIS 2.0 solid modeler, Cþþ language, running on HP were recognized by our algorithm as the first feature inter-
C180 Unix workstations. We have tested the recognizer for pretation of the part. Figure 14b shows three pockets, one
various parts including popular industry test parts, such as blind slot, and one face feature with an isolated island in it.
CAMI/ANC101 and the Gehaeuse. The test parts involve all Figure 14c shows four holes, one face feature, and another
interaction types defined in the Subgraph definitions section. face feature with an isolated island in it. Figure 14d shows
Three of the test parts and their initial (default) feature nine blind holes and one face feature (note that this face is a
interpretations are shown in Figures 13–15. CH-face). Two compound holes recognized are highlighted
Test part 1 is shown in Figure 13. Its stock is specified to in Figure 14e. Five other features recognized are high-
be a block corresponding to the convex hull of the part; the lighted in Figure 14f, including three pockets, one blind
stock is not shown. For this part, 11 features were recog- hole and one open pocket. The execution time for this part
nized by our algorithm as the first feature interpretation of was 0.45 s on the HP C180.
the part. Features found were three steps, two holes, two Test part 3 is shown in Figure 15a. The stock of test part 3

Table 4 Comparison of test part characteristics and system performance

Test Total no. Total no. No. of No. of No. of No. of No. of features No. of Execution time
of faces of edges convex edges MFAGs PCAGs CAGs recognized possible FI a (s)
1 31 98 17 5 10 10 11 4 0.2 s
2 99 209 102 5 29 28 28 4 0.45 s
3 38 105 17 1 13 13 8 8 0.22 s
a
FI ¼ feature interpretations.

737
Automatic recognition of interacting machining features: S Gao and J J Shah

is a cylinder which is the same as the convex hull of the part. approach, the open pocket is first recognized as an isolated
Our algorithm recognized 13 features from the part as the feature. It is processed by a heuristic procedure which deter-
initial feature interpretation. Figure 15b shows four through mines whether there exist other better interpretations of it,
holes and one blind hole. Figure 15c shows four steps. and if so, it generates the best one according to the given
Figure 15d shows two holes and one slot. Another slot is rules. The heuristic procedure is being developed based on
highlighted in Figure 15e. The execution time for test part 3 both the geometry and the manufacturing knowledge. At
was 0.22 s. present, we can extract all slots and steps contained in an
A summary of results for the three test parts is given in open pocket if required by the user.
Table 4. The execution time refers to the time spent in Finally, this method does not contribute anything toward
generating the first feature interpretation of the part, includ- the recognition of features with sculptured surfaces. Owing
ing the time for reading the ACIS.sat file, recognizing to the complexity of sculptured surfaces, it is a challenge for
features, extracting feature parameters, and calculating all the existing feature recognition methods which are
tool access directions for each feature. usually limited to features defined by planar and quadric
surfaces.

DISCUSSION
ACKNOWLEDGEMENTS
In this paper, we have presented a hybrid approach for
automatic recognition of machining features from B-rep This work was conducted during the period when the first
solid models. The approach combines aspects of graph- author was a visiting scholar at the Design Automation
based and hint-based feature recognition with delta volume Laboratory at Arizona State University. His visit was sup-
decomposition, so that it can deal with all six types of ported by the Pao Yu-Kong and Pao Zhao-Long Scholar-
feature interactions with high efficiency. Theoretically, the ship. Partial funding was provided by a DARPA/RaDEO
computational complexity of the algorithm can be shown to project. The authors are also grateful to the following
be: researchers at the Design Automation Laboratory: Hiren
Dedhia, Sachin Solkhan, Roshan DeSouza, Boming Xu
O[M p N p T p (M þ N)], and Bernie Bettig for their suggestions and critique.
where M ¼ the maximum number of edges per face (non-
stock and non-CH); T ¼ the maximum number of arcs (con-
vex, nonstock and outloop) per MFAG; and N ¼ the REFERENCES
maximum number of nodes per MFAG.
The hybrid recognition method presented in this paper 1. Shah, J. J., Mantyla, M. and Nau, D., eds, Advances in Feature Based
offers several advantages over previous methods. Feature Manufacturing. Elsevier/North-Holland, Amsterdam, 1994.
MCSGs are used as feature hints, so that the hints for all 2. Salomons, O., Constraint specification and satisfaction in feature
types of features can be generated and completed with the based design for manufacturing, PhD thesis, University of Tarente,
1995.
same procedure. This makes it possible for the user to add 3. Tseng, Y. J. and Joshi, S. B., Recognizing multiple interpretations of
new features without changing the code. In our approach, interacting machining features. Computer-Aided Design, 1994, 26(9),
the user just needs to create a feature instance with ACIS in 667–688.
order to add a new type of feature — all its properties are 4. Han, J. H., 3D geometric reasoning algorithm for feature recognition,
automatically extracted and stored in a feature library. All PhD thesis, University of Southern California, 1996.
5. Laakko, T. and Mantyla, M., Feature modeling by incremental feature
MCSGs are generated by graph decomposition without recognition. Computer-Aided Design, 1993, 25(8), 479–492.
redundant MCSG being produced. Features are completed 6. Joshi, S. and Chang, T. C., Graph-based heuristics for recognition of
by the same completion algorithm (independent of feature machined features from a 3D solid model. Computer-Aided Design,
type) based on an efficient virtual link generation algorithm, 1988, 20(2), 58–66.
7. Marefat, M. and Kashyap, R. L., Geometric reasoning for recognition
which achieves its high efficiency by minimizing the search of three-dimensional object features. IEEE Transactions on Pattern
space for virtual links and not generating unusable virtual Analysis and Machine Intelligence, 1990, 12(10), 949–965.
links. A new feature interaction classification and a virtual 8. Ji, Q., Marefat, M. and Lever, P. J., An evidential reasoning approach
link classification are used to support the recognition of for recognizing shape feature. In Proceedings of the 11th IEEE Con-
interacting features. The manufacturing face adjacency ference on AI for Applications, 1995.
9. Trika, S. N. and Kashyap, R. L., Geometric reasoning for extraction of
graph proposed enables all isolated features to be recog- manufacturing features in isooriented polyhedrons. IEEE Transac-
nized before interacting features. MFAG also plays an tions on Pattern Analysis and Machine Intelligence, 1993, 16(11),
important role in reducing the search spaces for virtual 1087–1100.
links, unifiable faces and features. Unlike other graph- 10. Vandenbrande, J. H. and Requicha, A. A. G., Spatial reasoning for the
automatic recognition of machinable features in solid models. IEEE
based methods, our approach can generate alternative inter- Transactions on Pattern Analysis and Machine Analysis, 1993,
pretations of interacting features. 15(12), 1269.
One issue not yet addressed is that of open pockets, which 11. Han, J. H. and Requicha, A. A. G., Integration of feature based design
are still problematic. At present, there are two main kinds of and feature recognition, ASME International Computers in Engineer-
methods to recognize open pockets. One 21,7,9,14–18 treats ing Conference, September 1995.
12. Regli, W. C., Gupta, S. K. and Nau, D. S., Feature recognition for
them as interacting features, always dividing them into manufacturability analysis, ASME International Computers in Engi-
many predefined features first. This method is time- neering Conference, Minneapolis, 1994.
consuming. Even worse is that sometimes it is unreasonable, 13. Regli, W. C., Geometric algorithms for recognition of features from
since it is better to machine an open pocket as a single solid models, PhD thesis, The University of Maryland, College Park,
MD, 1995.
feature. In another approach 6,13, open pockets are recog- 14. Sakurai, H., Volume decomposition and feature recognition: Part I —
nized as single features, but no other interpretation can be polyhedral objects. Computer-Aided Design, 1995, 27(11), 833–843.
provided which may exist and may be better. In our 15. Sakurai, H. and Dave, P., Volume decomposition and feature

738
Automatic recognition of interacting machining features: S Gao and J J Shah

recognition: Part H — curved objects. Computer-Aided Design, 1996, base volume decomposition. In Proceedings of the ASME Design
28(6/7), 519–532. Automation Conference 1, 1994.
16. Kim, Y. S., Volumetric feature recognition using convex decomposi- 19. Falcidieno, B. and Giannini F., Extraction and organization of forrm
tion. In Advances in Feature Based Manufacturing, ed. J. J. Shah, features into a structured boundary model. In Proceedings of Euro-
M. Mantyla and D. Nau. Elsevier/North Holland, Amsterdam, graphics’87, Amsterdam, 1987.
1994. 20. Floriani, D. and Bruzzone, E., Building a feature-based object description
17. Shen, Y. and Shah, J. J., Feature recognition by volume decomposition fromaboundarymodel.Computer-AidedDesign, 1989, 21(10), 602–610.
using half-space partitioning. In Proceedings of the ASME Computers 21. Ferreira, J. and Hinduja, S., Convex hull-based feature recognition
in Engineering, Minneapolis, 1994. method for 2.5 components. Computer-Aided Design, 1990, 22(1),
18. Coles, J., Crawford, R. and Wood K., Form feature recognition using 41–49.

Shuming Gao is currently a professor Jami J. Shah is Professor of Mech-


of Computer Science at Zhejiang Uni- anical & Aerospace Engineering and
versity and is serving as the Vice Director of Design Automation Lab at
Director of State Key Laboratory of Arizona State University, where he
CAD&CG at Zheijiang University. has been since 1984. He has authored
He received his BS in Mathematics over 90 technical papers on geometric
from Anhui University, and his MS modeling, features, databases, pro-
and Ph.D. in Applied Mathematics cess planning, and design automation.
from Zhejiang University, P.R. He is co-author of the first textbook
China. He was a visiting scholar in on features, titled ‘‘Parametric &
Design Automation Laboratory at Feature based CAD/CAM’’.
Arizona State University from 1996
to 1997. His research interests include feature modeling, solid
modeling, CAD/CAM integration, and virtual reality in design and
manufacturing.

739

You might also like