Tsar_Maple
Well-known member
- Joined
- May 24, 2012
- Messages
- 673
- Thread Author
- #1
Hey everyone! So this semester, one of my Computer Science classes is 1610 Discrete Mathematics, which is logic-based reasoning. This means deducing things using true or false. I recently discovered that the applications of discrete mathematics can be visualized in Minecraft using logic gates, which didn't make any sense to me before I started this course!
Logic uses a few terms such as AND, OR, and XOR. Each term has different properties associated with it.
So, with that said, I'm going to be showing you guys that don't do much redstone what a simple logic gate is, using an OR gate. OR gates are True if one or both inputs are True (turned on). If both inputs are false, the output will be false (turned off).
In discrete mathematics, we use what's called a truth table to visualize this.
[table="width: 500, class: grid, align: center"]
[tr]
[td]A[/td]
[td]True[/td]
[td]True[/td]
[td]False[/td]
[td]False[/td]
[/tr]
[tr]
[td]B[/td]
[td]True[/td]
[td]False[/td]
[td]True[/td]
[td]False[/td]
[/tr]
[tr]
[td]A OR B[/td]
[td]True[/td]
[td]True[/td]
[td]True[/td]
[td]False[/td]
[/tr]
[/table]
(The alignment is usually oriented differently, as you'll see in a bit. Too lazy to make it super pretty, but the table is still correct)
So, I wanted to test this out for myself. I built my truth table...
...and then built a simple proof-of-concept. If the redstone lamp is on, then the output is True. If it's off, the output is False.
These concepts are kinda key to many redstone works. AND gates are useful for locking doors (AND requires both inputs to be True, so if you had a door that had a switch on the interior and a pressure plate on the exterior, the switch would need to be On (True) in order for the door to open when the pressure plate is pressed).
I'm still learning a lot about Logic implementations in Minecraft, but if y'all found this interesting, lemme know and I'll post more! Also, if you've got questions, I'll answer those too
Logic uses a few terms such as AND, OR, and XOR. Each term has different properties associated with it.
So, with that said, I'm going to be showing you guys that don't do much redstone what a simple logic gate is, using an OR gate. OR gates are True if one or both inputs are True (turned on). If both inputs are false, the output will be false (turned off).
In discrete mathematics, we use what's called a truth table to visualize this.
[table="width: 500, class: grid, align: center"]
[tr]
[td]A[/td]
[td]True[/td]
[td]True[/td]
[td]False[/td]
[td]False[/td]
[/tr]
[tr]
[td]B[/td]
[td]True[/td]
[td]False[/td]
[td]True[/td]
[td]False[/td]
[/tr]
[tr]
[td]A OR B[/td]
[td]True[/td]
[td]True[/td]
[td]True[/td]
[td]False[/td]
[/tr]
[/table]
(The alignment is usually oriented differently, as you'll see in a bit. Too lazy to make it super pretty, but the table is still correct)
So, I wanted to test this out for myself. I built my truth table...
Truth table:

...and then built a simple proof-of-concept. If the redstone lamp is on, then the output is True. If it's off, the output is False.
True OR True
True OR False
False OR True
False OR False

True OR False

False OR True

False OR False

These concepts are kinda key to many redstone works. AND gates are useful for locking doors (AND requires both inputs to be True, so if you had a door that had a switch on the interior and a pressure plate on the exterior, the switch would need to be On (True) in order for the door to open when the pressure plate is pressed).
I'm still learning a lot about Logic implementations in Minecraft, but if y'all found this interesting, lemme know and I'll post more! Also, if you've got questions, I'll answer those too
