New Reply

Order of operations in boolean algebra

 
Share Thread Thread Tools
Feb4-13, 05:17 PM   #1
 

Order of operations in boolean algebra


I have a rather technical question in boolean algebra to which I was not able to find an answer.

What is the order of operations in boolean algebra?
Is it first logical NOT, logical AND, logical OR, and finally logical XOR?

Correct me if I am wrong.

BiP
PhysOrg.com
PhysOrg
science news on PhysOrg.com

>> Bird's playlist could signal mental strengths and weaknesses
>> Minus environment, patterns still emerge: Computational study tracks E. coli cells' regulatory mechanisms
>> Bacterium uses natural 'thermometer' to trigger diarrheal disease, scientists find
Feb4-13, 05:36 PM   #2
 
The order of Boolean operations from high to low priority is NOT, AND, OR, while expressions inside brackets are always evaluated first.

Lecture 1: Introduction to Boolean Algebra, Handout, page 2.
Feb4-13, 05:46 PM   #3
 
What about XOR?

BiP
Feb4-13, 06:00 PM   #4
D H
 
Mentor

Order of operations in boolean algebra


Since xor is equivalent as not equals, at least in C-based languages xor (as !=) has precedence over logical and (&&) and logical or (||). However, bitwise and (&) has precedence over bitwise xor (^), which in turn has precedence over bitwise or (|).

In the end, does it really matter? Just use parentheses and there's no doubt.
New Reply
Thread Tools


Similar Threads for: Order of operations in boolean algebra
Thread Forum Replies
min and max in order of operations General Math 5
Order of Operations Precalculus Mathematics Homework 4
Simplifying Boolean Expressions using the Laws of Boolean Algebra Calculus & Beyond Homework 15
Simplifying Boolean Expressions using the Laws of Boolean Algebra Engineering, Comp Sci, & Technology Homework 1
Order of operations Introductory Physics Homework 3