Jump to content
BrainDen.com - Brain Teasers

araver

Members
  • Posts

    1976
  • Joined

  • Last visited

  • Days Won

    5

Posts posted by araver

  1. 2 hours ago, plainglazed said:

    Ok, think I'm close:

      Reveal hidden contents

    Each operand n is converted to the number of positive integers less than n and relatively prime to n.  Then simple addition of the two converted operands yields the result. 

    I said I think this is close because if an n is not prime and converts to a multiple of 4, then it appears that result must be halved before adding to the other half of the operation.  Knowing araver, gotta think there is a more elegant way to describe what appears to be a need for further reduction in certain cases.

    For example:

    5 ||| 6 = 6

    (1,2,3,4) ||| (1,5) = 6

    4 + 2 6

     

    12 ||| 4 = 4

    (1,5,7,11) ||| (1,3) = 4

    4/2 + 2 = 4

     

    So:

    27 ||| 24 = ?

    (1,2,4,5,7,8,10,11,13,14,16,17,19,20,22,23,25,26) ||| (1,5,7,11,13,17,19,23) = ?

    18 + 8/2 = 22 ???

     

     

    Yup, that is close.

    EDIT: But the result for the question in the OP is incorrect.

    However, to get your attention, a couple more cases that might help.

    2 ||| 155

    5 ||| 21 = 10

    7 ||| 28 = 12

    7 ||| 40 = 10

  2. Yeah, that's not what I meant. I did not mean to discourage you from trying, just trying to put you in the right direction.

    Lemme rephrase that:

    If you could do a strategy with the odds you are expecting, you would design a very efficient error correcting code. There's a thing called Hamming bound preventing that. Non-trivial cases when one happens to reach that bound have been mapped out since the 70s (for prime alphabets, so including binary). Mathematical proofs. One class is the one I gave you in the spoiler above. The other works for larger n.

    In basic terms, every bit of information you add is another entropy generator that messes up the cases. Only in perfect settings one can separate entropy in different "jars" efficiently.

    P.S. All of these codes are used in every bit of technology you currently use.

  3. A solution with 50% odds is

    Spoiler

    16 possibilities.


    Choose A = {0000,1111} in step 0.
    0000 (1000, 0100, 0010, 0001)
    1111 (0111, 1011, 1101, 1110)

    If 0000 or 1111 they all choose wrong in step 3.
    If 1000, 0100, 0010, 0001, 0111, 1011, 1101, 1110, then they all choose correctly.
    E.g. for 1000
    The first sees 1000 and 0000 as possibilities. 0000 is in A so he chooses 1000
    The rest see 2 not in A e.g 1010 and 1000 as possibilities. Neither are in A so they abstain.

    If 0011, 0101, 0110, 1001, 1010, 1100 then they fail by all abstaining since these are all 2 bits away from both elements in A.

    8/16 = 50% chance of success.

     

  4. There has been something similar posted: http://brainden.com/forum/topic/13034--

    But it does not work for n=4.

    In short the optimal solution for other values of n (including n = 3) is:

    Spoiler

    For n=2^m-1 (n=3,7,15,31,63..) a nice statement holds: "The set of n-bit strings can be partitioned in radius-1 balls".

    This means that choosing a nice set of possible strings (m) will get you the following optimal strategy for  1-1/2^m probability of success. E.g. for n =3, m = 2, winning strategy is 75%.

    They have to communicate beforehand so that they establish the strategy (step 0 below). Assume that one of them is the always the first and use 1/0 for black/white. There is an unknown number with exactly 3 bits of information of which everyone knows 2 bits.

    Step 0) choose a set A that partitions the space (such as a Hamming set) of all n-bit numbers where every number not in A can be obtained from one in A flipping exactly 1 bit. e.g. for n=3 A = {000, 111}. One can easily get by flipping exactly one bit 000 (100, 010, 001) and 111 (011, 101, 110). A has exactly m elements (n = 2^m-1).

    Step 1) compute a and b which are two possible solutions with 1 and 0 as your own hat and the rest of the bits you see.

    Step 2) If neither a nor b are in A, abstain.

    Step 3) If a or b are in A (at most one due to how A was constructed), choose the one that does not belong to A.

    The above strategy fails if the actual hats are describing one of the elements in A since all would choose the wrong color in Step 3. So 2/8 chances of failing means 75%.

    In the rest of the cases (6/8), the solution (denoted d) is 1 bit away from an element x in A which means:

    - the person that doesn't know that bit will figure out which of a and b is not in A in Step 3 and make the correct choice.

    - the others will abstain. Not easy to understand why but it's a property of the partitioning set itself - every n-digit number belongs to exactly one radius-1 ball. This is why it doesn't work for other values of n.

    Assume the solution is not in A, someone other (than the one who corresponds to the bit flipped from an element x in A) computes some a_j and b_j as candidates in step 1. One of these candidates is d the solution and the other (denoted c) differs from d in one bit. We already know d is not in A.

    Assuming that c is in A we get x and c each differing from d in exactly one bit but a different position. Which is false b/c of how A was constructed. So c is not in A, therefore this guy will abstain in step 2.

    Since all but one abstain and that one gets it correctly, the game is won.

    Now for n = 4, I do not know of an optimal solution.

  5. WEEKS

    AVANT - 0
    GARDE - 0
    SEEDS - 3
    EIDER - 0
    HEADS - 2
    EVENT - 1 Plainglazed +5 Phaze +10
    BEERS - 3
    LEEKS - 4
    WEEKS - 5 Maurice +15

    maurice - 174 + 15 = 189
    Logophobic - 143
    phaze - 112 + 10 = 122
    plainglazed -  112 + 5 = 117
    araver - 15 + 9 = 24
    nana - 10

  6. Not constructive, but only 174 possibilities to check.

    Spoiler

    abcdefg is divisible by its product (a*b*c*d*e*f*g) where a,b,c,d,e,f,g are distinct digits

    1) There is no 0 in abcdefg since the product cannot be 0, nothing is divisible by 0.
    2) There is no 5 in abcdefg since 7 digits out of {1,..,9} mean at least one is even and if the product contains 5 that means the product is divisible by 10 so the last digit is 0, contradiction.
    3) 8 possible digits left of which 9 is definitely a digit. If there were no 9 in abcdefg then 3 would be in the product of digits and the sum would be 1+2+3+4+6+7+8 = 8*9/2-5 = 31 which is not divisible by 3.
    4) There is no 4 in abcdefg. Since 9 is a digit and the sum of all digits from 1 to 9 except for 5 is 9*10/2-5=45-5=40, the only way to make the sum of digits divisible by 9 is to remove 4 yielding the sum 36.
    5) From the above, abcdefg contains 1,2,3,6,7,8,9 hence the product is 18144 and the sum is 36.
    a*b*c*d*e*f*g = 18144
    a+b+c+d+e+f+g = 36

    which brings us to the original post.
    6) 18144 = 7*81*32 = 7*3^4*2^5. There are rules of divisibility for powers of two (2^N) that take into account the fact that the last N digits are relevant since the others are multiplied by 10^N so will not change divisibility.
    g is divisible by 2 so 2,6,8.
    fg is divisible by 4 so 12, 32, 72, 92, 16, 36, 76, 96, 28, 68.
    efg is divisible by 8 so 312, 712, 912, 632, 832, 672, 872, 192, 392, 792, 216, 816, 136, 736, 936, 176, 376, 976, 296, 896, 128, 328, 728, 928, 168, 368, 768, 968.
    defg is divisible by 16 so 7312, 9312, 3712, 9712, 6912, 8912, 1632, 7632, 9632, 6832, 8672, 1872, 3872, 9872, 6192, 8192, 1392, 7392, 1792, 3792, 3216, 7216, 9216, 2816, 7136, 9136, 2736, 8736, 1936, 7936, 2176, 8176, 1376, 9376, 2976, 8976, 1296, 3296, 7296, 2896, 6128, 1328, 7328, 9328, 1728, 3728, 9728, 6928, 3168, 7168, 9168, 2368, 2768, 1968, 3968, 7968.
    cdefg is divisible by 32 so 97312, 69312, 89312, 63712, 83712, 39712, 86912, 38912, 78912, 81632, 17632, 97632, 89632, 16832, 76832, 96832, 31872, 91872, 63872, 19872, 39872, 36192, 76192, 68192, 71392, 67392, 87392, 61792, 81792, 13792, 73216, 93216, 37216, 97216, 89216, 27136, 87136, 79136, 12736, 92736, 28736, 71936, 27936, 87936, 82176, 38176, 98176, 21376, 81376, 29376, 89376, 82976, 18976, 38976, 31296, 71296, 83296, 87296, 12896, 32896, 72896, 36128, 76128, 96128, 71328, 91328, 67328, 19328, 79328, 61728, 13728, 93728, 69728, 16928, 36928, 76928, 23168, 27168, 39168, 79168, 12768, 32768, 92768, 31968, 71968, 23968, 27968.

    87 possibilities. It looks like brute force but it's easy to construct with pen&paper in under 30 minutes (and 1 cup of coffee).

    Last two digits a and b are known for each possibility so that means 2*87 = 174 combinations to try divisibility with 18144.

    Comments

    I). I haven't found a use for divisibility with 7. I know of two criteria:
    i) from left-to-right take digits and multiply with 1-3-2-6-4-5 so g + 3f + 2e + 6d + 4c + 5b + a is divisible by 7
    ii) abcdef-2*g is divisible by 7.

    II) I haven't found a use for divisibility with 27 and 81 (actually I know of no rule for 81 that would work on 7 digit numbers)
    For 27 the divisibility trick is to get blocks of 3 digits because 1000 = 1 (mod 27).
    That means efg + bcd + a must be divisible with 27.

    One could theoretically use one of these rules to narrow the space of solutions combined with the divisibility criteria for powers of 2 above.

     

     

  7. Spoiler

    There are 3+4+5+4+3 = 19 huts so 19 ages of the eldest sons in each hut.
    Sum of all ages is 5 times the sum of any row which is twice the age of the oldest sun in the village.
    There are no gaps and no two are the same so the sum of the 19 ages.
    Hence:
    (i) S = 10*X
    (ii) S = Y + (Y+1) + .... +(Y+18)
    (iii) X = Y+18

    Rewriting (ii) as a consecutive sum:
    S = 19*(Y-1) + (1+....+19) = 19*(Y-1) + 19*20/2
    and using (i) and (iii):
    10*X = 10*(Y-1)+10*19 = S = 19*(Y-1) + 19*10

    Therefore 9*(Y-1) = 0, so Y=1 and X = 19.

    Did not use the fact that they are not of voting age (which indeed narrows the possibilities for Y to be either 1 or 2).

     

  8. 2 hours ago, plainglazed said:

    Still at it araver.  Probably obvious to any out there checking this thread out but gonna put it out there anyway:

      Hide contents

    If both numbers of the operation are prime, the resulting number is two less than their sum.  Been working with the assumption that could be the sum of the difference of their factors i.e 7 ||| 11 = 16  could be (7-1)+(11-1).  So instances where you have a prime and a nonprime input as in 8 ||| 11 = 12  the 8 would have to yield 2.  From similar instances: 6-->2, 18-->6, 24-->6.  So been playing with prime factors, factored pairs, multiplicities etc but to no avail as of yet.  Running out of coffee.  Got    to    get...

     

    Spoiler

    You're on the right track. Just one or two stations to go.

    The assumption holds.

    From there you have 2 options:

    1. The examples could give you another assumption. And from there another look would yield the "Aha" moment.

    2. Brute force the examples and reverse engineer the most plausible explanation for the sequence.

    So one or two stations to go depending on how much coffee ... :D

     

  9. 8 hours ago, plasmid said:

    It's just that this is really hard.

    We know there are operations on both the first and second input that make it non-monotonic (since 2 ||| 11 = 11, 7 ||| 11 = 16, 8 ||| 11 = 12; and 7 ||| 3 = 8, 7 ||| 11 = 16, 7 ||| 28 = 12). It's also alternating between increasing and decreasing multiple times based on the inputs with X ||| 11, so it's not just a matter of having the difference between the inputs (or some function along those lines) play a role. My best guesses are still that greatest common denominator or least common multiple or modular arithmetic are coming into play, but I don't see a solution emerging with any of those approaches. The strongest clue seems to be that so far, for any value of N, we've had 2 ||| N = N (so maybe it is monotonic in the special case where the first number is 2?)

    Spoiler

    It is hard in the sense that it is way easier to throw boulders into a deep lake than it is to take them out :)

    Your observation is correct, your conclusion may not be, depending on what you meant. More exactly I see a problem/ambiguity in this sentence "It's also alternating between increasing and decreasing multiple times based on the inputs with X ||| 11, so it's not just a matter of having the difference between the inputs (or some function along those lines) play a role". If by some function you mean monotonic, yes. If you mean some function then, no. There may be lots of functions with interesting properties that are not monotonic but likewise simple in nature and a lot of combinations of such functions may lead to increasing/decreasing patterns. Not saying the solution is one of them, just that the class of simple/interesting functions is ... big.

    "The strongest clue" that you mentioned is intentional and the hypothesis is correct. And also in the spirit of encouraging, there may be similar clues that can help with establishing a pattern, it doesn't necessarily have to be a "1-click-type solution". It is harder for me to figure out how everyone's brain work so I don't know if what I am saying will help you or not.

     

    3 hours ago, plainglazed said:

    At first was leaning more toward modulo vs multiples. Now thinking primes play a role. And/or that puzzle going around FB and other places where you add first digits and subtract second ones or similar like at http://brainden.com.

     

    Difinitely been pulling my hair out daily crunching on this one, Araver. Cheers

    Spoiler

    Those are all valid hypothesis. 

    I would however try to help you stay with more hair on rather than out, so lemme throw in a hint: "it's not like that puzzle on FB/other places".

    I am glad that you are trying to solve it (which is why I hit Reply :) ), but I can't help myself talking about it while you are trying, so I used spoilers (even though there are no major spoilers in my responses).

×
×
  • Create New...