Generated on Thu Apr 11 13:58:52 2019 for Gecode by doxygen 1.6.3

magic-square-partial.cpp

Go to the documentation of this file.
00001 /* -*- mode: C++; c-basic-offset: 2; indent-tabs-mode: nil -*- */
00002 /*
00003  *  Main authors:
00004  *     Christian Schulte <schulte@gecode.org>
00005  *
00006  *  Contributing authors:
00007  *     Samuel Gagnon <samuel.gagnon92@gmail.com>
00008 
00009  *  Copyright:
00010  *     Christian Schulte, 2001
00011  *     Samuel Gagnon, 2018
00012  *
00013  *  This file is part of Gecode, the generic constraint
00014  *  development environment:
00015  *     http://www.gecode.org
00016  *
00017  *  Permission is hereby granted, free of charge, to any person obtaining
00018  *  a copy of this software and associated documentation files (the
00019  *  "Software"), to deal in the Software without restriction, including
00020  *  without limitation the rights to use, copy, modify, merge, publish,
00021  *  distribute, sublicense, and/or sell copies of the Software, and to
00022  *  permit persons to whom the Software is furnished to do so, subject to
00023  *  the following conditions:
00024  *
00025  *  The above copyright notice and this permission notice shall be
00026  *  included in all copies or substantial portions of the Software.
00027  *
00028  *  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
00029  *  EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
00030  *  MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
00031  *  NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
00032  *  LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
00033  *  OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
00034  *  WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
00035  *
00036  */
00037 
00038 #include <gecode/driver.hh>
00039 #include <gecode/int.hh>
00040 #include <gecode/minimodel.hh>
00041 
00042 using namespace Gecode;
00043 
00044 namespace {
00046   extern const int *specs[];
00048   extern const unsigned int n_examples;
00049 }
00050 
00061 class MagicSquare : public Script {
00062 private:
00064   const int* spec;
00066   const int n_filled;
00068   const int n;
00070   IntVarArray x;
00071 
00072 public:
00074   enum {
00075     BRANCH_SIZE,    
00076     BRANCH_AFC_SIZE, 
00077     BRANCH_CBS_MAX_SD 
00078   };
00080   MagicSquare(const SizeOptions& opt)
00081     : Script(opt), spec(specs[opt.size()]),
00082       n_filled(spec[1]), n(spec[0]), x(*this,n*n,1,n*n) {
00083     // Number of fields on square
00084     const int nn = n*n;
00085 
00086     // Sum of all a row, column, or diagonal
00087     const int s  = nn*(nn+1) / (2*n);
00088 
00089     // Matrix-wrapper for the square
00090     Matrix<IntVarArray> m(x, n, n);
00091 
00092     for (int i=0; i<n_filled; i++) {
00093       int row, col, num;
00094       {
00095         int idx = 3 * i + 2;
00096         row = spec[idx] - 1;
00097         col = spec[idx + 1] - 1;
00098         num = spec[idx + 2];
00099       }
00100       rel(*this, m(col,row), IRT_EQ, num);
00101     }
00102 
00103     for (int i = n; i--; ) {
00104       linear(*this, m.row(i), IRT_EQ, s, opt.ipl());
00105       linear(*this, m.col(i), IRT_EQ, s, opt.ipl());
00106     }
00107     // Both diagonals must have sum s
00108     {
00109       IntVarArgs d1y(n);
00110       IntVarArgs d2y(n);
00111       for (int i = n; i--; ) {
00112         d1y[i] = m(i,i);
00113         d2y[i] = m(n-i-1,i);
00114       }
00115       linear(*this, d1y, IRT_EQ, s, opt.ipl());
00116       linear(*this, d2y, IRT_EQ, s, opt.ipl());
00117     }
00118 
00119     // All fields must be distinct
00120     distinct(*this, x, opt.ipl());
00121 
00122     switch (opt.branching()) {
00123     case BRANCH_CBS_MAX_SD:
00124 #ifdef GECODE_HAS_CBS
00125       cbsbranch(*this, x);
00126 #endif
00127     case BRANCH_SIZE:
00128       branch(*this, x, INT_VAR_SIZE_MIN(), INT_VAL_SPLIT_MIN());
00129       break;
00130     case BRANCH_AFC_SIZE:
00131       branch(*this, x, INT_VAR_AFC_SIZE_MAX(opt.decay()), INT_VAL_SPLIT_MIN());
00132       break;
00133     }
00134   }
00135 
00137   MagicSquare(MagicSquare& s)
00138     : Script(s), spec(s.spec), n_filled(s.n_filled), n(s.n) {
00139     x.update(*this, s.x);
00140   }
00141 
00143   virtual Space*
00144   copy(void) {
00145     return new MagicSquare(*this);
00146   }
00148   virtual void
00149   print(std::ostream& os) const {
00150     // Matrix-wrapper for the square
00151     Matrix<IntVarArray> m(x, n, n);
00152     for (int i = 0; i<n; i++) {
00153       os << "\t";
00154       for (int j = 0; j<n; j++) {
00155         os.width(2);
00156         os << m(i,j) << "  ";
00157       }
00158       os << std::endl;
00159     }
00160   }
00161 
00162 };
00163 
00167 int
00168 main(int argc, char* argv[]) {
00169   SizeOptions opt("MagicSquare");
00170   opt.iterations(1);
00171   opt.size(0);
00172   opt.branching(MagicSquare::BRANCH_SIZE);
00173   opt.branching(MagicSquare::BRANCH_SIZE, "size");
00174   opt.branching(MagicSquare::BRANCH_AFC_SIZE, "afc-size");
00175 #ifdef GECODE_HAS_CBS
00176   opt.branching(MagicSquare::BRANCH_CBS_MAX_SD, "maxSD");
00177 #endif
00178   opt.parse(argc,argv);
00179   Script::run<MagicSquare,DFS,SizeOptions>(opt);
00180   return 0;
00181 }
00182 
00183 namespace {
00184 
00196   const int magicSquare5_filled10_10[] = {
00197     5,10,
00198     1,2,18,
00199     1,3,9,
00200     1,5,2,
00201     2,2,5,
00202     3,1,1,
00203     3,5,24,
00204     4,2,21,
00205     4,3,6,
00206     5,2,13,
00207     5,4,10,
00208   };
00209 
00210   const int magicSquare5_filled10_11[] = {
00211     5,10,
00212     1,3,6,
00213     1,5,2,
00214     2,2,8,
00215     2,5,25,
00216     3,1,1,
00217     3,4,17,
00218     3,5,24,
00219     4,1,9,
00220     4,2,21,
00221     5,3,16,
00222   };
00223 
00224   const int magicSquare5_filled10_12[] = {
00225     5,10,
00226     1,2,5,
00227     1,4,21,
00228     2,1,10,
00229     2,2,16,
00230     2,3,8,
00231     3,4,12,
00232     4,2,20,
00233     4,5,11,
00234     5,1,18,
00235     5,5,3,
00236   };
00237 
00238   const int magicSquare5_filled10_13[] = {
00239     5,10,
00240     1,5,2,
00241     1,2,16,
00242     2,3,8,
00243     3,3,21,
00244     3,1,1,
00245     4,1,12,
00246     5,2,6,
00247     5,1,20,
00248     5,3,14,
00249     5,5,3,
00250   };
00251 
00252   const int magicSquare5_filled10_14[] = {
00253     5,10,
00254     1,3,14,
00255     1,2,7,
00256     2,3,12,
00257     2,4,4,
00258     3,3,21,
00259     3,5,24,
00260     4,5,11,
00261     4,4,6,
00262     4,3,13,
00263     5,4,22,
00264   };
00265 
00266   const int magicSquare5_filled10_15[] = {
00267     5,10,
00268     1,5,2,
00269     1,1,21,
00270     2,1,15,
00271     2,2,5,
00272     4,2,18,
00273     4,5,11,
00274     5,4,20,
00275     5,5,3,
00276     5,2,12,
00277     5,3,8,
00278   };
00279 
00280   const int magicSquare5_filled10_16[] = {
00281     5,10,
00282     1,1,22,
00283     1,5,2,
00284     1,4,18,
00285     2,5,25,
00286     2,4,7,
00287     3,4,15,
00288     3,1,1,
00289     3,2,9,
00290     4,4,4,
00291     5,1,23,
00292   };
00293 
00294   const int magicSquare5_filled10_17[] = {
00295     5,10,
00296     1,2,5,
00297     2,4,4,
00298     2,5,25,
00299     3,4,16,
00300     3,5,24,
00301     3,3,14,
00302     3,1,1,
00303     4,2,22,
00304     5,3,13,
00305     5,4,7,
00306   };
00307 
00308   const int magicSquare5_filled10_18[] = {
00309     5,10,
00310     1,3,7,
00311     1,4,22,
00312     2,5,25,
00313     2,4,4,
00314     2,1,10,
00315     3,1,1,
00316     4,4,6,
00317     4,3,20,
00318     5,3,8,
00319     5,2,12,
00320   };
00321 
00322   const int magicSquare5_filled10_19[] = {
00323     5,10,
00324     1,2,6,
00325     1,5,2,
00326     2,2,18,
00327     2,1,13,
00328     3,5,24,
00329     3,3,17,
00330     5,2,7,
00331     5,1,22,
00332     5,4,21,
00333     5,3,12,
00334   };
00335 
00336   const int magicSquare5_filled10_1[] = {
00337     5,10,
00338     1,4,16,
00339     1,5,2,
00340     1,3,20,
00341     2,5,25,
00342     2,4,4,
00343     3,5,24,
00344     3,1,1,
00345     4,4,9,
00346     5,2,12,
00347     5,1,23,
00348   };
00349 
00350   const int magicSquare5_filled10_20[] = {
00351     5,10,
00352     1,1,22,
00353     2,5,25,
00354     2,2,5,
00355     3,5,24,
00356     3,1,1,
00357     4,4,19,
00358     4,5,11,
00359     5,1,23,
00360     5,2,8,
00361     5,3,10,
00362   };
00363 
00364   const int magicSquare5_filled10_2[] = {
00365     5,10,
00366     1,2,19,
00367     1,4,9,
00368     2,5,25,
00369     2,1,15,
00370     3,2,6,
00371     4,2,20,
00372     4,1,5,
00373     5,5,3,
00374     5,3,10,
00375     5,1,23,
00376   };
00377 
00378   const int magicSquare5_filled10_3[] = {
00379     5,10,
00380     1,1,15,
00381     1,5,2,
00382     2,1,20,
00383     2,3,7,
00384     3,4,5,
00385     4,1,6,
00386     4,4,16,
00387     5,1,23,
00388     5,2,12,
00389     5,3,8,
00390   };
00391 
00392   const int magicSquare5_filled10_4[] = {
00393     5,10,
00394     1,2,15,
00395     1,5,2,
00396     1,1,22,
00397     1,4,16,
00398     2,5,25,
00399     3,5,24,
00400     3,1,1,
00401     4,1,23,
00402     4,2,18,
00403     4,3,9,
00404   };
00405 
00406   const int magicSquare5_filled10_5[] = {
00407     5,10,
00408     1,1,14,
00409     1,4,21,
00410     2,2,12,
00411     2,5,25,
00412     3,2,5,
00413     3,3,19,
00414     3,5,24,
00415     4,2,18,
00416     5,1,22,
00417     5,2,10,
00418   };
00419 
00420   const int magicSquare5_filled10_6[] = {
00421     5,10,
00422     1,1,19,
00423     1,2,20,
00424     2,1,7,
00425     3,3,23,
00426     4,5,11,
00427     4,4,4,
00428     5,3,13,
00429     5,5,3,
00430     5,4,22,
00431     5,2,10,
00432   };
00433 
00434   const int magicSquare5_filled10_7[] = {
00435     5,10,
00436     1,2,10,
00437     2,4,4,
00438     3,5,24,
00439     3,4,17,
00440     4,5,11,
00441     4,2,23,
00442     4,4,5,
00443     4,1,14,
00444     5,2,6,
00445     5,5,3,
00446   };
00447 
00448   const int magicSquare5_filled10_8[] = {
00449     5,10,
00450     1,1,22,
00451     1,3,5,
00452     2,5,25,
00453     2,4,4,
00454     3,5,24,
00455     3,2,8,
00456     4,1,10,
00457     4,2,21,
00458     4,3,16,
00459     4,5,11,
00460   };
00461 
00462   const int magicSquare5_filled10_9[] = {
00463     5,10,
00464     1,5,2,
00465     2,2,10,
00466     2,5,25,
00467     3,3,23,
00468     3,1,1,
00469     4,2,15,
00470     4,4,13,
00471     4,3,6,
00472     5,5,3,
00473     5,3,5,
00474   };
00475 
00476   const int magicSquare5_filled11_3_1[] = {
00477     5,11,
00478     1,1,15,
00479     1,5,2,
00480     2,1,20,
00481     2,3,7,
00482     3,2,13,
00483     3,4,5,
00484     4,1,6,
00485     4,4,16,
00486     5,1,23,
00487     5,2,12,
00488     5,3,8,
00489   };
00490 
00491   const int magicSquare5_filled11_5_1[] = {
00492     5,11,
00493     1,1,14,
00494     1,4,21,
00495     2,2,12,
00496     2,5,25,
00497     3,2,5,
00498     3,3,19,
00499     3,4,16,
00500     3,5,24,
00501     4,2,18,
00502     5,1,22,
00503     5,2,10,
00504   };
00505 
00506   const int magicSquare5_filled11_5_2[] = {
00507     5,11,
00508     1,1,14,
00509     1,4,21,
00510     2,2,12,
00511     2,5,25,
00512     3,2,5,
00513     3,3,19,
00514     3,5,24,
00515     4,2,18,
00516     5,1,22,
00517     5,2,10,
00518     5,5,3,
00519   };
00520 
00521   const int magicSquare5_filled11_5_3[] = {
00522     5,11,
00523     1,1,14,
00524     1,3,8,
00525     1,4,21,
00526     2,2,12,
00527     2,5,25,
00528     3,2,5,
00529     3,3,19,
00530     3,5,24,
00531     4,2,18,
00532     5,1,22,
00533     5,2,10,
00534   };
00535 
00536   const int magicSquare5_filled12_10_1[] = {
00537     5,12,
00538     1,2,18,
00539     1,3,9,
00540     1,5,2,
00541     2,2,5,
00542     3,1,1,
00543     3,3,15,
00544     3,5,24,
00545     4,1,7,
00546     4,2,21,
00547     4,3,6,
00548     5,2,13,
00549     5,4,10,
00550   };
00551 
00552   const int magicSquare5_filled12_1_1[] = {
00553     5,12,
00554     1,1,21,
00555     1,3,20,
00556     1,4,16,
00557     1,5,2,
00558     2,5,25,
00559     2,4,4,
00560     3,1,1,
00561     3,3,14,
00562     3,5,24,
00563     4,4,9,
00564     5,2,12,
00565     5,1,23,
00566   };
00567 
00568   const int magicSquare5_filled12_1_2[] = {
00569     5,12,
00570     1,3,20,
00571     1,4,16,
00572     1,5,2,
00573     2,2,18,
00574     2,4,4,
00575     2,5,25,
00576     3,1,1,
00577     3,3,14,
00578     3,5,24,
00579     4,4,9,
00580     5,2,12,
00581     5,1,23,
00582   };
00583 
00584   const int magicSquare5_filled12_1_3[] = {
00585     5,12,
00586     1,3,20,
00587     1,4,16,
00588     1,5,2,
00589     2,2,18,
00590     2,4,4,
00591     2,5,25,
00592     3,1,1,
00593     3,5,24,
00594     4,4,9,
00595     5,1,23,
00596     5,2,12,
00597     5,3,10,
00598   };
00599 
00600   const int magicSquare5_filled12_2_1[] = {
00601     5,12,
00602     1,1,21,
00603     1,2,19,
00604     1,4,9,
00605     2,1,15,
00606     2,5,25,
00607     3,2,6,
00608     3,4,18,
00609     4,1,5,
00610     4,2,20,
00611     5,1,23,
00612     5,3,10,
00613     5,5,3,
00614   };
00615 
00616   const int magicSquare5_filled12_2_2[] = {
00617     5,12,
00618     1,2,19,
00619     1,4,9,
00620     2,1,15,
00621     2,3,8,
00622     2,5,25,
00623     3,2,6,
00624     3,4,18,
00625     4,1,5,
00626     4,2,20,
00627     5,1,23,
00628     5,3,10,
00629     5,5,3,
00630   };
00631 
00632   const int magicSquare5_filled12_2_3[] = {
00633     5,12,
00634     1,1,21,
00635     1,2,19,
00636     1,4,9,
00637     2,1,15,
00638     2,5,25,
00639     3,2,6,
00640     4,1,5,
00641     4,2,20,
00642     4,4,12,
00643     5,1,23,
00644     5,3,10,
00645     5,5,3,
00646   };
00647 
00648   const int magicSquare5_filled12_3_1[] = {
00649     5,12,
00650     1,1,15,
00651     1,4,21,
00652     1,5,2,
00653     2,1,20,
00654     2,3,7,
00655     3,4,5,
00656     4,1,6,
00657     4,4,16,
00658     5,1,23,
00659     5,2,12,
00660     5,3,8,
00661     5,5,3,
00662   };
00663 
00664   const int magicSquare5_filled12_3_2[] = {
00665     5,12,
00666     1,1,15,
00667     1,2,17,
00668     1,3,10,
00669     1,5,2,
00670     2,1,20,
00671     2,3,7,
00672     3,4,5,
00673     4,1,6,
00674     4,4,16,
00675     5,1,23,
00676     5,2,12,
00677     5,3,8,
00678   };
00679 
00680   const int magicSquare9_filled10_10[] = {
00681     9,10,
00682     8,2,19,
00683     6,7,25,
00684     7,3,15,
00685     8,4,77,
00686     7,1,29,
00687     4,9,63,
00688     4,6,53,
00689     7,1,29,
00690     3,9,36,
00691     5,4,74,
00692   };
00693 
00694   const int magicSquare9_filled10_11[] = {
00695     9,10,
00696     5,5,78,
00697     6,5,56,
00698     9,8,30,
00699     3,3,38,
00700     2,3,9,
00701     1,2,23,
00702     3,5,80,
00703     9,7,52,
00704     7,5,1,
00705     1,1,32,
00706   };
00707 
00708   const int magicSquare9_filled10_12[] = {
00709     9,10,
00710     6,7,25,
00711     1,4,2,
00712     5,1,54,
00713     3,3,38,
00714     7,2,71,
00715     1,5,28,
00716     3,2,50,
00717     2,7,59,
00718     7,7,42,
00719     5,4,74,
00720   };
00721 
00722   const int magicSquare9_filled10_13[] = {
00723     9,10,
00724     7,2,71,
00725     8,9,22,
00726     2,2,17,
00727     3,3,38,
00728     1,8,72,
00729     6,5,56,
00730     5,6,41,
00731     9,1,8,
00732     7,8,37,
00733     3,3,38,
00734   };
00735 
00736   const int magicSquare9_filled10_14[] = {
00737     9,10,
00738     9,4,35,
00739     1,3,48,
00740     9,6,69,
00741     7,6,70,
00742     6,1,46,
00743     5,1,54,
00744     4,2,62,
00745     2,8,67,
00746     7,6,70,
00747     7,3,15,
00748   };
00749 
00750   const int magicSquare9_filled10_15[] = {
00751     9,10,
00752     9,8,30,
00753     1,6,4,
00754     9,9,45,
00755     9,2,49,
00756     5,6,41,
00757     6,5,56,
00758     5,9,7,
00759     2,6,3,
00760     3,2,50,
00761     1,2,23,
00762   };
00763 
00764   const int magicSquare9_filled10_16[] = {
00765     9,10,
00766     1,9,81,
00767     3,8,18,
00768     8,4,77,
00769     6,5,56,
00770     7,9,31,
00771     1,9,81,
00772     7,3,15,
00773     6,4,5,
00774     6,8,61,
00775     4,6,53,
00776   };
00777 
00778   const int magicSquare9_filled10_17[] = {
00779     9,10,
00780     4,4,12,
00781     9,5,26,
00782     7,6,70,
00783     8,2,19,
00784     7,2,71,
00785     8,1,68,
00786     8,2,19,
00787     5,5,78,
00788     6,3,21,
00789     5,3,75,
00790   };
00791 
00792   const int magicSquare9_filled10_18[] = {
00793     9,10,
00794     7,2,71,
00795     4,1,47,
00796     6,9,24,
00797     8,8,39,
00798     3,9,36,
00799     2,9,60,
00800     4,3,64,
00801     5,8,11,
00802     4,2,62,
00803     3,7,43,
00804   };
00805 
00806   const int magicSquare9_filled10_19[] = {
00807     9,10,
00808     7,4,73,
00809     8,3,44,
00810     8,1,68,
00811     1,2,23,
00812     1,6,4,
00813     5,7,16,
00814     3,6,6,
00815     8,2,19,
00816     4,5,14,
00817     3,3,38,
00818   };
00819 
00820   const int magicSquare9_filled10_1[] = {
00821     9,10,
00822     4,5,14,
00823     6,7,25,
00824     8,8,39,
00825     6,7,25,
00826     3,8,18,
00827     4,4,12,
00828     8,2,19,
00829     4,1,47,
00830     4,6,53,
00831     8,5,10,
00832   };
00833 
00834   const int magicSquare9_filled10_20[] = {
00835     9,10,
00836     1,4,2,
00837     8,6,57,
00838     1,5,28,
00839     1,8,72,
00840     6,1,46,
00841     4,1,47,
00842     8,7,33,
00843     4,6,53,
00844     1,5,28,
00845     5,8,11,
00846   };
00847 
00848   const int magicSquare9_filled10_2[] = {
00849     9,10,
00850     2,5,76,
00851     9,1,8,
00852     2,4,51,
00853     1,2,23,
00854     9,7,52,
00855     1,8,72,
00856     3,3,38,
00857     6,6,66,
00858     3,7,43,
00859     7,6,70,
00860   };
00861 
00862   const int magicSquare9_filled10_3[] = {
00863     9,10,
00864     5,6,41,
00865     5,3,75,
00866     6,1,46,
00867     3,2,50,
00868     3,8,18,
00869     1,5,28,
00870     3,2,50,
00871     5,9,7,
00872     4,8,34,
00873     1,4,2,
00874   };
00875 
00876   const int magicSquare9_filled10_4[] = {
00877     9,10,
00878     4,9,63,
00879     9,4,35,
00880     7,5,1,
00881     2,6,3,
00882     8,4,77,
00883     7,6,70,
00884     5,8,11,
00885     2,5,76,
00886     9,4,35,
00887     3,6,6,
00888   };
00889 
00890   const int magicSquare9_filled10_5[] = {
00891     9,10,
00892     2,5,76,
00893     1,4,2,
00894     9,3,55,
00895     1,2,23,
00896     3,3,38,
00897     2,5,76,
00898     3,4,40,
00899     3,4,40,
00900     1,2,23,
00901     3,6,6,
00902   };
00903 
00904   const int magicSquare9_filled10_6[] = {
00905     9,10,
00906     7,5,1,
00907     4,7,20,
00908     8,7,33,
00909     5,5,78,
00910     5,2,13,
00911     3,1,58,
00912     1,9,81,
00913     5,1,54,
00914     3,1,58,
00915     7,5,1,
00916   };
00917 
00918   const int magicSquare9_filled10_7[] = {
00919     9,10,
00920     7,5,1,
00921     7,5,1,
00922     1,5,28,
00923     4,8,34,
00924     4,1,47,
00925     4,2,62,
00926     2,6,3,
00927     2,8,67,
00928     1,9,81,
00929     5,4,74,
00930   };
00931 
00932   const int magicSquare9_filled10_8[] = {
00933     9,10,
00934     9,4,35,
00935     4,9,63,
00936     1,6,4,
00937     5,5,78,
00938     7,5,1,
00939     9,4,35,
00940     5,6,41,
00941     6,3,21,
00942     9,3,55,
00943     3,5,80,
00944   };
00945 
00946   const int magicSquare9_filled10_9[] = {
00947     9,10,
00948     4,8,34,
00949     4,1,47,
00950     3,9,36,
00951     8,6,57,
00952     9,2,49,
00953     9,9,45,
00954     1,6,4,
00955     4,6,53,
00956     3,6,6,
00957     2,2,17,
00958   };
00959 
00960   const int magicSquare9_filled50_10[] = {
00961     9,50,
00962     4,3,64,
00963     3,9,36,
00964     8,3,44,
00965     6,9,24,
00966     2,7,59,
00967     7,2,71,
00968     8,2,19,
00969     2,8,67,
00970     6,7,25,
00971     6,6,66,
00972     3,8,18,
00973     1,9,81,
00974     8,4,77,
00975     5,4,74,
00976     8,2,19,
00977     6,9,24,
00978     4,9,63,
00979     9,3,55,
00980     2,5,76,
00981     9,2,49,
00982     3,7,43,
00983     3,8,18,
00984     6,3,21,
00985     6,2,65,
00986     9,2,49,
00987     7,9,31,
00988     8,6,57,
00989     8,6,57,
00990     9,3,55,
00991     7,5,1,
00992     2,4,51,
00993     5,4,74,
00994     3,4,40,
00995     4,2,62,
00996     6,3,21,
00997     3,6,6,
00998     7,4,73,
00999     5,4,74,
01000     4,8,34,
01001     3,3,38,
01002     8,1,68,
01003     3,4,40,
01004     6,8,61,
01005     7,3,15,
01006     9,5,26,
01007     7,1,29,
01008     6,9,24,
01009     2,6,3,
01010     3,5,80,
01011     7,9,31,
01012   };
01013 
01014   const int magicSquare9_filled50_11[] = {
01015     9,50,
01016     6,8,61,
01017     3,3,38,
01018     9,7,52,
01019     6,3,21,
01020     4,9,63,
01021     3,9,36,
01022     7,3,15,
01023     1,1,32,
01024     2,7,59,
01025     1,8,72,
01026     2,5,76,
01027     8,7,33,
01028     5,1,54,
01029     3,5,80,
01030     3,8,18,
01031     4,8,34,
01032     4,5,14,
01033     2,3,9,
01034     9,5,26,
01035     3,3,38,
01036     2,5,76,
01037     9,8,30,
01038     8,9,22,
01039     6,7,25,
01040     7,6,70,
01041     5,6,41,
01042     2,1,27,
01043     4,4,12,
01044     8,4,77,
01045     8,2,19,
01046     9,1,8,
01047     7,3,15,
01048     5,6,41,
01049     3,4,40,
01050     2,5,76,
01051     5,1,54,
01052     8,4,77,
01053     7,4,73,
01054     2,3,9,
01055     1,8,72,
01056     7,3,15,
01057     4,6,53,
01058     3,5,80,
01059     9,2,49,
01060     7,7,42,
01061     1,6,4,
01062     7,7,42,
01063     7,2,71,
01064     4,7,20,
01065     4,3,64,
01066   };
01067 
01068   const int magicSquare9_filled50_12[] = {
01069     9,50,
01070     1,3,48,
01071     3,5,80,
01072     4,5,14,
01073     6,1,46,
01074     8,8,39,
01075     2,8,67,
01076     8,8,39,
01077     9,2,49,
01078     2,2,17,
01079     6,1,46,
01080     9,9,45,
01081     8,9,22,
01082     3,4,40,
01083     2,3,9,
01084     4,6,53,
01085     5,3,75,
01086     6,6,66,
01087     7,1,29,
01088     8,1,68,
01089     1,7,79,
01090     7,9,31,
01091     5,3,75,
01092     6,4,5,
01093     5,7,16,
01094     3,1,58,
01095     5,3,75,
01096     7,4,73,
01097     9,8,30,
01098     5,8,11,
01099     1,7,79,
01100     4,4,12,
01101     9,8,30,
01102     7,4,73,
01103     6,5,56,
01104     4,4,12,
01105     2,8,67,
01106     1,4,2,
01107     2,6,3,
01108     6,4,5,
01109     1,8,72,
01110     2,6,3,
01111     8,9,22,
01112     7,7,42,
01113     5,9,7,
01114     5,5,78,
01115     6,7,25,
01116     6,5,56,
01117     3,3,38,
01118     8,8,39,
01119     8,1,68,
01120   };
01121 
01122   const int magicSquare9_filled50_13[] = {
01123     9,50,
01124     2,7,59,
01125     6,2,65,
01126     9,5,26,
01127     6,5,56,
01128     8,6,57,
01129     1,1,32,
01130     9,9,45,
01131     7,6,70,
01132     4,2,62,
01133     4,9,63,
01134     4,9,63,
01135     4,8,34,
01136     3,6,6,
01137     1,1,32,
01138     2,6,3,
01139     8,3,44,
01140     2,3,9,
01141     2,1,27,
01142     7,7,42,
01143     3,6,6,
01144     2,3,9,
01145     4,1,47,
01146     2,1,27,
01147     5,4,74,
01148     9,8,30,
01149     3,1,58,
01150     7,4,73,
01151     6,9,24,
01152     7,5,1,
01153     8,8,39,
01154     1,4,2,
01155     1,9,81,
01156     6,9,24,
01157     7,2,71,
01158     5,9,7,
01159     5,6,41,
01160     1,8,72,
01161     4,2,62,
01162     6,8,61,
01163     3,3,38,
01164     6,5,56,
01165     1,2,23,
01166     6,7,25,
01167     8,3,44,
01168     2,4,51,
01169     1,9,81,
01170     8,8,39,
01171     9,2,49,
01172     6,6,66,
01173     3,1,58,
01174   };
01175 
01176   const int magicSquare9_filled50_14[] = {
01177     9,50,
01178     1,4,2,
01179     6,7,25,
01180     3,2,50,
01181     6,6,66,
01182     2,8,67,
01183     5,1,54,
01184     2,6,3,
01185     7,7,42,
01186     6,2,65,
01187     2,8,67,
01188     8,3,44,
01189     2,9,60,
01190     4,5,14,
01191     9,5,26,
01192     4,1,47,
01193     5,2,13,
01194     4,9,63,
01195     6,5,56,
01196     1,9,81,
01197     1,2,23,
01198     8,4,77,
01199     1,9,81,
01200     9,7,52,
01201     5,3,75,
01202     8,6,57,
01203     1,7,79,
01204     8,9,22,
01205     4,9,63,
01206     5,1,54,
01207     3,6,6,
01208     1,7,79,
01209     5,3,75,
01210     6,2,65,
01211     5,6,41,
01212     1,3,48,
01213     6,8,61,
01214     6,6,66,
01215     6,3,21,
01216     3,1,58,
01217     6,8,61,
01218     6,4,5,
01219     5,4,74,
01220     4,7,20,
01221     1,6,4,
01222     7,3,15,
01223     2,6,3,
01224     1,6,4,
01225     6,4,5,
01226     5,1,54,
01227     8,4,77,
01228   };
01229 
01230   const int magicSquare9_filled50_15[] = {
01231     9,50,
01232     1,4,2,
01233     2,7,59,
01234     7,5,1,
01235     7,7,42,
01236     5,3,75,
01237     5,1,54,
01238     7,8,37,
01239     2,8,67,
01240     3,3,38,
01241     4,9,63,
01242     3,3,38,
01243     3,1,58,
01244     6,8,61,
01245     5,2,13,
01246     6,1,46,
01247     5,5,78,
01248     4,4,12,
01249     2,8,67,
01250     9,8,30,
01251     5,2,13,
01252     9,7,52,
01253     3,4,40,
01254     5,2,13,
01255     9,7,52,
01256     2,3,9,
01257     5,5,78,
01258     3,5,80,
01259     5,8,11,
01260     2,7,59,
01261     9,7,52,
01262     7,2,71,
01263     9,8,30,
01264     4,1,47,
01265     6,1,46,
01266     7,8,37,
01267     2,4,51,
01268     6,2,65,
01269     5,8,11,
01270     2,4,51,
01271     6,3,21,
01272     6,8,61,
01273     5,8,11,
01274     3,8,18,
01275     4,4,12,
01276     5,4,74,
01277     9,1,8,
01278     3,8,18,
01279     8,4,77,
01280     7,3,15,
01281     4,2,62,
01282   };
01283 
01284   const int magicSquare9_filled50_16[] = {
01285     9,50,
01286     1,4,2,
01287     3,6,6,
01288     3,7,43,
01289     5,4,74,
01290     1,8,72,
01291     5,6,41,
01292     4,7,20,
01293     2,6,3,
01294     3,5,80,
01295     8,8,39,
01296     6,5,56,
01297     6,7,25,
01298     3,4,40,
01299     1,7,79,
01300     4,3,64,
01301     8,5,10,
01302     4,8,34,
01303     8,6,57,
01304     5,3,75,
01305     8,5,10,
01306     8,1,68,
01307     8,2,19,
01308     5,9,7,
01309     8,8,39,
01310     3,4,40,
01311     4,6,53,
01312     8,9,22,
01313     3,8,18,
01314     1,2,23,
01315     6,5,56,
01316     4,2,62,
01317     9,7,52,
01318     1,7,79,
01319     1,5,28,
01320     8,8,39,
01321     1,6,4,
01322     6,8,61,
01323     8,2,19,
01324     6,4,5,
01325     9,6,69,
01326     5,3,75,
01327     2,3,9,
01328     2,3,9,
01329     1,9,81,
01330     4,4,12,
01331     4,5,14,
01332     6,3,21,
01333     2,4,51,
01334     8,9,22,
01335     8,6,57,
01336   };
01337 
01338   const int magicSquare9_filled50_17[] = {
01339     9,50,
01340     8,6,57,
01341     9,2,49,
01342     3,5,80,
01343     3,6,6,
01344     8,2,19,
01345     9,1,8,
01346     2,1,27,
01347     3,1,58,
01348     1,2,23,
01349     1,2,23,
01350     5,2,13,
01351     6,8,61,
01352     5,5,78,
01353     2,1,27,
01354     5,8,11,
01355     4,1,47,
01356     4,3,64,
01357     2,4,51,
01358     8,3,44,
01359     9,4,35,
01360     2,8,67,
01361     5,4,74,
01362     7,5,1,
01363     2,7,59,
01364     6,2,65,
01365     9,9,45,
01366     4,3,64,
01367     7,6,70,
01368     8,9,22,
01369     4,3,64,
01370     7,7,42,
01371     1,1,32,
01372     7,2,71,
01373     3,3,38,
01374     2,2,17,
01375     5,4,74,
01376     8,7,33,
01377     7,3,15,
01378     2,8,67,
01379     7,6,70,
01380     8,4,77,
01381     5,9,7,
01382     7,2,71,
01383     3,3,38,
01384     1,6,4,
01385     5,5,78,
01386     1,3,48,
01387     4,7,20,
01388     2,6,3,
01389     8,4,77,
01390   };
01391 
01392   const int magicSquare9_filled50_18[] = {
01393     9,50,
01394     5,3,75,
01395     7,1,29,
01396     9,4,35,
01397     3,8,18,
01398     9,1,8,
01399     4,5,14,
01400     2,6,3,
01401     2,8,67,
01402     8,4,77,
01403     1,6,4,
01404     7,3,15,
01405     2,5,76,
01406     5,5,78,
01407     3,7,43,
01408     1,8,72,
01409     8,5,10,
01410     1,5,28,
01411     6,7,25,
01412     6,6,66,
01413     5,3,75,
01414     6,7,25,
01415     8,8,39,
01416     3,9,36,
01417     4,1,47,
01418     2,3,9,
01419     7,8,37,
01420     5,6,41,
01421     4,8,34,
01422     1,4,2,
01423     3,8,18,
01424     9,1,8,
01425     3,9,36,
01426     5,6,41,
01427     6,8,61,
01428     3,8,18,
01429     1,6,4,
01430     5,8,11,
01431     2,8,67,
01432     6,4,5,
01433     6,5,56,
01434     6,1,46,
01435     1,8,72,
01436     6,2,65,
01437     6,6,66,
01438     5,6,41,
01439     4,2,62,
01440     6,5,56,
01441     1,8,72,
01442     8,4,77,
01443     4,8,34,
01444   };
01445 
01446   const int magicSquare9_filled50_19[] = {
01447     9,50,
01448     1,5,28,
01449     3,5,80,
01450     1,2,23,
01451     1,4,2,
01452     5,7,16,
01453     8,8,39,
01454     5,9,7,
01455     7,2,71,
01456     1,1,32,
01457     5,4,74,
01458     7,9,31,
01459     5,1,54,
01460     2,4,51,
01461     7,9,31,
01462     7,1,29,
01463     6,5,56,
01464     3,8,18,
01465     1,4,2,
01466     9,8,30,
01467     7,3,15,
01468     3,4,40,
01469     1,8,72,
01470     3,5,80,
01471     9,3,55,
01472     6,4,5,
01473     6,1,46,
01474     1,9,81,
01475     1,2,23,
01476     3,5,80,
01477     9,7,52,
01478     4,5,14,
01479     3,6,6,
01480     1,1,32,
01481     7,9,31,
01482     8,3,44,
01483     2,2,17,
01484     6,1,46,
01485     9,6,69,
01486     5,6,41,
01487     8,1,68,
01488     7,3,15,
01489     1,8,72,
01490     9,9,45,
01491     7,2,71,
01492     2,4,51,
01493     8,5,10,
01494     6,1,46,
01495     2,6,3,
01496     1,6,4,
01497     4,7,20,
01498   };
01499 
01500   const int magicSquare9_filled50_1[] = {
01501     9,50,
01502     7,1,29,
01503     2,9,60,
01504     2,4,51,
01505     1,8,72,
01506     8,5,10,
01507     4,6,53,
01508     3,4,40,
01509     6,2,65,
01510     8,2,19,
01511     3,6,6,
01512     6,2,65,
01513     2,8,67,
01514     2,5,76,
01515     8,9,22,
01516     6,2,65,
01517     6,1,46,
01518     2,8,67,
01519     1,4,2,
01520     9,8,30,
01521     2,5,76,
01522     3,3,38,
01523     1,3,48,
01524     4,6,53,
01525     5,1,54,
01526     7,5,1,
01527     6,1,46,
01528     4,6,53,
01529     6,5,56,
01530     1,5,28,
01531     3,6,6,
01532     4,8,34,
01533     7,6,70,
01534     4,5,14,
01535     7,3,15,
01536     1,6,4,
01537     8,2,19,
01538     7,6,70,
01539     4,8,34,
01540     3,8,18,
01541     8,7,33,
01542     1,5,28,
01543     6,5,56,
01544     8,2,19,
01545     9,8,30,
01546     4,2,62,
01547     3,8,18,
01548     8,7,33,
01549     4,2,62,
01550     9,8,30,
01551     5,9,7,
01552   };
01553 
01554   const int magicSquare9_filled50_20[] = {
01555     9,50,
01556     8,3,44,
01557     8,2,19,
01558     3,5,80,
01559     7,8,37,
01560     8,4,77,
01561     6,5,56,
01562     4,5,14,
01563     1,3,48,
01564     2,6,3,
01565     4,3,64,
01566     9,9,45,
01567     6,6,66,
01568     8,5,10,
01569     2,6,3,
01570     1,5,28,
01571     3,7,43,
01572     8,8,39,
01573     8,8,39,
01574     1,4,2,
01575     4,8,34,
01576     5,8,11,
01577     2,8,67,
01578     1,2,23,
01579     1,2,23,
01580     7,2,71,
01581     2,7,59,
01582     1,7,79,
01583     1,6,4,
01584     2,9,60,
01585     3,1,58,
01586     3,3,38,
01587     7,8,37,
01588     9,3,55,
01589     6,9,24,
01590     4,1,47,
01591     8,8,39,
01592     6,9,24,
01593     6,6,66,
01594     8,4,77,
01595     5,6,41,
01596     5,6,41,
01597     1,4,2,
01598     2,8,67,
01599     9,1,8,
01600     7,9,31,
01601     1,9,81,
01602     3,7,43,
01603     7,2,71,
01604     8,2,19,
01605     8,2,19,
01606   };
01607 
01608   const int magicSquare9_filled50_2[] = {
01609     9,50,
01610     2,1,27,
01611     8,8,39,
01612     6,3,21,
01613     7,6,70,
01614     8,5,10,
01615     2,9,60,
01616     7,7,42,
01617     4,5,14,
01618     8,1,68,
01619     2,3,9,
01620     3,2,50,
01621     8,1,68,
01622     8,9,22,
01623     9,5,26,
01624     7,2,71,
01625     2,8,67,
01626     2,1,27,
01627     5,6,41,
01628     3,2,50,
01629     9,8,30,
01630     4,1,47,
01631     7,9,31,
01632     7,1,29,
01633     4,4,12,
01634     2,3,9,
01635     4,2,62,
01636     4,9,63,
01637     9,9,45,
01638     8,8,39,
01639     2,5,76,
01640     1,4,2,
01641     1,9,81,
01642     4,5,14,
01643     3,4,40,
01644     4,3,64,
01645     2,8,67,
01646     1,9,81,
01647     7,8,37,
01648     7,8,37,
01649     9,6,69,
01650     9,1,8,
01651     5,1,54,
01652     9,2,49,
01653     1,7,79,
01654     1,9,81,
01655     9,8,30,
01656     3,7,43,
01657     5,4,74,
01658     3,8,18,
01659     7,4,73,
01660   };
01661 
01662   const int magicSquare9_filled50_3[] = {
01663     9,50,
01664     8,7,33,
01665     9,8,30,
01666     4,4,12,
01667     4,1,47,
01668     3,3,38,
01669     5,9,7,
01670     1,9,81,
01671     9,7,52,
01672     9,7,52,
01673     2,7,59,
01674     7,1,29,
01675     5,9,7,
01676     8,7,33,
01677     2,8,67,
01678     3,6,6,
01679     2,1,27,
01680     3,9,36,
01681     9,6,69,
01682     3,3,38,
01683     5,3,75,
01684     4,9,63,
01685     2,4,51,
01686     6,2,65,
01687     2,5,76,
01688     8,1,68,
01689     9,5,26,
01690     2,2,17,
01691     3,7,43,
01692     9,2,49,
01693     3,2,50,
01694     7,2,71,
01695     3,1,58,
01696     1,2,23,
01697     6,4,5,
01698     4,1,47,
01699     6,5,56,
01700     7,8,37,
01701     9,2,49,
01702     9,8,30,
01703     4,5,14,
01704     8,4,77,
01705     8,7,33,
01706     5,8,11,
01707     2,4,51,
01708     9,4,35,
01709     4,6,53,
01710     4,6,53,
01711     6,4,5,
01712     5,1,54,
01713     7,6,70,
01714   };
01715 
01716   const int magicSquare9_filled50_4[] = {
01717     9,50,
01718     8,2,19,
01719     2,6,3,
01720     9,8,30,
01721     5,6,41,
01722     4,8,34,
01723     8,9,22,
01724     9,6,69,
01725     5,5,78,
01726     4,6,53,
01727     6,3,21,
01728     8,7,33,
01729     7,2,71,
01730     1,3,48,
01731     3,5,80,
01732     1,8,72,
01733     9,9,45,
01734     9,8,30,
01735     3,6,6,
01736     6,7,25,
01737     9,7,52,
01738     3,5,80,
01739     6,3,21,
01740     2,1,27,
01741     5,3,75,
01742     5,8,11,
01743     4,1,47,
01744     6,1,46,
01745     9,6,69,
01746     1,2,23,
01747     9,2,49,
01748     7,8,37,
01749     1,4,2,
01750     4,3,64,
01751     7,7,42,
01752     7,6,70,
01753     4,9,63,
01754     2,9,60,
01755     9,1,8,
01756     8,4,77,
01757     1,1,32,
01758     3,4,40,
01759     1,6,4,
01760     2,9,60,
01761     2,3,9,
01762     8,8,39,
01763     2,4,51,
01764     4,2,62,
01765     7,7,42,
01766     2,5,76,
01767     4,8,34,
01768   };
01769 
01770   const int magicSquare9_filled50_5[] = {
01771     9,50,
01772     8,7,33,
01773     7,7,42,
01774     5,7,16,
01775     5,1,54,
01776     8,6,57,
01777     1,1,32,
01778     9,8,30,
01779     4,2,62,
01780     5,6,41,
01781     2,1,27,
01782     2,3,9,
01783     4,6,53,
01784     2,9,60,
01785     3,3,38,
01786     4,5,14,
01787     1,9,81,
01788     9,5,26,
01789     7,2,71,
01790     9,2,49,
01791     2,8,67,
01792     7,9,31,
01793     6,5,56,
01794     5,1,54,
01795     4,7,20,
01796     4,5,14,
01797     8,5,10,
01798     5,9,7,
01799     1,6,4,
01800     8,2,19,
01801     8,9,22,
01802     6,6,66,
01803     9,3,55,
01804     1,6,4,
01805     5,1,54,
01806     5,6,41,
01807     8,3,44,
01808     4,2,62,
01809     7,8,37,
01810     2,8,67,
01811     4,5,14,
01812     3,2,50,
01813     1,7,79,
01814     1,8,72,
01815     3,7,43,
01816     9,8,30,
01817     6,3,21,
01818     4,5,14,
01819     6,2,65,
01820     1,1,32,
01821     2,6,3,
01822   };
01823 
01824   const int magicSquare9_filled50_6[] = {
01825     9,50,
01826     4,7,20,
01827     6,7,25,
01828     9,1,8,
01829     4,1,47,
01830     8,7,33,
01831     4,8,34,
01832     6,4,5,
01833     5,4,74,
01834     9,5,26,
01835     1,9,81,
01836     1,7,79,
01837     9,4,35,
01838     2,5,76,
01839     5,1,54,
01840     3,5,80,
01841     4,7,20,
01842     9,7,52,
01843     2,8,67,
01844     7,3,15,
01845     7,3,15,
01846     7,1,29,
01847     1,1,32,
01848     2,3,9,
01849     5,1,54,
01850     5,5,78,
01851     7,5,1,
01852     9,5,26,
01853     6,2,65,
01854     7,8,37,
01855     9,1,8,
01856     1,1,32,
01857     5,1,54,
01858     7,4,73,
01859     8,2,19,
01860     5,3,75,
01861     4,2,62,
01862     1,2,23,
01863     3,2,50,
01864     2,5,76,
01865     1,6,4,
01866     9,5,26,
01867     8,9,22,
01868     9,2,49,
01869     8,5,10,
01870     9,5,26,
01871     5,1,54,
01872     5,7,16,
01873     8,2,19,
01874     1,4,2,
01875     3,3,38,
01876   };
01877 
01878   const int magicSquare9_filled50_7[] = {
01879     9,50,
01880     6,3,21,
01881     7,6,70,
01882     3,4,40,
01883     5,2,13,
01884     6,6,66,
01885     7,8,37,
01886     8,6,57,
01887     8,1,68,
01888     2,9,60,
01889     4,8,34,
01890     7,3,15,
01891     2,3,9,
01892     4,3,64,
01893     2,2,17,
01894     7,2,71,
01895     3,3,38,
01896     4,9,63,
01897     8,4,77,
01898     2,4,51,
01899     3,5,80,
01900     7,1,29,
01901     3,5,80,
01902     6,1,46,
01903     4,7,20,
01904     1,5,28,
01905     3,5,80,
01906     8,4,77,
01907     7,2,71,
01908     6,8,61,
01909     3,3,38,
01910     8,4,77,
01911     3,9,36,
01912     1,2,23,
01913     4,2,62,
01914     3,6,6,
01915     4,7,20,
01916     4,7,20,
01917     9,9,45,
01918     5,1,54,
01919     4,3,64,
01920     6,6,66,
01921     8,2,19,
01922     8,5,10,
01923     3,2,50,
01924     2,4,51,
01925     3,7,43,
01926     5,5,78,
01927     4,5,14,
01928     4,7,20,
01929     5,4,74,
01930   };
01931 
01932   const int magicSquare9_filled50_8[] = {
01933     9,50,
01934     2,8,67,
01935     1,3,48,
01936     5,8,11,
01937     3,8,18,
01938     8,6,57,
01939     1,2,23,
01940     1,8,72,
01941     3,8,18,
01942     2,4,51,
01943     7,1,29,
01944     5,9,7,
01945     5,9,7,
01946     5,8,11,
01947     4,6,53,
01948     4,8,34,
01949     1,3,48,
01950     5,8,11,
01951     5,7,16,
01952     6,5,56,
01953     5,3,75,
01954     9,4,35,
01955     4,9,63,
01956     9,5,26,
01957     5,8,11,
01958     8,2,19,
01959     6,3,21,
01960     9,1,8,
01961     2,4,51,
01962     7,3,15,
01963     9,1,8,
01964     9,7,52,
01965     1,2,23,
01966     6,5,56,
01967     8,2,19,
01968     8,2,19,
01969     2,7,59,
01970     5,6,41,
01971     6,4,5,
01972     8,8,39,
01973     3,6,6,
01974     7,8,37,
01975     6,6,66,
01976     7,5,1,
01977     7,2,71,
01978     5,5,78,
01979     2,2,17,
01980     2,9,60,
01981     3,7,43,
01982     2,2,17,
01983     7,9,31,
01984   };
01985 
01986   const int magicSquare9_filled50_9[] = {
01987     9,50,
01988     3,8,18,
01989     6,7,25,
01990     2,9,60,
01991     8,9,22,
01992     7,8,37,
01993     3,3,38,
01994     5,6,41,
01995     8,2,19,
01996     8,4,77,
01997     3,4,40,
01998     8,2,19,
01999     5,9,7,
02000     8,8,39,
02001     5,9,7,
02002     7,9,31,
02003     9,9,45,
02004     5,5,78,
02005     4,7,20,
02006     3,9,36,
02007     4,9,63,
02008     8,5,10,
02009     9,3,55,
02010     8,6,57,
02011     2,7,59,
02012     9,2,49,
02013     1,7,79,
02014     1,3,48,
02015     4,8,34,
02016     8,6,57,
02017     7,5,1,
02018     5,6,41,
02019     2,1,27,
02020     9,3,55,
02021     5,2,13,
02022     3,6,6,
02023     8,1,68,
02024     8,8,39,
02025     1,7,79,
02026     2,2,17,
02027     4,1,47,
02028     1,2,23,
02029     5,1,54,
02030     2,6,3,
02031     8,1,68,
02032     3,5,80,
02033     3,5,80,
02034     9,3,55,
02035     3,8,18,
02036     5,7,16,
02037     7,5,1,
02038   };
02039 
02040   const int *specs[] = {
02041     magicSquare5_filled10_1,    //0
02042     magicSquare5_filled10_2,    //1
02043     magicSquare5_filled10_3,    //2
02044     magicSquare5_filled10_4,    //3
02045     magicSquare5_filled10_5,    //4
02046     magicSquare5_filled10_6,    //5
02047     magicSquare5_filled10_7,    //6
02048     magicSquare5_filled10_8,    //7
02049     magicSquare5_filled10_9,    //8
02050     magicSquare5_filled10_10,   //9
02051     magicSquare5_filled10_11,   //10
02052     magicSquare5_filled10_12,   //11
02053     magicSquare5_filled10_13,   //12
02054     magicSquare5_filled10_14,   //13
02055     magicSquare5_filled10_15,   //14
02056     magicSquare5_filled10_16,   //15
02057     magicSquare5_filled10_17,   //16
02058     magicSquare5_filled10_18,   //17
02059     magicSquare5_filled10_19,   //18
02060     magicSquare5_filled10_20,   //19
02061     magicSquare5_filled11_3_1,  //20
02062     magicSquare5_filled11_5_1,  //21
02063     magicSquare5_filled11_5_2,  //22
02064     magicSquare5_filled11_5_3,  //23
02065     magicSquare5_filled12_10_1, //24
02066     magicSquare5_filled12_1_1,  //25
02067     magicSquare5_filled12_1_2,  //26
02068     magicSquare5_filled12_1_3,  //27
02069     magicSquare5_filled12_2_1,  //28
02070     magicSquare5_filled12_2_2,  //29
02071     magicSquare5_filled12_2_3,  //30
02072     magicSquare5_filled12_3_1,  //31
02073     magicSquare5_filled12_3_2,  //32
02074     magicSquare9_filled10_1,    //33
02075     magicSquare9_filled10_2,    //34
02076     magicSquare9_filled10_3,    //35
02077     magicSquare9_filled10_4,    //36
02078     magicSquare9_filled10_5,    //37
02079     magicSquare9_filled10_6,    //38
02080     magicSquare9_filled10_7,    //39
02081     magicSquare9_filled10_8,    //40
02082     magicSquare9_filled10_9,    //41
02083     magicSquare9_filled10_10,   //42
02084     magicSquare9_filled10_11,   //43
02085     magicSquare9_filled10_12,   //44
02086     magicSquare9_filled10_13,   //45
02087     magicSquare9_filled10_14,   //46
02088     magicSquare9_filled10_15,   //47
02089     magicSquare9_filled10_16,   //48
02090     magicSquare9_filled10_17,   //49
02091     magicSquare9_filled10_18,   //50
02092     magicSquare9_filled10_19,   //51
02093     magicSquare9_filled10_20,   //52
02094     magicSquare9_filled50_1,    //53
02095     magicSquare9_filled50_2,    //54
02096     magicSquare9_filled50_3,    //55
02097     magicSquare9_filled50_4,    //56
02098     magicSquare9_filled50_5,    //57
02099     magicSquare9_filled50_6,    //58
02100     magicSquare9_filled50_7,    //59
02101     magicSquare9_filled50_8,    //60
02102     magicSquare9_filled50_9,    //61
02103     magicSquare9_filled50_10,   //62
02104     magicSquare9_filled50_11,   //63
02105     magicSquare9_filled50_12,   //64
02106     magicSquare9_filled50_13,   //65
02107     magicSquare9_filled50_14,   //66
02108     magicSquare9_filled50_15,   //67
02109     magicSquare9_filled50_16,   //68
02110     magicSquare9_filled50_17,   //69
02111     magicSquare9_filled50_18,   //70
02112     magicSquare9_filled50_19,   //71
02113     magicSquare9_filled50_20    //72
02114   };
02115 
02116   const unsigned n_examples = sizeof(specs)/sizeof(int*);
02118 
02119 }
02120 
02121 // STATISTICS: example-any
02122