20 Street kadissia Oujda 60000 Morocco. Email1 :
. Email2 :
. Comments : 4
Polynomial algorithm for graphs isomorphism'si Author: Mohamed MIMOUNI. 20 Street kadissia Oujda 60000 Morocco. Email1 :
[email protected] Email2 :
[email protected] Comments : 4 pages. Subj – Class : Graph isomorphism. Abstract: isomorphism is in P. Graph isomorphism
Abstract When two graphs are isomorphic, one can find the function of isomorphism's between two graphs. Here I show that this problem is polynomial
Pseudo-tree from a vertex Let G a graph and s one of these vertices. From this vertex we draw the graph in another way: 1. Here we set the top s. 2. Here we set all vertices adjacent to s. Without forgetting the edges. 3. Here we set all vertices adjacent to vertices of the highest level. 4. End when there is no more vertices.
Labeling of vertices Each vertex has adjacent peaks; the labeling of a vertex is thus obtained in terms of this adjacent: 1. Make all the pseudo-trees. 2. If the graph G year peaks, then a peak year S parts or in its labeling. 3. Each part consists of four parts: I) The level where it is. II) The number of which are adjacent in the level above. III) The number of which are adjacent in the same level. IV) The number of which are adjacent in the level below.
Example Either the two graphs presented in the table, here we obtained a labeling of each vertex, and find the corresponding... a:c,d,f,h,j 1:2,4,5,6 b:c,d,e,h,j 2:1,6,9 c:a,b,e,f 3:5,6,7,8,10 d:a,b,e,f,i,j 4:1,5,6,7,8 e:b,c,d,i 5:1,3,4,10 f:a,c,d,g,j 6:1,2,3,4,7,10 g:f,i 7:3,4,6,10 h:a,b 8:3,4 i:d,e,g 9:2,10 j:a,b,d,f 10:3,5,6,7,9
1
The pseudo-trees. The following table gives all the pseudo-first graph trees. header level vertex level vertex header 1
1
1
1
6
6
2
2,4,5,6
1
2
1,2,3,4,7,10 6
3
9,7,8,3,10 1
3
5,9,8
6
1
2
2
1
7
7
2
1,6,9
2
2
3,4,6,10
7
3
4,5,3,7,10 2
3
5,8,1,2,9
7
4
8
2
1
8
8
1
3
3
2
3,4
8
2
5,6,7,8,10 3
3
5,6,7,10,1
8
3
1,4,2,9
3
4
2,9
8
1
4
4
1
9
9
2
1,5,6,7,8 4
2
2,10
9
3
2,3,10
4
3
1,6,3,5,7
9
4
9
4
4
4,8
9
1
5
5
1
10
10
2
1,3,4,10
5
2
3,5,6,7,9
10
3
2,6,7,8,9 5
3
8,1,4,2
10
The following table gives the entire pseudo-second-tree graph. level vertex header level vertex header 1
a
a
2
a,c,d,g,j f
2
c,d,f,h,j a
3
h,b,e,i
f
3
b,e,i,g
a
1
g
g
1
b
b
2
f,i
g
2
c,d,e,h,j b
3
a,c,d,j,e g
3
a,f,i
b
4
h,b
g
4
g
b
1
h
h
1
c
c
2
a,b
h
2
a,b,e,f
c
3
c,d,f,j,e h
3
d,h,j,i,g c
4
i,g
h
1
d
d
1
i
i
2
a,b,e,f,i,j d
2
d,e,g
i
3
c,h,g
d
3
a,b,f,j,c i
1
e
e
4
h
i
2
b,c,d,i
e
1
j
j
3
h,j,a,f,g e
2
a,b,d,f
j
1
f
3
c,h,e,i,g j
f
2
The labeling of first graph is: vertex label 9
|1-0-0-2|2-1-0-1|2-1-0-1|3-1-1-0|3-1-1-0|3-1-1-0|3-1-1-0|3-2-0-0|4-1-1-0|4-2-0-0
8
|1-0-0-2|2-1-0-1|2-1-0-1|3-1-1-0|3-1-1-0|3-2-0-0|3-2-0-0|3-2-0-0|4-1-1-0|4-2-0-0
2
|1-0-0-3|2-1-0-2|2-1-1-1|2-1-1-1|3-1-2-0|3-1-2-0|3-1-2-0|3-2-0-1|3-2-1-0|4-2-1-0
5
|1-0-0-4|2-1-1-2|2-1-1-2|2-1-1-2|2-1-1-2|3-1-2-1|3-1-3-0|3-2-2-0|3-3-1-0|3-4-0-0
1
|1-0-0-4|2-1-1-2|2-1-1-2|2-1-2-1|2-1-2-1|3-1-2-1|3-1-2-1|3-2-2-0|3-2-2-0|3-2-2-0
7
|1-0-0-4|2-1-1-2|2-1-2-1|2-1-2-1|2-1-3-0|3-1-2-1|3-1-3-0|3-2-2-0|3-2-2-0|3-3-1-0
4
|1-0-0-5|2-1-0-4|2-1-1-3|2-1-1-3|2-1-2-2|2-1-2-2|3-2-2-1|3-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3-3-1-1
d
|1-0-0-6|2-1-1-4|2-1-2-3|2-1-2-3|2-1-2-3|2-1-2-3|2-1-3-2|3-2-3-1|3-2-3-1|3-4-2-0
So the solution is: graph1 graph2
9
g
8
h
2
i
5
c
1
e
7
j
4
b
3
a
10
f
6
d
3
Validity of the algorithm Demonstrate validation of this algorithm is trivial!
Theorem Let A and B, two vertices in a graph G. function of the automorphism of G to G is noted f. f (A) = B if and only if, A and B have the same labeling.
Proof 1) f (A) = B. Here we show that A and B on the same label. Let x and two other top graph G, such that f (x) = y. labeling is done from a pseudo-tree, so if the pseudo-tree with x as header, A is in the level p, and B is in the level q. then the automorphism preserves the distance, we have: For the pseudo-tree with it as header, B is in the level p, and A is in the level q. With the same idea, we have for the pseudo-tree x, the vertices adjacent to A are divided into three parts (top, at the same level as A, and bottom), then for the pseudo-tree y, the vertices adjacent B are also divided into three parts (top, at the same level as B, and bottom). So the two peaks: A and B have the same labeling. 2) A and B have the same labeling. If the labeling of A in the pseudo-tree x: n|h|m|b, labeling of B in the pseudo-tree is also: n|h|m|b because we have f (x) = y. with the same idea (the automorphism preserves the distance), we find that f (A) = B. So: f (A) = B if and only if, A and B have the same labeling.
Complexity of the algorithm 1. The complexity of a pseudo-tree is O (n 2 ) . 2. The complexity of all the pseudo is O (n 3 ) . 3. The complexity of the labeling of a vertex from a pseudo-tree O (n) . 4. The complexity of the labeling of a vertex is O (n 2 ) . So the algorithm is polynomial. i
It is a machine translation.
4