Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Comment on

( #3333=superdoc: print w/ replies, xml ) Need Help??
It looks like exponential-order to me. I added some code to sum up the number of permutations of the sets:
$bigtotal += Math::NumberCruncher::Permutation(scalar(@Num),MATRIX_D +IM); @Sol=CheckSolution(\@Num);
Here are the results:
Order 4: Maximum divisor is 416, solution is 2496-9152-1664-2080 Checked 19301184 cases 1445.940u 5.500s 27:10.91 88.9% 0+0k 0+0io 364pf+0w Order 3: Maximum divisor is 44, solution is 132-792-660 Checked 140526 cases 10.690u 0.050s 0:14.69 73.1% 0+0k 0+0io 364pf+0w Order 2:Maximum divisor is 7, solution is 21-84 Checked 820 cases 0.290u 0.010s 0:00.33 90.9% 0+0k 0+0io 364pf+0w
At that rate, order 5 will test about 1 billion cases and take over a day to run. But I think it might be feasible if bad solution sets are eliminated early.

The big problem is the permutations, which are factorial order. I would suggest picking the corner two items first. They have to have the same top digit. Then that determines the possible top digits of the rest of the rows.

In reply to Re: Re: Code to solve the "matrix formation" puzzle by tall_man
in thread Code to solve the "matrix formation" puzzle by Rhose

Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":

  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?

    What's my password?
    Create A New User
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others chanting in the Monastery: (12)
    As of 2015-11-30 14:49 GMT
    Find Nodes?
      Voting Booth?

      What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

      Results (773 votes), past polls