# 23.1 Introduction

At first sight, logic can be confusing. A lot of this is because it can be quite abstract (well, at least it can feel abstract compared to things such as algebra 11 1 Not abstract algebra!). The key thing (in my view) to understand is that logic is well-defined; there is a strict set of rules according to which logical expressions can be manipulated, much like there is with "normal" algebra.

For example, consider this well-known fact about any $x\in\mathbb{R}$ and addition

$x+0=x$ (23.1)

There are some analogous rules for logical expressions. However, instead of a whole series of numbers, in logic every value is in the set $\mathbb{B}=\{T,F\}$ - i.e. it is either \saytrue or \sayfalse. We can define an "operator" (i.e. something which takes two values and outputs a new one, just like the familiar addition operator). For example, let us create a new operator $\land$. We can define the result of $A\land B$ by considering what happens in every case

• If both values are true, i.e. $T\land T$, then the output is also true.

• If one value is true and the other is false, i.e. $T\land F$ or $F\land T$ then the output is false.

• In the other case (i.e. $F\land F$) then the output is false.

Based on this definition (which corresponds to a logical operator known as \saylogical and, so named because the output is true whenever both inputs are $T$ and false in every other case) we can determine a similar relationship. Specifically,

$T\land A\equiv A$ (23.2)

Hopefully this makes intuitive sense, but first we need to define $A$! It’s a variable, just like $x$ was above - i.e. it can be anything we want, so long as it is a boolean (whereas $x$ can be anything we want, so long as it is a real number). If $A$ is true, then as $T\land T=T$ $T\land A=A$ in this case, and if $A$ is false, then as $T\land F=F$ for this case $T\land A=A$.

This is logic which is generally useful in other areas of mathematics.