码迷,mamicode.com
首页 > 编程语言 > 详细

图同构哈希算法实现 (作业)

时间:2015-05-19 22:31:01      阅读:290      评论:0      收藏:0      [点我收藏+]

标签:

图同构哈希算法实现 (作业)

图同构哈希算法实现 (作业)

技术分享

测试数据和测试图片参考地址

Hash 函数除了做为 Hash 表的辅助工具,在单独使用的时候可以实现判断两个数据是否相同或等价

代码

// CreateTime: 2015-05-15 21:24:47

#include <iostream>
#include <cstdio>
#include <cstring>
#include <algorithm>

using namespace std;

const int maxn = 1000+10;
int g1[maxn][maxn];
int g2[maxn][maxn];

long long f[maxn];
long long tf[maxn];
long long hash_array1[maxn];
long long hash_array2[maxn];
int n;
int m;
int A = 9998;
int B = 9998;
int C = 9998;
int K = 129;
int D = 559;
int mod = 999990;
pair<int, int> P1[100000];
pair<int, int> P2[100000];

void graph_hash1() {
    for (int i = 0; i < n; i++) {
        for (int q = 0; q < n; q++) {
            f[q] = 1;
        }
        for (int z = 0; z < K; z++) {
            for (int t = 0; t < n; t++) {
                tf[t] = f[t];
            }

            for (int q = 0; q < n; q++) {
                f[q] = f[q] * A;
            }
            for (int q = 0; q < m; q++) {
                int first = P2[q].first;
                int second = P2[q].second;
                f[first] = f[first] + tf[second] * B;
                f[second] = f[second] + tf[first] * C;
            }
            f[i] += D;
            for (int q = 0; q < n; q++) {
                f[q] = f[q] % mod;
            }
        }
        hash_array2[i] = f[i];
    }
    sort(hash_array2, hash_array2+n);
}

void graph_hash2() {
    for (int i = 0; i < n; i++) {
        for (int q = 0; q < n; q++) {
            f[q] = 1;
        }
        for (int z = 0; z < K; z++) {
            for (int t = 0; t < n; t++) {
                tf[t] = f[t];
            }

            for (int q = 0; q < n; q++) {
                f[q] = f[q] * A;
            }
            for (int q = 0; q < m; q++) {
                int first = P1[q].first;
                int second = P1[q].second;
                f[first] = f[first] + tf[second] * B;
                f[second] = f[second] + tf[first] * C;
            }
            f[i] += D;
            for (int q = 0; q < n; q++) {
                f[q] = f[q] % mod;
            }
        }
        hash_array1[i] = f[i];
    }
    sort(hash_array1, hash_array1+n);
}

int main(void) {
    int m1 = 0;
    int m2 = 0;
    int n1 = 0;
    int n2 = 0;

    scanf("%d", &n1);
    for (int i = 0; i < n1; i++) {
        for (int j = 0; j < n1; j++) {
            scanf("%d", &g1[i][j]);
            if (g1[i][j] == 1) {
                P1[m1++] = make_pair(i, j);
            }
        }
    }

    scanf("%d", &n2);
    for (int i = 0; i < n2; i++) {
        for (int j = 0; j < n2; j++) {
            scanf("%d", &g2[i][j]);
            if (g2[i][j] == 1) {
                P2[m2++] = make_pair(i, j);
            }
        }
    }

    if (n1 != n2) {
        printf("No\n");
        return 0;
    }

    if (m1 != m2) {
        printf("No\n");
        return 0;
    }

    m = m1;
    n = n1;

    graph_hash1();
    graph_hash2();

    for (int i = 0; i < n; i++) {
        long long num1  = hash_array1[i];
        long long num2  = hash_array2[i];
        if (num1 != num2) {
            printf("No\n");
            return 0;
        }
        // cout << num1 << "  " << num2 << endl;
    }
    printf("Yes\n");

    return 0;
}

例子 1

8
0 0 0 1 1 1 1 1
0 0 0 1 1 1 1 1
0 0 0 1 1 1 1 1
1 1 1 0 0 1 1 1
1 1 1 0 0 1 1 1
1 1 1 1 1 0 0 0
1 1 1 1 1 0 0 0
1 1 1 1 1 0 0 0
8
0 1 1 1 1 1 1 0
1 0 1 0 0 1 1 1
1 1 0 1 1 0 0 1
1 0 1 0 0 1 1 1
1 0 1 0 0 1 1 1
1 1 0 1 1 0 0 1
1 1 0 1 1 0 0 1
0 1 1 1 1 1 1 0

例子 2

10
0 1 0 0 1 0 1 0 0 0
1 0 1 0 0 0 0 1 0 0
0 1 0 1 0 0 0 0 1 0
0 0 1 0 1 0 0 0 0 1
1 0 0 1 0 1 0 0 0 0
0 0 0 0 1 0 0 1 1 0
1 0 0 0 0 0 0 0 1 1
0 1 0 0 0 1 0 0 0 1
0 0 1 0 0 1 1 0 0 0
0 0 0 1 0 0 1 1 0 0

10
0 0 0 1 0 1 0 0 0 1
0 0 0 1 1 0 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 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 1 0 0 1 0 0
0 0 1 0 0 1 1 1 0 0 1 0 0 0 0 0 0 0 1 0 0 1 1 0 0 0 0 0 1 0 0 0 0 1 1 0 1 0 0 0
1 1 1 0 0 1 1 0 1 0 0 0 0 0 0 0 1 1 0 0 0 1 0 1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0
0 1 0 1 0 0 1 0 1 1 0 1 0 0 0 1 0 0 1 0 0 0 0 1 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 1 1 1 0 0 1 1 1 1 0 0 0 1 0 0 0 0 0 0 0 0 1 1 0 0 0 1 0 0 0 1
0 0 0 1 0 0 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 0 0 0 0 1
0 1 1 0 1 0 0 0 0 1 0 0 1 0 1 0 0 0 0 0 0 0 0 1 0 1 0 0 1 1 0 1 0 0 0 0 0 0 0 1
1 0 0 0 1 1 1 0 1 0 1 1 1 0 0 1 0 0 0 0 0 0 0 0 0 1 0 0 1 0 1 0 0 0 0 0 0 0 0 0
1 0 1 0 0 0 1 0 0 1 1 0 0 1 1 1 0 0 0 1 0 0 1 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0
1 0 0 0 1 0 0 1 1 0 0 0 0 0 0 1 0 0 1 1 1 0 0 1 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 0
程序输出
 NO

图同构哈希算法实现 (作业)

标签:

原文地址:http://www.cnblogs.com/sunznx/p/4515537.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!