All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars
 perplexus dot info

 Who`s on the right base? (Posted on 2011-03-03)
When can two wrongs make one right in 2 different ways, but no two rights ever make wrong?

 No Solution Yet Submitted by Ady TZIDON No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
 solution Comment 1 of 1

In base 8, twice 12634 is 25470, and twice 25706 is 53614, and thus these serve as alphametic solutions for 2*WRONG = RIGHT. That base has no solutions where 2*RIGHT=WRONG.

This situation seems to be unique to base 8, as the numbers of solutions keeps getting higher for higher bases.  Of course it can't be solved in a base lower than 8 as there are 8 different letters used.

In the following table, for each base is shown: the number of solutions of 2*WRONG = RIGHT involving leading zeros; the number that don't involve leading zeros; the number of solutions of 2*RIGHT = WRONG involving leading zeros and those not involving leading zeros.

`base 8             0  2          0  0 9             0  3          1  7 10            0  21         5  11 11            0  27         14  33 12            0  49         20  54 13            0  99         31  109 14            0  198        59  164 15            0  211        89  229 16            0  350        117  387 DEFDBL A-ZCLSFOR b = 8 TO 16  p4 = b * b * b * b: p3 = b * b * b: p2 = b * b: p1 = b  ztot1 = 0: nztot1 = 0: REDIM used(b - 1)  ztot = 20: nztot2 = 0  FOR w = 0 TO b - 1   used(w) = 1  FOR r = 0 TO b - 1   IF used(r) = 0 THEN     used(r) = 1  FOR o = 0 TO b - 1   IF used(o) = 0 THEN     used(o) = 1  FOR n = 0 TO b - 1   IF used(n) = 0 THEN     used(n) = 1  FOR g = 0 TO b - 1   IF used(g) = 0 THEN     used(g) = 1  FOR i = 0 TO b - 1   IF used(i) = 0 THEN     used(i) = 1  FOR h = 0 TO b - 1   IF used(h) = 0 THEN     used(h) = 1  FOR t = 0 TO b - 1   IF used(t) = 0 THEN     used(t) = 1     wrong = w * p4 + r * p3 + o * p2 + n * p1 + g     right = r * p4 + i * p3 + g * p2 + h * p1 + t     IF 2 * wrong = right THEN       IF w = 0 OR r = 0 THEN ztot1 = ztot1 + 1:  ELSE nztot1 = nztot1 + 1       IF b = 8 THEN         PRINT w; r; o; n; g, r; i; g; h; t       END IF     END IF     IF 2 * right = wrong THEN       IF w = 0 OR r = 0 THEN ztot2 = ztot2 + 1:  ELSE nztot2 = nztot2 + 1     END IF     used(t) = 0   END IF  NEXT     used(h) = 0   END IF  NEXT     used(i) = 0   END IF  NEXT     used(g) = 0   END IF  NEXT     used(n) = 0   END IF  NEXT     used(o) = 0   END IF  NEXT     used(r) = 0   END IF  NEXT   used(w) = 0  NEXT  PRINT b, ztot1; nztot1, ztot2; nztot2NEXT`

 Posted by Charlie on 2011-03-04 01:10:35

 Search: Search body:
Forums (0)