> In the quote below, he names the AND function "f", which in itself is a bit strange. What's wrong with "and" or ∧?
'∧' usually denotes the logical AND operator, which does not operate on integer values, (i.e. writing 22 ∧ 78 = 6 is weird). So it's not a bad idea to give this function a different name.
There is not, and there cannot be. However, even if he was figuring this all out from scratch, he could not have come up with the hand-written charts without realizing that.
I'm going to go out on a limb and guess that it is of some habitual relevance to a mathematician, since he mentions the identity function (not really relevant here either), but that the material he actually explains here doesn't do anything to justify its appearance.
However, I cannot present to you the crucial difference between the maximum of two numbers and the minimum of two numbers that explains what he was thinking. This must exist for my hypothesized explanation to make sense.
> I'm going to go out on a limb and guess that it is of some habitual relevance to a mathematician, since he mentions the identity function (not really relevant here either), but that the material he actually explains here doesn't do anything to justify its appearance.
It's worse than that; he mentions the identity function only to make a gross error about it. The identity function on (a, a) is (a, a), not a.
Granted. g(a) = f(a,a) is indeed the identity function for all f such that f(a,a) = a. That seems pretty pointless as an observation. We have f, so we're observing that some other, unrelated function is the identity function?
Assuming you actually care about the answer, this just help me drew the exploratory graph, and this property was useful to fill in cells for which operands were equal. Finding obvious properties is a great way to learn a pattern without even computing things. Unlike what you may think, I had no idea what I was about to find - I had never seen this chart drawn before, and so this post is structured around how I thought about the exploration, not around how it may be presented to an audience who already knows way more than I do on bitwise operations. Sounds fair?
Sure it's fair. Bitwise operations produce pretty strange numeric results, so no, I wouldn't think you'd expect much going in. But I don't see where the identity function comes into it at all. It looks like the term "the identity function" stuck in your mind, and you reached for it when you found something subjectively similar. But shared semantic space isn't a good reason to say that a function which isn't the identity function, is. Your middle point is the observation "f(a,a) = a", which is perfectly valid, but is not the same finding as the finding you report. Using pretty-simple terms to state something true is generally preferable to using even simpler terms to state something false.
The given function is clearly only defined over naturals. In the first part using bits, there's no indication of how to encode negatives, and in the second part with the sum equation, f(-1,-1) >= 0 (and thus not equal to -1) for any reasonable definition of the modulo function paired with any `b`, which breaks one of the stated identities. In fact, that's true if you replace mod with _any_ function.
> The given function is clearly only defined over naturals.
The post doesn't specify. Programming languages do define it over the negatives, however. I just didn't want anyone going into python and asserting that a & b >= min(a,b).
> there's no indication of how to encode negatives
Just do the standard thing: use 2s complement arithmetic [1]. More concretely: set b to infinity and take the limit under the 2-adic metric [2]. For example, -2 & -1 has partial sums 0, 10, 110, 1110, 11110, etc. It's limiting to ...1111110, which is the 2's complement representation of -2.
Excellent. I'm glad we agree. You'll notice that the stated identity f(x,x) = x fails to hold over x < 0. I hope this is sufficient to make it clear that the equation does not consider the negatives?
(In the quote below, he names the AND function "f", which in itself is a bit strange. What's wrong with "and" or ∧?)
As far as I can tell, the result can never be greater than the smaller of a and b. I can't come up with a counterexample. Is there one?