The key to construct an ultra magic 17x17 square is 0 - 16 - 1 - 2 - 3 - 4 - 5 - 6 - 7 - 8 - 9 - 10 - 11 - 12 - 13 - 14 - 15
The second grid is a reflection (rotated by a quarter and mirrored) of the first grid.
Take 1x number from the first grid +1
0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |
14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 |
10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |
8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 |
6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 |
4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 |
2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 |
16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 |
15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 |
13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 |
11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 |
9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 |
7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 | 5 | 6 |
5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 | 3 | 4 |
3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 | 1 | 2 |
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 0 | 16 |
+ 17x number from second grid
0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 |
16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 |
1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 |
2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 |
3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 |
4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 |
5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 |
6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 |
7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 |
8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 |
9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 |
10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 |
11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 |
12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 |
13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 |
14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 | 15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 |
15 | 13 | 11 | 9 | 7 | 5 | 3 | 1 | 0 | 14 | 12 | 10 | 8 | 6 | 4 | 2 | 16 |
= Ultra magic 17x17 square
1 | 255 | 206 | 173 | 140 | 107 | 74 | 41 | 280 | 264 | 231 | 198 | 165 | 132 | 99 | 66 | 33 |
287 | 271 | 222 | 204 | 155 | 122 | 89 | 56 | 23 | 7 | 246 | 213 | 180 | 147 | 114 | 81 | 48 |
30 | 14 | 253 | 220 | 171 | 153 | 104 | 71 | 38 | 277 | 261 | 228 | 195 | 162 | 129 | 96 | 63 |
45 | 284 | 268 | 235 | 202 | 169 | 120 | 102 | 53 | 20 | 4 | 243 | 210 | 177 | 144 | 111 | 78 |
60 | 27 | 11 | 250 | 217 | 184 | 151 | 118 | 69 | 51 | 274 | 258 | 225 | 192 | 159 | 126 | 93 |
75 | 42 | 281 | 265 | 232 | 199 | 166 | 133 | 100 | 67 | 18 | 17 | 240 | 207 | 174 | 141 | 108 |
90 | 57 | 24 | 8 | 247 | 214 | 181 | 148 | 115 | 82 | 49 | 288 | 256 | 238 | 189 | 156 | 123 |
105 | 72 | 39 | 278 | 262 | 229 | 196 | 163 | 130 | 97 | 64 | 31 | 15 | 254 | 205 | 187 | 138 |
136 | 87 | 54 | 21 | 5 | 244 | 211 | 178 | 145 | 112 | 79 | 46 | 285 | 269 | 236 | 203 | 154 |
152 | 103 | 85 | 36 | 275 | 259 | 226 | 193 | 160 | 127 | 94 | 61 | 28 | 12 | 251 | 218 | 185 |
167 | 134 | 101 | 52 | 34 | 2 | 241 | 208 | 175 | 142 | 109 | 76 | 43 | 282 | 266 | 233 | 200 |
182 | 149 | 116 | 83 | 50 | 273 | 272 | 223 | 190 | 157 | 124 | 91 | 58 | 25 | 9 | 248 | 215 |
197 | 164 | 131 | 98 | 65 | 32 | 16 | 239 | 221 | 172 | 139 | 106 | 73 | 40 | 279 | 263 | 230 |
212 | 179 | 146 | 113 | 80 | 47 | 286 | 270 | 237 | 188 | 170 | 121 | 88 | 55 | 22 | 6 | 245 |
227 | 194 | 161 | 128 | 95 | 62 | 29 | 13 | 252 | 219 | 186 | 137 | 119 | 70 | 37 | 276 | 260 |
242 | 209 | 176 | 143 | 110 | 77 | 44 | 283 | 267 | 234 | 201 | 168 | 135 | 86 | 68 | 19 | 3 |
257 | 224 | 191 | 158 | 125 | 92 | 59 | 26 | 10 | 249 | 216 | 183 | 150 | 117 | 84 | 35 | 289 |
This 17x17 magic square is panmagic and symmetric.
You can use this method to construct ultra magic squares of order is prime number from 5x5 to infinity. See 5x5, 7x7, 11x11, 13x13, 17x17, 19x19, 23x23, 29x29, 31x31