Knight's Tour Generator
Tourneys and the Fast Generation and Obfuscation of Closed Knight's Tours
ConcentricBraid.h
Go to the documentation of this file.
1 
4 // MIT License
5 //
6 // Copyright (c) 2019 Ian Parberry
7 //
8 // Permission is hereby granted, free of charge, to any person obtaining a copy
9 // of this software and associated documentation files (the "Software"), to
10 // deal in the Software without restriction, including without limitation the
11 // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
12 // sell copies of the Software, and to permit persons to whom the Software is
13 // furnished to do so, subject to the following conditions:
14 //
15 // The above copyright notice and this permission notice shall be included in
16 // all copies or substantial portions of the Software.
17 //
18 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
21 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
23 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
24 // IN THE SOFTWARE.
25 
26 #ifndef __Braid__
27 #define __Braid__
28 
29 #include "Board.h"
30 #include "Defines.h"
31 #include "Structs.h"
32 
41 
43  private:
44  int m_nMove4x4[16] =
45  {
46  6, 7, 4, 5,
47  13, 12, 15, 14,
48  1, 0, 3, 2,
49  10, 11, 8, 9
50  }; //m_nMove4x4
51 
52  int m_nMove6x6[36] =
53  {
54  8, 12, 6, 7, 17, 9,
55  19, 18, 4, 1, 2, 3,
56  25, 0, 22, 11, 5, 28,
57  31, 30, 16, 34, 35, 10,
58  13, 33, 15, 14, 32, 21,
59  26, 20, 24, 29, 23, 27
60  };
61 
62  CBoard* m_pBoard4x4 = nullptr;
63  CBoard* m_pBoard6x6 = nullptr;
64 
65  public:
68 
69  void Generate(CBoard& b);
70 }; //CConcentricBraid
71 
72 #endif
void Generate(CBoard &b)
Generate a concentric braided tourney.
Defines, enumerated types, and typedefs.
CBoard * m_pBoard4x4
Pointer to 4x4 center.
int m_nMove6x6[36]
Undirected move table for 6x6 center.
CConcentricBraid()
Constructor.
Header for the structs CSearchRequest, CSearchResult, and CRect.
int m_nMove4x4[16]
Undirected move table for 4x4 center.
Concentric braided tourney generator.
Chessboard.
Definition: Board.h:42
Header for the chessboard CBoard.
~CConcentricBraid()
Destructor.
CBoard * m_pBoard6x6
Pointer to 6x6 center.