graph_matching 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (94) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +20 -0
  3. data/.rubocop.yml +112 -0
  4. data/.ruby-version +1 -0
  5. data/.travis.yml +9 -0
  6. data/Gemfile +4 -0
  7. data/LICENSE.txt +22 -0
  8. data/README.md +205 -0
  9. data/Rakefile +9 -0
  10. data/benchmark/mcm_bipartite/complete_bigraphs/benchmark.rb +33 -0
  11. data/benchmark/mcm_bipartite/complete_bigraphs/compare.gnuplot +19 -0
  12. data/benchmark/mcm_bipartite/complete_bigraphs/edges_times_vertexes.data +500 -0
  13. data/benchmark/mcm_bipartite/complete_bigraphs/plot.gnuplot +21 -0
  14. data/benchmark/mcm_bipartite/complete_bigraphs/plot.png +0 -0
  15. data/benchmark/mcm_bipartite/complete_bigraphs/time.data +499 -0
  16. data/benchmark/mcm_general/complete_graphs/benchmark.rb +30 -0
  17. data/benchmark/mcm_general/complete_graphs/plot.gnuplot +19 -0
  18. data/benchmark/mcm_general/complete_graphs/plot.png +0 -0
  19. data/benchmark/mcm_general/complete_graphs/time.data +499 -0
  20. data/benchmark/mcm_general/complete_graphs/v_cubed.data +500 -0
  21. data/benchmark/mwm_bipartite/complete_bigraphs/benchmark.rb +43 -0
  22. data/benchmark/mwm_bipartite/complete_bigraphs/nmN.data +499 -0
  23. data/benchmark/mwm_bipartite/complete_bigraphs/nmN.xlsx +0 -0
  24. data/benchmark/mwm_bipartite/complete_bigraphs/plot.gnuplot +22 -0
  25. data/benchmark/mwm_bipartite/complete_bigraphs/plot.png +0 -0
  26. data/benchmark/mwm_bipartite/complete_bigraphs/time.data +299 -0
  27. data/benchmark/mwm_bipartite/misc/calc_d2/benchmark.rb +29 -0
  28. data/benchmark/mwm_general/complete_graphs/benchmark.rb +32 -0
  29. data/benchmark/mwm_general/complete_graphs/compare.gnuplot +19 -0
  30. data/benchmark/mwm_general/complete_graphs/mn_log_n.data +299 -0
  31. data/benchmark/mwm_general/complete_graphs/mn_log_n.xlsx +0 -0
  32. data/benchmark/mwm_general/complete_graphs/plot.gnuplot +22 -0
  33. data/benchmark/mwm_general/complete_graphs/plot.png +0 -0
  34. data/benchmark/mwm_general/complete_graphs/time.data +299 -0
  35. data/benchmark/mwm_general/incomplete_graphs/benchmark.rb +39 -0
  36. data/benchmark/mwm_general/incomplete_graphs/plot.gnuplot +22 -0
  37. data/benchmark/mwm_general/incomplete_graphs/plot.png +0 -0
  38. data/benchmark/mwm_general/incomplete_graphs/time_10_pct.data +299 -0
  39. data/benchmark/mwm_general/incomplete_graphs/time_20_pct.data +299 -0
  40. data/benchmark/mwm_general/incomplete_graphs/time_30_pct.data +299 -0
  41. data/graph_matching.gemspec +35 -0
  42. data/lib/graph_matching.rb +15 -0
  43. data/lib/graph_matching/algorithm/matching_algorithm.rb +23 -0
  44. data/lib/graph_matching/algorithm/mcm_bipartite.rb +118 -0
  45. data/lib/graph_matching/algorithm/mcm_general.rb +289 -0
  46. data/lib/graph_matching/algorithm/mwm_bipartite.rb +147 -0
  47. data/lib/graph_matching/algorithm/mwm_general.rb +1086 -0
  48. data/lib/graph_matching/algorithm/mwmg_delta_assertions.rb +94 -0
  49. data/lib/graph_matching/assertion.rb +41 -0
  50. data/lib/graph_matching/core_ext/set.rb +36 -0
  51. data/lib/graph_matching/directed_edge_set.rb +31 -0
  52. data/lib/graph_matching/errors.rb +23 -0
  53. data/lib/graph_matching/graph/bigraph.rb +37 -0
  54. data/lib/graph_matching/graph/graph.rb +63 -0
  55. data/lib/graph_matching/graph/weighted.rb +112 -0
  56. data/lib/graph_matching/graph/weighted_bigraph.rb +17 -0
  57. data/lib/graph_matching/graph/weighted_graph.rb +17 -0
  58. data/lib/graph_matching/integer_vertexes.rb +29 -0
  59. data/lib/graph_matching/matching.rb +120 -0
  60. data/lib/graph_matching/ordered_set.rb +59 -0
  61. data/lib/graph_matching/version.rb +6 -0
  62. data/lib/graph_matching/visualize.rb +93 -0
  63. data/profile/mcm_bipartite/compare.sh +15 -0
  64. data/profile/mcm_bipartite/publish.sh +12 -0
  65. data/profile/mwm_general/compare.sh +15 -0
  66. data/profile/mwm_general/profile.rb +28 -0
  67. data/profile/mwm_general/publish.sh +12 -0
  68. data/research/1965_edmonds.pdf +0 -0
  69. data/research/1975_even_kariv.pdf +0 -0
  70. data/research/1976_gabow.pdf +0 -0
  71. data/research/1980_micali_vazirani.pdf +0 -0
  72. data/research/1985_gabow.pdf +0 -0
  73. data/research/2002_tarjan.pdf +0 -0
  74. data/research/2013_zwick.pdf +0 -0
  75. data/research/examples/unweighted_general/1.txt +86 -0
  76. data/research/goodwin.pdf +0 -0
  77. data/research/kavathekar-scribe.pdf +0 -0
  78. data/research/kusner.pdf +0 -0
  79. data/research/van_rantwijk/mwm_example.py +19 -0
  80. data/research/van_rantwijk/mwmatching.py +945 -0
  81. data/spec/graph_matching/algorithm/matching_algorithm_spec.rb +14 -0
  82. data/spec/graph_matching/algorithm/mcm_bipartite_spec.rb +98 -0
  83. data/spec/graph_matching/algorithm/mcm_general_spec.rb +159 -0
  84. data/spec/graph_matching/algorithm/mwm_bipartite_spec.rb +82 -0
  85. data/spec/graph_matching/algorithm/mwm_general_spec.rb +439 -0
  86. data/spec/graph_matching/graph/bigraph_spec.rb +73 -0
  87. data/spec/graph_matching/graph/graph_spec.rb +53 -0
  88. data/spec/graph_matching/graph/weighted_spec.rb +29 -0
  89. data/spec/graph_matching/integer_vertexes_spec.rb +21 -0
  90. data/spec/graph_matching/matching_spec.rb +89 -0
  91. data/spec/graph_matching/visualize_spec.rb +38 -0
  92. data/spec/graph_matching_spec.rb +9 -0
  93. data/spec/spec_helper.rb +26 -0
  94. metadata +263 -0
@@ -0,0 +1,500 @@
1
+ 1 1
2
+ 2 8
3
+ 3 27
4
+ 4 64
5
+ 5 125
6
+ 6 216
7
+ 7 343
8
+ 8 512
9
+ 9 729
10
+ 10 1000
11
+ 11 1331
12
+ 12 1728
13
+ 13 2197
14
+ 14 2744
15
+ 15 3375
16
+ 16 4096
17
+ 17 4913
18
+ 18 5832
19
+ 19 6859
20
+ 20 8000
21
+ 21 9261
22
+ 22 10648
23
+ 23 12167
24
+ 24 13824
25
+ 25 15625
26
+ 26 17576
27
+ 27 19683
28
+ 28 21952
29
+ 29 24389
30
+ 30 27000
31
+ 31 29791
32
+ 32 32768
33
+ 33 35937
34
+ 34 39304
35
+ 35 42875
36
+ 36 46656
37
+ 37 50653
38
+ 38 54872
39
+ 39 59319
40
+ 40 64000
41
+ 41 68921
42
+ 42 74088
43
+ 43 79507
44
+ 44 85184
45
+ 45 91125
46
+ 46 97336
47
+ 47 103823
48
+ 48 110592
49
+ 49 117649
50
+ 50 125000
51
+ 51 132651
52
+ 52 140608
53
+ 53 148877
54
+ 54 157464
55
+ 55 166375
56
+ 56 175616
57
+ 57 185193
58
+ 58 195112
59
+ 59 205379
60
+ 60 216000
61
+ 61 226981
62
+ 62 238328
63
+ 63 250047
64
+ 64 262144
65
+ 65 274625
66
+ 66 287496
67
+ 67 300763
68
+ 68 314432
69
+ 69 328509
70
+ 70 343000
71
+ 71 357911
72
+ 72 373248
73
+ 73 389017
74
+ 74 405224
75
+ 75 421875
76
+ 76 438976
77
+ 77 456533
78
+ 78 474552
79
+ 79 493039
80
+ 80 512000
81
+ 81 531441
82
+ 82 551368
83
+ 83 571787
84
+ 84 592704
85
+ 85 614125
86
+ 86 636056
87
+ 87 658503
88
+ 88 681472
89
+ 89 704969
90
+ 90 729000
91
+ 91 753571
92
+ 92 778688
93
+ 93 804357
94
+ 94 830584
95
+ 95 857375
96
+ 96 884736
97
+ 97 912673
98
+ 98 941192
99
+ 99 970299
100
+ 100 1000000
101
+ 101 1030301
102
+ 102 1061208
103
+ 103 1092727
104
+ 104 1124864
105
+ 105 1157625
106
+ 106 1191016
107
+ 107 1225043
108
+ 108 1259712
109
+ 109 1295029
110
+ 110 1331000
111
+ 111 1367631
112
+ 112 1404928
113
+ 113 1442897
114
+ 114 1481544
115
+ 115 1520875
116
+ 116 1560896
117
+ 117 1601613
118
+ 118 1643032
119
+ 119 1685159
120
+ 120 1728000
121
+ 121 1771561
122
+ 122 1815848
123
+ 123 1860867
124
+ 124 1906624
125
+ 125 1953125
126
+ 126 2000376
127
+ 127 2048383
128
+ 128 2097152
129
+ 129 2146689
130
+ 130 2197000
131
+ 131 2248091
132
+ 132 2299968
133
+ 133 2352637
134
+ 134 2406104
135
+ 135 2460375
136
+ 136 2515456
137
+ 137 2571353
138
+ 138 2628072
139
+ 139 2685619
140
+ 140 2744000
141
+ 141 2803221
142
+ 142 2863288
143
+ 143 2924207
144
+ 144 2985984
145
+ 145 3048625
146
+ 146 3112136
147
+ 147 3176523
148
+ 148 3241792
149
+ 149 3307949
150
+ 150 3375000
151
+ 151 3442951
152
+ 152 3511808
153
+ 153 3581577
154
+ 154 3652264
155
+ 155 3723875
156
+ 156 3796416
157
+ 157 3869893
158
+ 158 3944312
159
+ 159 4019679
160
+ 160 4096000
161
+ 161 4173281
162
+ 162 4251528
163
+ 163 4330747
164
+ 164 4410944
165
+ 165 4492125
166
+ 166 4574296
167
+ 167 4657463
168
+ 168 4741632
169
+ 169 4826809
170
+ 170 4913000
171
+ 171 5000211
172
+ 172 5088448
173
+ 173 5177717
174
+ 174 5268024
175
+ 175 5359375
176
+ 176 5451776
177
+ 177 5545233
178
+ 178 5639752
179
+ 179 5735339
180
+ 180 5832000
181
+ 181 5929741
182
+ 182 6028568
183
+ 183 6128487
184
+ 184 6229504
185
+ 185 6331625
186
+ 186 6434856
187
+ 187 6539203
188
+ 188 6644672
189
+ 189 6751269
190
+ 190 6859000
191
+ 191 6967871
192
+ 192 7077888
193
+ 193 7189057
194
+ 194 7301384
195
+ 195 7414875
196
+ 196 7529536
197
+ 197 7645373
198
+ 198 7762392
199
+ 199 7880599
200
+ 200 8000000
201
+ 201 8120601
202
+ 202 8242408
203
+ 203 8365427
204
+ 204 8489664
205
+ 205 8615125
206
+ 206 8741816
207
+ 207 8869743
208
+ 208 8998912
209
+ 209 9129329
210
+ 210 9261000
211
+ 211 9393931
212
+ 212 9528128
213
+ 213 9663597
214
+ 214 9800344
215
+ 215 9938375
216
+ 216 10077696
217
+ 217 10218313
218
+ 218 10360232
219
+ 219 10503459
220
+ 220 10648000
221
+ 221 10793861
222
+ 222 10941048
223
+ 223 11089567
224
+ 224 11239424
225
+ 225 11390625
226
+ 226 11543176
227
+ 227 11697083
228
+ 228 11852352
229
+ 229 12008989
230
+ 230 12167000
231
+ 231 12326391
232
+ 232 12487168
233
+ 233 12649337
234
+ 234 12812904
235
+ 235 12977875
236
+ 236 13144256
237
+ 237 13312053
238
+ 238 13481272
239
+ 239 13651919
240
+ 240 13824000
241
+ 241 13997521
242
+ 242 14172488
243
+ 243 14348907
244
+ 244 14526784
245
+ 245 14706125
246
+ 246 14886936
247
+ 247 15069223
248
+ 248 15252992
249
+ 249 15438249
250
+ 250 15625000
251
+ 251 15813251
252
+ 252 16003008
253
+ 253 16194277
254
+ 254 16387064
255
+ 255 16581375
256
+ 256 16777216
257
+ 257 16974593
258
+ 258 17173512
259
+ 259 17373979
260
+ 260 17576000
261
+ 261 17779581
262
+ 262 17984728
263
+ 263 18191447
264
+ 264 18399744
265
+ 265 18609625
266
+ 266 18821096
267
+ 267 19034163
268
+ 268 19248832
269
+ 269 19465109
270
+ 270 19683000
271
+ 271 19902511
272
+ 272 20123648
273
+ 273 20346417
274
+ 274 20570824
275
+ 275 20796875
276
+ 276 21024576
277
+ 277 21253933
278
+ 278 21484952
279
+ 279 21717639
280
+ 280 21952000
281
+ 281 22188041
282
+ 282 22425768
283
+ 283 22665187
284
+ 284 22906304
285
+ 285 23149125
286
+ 286 23393656
287
+ 287 23639903
288
+ 288 23887872
289
+ 289 24137569
290
+ 290 24389000
291
+ 291 24642171
292
+ 292 24897088
293
+ 293 25153757
294
+ 294 25412184
295
+ 295 25672375
296
+ 296 25934336
297
+ 297 26198073
298
+ 298 26463592
299
+ 299 26730899
300
+ 300 27000000
301
+ 301 27270901
302
+ 302 27543608
303
+ 303 27818127
304
+ 304 28094464
305
+ 305 28372625
306
+ 306 28652616
307
+ 307 28934443
308
+ 308 29218112
309
+ 309 29503629
310
+ 310 29791000
311
+ 311 30080231
312
+ 312 30371328
313
+ 313 30664297
314
+ 314 30959144
315
+ 315 31255875
316
+ 316 31554496
317
+ 317 31855013
318
+ 318 32157432
319
+ 319 32461759
320
+ 320 32768000
321
+ 321 33076161
322
+ 322 33386248
323
+ 323 33698267
324
+ 324 34012224
325
+ 325 34328125
326
+ 326 34645976
327
+ 327 34965783
328
+ 328 35287552
329
+ 329 35611289
330
+ 330 35937000
331
+ 331 36264691
332
+ 332 36594368
333
+ 333 36926037
334
+ 334 37259704
335
+ 335 37595375
336
+ 336 37933056
337
+ 337 38272753
338
+ 338 38614472
339
+ 339 38958219
340
+ 340 39304000
341
+ 341 39651821
342
+ 342 40001688
343
+ 343 40353607
344
+ 344 40707584
345
+ 345 41063625
346
+ 346 41421736
347
+ 347 41781923
348
+ 348 42144192
349
+ 349 42508549
350
+ 350 42875000
351
+ 351 43243551
352
+ 352 43614208
353
+ 353 43986977
354
+ 354 44361864
355
+ 355 44738875
356
+ 356 45118016
357
+ 357 45499293
358
+ 358 45882712
359
+ 359 46268279
360
+ 360 46656000
361
+ 361 47045881
362
+ 362 47437928
363
+ 363 47832147
364
+ 364 48228544
365
+ 365 48627125
366
+ 366 49027896
367
+ 367 49430863
368
+ 368 49836032
369
+ 369 50243409
370
+ 370 50653000
371
+ 371 51064811
372
+ 372 51478848
373
+ 373 51895117
374
+ 374 52313624
375
+ 375 52734375
376
+ 376 53157376
377
+ 377 53582633
378
+ 378 54010152
379
+ 379 54439939
380
+ 380 54872000
381
+ 381 55306341
382
+ 382 55742968
383
+ 383 56181887
384
+ 384 56623104
385
+ 385 57066625
386
+ 386 57512456
387
+ 387 57960603
388
+ 388 58411072
389
+ 389 58863869
390
+ 390 59319000
391
+ 391 59776471
392
+ 392 60236288
393
+ 393 60698457
394
+ 394 61162984
395
+ 395 61629875
396
+ 396 62099136
397
+ 397 62570773
398
+ 398 63044792
399
+ 399 63521199
400
+ 400 64000000
401
+ 401 64481201
402
+ 402 64964808
403
+ 403 65450827
404
+ 404 65939264
405
+ 405 66430125
406
+ 406 66923416
407
+ 407 67419143
408
+ 408 67917312
409
+ 409 68417929
410
+ 410 68921000
411
+ 411 69426531
412
+ 412 69934528
413
+ 413 70444997
414
+ 414 70957944
415
+ 415 71473375
416
+ 416 71991296
417
+ 417 72511713
418
+ 418 73034632
419
+ 419 73560059
420
+ 420 74088000
421
+ 421 74618461
422
+ 422 75151448
423
+ 423 75686967
424
+ 424 76225024
425
+ 425 76765625
426
+ 426 77308776
427
+ 427 77854483
428
+ 428 78402752
429
+ 429 78953589
430
+ 430 79507000
431
+ 431 80062991
432
+ 432 80621568
433
+ 433 81182737
434
+ 434 81746504
435
+ 435 82312875
436
+ 436 82881856
437
+ 437 83453453
438
+ 438 84027672
439
+ 439 84604519
440
+ 440 85184000
441
+ 441 85766121
442
+ 442 86350888
443
+ 443 86938307
444
+ 444 87528384
445
+ 445 88121125
446
+ 446 88716536
447
+ 447 89314623
448
+ 448 89915392
449
+ 449 90518849
450
+ 450 91125000
451
+ 451 91733851
452
+ 452 92345408
453
+ 453 92959677
454
+ 454 93576664
455
+ 455 94196375
456
+ 456 94818816
457
+ 457 95443993
458
+ 458 96071912
459
+ 459 96702579
460
+ 460 97336000
461
+ 461 97972181
462
+ 462 98611128
463
+ 463 99252847
464
+ 464 99897344
465
+ 465 100544625
466
+ 466 101194696
467
+ 467 101847563
468
+ 468 102503232
469
+ 469 103161709
470
+ 470 103823000
471
+ 471 104487111
472
+ 472 105154048
473
+ 473 105823817
474
+ 474 106496424
475
+ 475 107171875
476
+ 476 107850176
477
+ 477 108531333
478
+ 478 109215352
479
+ 479 109902239
480
+ 480 110592000
481
+ 481 111284641
482
+ 482 111980168
483
+ 483 112678587
484
+ 484 113379904
485
+ 485 114084125
486
+ 486 114791256
487
+ 487 115501303
488
+ 488 116214272
489
+ 489 116930169
490
+ 490 117649000
491
+ 491 118370771
492
+ 492 119095488
493
+ 493 119823157
494
+ 494 120553784
495
+ 495 121287375
496
+ 496 122023936
497
+ 497 122763473
498
+ 498 123505992
499
+ 499 124251499
500
+ 500 125000000