# Boolean algebra



## NC Plc (Mar 24, 2014)

Now I know the basics of it, but how important is it to become extremely comfortable with boolean algebra for PLC programming? Are you fluent in it or is it just something you are comfortable with and use from time to time?

I mean, AND OR NOR NOT NAND are fairly simple, but I wanted to see if it is worth getting a boolean PDF and spending a great deal of time studying the stuff.


----------



## Mich drew (Mar 3, 2013)

I don't know Boolean algebra, but I do know the square root of 69 is eight something..................


----------



## dronai (Apr 11, 2011)

Did you change your user name ?

Take a formal PLC class, and you wont be asking questions like this. 

Being a maintenance mechanic with no senior level guys to learn from is going to take you years. Also skipping out on a formal apprenticeship you are short changing yourself in the long run.

You should also just hang out at the PLC forum. I don't think there's anything for you here.


----------



## JRaef (Mar 23, 2009)

I don't know of anyone who PROGRAMS in Boolean any more. but there will be Boolean commands embedded in Statement List and Function Block programming, so it's not a total waste of time to understand it, but I wouldn't spend a lot of time trying to memorize it or anything.


----------



## NC Plc (Mar 24, 2014)

dronai said:


> Did you change your user name ?
> 
> Take a formal PLC class, and you wont be asking questions like this.
> 
> ...


1) I have taken a formal PLC class at my local CC. The basic and advanced classes did not go into boolean algebra aside from very, very basic stuff. The teacher suggested practicing boolean but he never went into it much. He wrote some PLC programs for Honda, I wish I could have spent more time picking his brain.

2) I'm learning the PLC stuff on the side. My employer gave me a 295 rung program today that I have been slowly putting into the DL06 they gave me. We have a PLC programmer that we use but I can't exactly shadow him as he and I are too busy, he lives in Cali and all his work is done remotely, and he charges quite a lot for his services.

3) Maintenance is only a small portion of what I do, but nice try. :thumbsup:

4) I'm flattered by your obsession with me and your attempts at saying I'm not an apprentice, attempting to insult my intelligence and my job, etc. It's the people like you that give me the motivation to get my electrical license, an engineering degree of some sort, and learn how to program PLCs in my spare time. Thank you. :thumbup:



JRaef said:


> I don't know of anyone who PROGRAMS in Boolean any more. but there will be Boolean commands embedded in Statement List and Function Block programming, so it's not a total waste of time to understand it, but I wouldn't spend a lot of time trying to memorize it or anything.


Alright man, thanks. I've found a few neat (and free) PDFs that go over it so I'm gonna run through them a few times.

While asking around I had one guy say that it's a fairly valuable thing to be fairly comfortable with.


----------



## RIVETER (Sep 26, 2009)

Just think about TRUTHS. If, in a sentence that makes sense, aka, LOGIC, if A is true, B is true, and C is not true(false), then the answer to the sentence is false. To be a logical sentence the answer is the result of what is IN the sentence. To me that makes sense and I don't remember being taught BOOLEAN. It must not have been around when I was learning to change the wicks in gas lanterns.


----------



## dronai (Apr 11, 2011)

NC Plc said:


> 1) I have taken a formal PLC class at my local CC. The basic and advanced classes did not go into boolean algebra aside from very, very basic stuff. The teacher suggested practicing boolean but he never went into it much. He wrote some PLC programs for Honda, I wish I could have spent more time picking his brain.
> 
> 2) I'm learning the PLC stuff on the side. My employer gave me a 295 rung program today that I have been slowly putting into the DL06 they gave me. We have a PLC programmer that we use but I can't exactly shadow him as he and I are too busy, he lives in Cali and all his work is done remotely, and he charges quite a lot for his services.
> 
> ...


 1) First thing we learned was applying Boolean to logic. I had a great instructor.

2) :whistling2:

3) There is nothing wrong with being a real maintenance mechanic, in fact I learns tons from the guys I work around. I'm talking about machines though. You might be thinking of something else.

4) Sorry, I just get irked by your posts :laughing: Really, I don't understand why you don't hang out on the PLC forum. Sounds that's what you what to be someday


----------



## RIVETER (Sep 26, 2009)

dronai said:


> 1) First thing we learned was applying Boolean to logic. I had a great instructor.
> 
> 2) :whistling2:
> 
> ...


Don't be a BOOLEAN-ey.


----------



## NC Plc (Mar 24, 2014)

dronai said:


> 4) Sorry, I just get irked by your posts :laughing: Really, I don't understand why you don't hang out on the PLC forum. Sounds that's what you what to be someday


It's alright man, not everyone matures past high school. :thumbsup:


----------



## drsparky (Nov 13, 2008)

We do a lot of windshield time and I teach the new guys Boolean Algebra while we drive. If they are not interested we can listen to the radio. They all like to learn and so most of the time class is in session. I even asked on of the guys for the truth table for a exclusive OR gate (the logo for DPS Telecom, one of our equipment suppliers) he got right. You can never learn too much.


----------



## RIVETER (Sep 26, 2009)

NC Plc said:


> It's alright man, not everyone matures past high school. :thumbsup:


I like that...and I'll probably use it.:thumbsup:


----------



## dronai (Apr 11, 2011)

http://www.plcs.net/

Please go away


----------



## NC Plc (Mar 24, 2014)

drsparky said:


> We do a lot of windshield time and I teach the new guys Boolean Algebra while we drive. If they are not interested we can listen to the radio. They all like to learn and so most of the time class is in session. I even asked on of the guys for the truth table for a exclusive OR gate (the logo for DPS Telecom, one of our equipment suppliers) he got right. You can never learn too much.


Good stuff man. :thumbup: My boss teaches me a lot about PLCs but he's not specifically a PLC programmer, though he does mess around with them from time to time. 



RIVETER said:


> I like that...and I'll probably use it.:thumbsup:


:blush:


----------



## dronai (Apr 11, 2011)

NC Plc said:


> It's alright man, not everyone matures past high school. :thumbsup:


Like this ? 

This is your profile picture at the game site. Your right


----------



## NC Plc (Mar 24, 2014)

dronai said:


> Like this ?
> 
> This is your profile picture at the game site. Your right


I'm confused, what game site? OH, you mean Chess.Com I am really flattered that you're attempting to track me down. :thumbup:

Also you trying to track me down like some sort of lunatic just supports my statement that you never matured past high school haha.


----------



## RIVETER (Sep 26, 2009)

NC Plc said:


> Good stuff man. :thumbup: My boss teaches me a lot about PLCs but he's not specifically a PLC programmer, though he does mess around with them from time to time.
> 
> 
> 
> :blush:


You don't want money for the quote, do you?:blink:


----------



## NC Plc (Mar 24, 2014)

RIVETER said:


> You don't want money for the quote, do you?:blink:


I'm gonna need tree-fiddy.


----------



## RIVETER (Sep 26, 2009)

NC Plc said:


> I'm gonna need tree-fiddy.


"TREE FIDDY"? I guess some some people don't mature beyond high school.


----------



## NC Plc (Mar 24, 2014)

I can't help it, I love South Park.


----------



## dronai (Apr 11, 2011)

NC Plc said:


> I'm confused, what game site? OH, you mean Chess.Com I am really flattered that you're attempting to track me down. :thumbup:
> 
> Also you trying to track me down like some sort of lunatic just supports my statement that you never matured past high school haha.


 Nice try


----------



## NC Plc (Mar 24, 2014)

dronai said:


> Nice try


I don't know man, you took an old joke picture I took like 6 years ago and put on a chess site, renamed it to Douch Bag (you should use spell check sometime haha) uploaded it to this site, then tried to embarrass me or something?

That's pretty like, petty and immature. God man what are you like 18, 20? :laughing:


----------



## RIVETER (Sep 26, 2009)

NC Plc said:


> I can't help it, I love South Park.


I used it.:thumbsup::thumbsup::thumbsup:


----------



## Wirenuting (Sep 12, 2010)

NC Plc said:


> Now I know the basics of it, but how important is it to become extremely comfortable with boolean algebra for PLC programming? Are you fluent in it or is it just something you are comfortable with and use from time to time?
> 
> I mean, AND OR NOR NOT NAND are fairly simple, but I wanted to see if it is worth getting a boolean PDF and spending a great deal of time studying the stuff.


Beyond what Jraef stated, Boolean algebra is a good way to understand things outside the "yes/no", "on/off" world. It's a way to begin and expand on the troubleshooting concept of looking beyond what only what you see before you. 

The digital world was built on a single pole switch, on/off. You only saw the light at the end of the hall. It was expanded to 3 way, 4 way switches operated by a JK flip-flop that toggled them on and off. You didn't get to see it, you were only tasked to find and repair it. 
Learning or understanding Boolean logic can help a person understand things they can't see. 
Ya, that was the navy teaching that stuff 35 years ago.. But it still works for me.


----------



## fnsane (Apr 29, 2015)

Hi guys, this is my first day on this site. This is also my last day on this site.

Fnsane


----------



## NC Plc (Mar 24, 2014)

Wirenuting said:


> Beyond what Jraef stated, Boolean algebra is a good way to understand things outside the "yes/no", "on/off" world. It's a way to begin and expand on the troubleshooting concept of looking beyond what only what you see before you.
> 
> The digital world was built on a single pole switch, on/off. You only saw the light at the end of the hall. It was expanded to 3 way, 4 way switches operated by a JK flip-flop that toggled them on and off. You didn't get to see it, you were only tasked to find and repair it.
> Learning or understanding Boolean logic can help a person understand things they can't see.
> Ya, that was the navy teaching that stuff 35 years ago.. But it still works for me.


Good stuff man. :thumbup: I love amazon, I found a 300 page book on boolean for only $10.


----------



## RIVETER (Sep 26, 2009)

fnsane said:


> Hi guys, this is my first day on this site. This is also my last day on this site.
> 
> Fnsane


We'll miss you.:thumbsup:


----------



## Wirenuting (Sep 12, 2010)

RIVETER said:


> We'll miss you.:thumbsup:


Wonder if he will cash in his 2 points?


----------



## Voltron (Sep 14, 2012)

fnsane said:


> Hi guys, this is my first day on this site. This is also my last day on this site.
> 
> Fnsane


Don't let the door hit ya.


----------



## JRaef (Mar 23, 2009)

Here's some boolean logic all single guys should know before dating:

Dinner && movie = date 
Dinner && movie && wine >= date :thumbup:
Dinner ^ movie <= date :001_huh:
Dinner ! movie <= date :001_huh:
Movie ! dinner != date, = movie. 
Date ! dinner || movie != date :no:
Date && dutch treat != date, = angry GF


----------



## markbrady (Jun 2, 2014)

I took Boolean and have heard that its no longer taught at the jatc so my guess is that if that is the case then it is not being used that much anymore so i would check before you waste your time and/or money to know boolean by making sure that its still used enough to warrant the cost whether that be your time or money


----------



## NC Plc (Mar 24, 2014)

markbrady said:


> I took Boolean and have heard that its no longer taught at the jatc so my guess is that if that is the case then it is not being used that much anymore so i would check before you waste your time and/or money to know boolean by making sure that its still used enough to warrant the cost whether that be your time or money


Yea man the book was only $10 so I don't think it's a bad investment. I was talking to a guy today and he was of the opinion that it can improve your programming, even if you're not programming in boolean.


----------



## markbrady (Jun 2, 2014)

NC Plc said:


> Yea man the book was only $10 so I don't think it's a bad investment. I was talking to a guy today and he was of the opinion that it can improve your programming, even if you're not programming in boolean.


Thought you were going to take classes to learn my mistake. Leave the book in the dumper and learn away :laughing:


----------



## Safari (Jul 9, 2013)

Talking about boolean,I did in my diploma level,I have done it now again in the degree level.now apart from making simple programs I haven't used that knowledge of it.


----------



## Safari (Jul 9, 2013)

There is a program called PCS 7(process control system) from Siemens that uses only boolean to program and there is no way you can change that program to ladder or stl.


----------



## pete87 (Oct 22, 2012)

fnsane said:


> Hi guys, this is my first day on this site. This is also my last day on this site.
> 
> Fnsane




I'll bet he can move poles with his cheeks .



Pete


----------



## NC Plc (Mar 24, 2014)

nickson said:


> There is a program called PCS 7(process control system) from Siemens that uses only boolean to program and there is no way you can change that program to ladder or stl.


Interesting man. :thumbup:


----------



## wildleg (Apr 12, 2009)

whether it is taught or not, I find boolean extremely useful, in many forms, both in programming , as well as solutions to complex logical problems, since the basic syntax of many mathematics and deductive (and somewhat inductive) reasoning can be reduced to solutions of equations using symbolic logic, and ultimately boolean algebra. The intersection of boolean algebra, linear algebra, set theory, computer programming, and deductive reasoning provides for endless applications. I took a 3 semester course in symbolic logic once upon a time, and it is a fascinating subject. The course I took was actually given by a philosophy professor who was well versed in mathematics, and (surprisingly) gave us some really practical applications and exercises from programming to gambling on horses. If you think your programming skills are up to the task, look up "Turing Machine" and see if you can solve complex problems with it. It's interesting stuff.


as usual, just my 02


----------



## NC Plc (Mar 24, 2014)

I'll look into it man but I'm not entirely sure I'm up to the task.


----------



## JRaef (Mar 23, 2009)

nickson said:


> There is a program called PCS 7(process control system) from Siemens that uses only boolean to program and there is no way you can change that program to ladder or stl.


Well, not really. PCS7 is a DCS (Distributed Control System) that just uses Simatic S7-400 PLC hardware for the real-world interface to equipment, but the overall system programming is MUCH more complex and powerful than Boolean. It's called SCL, Structured Control Language. It might look kind of like Boolean to the untrained eye, but is far far more complex, because process control is all about PID algorithm loops within loops within loops; very math intensive with predictive control modeling and fuzzy logic etc. 

SCL is to Boolean as a bicycle is to a race car. They both have wheels and make you go forward, but the similarity stops there. SCL and Boolean both have shortened command statements, and some of the simplest of those within SCL are the same as Boolean, such as IF, AND, NOT etc., but SCL goes WAY further than that in that the more complex statements you use up front have pages and pages of code behind the scenes that execute these complex algorithms.

So again, IF you ever progress to the level of being able to tackle something like a DCS to run an entire processing facility, a knowledge of Boolean instructions is helpful as a stepping stone to more advanced programming languages. But if you are going to want to program machine controls with PLCs, you will not be using Boolean logic other than at the simplest level as commands inside of other commands, all of which will be obvious to you when you look at them. Things like AND, NOT, EQUAL, etc.


----------



## Safari (Jul 9, 2013)

Thought I should include some screen shots.your description jraef fits to what we have here.


----------

