1. Standard memberMathurine
    sorozatgyilkos
    leölés ellenfeleim
    Joined
    15 Jul '06
    Moves
    40507
    05 Jan '07 15:18
    Find a non-empty set of positive integers, base 10, no two equal, such that:

    (1) For any number N in the set, none of the numbers in the set has N digits.
    (2) For any number N in the set, the sum of the squares of the digits of N is also in the set.
    (3) The number of numbers in the set is also in the set.
    (4) The largest number in the set is equal to the sum of all of the other numbers in the set.

    Among all such sets find one with the fewest numbers, and among those,
    find the one with the smallest largest number.
  2. Standard membercelticcountry
    Copyright ©2001-2006
    Eastbourne
    Joined
    20 Sep '04
    Moves
    16434
    05 Jan '07 16:16
    1,2,3,4 ?
  3. Joined
    21 Feb '06
    Moves
    6830
    05 Jan '07 18:29
    Originally posted by celticcountry
    1,2,3,4 ?
    They've all got one digit, and one is in the set.
  4. Standard memberPBE6
    Bananarama
    False berry
    Joined
    14 Feb '04
    Moves
    28719
    05 Jan '07 18:43
    Originally posted by Fat Lady
    They've all got one digit, and one is in the set.
    Leave him be, this is the highest we've ever seen him count. 😵
  5. Joined
    12 Jul '06
    Moves
    1089
    07 Jan '07 11:14
    I know of the solution to this problem, I've seen it before. If anyone gets it right, I'm not sure I'll believe they've calculated it....
  6. B is for bye bye
    Joined
    09 Apr '06
    Moves
    27526
    07 Jan '07 14:49
    Originally posted by Fat Lady
    They've all got one digit, and one is in the set.
    And it doesn't meet conditions 2 or 3 either, but why be picky?
  7. Joined
    13 Dec '06
    Moves
    792
    07 Jan '07 17:40
    Originally posted by Mathurine
    [b]Find a non-empty set of positive integers, base 10, no two equal, such that:

    (1) For any number N in the set, none of the numbers in the set has N digits.
    (2) For any number N in the set, the sum of the squares of the digits of N is also in the set.
    (3) The number of numbers in the set is also in the set.
    (4) The largest number in the set is equa ...[text shortened]... e with the fewest numbers, and among those,
    find the one with the smallest largest number.
    [/b]
    I think I found a set which satisfies all but (4):

    (4, 14, 16, 17, 20, 25, 29, 37, 42, 50, 58, 85, 89, 145)

    I believe any set which satisfies (4) must be larger than this.
  8. Sydney
    Joined
    30 May '05
    Moves
    16100
    08 Jan '07 05:34
    {4,16,20,24,37,40,42,58,61,73,77,89,98,106,145,890}

    one of these numbers is kinda different, one of these numbers is not the same 😉

    i believe this is the smallest size set and top number that satisfies the criteria.
  9. Standard memberXanthosNZ
    Cancerous Bus Crash
    p^2.sin(phi)
    Joined
    06 Sep '04
    Moves
    25076
    08 Jan '07 05:56
    Originally posted by idioms
    {4,16,20,24,37,40,42,58,61,73,77,89,98,106,145,890}

    one of these numbers is kinda different, one of these numbers is not the same 😉

    i believe this is the smallest size set and top number that satisfies the criteria.
    Any details on how you approached the problem? I tried a few different ways but got lost every time.
  10. Sydney
    Joined
    30 May '05
    Moves
    16100
    08 Jan '07 07:37
    Originally posted by XanthosNZ
    Any details on how you approached the problem? I tried a few different ways but got lost every time.
    This isn't going to be especially clear i'm afraid. It's hard to explain without mathematical notation

    I knew the seed set i was looking for was self contained for not simply one iteration of the sum of squares algorithm but infinite iterations

    I then wrote a perl program to sort all numbers of 4 digits or less into groups based on the number iterations it took for the sum of squares algorithm to produce a bound set.

    I wrote another perl program to check each set. The numbers in the set i wanted (call it S) all had their sum of squares in the set as well. There was only one such set which had an iterative length of 8
    {16,37,58,89,145,42,20,4}

    So that was my seed set .. the next bit stumped me for a while. I knew it would be set size of 16 as this was the only reasonable length given that i had to stay under 1000 for the top number. I could also add as many permutations of the seed set including adding zero to fill up the set, no matter how i did it though i couldn't make it add up to a number in the original set S. Then i realized i can use a number not in S as long as the sum of its square was in S and that solved it

    I'm not 100% sure that 890 is the lowest number .. it could be that by carefully selecting numbers from other sets you can create a lower number but 16 is definitely minimum set size.
  11. Joined
    16 Nov '06
    Moves
    2857
    08 Jan '07 17:222 edits
    I started like this following the 2nd rule:

    5..
    25 //we need the square of 5 in the set of numbers..
    29 //2*2+5*5
    85 //2*2+9*9
    89 //64+25
    145 //64+81
    42..
    20..
    4..
    16..
    37..
    58 //and i stopped because i allready have 89 in the list.
    the total sum is 555.. but it's no good because i would need 5*5+5*5+5*5 which is 75. And I don't have 75 in my list.
    I started looking for a numer that would have the sum of square digits in the set above and added to 555 would lead to a number that has the sum of its square digits in the set.
    And quickly found 52. The sum will be 607 which has the sum 36+49=85.

    So the entire set is:
    4,5,16,20,25,29,37,42,52,58,85,89,145,607.

    LE: sorry.. i skipped one rule.. i don't have 14 in the set which is the number of integers. I will try to find a solution.

    LE2: ok.. I found on my way home the last 2 numbers: 102, 21. With them the sum becomes 730, and the number of number will be 16.
    Final result:
    4,5,16,20,21,25,29,37,42,52,58,85,89,102,145,730.
  12. Joined
    16 Nov '06
    Moves
    2857
    08 Jan '07 20:151 edit
    So.. I think I found the ultimate solution.

    I started by the same algorithm as described before to see where does every number from 4 to 15 lead to.. it's no sense trying numbers greater than this, because the minimum set until this point had 16 numbers.

    For 4 we have the most efficient set that solves rule nb 2.
    4,16,37,58,89,145,42,20;
    So the minimum set lenght could be 9.
    But it ain't because adding 9 breaks rule nb2
    10 needs 1 because of rule nb2, so it breaks rule nb 1;
    11 needs 2 but the sum isn't ok..
    12 leads to 5 and that leads to the solution above.
    13 leads to 10. No good.
    14 needs 17,50,25,29,85 and the main set so it doesn't meet with rule nb4
    15 needs 26,40 and the set above.

    So we have 15,26,40,4,16,37,58,89,145,42,20; And we need 4 more nb. We have the partial sum 492. Posible canditates at a quick glance: 98,24,2,61,73,85,51,62. After a dozen tries i come up with 2,24 and 62 as the lucky nbs. The total sum is 580 which is the last number.

    Final result:
    2,4,15,16,20,24,26,37,40,42,58,62,89,145,580
  13. Sydney
    Joined
    30 May '05
    Moves
    16100
    08 Jan '07 20:26
    Originally posted by altfell
    So.. I think I found the ultimate solution.

    I started by the same algorithm as described before to see where does every number from 4 to 15 lead to.. it's no sense trying numbers greater than this, because the minimum set until this point had 16 numbers.

    For 4 we have the most efficient set that solves rule nb 2.
    4,16,37,58,89,145,42,20;
    So the minim ...[text shortened]... 580 which is the last number.

    Final result:
    2,4,15,16,20,24,26,37,40,42,58,62,89,145,580
    can't use 2
  14. Joined
    16 Nov '06
    Moves
    2857
    08 Jan '07 21:091 edit
    yup.. you're right.. forgot about that.. 😳

    Last chance:
    4,15,16,20,24,26,37,40,42,58,61,73,89,145,650
  15. Sydney
    Joined
    30 May '05
    Moves
    16100
    08 Jan '07 21:251 edit
    Originally posted by idioms
    This isn't going to be especially clear i'm afraid. It's hard to explain without mathematical notation

    I knew the seed set i was looking for was self contained for not simply one iteration of the sum of squares algorithm but infinite iterations

    I then wrote a perl program to sort all numbers of 4 digits or less into groups based on the number iterations umbers from other sets you can create a lower number but 16 is definitely minimum set size.
    I think this is the set with smallest high number

    {16,37,58,89,145,42,20,4,24,26,29,38,40,76,59,703}

    ED: maybe not .. you can actually use any number that produces a number in the seed set in less that 8 iterations of the sum of squares function .. so it is potentially possible to create a set with less than 16 members
Back to Top

Cookies help us deliver our Services. By using our Services or clicking I agree, you agree to our use of cookies. Learn More.I Agree