Skip to content

Commit

Permalink
bugfix in GameOfLife Gotts_dots: 9,14 -> 9,15
Browse files Browse the repository at this point in the history
  • Loading branch information
martinus committed Mar 11, 2023
1 parent 105699e commit c4719db
Showing 1 changed file with 18 additions and 7 deletions.
25 changes: 18 additions & 7 deletions src/benchmarks/GameOfLife.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,13 +105,24 @@ BENCHMARK(GameOfLife_stabilizing) {

BENCHMARK(GameOfLife_growing) {
// https://conwaylife.com/wiki/Gotts_dots
game_of_life(bench, "Gotts dots", 2000, 4091,
{{0, 0}, {0, 1}, {0, 2}, {4, 11}, {5, 12}, {6, 13}, {7, 12}, {8, 11}, {9, 13}, {9, 14}, {9, 14},
{185, 24}, {186, 25}, {186, 26}, {186, 27}, {185, 27}, {184, 27}, {183, 27}, {182, 26}, {179, 28}, {180, 29}, {181, 29},
{179, 30}, {182, 32}, {183, 31}, {184, 31}, {185, 31}, {186, 31}, {186, 32}, {186, 33}, {185, 34}, {175, 35}, {176, 36},
{170, 37}, {176, 37}, {171, 38}, {172, 38}, {173, 38}, {174, 38}, {175, 38}, {176, 38}});
game_of_life(bench, "Gotts dots", 2000, 4599,
{
{0, 0}, {0, 1}, {0, 2}, // 1
{4, 11}, {5, 12}, {6, 13}, {7, 12}, {8, 11}, // 2
{9, 13}, {9, 14}, {9, 15}, // 3
{185, 24}, {186, 25}, {186, 26}, {186, 27}, {185, 27}, {184, 27}, {183, 27}, {182, 26}, // 4
{179, 28}, {180, 29}, {181, 29}, {179, 30}, // 5
{182, 32}, {183, 31}, {184, 31}, {185, 31}, {186, 31}, {186, 32}, {186, 33}, {185, 34}, // 6
{175, 35}, {176, 36}, {170, 37}, {176, 37}, {171, 38}, {172, 38}, {173, 38}, {174, 38}, {175, 38}, {176, 38}, // 7
});

// https://conwaylife.com/wiki/Puffer_2
game_of_life(bench, "Puffer 2", 2000, 7400, {{1, 0}, {2, 0}, {3, 0}, {15, 0}, {16, 0}, {17, 0}, {0, 1}, {3, 1}, {14, 1}, {17, 1}, {3, 2},
{8, 2}, {9, 2}, {10, 2}, {17, 2}, {3, 3}, {8, 3}, {11, 3}, {17, 3}, {2, 4}, {7, 4}, {16, 4}});
game_of_life(bench, "Puffer 2", 2000, 7400,
{
{1, 0}, {2, 0}, {3, 0}, {15, 0}, {16, 0}, {17, 0}, // line 0
{0, 1}, {3, 1}, {14, 1}, {17, 1}, // line 1
{3, 2}, {8, 2}, {9, 2}, {10, 2}, {17, 2}, // line 2
{3, 3}, {8, 3}, {11, 3}, {17, 3}, // line 3
{2, 4}, {7, 4}, {16, 4}, // line 4
});
}

0 comments on commit c4719db

Please sign in to comment.