Calcudoku puzzle forum
http://www.calcudoku.org/forum/

Bitwise operator
http://www.calcudoku.org/forum/viewtopic.php?f=3&t=63
Page 2 of 2

Author:  clm  [ Wed Sep 21, 2011 9:30 am ]
Post subject:  Re: Bitwise operator

jomapil wrote:
Hi, clm.

" But if n| is even the cage is always even, but if n! is odd the cage can be odd or even." ...

Another point refers to the n| cages of 3-cells: In my first solved problem with bitwise OR ( 20Sep2011-8x8 difficult ) I didn't need what I'm going to tell you because I solved these 3-cages in another way. But, on the whole, I eventually need to calculate great number of results ( 7| has, theoretically, 7^3 hypothesis, if I'm not wrong! ). Anyway we must calculate them? Or is there any secrets I don't know?

Best regards.

P.S. - As you see I'm not a great expert of English language, but I hope you understand me in the essencial.


Yes, I was talking yesterday about that "paradox". What it really happens for n| when n is odd is that, once the main result is obtained, this result is not modified if you add another number that, keeping the essential result, finishes in 0. For instance:
1000 (8)
0101 (5)
0100 (4) bitwise "ORed" produce 1101 (13|), the result in decimal is 13, but the sum of those is 17 (odd), while

1000 (8)
0101 (5)
0101 (5) produce the same 1101 (13|) (both combinations are valid) with a sum now of 18 (even) because it is indifferent that the last bit of this last number be a 0 or a 1 once you have already a 1.

With respect to three cells, no, you do not have 7^3 = 343 hypothesis, here you are considering all numbers from 1 to 7 against all, but think that 2-2-3, i.e., would never produce 7| since we need the third bit active (counting bits from right to left), also you are including combinations as 4-4-4 repeating 3 times a number which are impossible in a 3-cells L-shaped. If you eliminate all the forbidden combinations you will find the 56 combinations I was referring to in my topic "Searching for the operands" (if I was right in that topic). There are no more secrets (anyway in the wikipedia, or if you search with the Google, looking for "bitwise OR", for instance, you have more extensive articles about the subject).

P.D.: Muito obrigado, your English is very good (for me) and I understand your expositions, doubts and points of view, and I think that probably other members of our "club" have the same uncertainties.

Author:  jomapil  [ Wed Sep 21, 2011 9:56 am ]
Post subject:  Re: Bitwise operator

7^3=343 hypothesis. I said THEORETICALLY because we must eliminate the not valid combinations. So they will be lesser than this total.
I didn't know 56 was the number for the correct combinations for 7| (3-cages ).

I didn't read yet your topic " Searching about operands ". It's the next one I'm going to study.

Till the next

Page 2 of 2 All times are UTC + 1 hour [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/