Send Close Add comments: (status displays here)
Got it!  This site "creationpie.org" uses cookies. You consent to this by clicking on "Got it!" or by continuing to use this website.  Note: This appears on each machine/browser from which this site is accessed.
DeMorgan's Laws of compound logical negation
by RS  admin@creationpie.org : 1024 x 640


1. DeMorgan's Laws of compound logical negation

 1   2   3   +   -   ▶ 

DeMorgan's Law for propositional logic (i.e., truth table logic) are from the mid 1800's and named after Augustus De Morgan (1806-1871).

De Morgan tutored (mostly via correspondence) Ada Lovelace, considered the first programmer, in the early 1840's. The Ada programming language, used mostly for government work, is named after Ada Lovelace.

2. Boolean variables
Boolean domain
In computer programming, a Boolean variable, named after George Boole, (e.g., in the C# programming language) can have the following values: true, false, null (not assigned).
In programming language theory notation, the null represents the value, or lack of value, bottom. This value can represent one of the following.

3. DeMorgan's laws
Expression tree for (! (a & b)) = ((! a) | (! b))
a b | ( ! ( a & b ) ) = ( ( ! a ) | ( ! b ) ) --------------------------------------------- 0 0 | ( 1 ( 0 0 0 ) ) 1 ( ( 1 0 ) 1 ( 1 0 ) ) 0 1 | ( 1 ( 0 0 1 ) ) 1 ( ( 1 0 ) 1 ( 0 1 ) ) 1 0 | ( 1 ( 1 0 0 ) ) 1 ( ( 0 1 ) 1 ( 1 0 ) ) 1 1 | ( 0 ( 1 1 1 ) ) 1 ( ( 0 1 ) 0 ( 0 1 ) )

DeMorgan's laws are always useful for reasoning about programs, especially loops and conditional statements. Here is one of DeMorgan's laws.

The extended truth table constitutes a proof of the law since all values under the "=" are 1.

4. DeMorgan's laws
Expression tree for (! (a | b)) = ((! a) & (! b))
a b | ( ! ( a | b ) ) = ( ( ! a ) & ( ! b ) ) --------------------------------------------- 0 0 | ( 1 ( 0 0 0 ) ) 1 ( ( 1 0 ) 1 ( 1 0 ) ) 0 1 | ( 0 ( 0 1 1 ) ) 1 ( ( 1 0 ) 0 ( 0 1 ) ) 1 0 | ( 0 ( 1 1 0 ) ) 1 ( ( 0 1 ) 0 ( 1 0 ) ) 1 1 | ( 0 ( 1 1 1 ) ) 1 ( ( 0 1 ) 0 ( 0 1 ) )

Here is another way to express DeMorgan's laws.

The extended truth table constitutes a proof of the law since all values under the "=" are 1.

5. DeMorgan's laws in code
DeMorgan's laws can be used to flip the then part and else part of an if construct in an algebraic manner. Here are some equivalent ways. All the following code has the same effect (for assigned boolean variables a and b).

Compound conjunction and negated conjunction:
if (a & b) { p2 } else { p1 } if (! (a & b)) { p1 } else { p2 } if ((!a) | (!b)) { p1 } else { p2 }

Compound disjunction and negated disjunction:
if (a | b) { p1 } else { p2 } if (! (a | b)) { p2 } else { p1 } if ((!a) & (!b)) { p2 } else { p1 }


The logical negation in important in understanding and (partial) correctness proving of iteration (e.g., while loops with compound conditions). (omitted)

Many beginning students try to use compound conjunction or disjunction in their programs. This was not allowed in my class since program errors would invariable arise. Note: One gets around this restriction by using nested conditional statements that make the logic much more clear.

6. Jesus and logic
Would Jesus ever use logic such as DeMorgan's laws of logical negation of compound logical expressions?

Would one need to understand such logic to fully understand what Jesus is saying?

Without the logical rules it is hard to not make an error in meaning.

Perhaps one should lean or lift up their own cleverness or wisdom in deciding, based on their own opinion or the opinion of others, as a tradition, what a given saying of Jesus means.

7. Proverbs 3:5 Mammon
Proverbs 3:5 Trust in the LORD with all thine heart; and lean not unto thine own understanding. [kjv]
ισθι πεποιθως εν ολη καρδια επι θεω επι δε ση σοφια μη επαιρου [lxx]

The Greek word translated as "trust" is that of "persuasion" or "belief", sometimes translated as "faith". The "your" is not in the LXX (Septuagint). The LXX uses the word "God" rather than "Lord".

Where the KJV (King James Version), from the Hebrew, uses "understanding", the LXX uses the ancient Greek word "σοφός""clever, cunning" and is often translated as the English word "wise". Jesus does not use the word "wise" in a good sense.

LXX: ... but on your cleverness/cunning (do) not lift up. As such, Proverbs 3:5 appears to address part of the expanded idea of "mammon".

Information sign More: A prudent approach to a wise understanding
Information sign More: Matthew 6:24 A wealth of logical ideas on mammon
Information sign More: Proverbs 3:1-35

8. Matthew 6:20 Neither nor
Matthew 6:20 But lay up for yourselves treasures in heaven, where neither moth nor rust doth corrupt, and where thieves do not break through nor steal: [kjv]
θησαυριζετε δε υμιν θησαυρους εν ουρανω οπου ουτε σης ουτε βρωσις αφανιζει και οπου κλεπται ου διορυσσουσιν ουδε κλεπτουσιν [gnt]

The following are equivalent and can be related using DeMorgan's Law (from the mid 1800's). The Greek words "και""and" and "η""or".

Logic Mail delivery Greek
neither A nor B neither rain nor snow ουτε A ουτε B ...
not (A or B) not  ( rain or snow ) ου (A η B) ...
(not A) and (not B) (not  rain) and (not snow) (ου A) και (ου B) ...

A negation analysis can now be done.

Information sign More: Matthew 6:19-21: A treasury of treasures of which to treasure

9. Matthew 6:19 Negation analysis
Matthew 6:19 Lay not up for yourselves treasures upon earth, where moth and rust doth corrupt, and where thieves break through and steal: [kjv]
μη θησαυριζετε υμιν θησαυρους επι της γης οπου σης και βρωσις αφανιζει και οπου κλεπται διορυσσουσιν και κλεπτουσιν [gnt]


10. Logical negation analysis of Matthew 6:20
Assume the pronoun "you" refers to "fasting" as in "not eating". Let the "food" be the "bread" of "life". Do not eat the fruit! Do not feed the birds!

6:19: "Treasure" on earth: (you opened the tunnel) 6:20: "Treasure" In heaven: (you closed the tunnel)

11. Matthew 12:32 Neither nor
Matthew 12:32 neither in this world, neither in the world to come. [kjv]
ουτε εν τουτω τω αιωνι ουτε εν τω μελλοντι [gnt]

What is meant when one says "neither" followed by "nor"? Is there any overlap between X and Y in English? That is, are the two alternatives mutually exclusive? In general not, but what about the translations of this verse?

Information sign More: Matthew 12:30-37 Pardon the idle word counting - new

12. Matthew 12:32 Parallelism
Matthew 12:32 And who soever speaketh a word against the Son of man, it shall be forgiven him: but who soever speaketh against the Holy Ghost, it shall not be forgiven him, neither in this world, neither in the world to come. [kjv]
και ος εαν ειπη λογον κατα του υιου του ανθρωπου αφεθησεται αυτω ος δ αν ειπη κατα του πνευματος του αγιου ουκ αφεθησεται αυτω ουτε εν τουτω τω αιωνι ουτε εν τω μελλοντι [gnt]

With the play on word inferences, a parallelism becomes more clear.

Now: Whoever if speaks reasoning against the Son of Man (Jesus) it will be forgiven (now). Neither in this age [Jonah, Messiah, Jesus] (now)
Future: Whoever if speaks against the Holy Spirit it will not be forgiven (future) Neither in the future (thereafter)


Information sign More: Matthew 12:30-37 Pardon the idle word counting - new

13. Observations in Matthew
Matthew 5:29 And if thy right eye offend thee, pluck it out, and cast it from thee: for it is profitable for thee that one of thy members should perish, and not that thy whole body should be cast into hell. [kjv]
18:9 And if thine eye offend thee, pluck it out, and cast it from thee: it is better for thee to enter into life with one eye, rather than having two eyes to be cast into hell fire. [kjv]

The similarities become apparent with the following transformations.

14. Matthew 18:9 Questions and statements
Matthew 18:9 And if thine eye offend thee, pluck it out, and cast it from thee: it is better for thee to enter into life with one eye, rather than having two eyes to be cast into hell fire. [kjv]
και ει ο οφθαλμος σου σκανδαλιζει σε εξελε αυτον και βαλε απο σου καλον σοι εστιν μονοφθαλμον εις την ζωην εισελθειν η δυο οφθαλμους εχοντα βληθηναι εις την γεενναν του πυρος [gnt]

Question mark
English has ways to unambiguously express a question. In many languages, including Greek, a statement and a question are written in exactly the same way.
To make a statement a question, one raises the voice at the end of the statement. These non-written hints are not in the Greek text.

Greek word order: ... good (for/to) you is one-eye into the life go ...

This part of the verse can be either a statement or a question. Traditional translations have assumed that it is a statement.

Information sign More: Questionable statements
Information sign More: Pluck out and cut off in Matthew related

15. Matthew 18:9 Rather than
Matthew 18:9 And if thine eye offend thee, pluck it out, and cast it from thee: it is better for thee to enter into life with one eye, rather than having two eyes to be cast into hell fire. [kjv]
και ει ο οφθαλμος σου σκανδαλιζει σε εξελε αυτον και βαλε απο σου καλον σοι εστιν μονοφθαλμον εις την ζωην εισελθειν η δυο οφθαλμους εχοντα βληθηναι εις την γεενναν του πυρος [gnt]

What Jesus says can be either a statement or a question. To make it a statement, the Greek word for "or" needs to be translated as "rather than".

The ancient Greek word "μᾶλλον""rather" as in "rather than". This word is used 8 times by Jesus in Matthew. If Jesus had meant to say "rather than", he had the word to say that. Instead, he said "or".

The modern Greek word "μάλλον" (MAL-lon) ≈ "rather, more precisely".

Information sign More: Pluck out and cut off in Matthew related

16. Matthew 18:9 Question and answer
Matthew 18:9 And if thine eye offend thee, pluck it out, and cast it from thee: it is better for thee to enter into life with one eye, rather than having two eyes to be cast into hell fire. [kjv]
και ει ο οφθαλμος σου σκανδαλιζει σε εξελε αυτον και βαλε απο σου καλον σοι εστιν μονοφθαλμον εις την ζωην εισελθειν η δυο οφθαλμους εχοντα βληθηναι εις την γεενναν του πυρος [gnt]

Consider the second part of the verse. To support the first alternative being "better" rather than "good" the word for "or" is translated as "rather than". Let us now look at Matthew 5:29.

Information sign More: Questionable statements
Information sign More: Pluck out and cut off in Matthew related

17. Matthew 5:29 Question and answer
Matthew 5:29 And if thy right eye offend thee, pluck it out, and cast it from thee: for it is profitable for thee that one of thy members should perish, and not that thy whole body should be cast into hell. [kjv]
ει δε ο οφθαλμος σου ο δεξιος σκανδαλιζει σε εξελε αυτον και βαλε απο σου συμφερει γαρ σοι ινα αποληται εν των μελων σου και μη ολον το σωμα σου βληθη εις γεενναν [gnt]

The word translated as "profitable" means "carry together" and is used by Jesus to say "carry these two (nearby) ideas together". Consider the second part of the verse.

18. Matthew 5:29 Question and answer
Matthew 5:29 And if thy right eye offend thee, pluck it out, and cast it from thee: for it is profitable for thee that one of thy members should perish, and not that thy whole body should be cast into hell. [kjv]
ει δε ο οφθαλμος σου ο δεξιος σκανδαλιζει σε εξελε αυτον και βαλε απο σου συμφερει γαρ σοι ινα αποληται εν των μελων σου και μη ολον το σωμα σου βληθη εις γεενναν [gnt]

To support the first alternative being "profitable" the word for "carry together" is translated that way.

19. Rewrite
Simplified expressions: By DeMorgan's Law for propositional logic (i.e., truth table logic), from the mid 1800's, these are opposites. This can be useful for showing both sides of a conditional probability. In neither case is Jesus making a value judgment as to which is "better" or "expedient". It should be clear which is more "better" or "expedient" but that is implied and left to be inferred and not stated unequivocally.

Information sign More: Pluck out and cut off in Matthew related

20. Equivalence of the verses
Matthew 5:29 And if thy right eye offend thee, pluck it out, and cast it from thee: for it is profitable for thee that one of thy members should perish, and not that thy whole body should be cast into hell. [kjv]

18:9 And if thine eye offend thee, pluck it out, and cast it from thee: it is better for thee to enter into life with one eye, rather than having two eyes to be cast into hell fire. [kjv]

Though not apparent without logical analysis, the following parts of the above verses are opposites. Simplified expressions that say the same thing.

21. End of page

by RS  admin@creationpie.org : 1024 x 640