Attribute Adjacency Matrix Approach for Extracting and Recognizing Manufacturing Prismatic Features from CAD Models

This p aper introduces Developed Attributes A djacency Matrix (DAAM) approach for extracting and recognizing of part ’ s features, by deal with decoupling or isolated manufacturing features. The proposed algorithm consists of two stages, pre-processor stage which perform extra ction o f i nformation from Design Exchange Format (DXF) file format in Computer Aided Design (CAD), and post-processor stage which recognizes part ’ s fe atures depending on a ttributes ad jacency matrix. The main contributions of this research include building the adjacent relations between faces of the part by geometrical characteristics in form of matrix, and use clustering operation to extract the exact faces of feature and use different classes of geometrical characteristics to assisting to recognize d epression prismatic features useful in machining and other application such as dimensional inspection and assembly.


Introduction
The gap in information between CAD and computer aided process planning (CAPP) or automated inspection planning is reflect by the fact these applications require as input form of features, where traditional CAD representation can provide only faces, edges and vertices [1,2].Therefore, to overcome this deficiency in integration, several different mechanisms have been proposed to automatically extract the high-level representation called features from low-level entities in CAD representation.The ambiguity of feature representation is one of the major sources of difficulty for feature extraction mechanisms [3].Various approaches have been developed for automatic feature recognition mechanisms that can be informally classified into the categories [4,5]: Syntactic pattern recognition approach, Graph-based approach, Rule-based approach, Volumetric approaches (including "cellbased" techniques) and Evidence-based reasoning approaches.
Syntactic pattern recognition characterizes the overall part shapes as the composition of certain geometric primitives.Feature recognition proceeds by parsing the input syntactic expression of a part using grammar rules to identify the syntactic patterns representing the geometric primitives.In graph-based feature recognition, a graph is used to describe the topological shape of a part as well as that of a primitive feature.Feature recognition is performed by searching graph representation of the part to identify a sub-graph that matches that of a primitive using sub-graph convex angles does not form part of a feature."Based on this assumption, the algorithm decomposes the AAG into sub-graphs by deleting the nodes which are only connected by convex edges.These sub graphs are further analyzed by the algorithm to determine the feature type [1].Ketan (1999) has developed the AAG.He suggests the Improved Attribute Adjacency Graph (IAAG) algorithm has the capability to the topological information in addition to the geometric relationships of faces that comprise the feature to overcome some shortcomings of AAG algorithm .He used values (+0,-0,0,1,+1,-1) in addition to the values (0,1) of the AAG [6].In Volumetric approaches, Regli, Gupta and Nau(1994) they presents a methodology for recognizing a class of machinable features and addressing the computational problems posed by the existence of feature-based alternatives.He addresses a class of volumetric features that describe material removal volumes made by operations on 3-axis vertical machining centers including: drilling, pocket-milling, slot-milling, face milling, chamfering, filleting, and blended surfaces [7,8,9].
In evidence-based reasoning approaches, Marefat (1997) combines and propagates evidences to determine a set of correct virtual links to be augmented to the cavity graph representing a depression of the object so that the resulting super graph can be partitioned to obtain the features of the object.The hierarchical belief network is constructed based on the hypotheses for the potential virtual links [10].Ji and M.M. Marefat

Attribute Adjacency Graph (AAG) and Edges Definition:-
The attribute adjacency graph (AAG) can be defined as a graph G = (N,A,T) where N is the set of nodes, A is the set of arcs, and ,T is the set of attributes to arcs in A, such that: • For every face f in F, there exists a unique node n in N.
• For every edge e in E, there exists a unique arc in A, connecting the nodes n i and n j , corresponding to face f i and face f j , which share the common edge e.
For every arc a in A, is assigned an attribute t, t= o, if the faces share the edge from a concave angle and t=1, if the faces share the edge from a convex angle.Let e be the edge shared between two faces Fi and Fj figure (2).Then, convexity or concavity of the edge is found as follows [13].
Q=cos -1 ((fi.f j )/|fi.f j |) Where: fi and fj are normals of the faces Fi and Fj Q is the angle between Fi and Fj If: Q=90, then the relation is concavity (0).Q<90, then the relation is concavity (-0).Q>90, then the relation is concavity (+0).
Otherwise the relation is convexity (1) or no relation between Fi and Fj the relation is empty (*).

Constructing Developed Attribute
Adjacency Matrix (DAAM) and Extraction and Recognition for Isolated Features: The steps of algorithm for construct the DAAM and feature recognition : Step-1: Construct the whole part matrix (N, M) which is equal to the number of faces in part, and then find the adjacencies faces to arbitrary face which is selected .If in analysis an adjacency is found between two faces then it is documented by entering (0, +0,-0, 1) into the cell (Ni, Mj) of the matrix which represents the row and column number.The procedure is continued until the whole part is analyzed; the flowchart of this analysis is illustrated in Figure (3).
Step-2: By examination of the column for any face in DAAM, if all cells in column contain (1) or empty (*); then this face dose not represent cluster, otherwise if the column contains (0),(-0) or (+0) in any cell , then this face represents cluster and the cluster corresponding to the face which has relation to analysis face is added.Step-4: For each cluster F r examine this cluster to recognize feature type corresponding to it, by doing the following: a) By taking every column corresponding to the underlying set in Fr.Calculate the number of the cells contained p= (0), S= (-0) and A= (+0) and then match to the feature pattern to know the type of this feature.b) After calculating the p, S, A for all columns corresponding to the underlying set in Fr (the columns in DAAM).c) Calculate H (the number of the cell contains 0,-0, +0) (H= P/2+S/2+A/2).Figure (6) shows a flowchart of feature recognition for some feature types.
A simple example is illustrated in Figure (7) to examine the feature extraction and recognition algorithm for simple slot feature.
Step-1: First build DAAM by identifying the edge situations for every face in part model as shown in Figure (8), step-1.
Step-2: In step 2 of the algorithm, the results of this step are: w 1 ={w 1 ,w 3 ,w 5 },w 3 ={w 3 ,w 1 },w 5 = {w 5 ,w 1 },as shown in figure (8), step-2 Step-3: By taking the results in pervious step and then examining the results in step3 of the algorithm.Take the cluster w 3 ={w 3 ,w 1 } because the algorithm does not accept the chance for taking any cluster.
w o =w 3 Uw 1. w o+1 ={w 1 ,w 3 ,w 5 }.If w o+1 -w o =Φ ; then F 1 = w o ={w 1 ,w 3 ,w 5 }, and delete the cluster w 1 ,w 2 ,w 5 in step 2 and repeat (b) in step 3.The result of this example is : F 1 ={w 1 ,w 3 ,w 5 }.As shown Figure (8), step-3 Step-4: This cluster is applied to step 4 in the algorithm by taking the columns corresponding to w 1 ,w 3 and w 5 , in this example , the number of the cells contains (0) is four and the number of the cells which contain (+0) or (-0) is zero.The type of feature in this example is simple slot.asshown in Figure (8), step-4.

Experiment results
The Applied the proposed algorithm we recognize six primitive clusters witch are representing features implicitly as shown in figure (10).

Another example:
Applied the algorithm on another example shown in figure (11), we recognize seven primitive clusters witch are representing features implicitly as shown in figure (12).

Conclusion
The main contributions of this research include building the adjacent relations between faces of the part by geometrical and topologies definitions in form of matrix, and use clustering operation to extract the exact faces of feature which simplifies the procedure of search and use different classes of geometrical characteristics.The system was success to recognize several primitive features for prismatic part with high efficiency.The feature recognition is useful in variety of manufacturing application such as computer process planning and dimensional inspection planning where the feature information can be used to determine the machining sequence and tool selection and tool approach direction.Extracting and recognizing different types of protrusion and cylindrical features and several types of interacting features are directions for future works.
w j ={u U w i } …….(1)And this continues until the all faces are examined.The results from this step represent the set of clusters.The flowchart of this step is shown in Figure (4).
w j ={w j ,w i+1, w i+2, …..,w n } ……...(2) Step-3: From the results in previous step by examine any cluster do the following: a) W=Φ ( empty set) ,then end PDF created with pdfFactory Pro trial version www.pdffactory.comw o+1w o = Φ, then F r = w o and delete the underlying set for any set in w o ( Wevery underlying set in w o ) from (a) because any face lies only in one cluster due to applying isolated features .If no, repeat (b).The results from this step are set of clusters: F r = w o , F r+1 = w o, F r+2 = w o …..(4) These clusters represent explicitly set of features and these results are used in next step.The flowchart of this step is shown in Figure (5).
feature recognition interfaced with AutoCAD 2002 package.AutoCAD stores the representation of the solid in form of the B-Rep, pre-process need to convert the DXF file format to obtain the representation of the part in form of faces, edges and vertices.The algorithm coded in visual basic 6 programming language and implemented on Pentium IV.Several parts with varying number of PDF created with pdfFactory Pro trial version www.pdffactory.comEng & Tech.Journal, Vol. 27, No.10, 2009 Attribute Adjacency Matrix Approach for Extracting and Recognizing Manufacturing Prismatic Features from CAD Models 2090 features were tested.Figure (9) show the part with isolated features.

Figure ( 12 )
Figure (12)The output results from feature recognition algorithm.

Eng & Tech. Journal, Vol. 27, No.10, 2009 Attribute Adjacency Matrix Approach for Extracting and Recognizing Manufacturing Prismatic Features from CAD Models
PDF created with pdfFactory Pro trial version www.pdffactory.com