What is propositional logic?
Propositional logic is a branch of mathematical logic. It is defined as the logical relationships between propositions (or statements, sentences, assertions) taken as a whole, and connected through logical connectives. Propositional logic is also known as propositional calculus, statement logic, sentential calculus, sentential logic, and can even be called zeroth-order logic.
Propositional logic application is the simplest and most abstract logic.
Propositions in propositional logic are statements that taken in their entirety are either true or false. They cannot be both true as well as false. These propositions are represented by symbols or letters whose relationship with other statements is defined by making use of a set of symbols (also known as connectives). The statement is described by its truth value (this is either true or it is false). A truth value of 1 shows that the statement is true, while a truth value of 0 shows that the proposition is false.
In contrast to syllogistic logic, propositional logic takes the statements in their entirety, tends to represent them by a symbol, and is only concerned with whether the statement is true or false, not not the individual terms in the statement.
By convention, a proposition will be represented by an uppercase letter, usually in boldface. So, the letter A could represent a proposition.
What is an atomic proposition?
Atomic propositions are the smallest set of propositions. An atomic proposition is a proposition whose truth or falsity does not depend on the truth or falsity of any other proposition.
What are the properties of propositional logic?
Satisfiable
An atomic propositional formula can be considered satisfiable if an interpretation exists for which it is true.
Tautology
A propositional formula is valid or a tautology only if it holds true for every possible interpretation.
Contradiction
A propositional formula is considered to be contradictory or unsatisfiable if there no interpretation exists for which it is true.
Contingent
It is possible for a propositional logic to be contingent. This basically means that it can be neither a tautology nor a contradiction.
Why is propositional logic important?
Propositional logic is rather important because it is used for the purpose of developing rather powerful search algorithms including implementation methods.
It is also important because of its wide usage in artificial intelligence for planning, problem-solving, intelligent control and for decision-making.
What is a truth table?
A truth table is a technique that you could use for visualizing the truth values of propositions. This technique is employed to clarify the meaning of a proposition or a connective.
As mentioned earlier, if the value is true, it is represented by a “1” and if the value is false, it is represented by a “0”.
Let’s take an example. Consider these propositions:
- A: James wears a white shirt.
- B: James has a cat.
- C: James wears a white shirt and James has a cat.
Here are the truth values for proposition C:
If James does not wear a white shirt and does not have a cat, proposition C is false.
If James does not wear a white shirt but has a cat, proposition C is false.
If James wears a white shirt but does not have a cat, proposition C is false.
If James wears a white shirt and has a cat, proposition C is true.
When you represent this in a truth table, you will have one row for each of those statements (including every possible combination of James wearing a white shirt and/or having a cat). Every column represents the possible states for each of the propositions A, B, and C.
Here is how those four statements would be represented in a truth table:
A
B
C = A ∧ B
0
0
0
0
1
0
1
0
0
1
1
1
What are the types of connectives in propositional logic?
When it comes to propositional logic, connectives are essentially logical symbols expressing relationships between propositions. Logical connectives are also known as logical operators. They are the logical operators that connect sentences.
There are five types of logical connectives in propositional logic. They are:
- Negation
- Conjunction (AND)
- Disjunction (Inclusive OR)
- Conditional (Implication)
- Biconditional (Double implication)
Negation
This is a unary logical connective. For a proposition A, the negation of A would be denoted ¬A. This is a proposition that implies that A is false. ¬A could be read as “not” A.
The truth table for negation is like this
A
¬A
1
0
0
1
Conjunction
This is a binary logical connective. Logical conjunction will assign a value of true only if both the propositions that it relates are true.
Here is the truth table for conjunction:
A
B
A ∧ B
0
0
0
0
1
0
1
0
0
1
1
1
Disjunction
This is an associative binary logical connective. Logical disjunction will assign the value of true if either of the propositions that it relates are true. This is the inclusive definition of disjunction. Do not confuse this with the exclusive form that is equivalent to an “XOR” gate in computer logic.
Here is the truth table for disjunction:
A
B
A ∨ B
0
0
0
0
1
1
1
0
1
1
1
1
Conditional
This is the equivalent of the expression “If A then B”. The result will be true if it is consistent with that statement. It will only be inconsistent if B is false while A is true. That situation would contradict the original statement.
Here is the truth table for conditional:
A
B
A → B
0
0
1
0
1
1
1
0
0
1
1
1
Biconditional
This is a connective representing the condition “if and only if”. A biconditional checks whether both the propositions evaluate to the same truth value. You can look at a biconditional as (A → B) ∧ (B → A).
The truth table for biconditional is:
A
B
A ↔ B
0
0
1
0
1
0
1
0
0
1
1
1
What are the applications of propositional logic in computer science and AI?
Propositional logic has various applications in computer science. These include, but are not limited to, designing computing machines, artificial intelligence, defining data structures for programming languages, etc.