6

On an ALU data sheet there are logic formulae showing the results that will be output for various inputs.

http://www.farnell.com/datasheets/1840939.pdf

(Second from last row on page 3.)

I assume that A+B means bitwise A OR B, this would follow, as the plus in a circle is XOR.

Does AB mean bitwise A AND B?

fadedbee
  • 994
  • 9
  • 24
  • It would follow, because the arithmetic plus is indicated by `PLUS`. And since the multiplication is not among the parts capability (as indicated on the first page), `AB` would mean bitwise `A AND B`. – Eugene Sh. Jun 23 '16 at 15:48
  • A lot of sources are already on the google search, no offense I don't think there is a question here. – MaMba Jun 23 '16 at 16:16
  • Unless it is a regex expression your deduction is true. –  Jun 23 '16 at 22:29

2 Answers2

13

Yes, when written as multiplication in normal math, it means AND in Boolean logic. This does make some sense when you think about it. Make a truth table of multiplying two value that can be either 0 or 1. The result is 0 except when both are 1, then the result is 1. That's exactly what AND does.

This logic doesn't really follow for "+", unless you consider 0 FALSE and anything else TRUE.

Olin Lathrop
  • 310,974
  • 36
  • 428
  • 915
  • So many words instead just yes –  Jun 23 '16 at 16:31
  • 5
    A one word answer is pretty much considered useless, and quickly downvoted. Points for the explanation. – R Drast Jun 23 '16 at 16:46
  • 2
    `unless you consider 0 FALSE and anything else TRUE` Like most C-derived programming languages, for example :) – cat Jun 23 '16 at 18:25
4

You are right AB mean A AND B . It is faster to write AB than A dot B or A AND B

MathieuL
  • 1,126
  • 1
  • 9
  • 22