Logic question

Every single book on logic that i read gives the introduction of logical disjunction in the form of a truth table, i know how it works, i know it makes sense intuitively, but where did it came from? There isn't a logical explanation of the logical disjunction, it just explain as a given like an angel came from the heavens and gave us the truth table.

Other urls found in this thread:

programming.dojo.net.nz/study/truth-table-generator/index
sciencedirect.com/science/article/pii/S0003347207002126
twitter.com/NSFWRedditImage

The truth table is just an easy way to consider all possible outcomes, you are studying a formal language now, don't read your book to see what the author says but pay attention and decide if you agree or not, when it comes to logic the people that made it had the same resources as you, there's nothing else to it, it's a human construction, so it's bound to the same limitations you and I have, don't treat it as something perfect but as a way for us to explain and communicate with eachother about the world around us

Just think of it as A and/or B. As long as at least one is true then A and/or B is true.

>disjunction
>V

cancer

There's 16 unique boolean functions of two boolean variables. We just happened to name that one disjunction and give it a V symbol.

Doesn't matter beyond that.

I have no idea what you're asking. It came from the use of the word in language and codified it. Truth tables are a relatively recent creation.

For four possible base-2 outputs there are 2^4 possible binary operations and OR is just one of these. In practice we don't consider all 2^4 operations unique but instead consider some of them as combinations of other operations, depending on context sometimes very few operations.

Is it a human construction?

as i said i know how it works and i get it intuitively, i just don't know where it is grounded.

AND : both are true is true otherwise false
OR : either is true or otherwise false when both are false
XOR : exclusively either is true or otherwise false
a if b = a b : b better be true if a otherwise true if a is false
a iff b = a b : a and b have the same truth value
NOT a : the opposite

thanks user but i know how it works, but i have trouble about it's foundations, or why disjunction is what it is.

this is gay theory

The logic you see here stems from philosophical logic.

>why disjunction is what it is.
"this seat is reserved for the disabled OR pregnant"

It is grounded in the fact that humans use the word "or" a lot and mathematicians wanted to formalize it's meaning.

so its grounded on language

its or it's

it's

Itsa Me Mario

Well they didn't do a good job. They should have made OR mean "exclusive or" and made up another term to refer to "inclusive or". Because of that now we've got a fuckton of these programmer-tier jokes:
>do you want rice or pasta
>yes

It's based off the powers of two.

If you have a truth table of N inputs, the OR will be false only on the 2^N-1 th output.

You don't necessarily have to define OR in terms of a truth table. You can define it in terms of other operators, instead.

You do need to define at least one Boolean operator using something like a truth table, however. By choosing carefully, you can then define the other Boolean operators in terms of that operator.

For example, one operator that can be used as a basis for all other Boolean operators is NAND. NAND can be specified via truth table, and then OR can be defined in terms of NAND as follows:

(X OR Y) = (X NAND X) NAND (Y NAND Y)

From this definition, and the truth table for NAND, you can derive the truth table for OR.

nor does the trick too

i didn't get it.

Yep, the equivalence of NAND and NOR as a basis can be shown by expressing each in terms of the other, as follows:

X NAND Y = ((X NOR X) NOR (Y NOR Y)) NOR ((X NOR X) NOR (Y NOR Y))

Y NOR Y = ((X NAND X) NAND (Y NAND Y)) NAND ((X NAND X) NAND (Y NAND Y))

Writing a logic statement in a program:
>bool1 = wants_pasta or wants_rice
bool1 will be True if either wants_past is True or if wants_rice is True, or both. An OR statement like that returns a yes or no answer depending on the two statements within the OR statement, when in the english language the answer you'd expect would be "rice" or "pasta".

But in both cases, inclusive and exclusive, you could use yes as a reply.

thats why i didn't get it

Hey OP I know you understand the operations involved in boolean operations.

I think the OR came about because of Aristotelian logic.

So Aristotle came about and started the field of logic offically.
This started with existentials, and groups of things.
See the famous:
All Men are mortal
Socrates is a man
Socrates is mortal.

this used operators like all, some, not.
I think after awhile. You gain mastery of these things, use the star test to find validity.
Then George Boole said he was going to take Aristotle's Logic further. according to the Wiki Boole applied arithmetic to logic and come up with the operators. OR, AND, and If/then.

t. agricultural engineer

Logical disjunction and all the other standard connectives are motivated by our use of their respective words in natural language.
You arrive at disjunction by analyzing how we use A or B, where A and B are propositions. Of course this fails to capture all the ways in which we use these words, here's an example from Wilfrid Hodges chapter on the Handbook of Philosophical Logic.
For a quick read look at the chapter on propositional logic in "The Handbook of Philosophical Logic Volume 1". "I heard a shot and I saw the girl fall" here we can see that "and" also is expressing a temporal concept, namely that he heard and shot AND THEN saw the girl fall. All this to say that these connectives don't necessarily correspond exactly to our use of their corresponding natural language words but their definitions are motivated by them, gtg late 4 bus now
"Those who can't into X complain about notation"

Thanks so much.

[math]
\overline{XY}= \overline{ \overline{ \overline{X+X}+ \overline{Y+Y}}+ \overline{ \overline{X+X}+ \overline{Y+Y}}}
\\
\overline{X+Y}= \overline{ \overline{ \overline{XX} \: \overline{YY}} \: \overline{ \overline{XX} \; \overline{YY}}}
[/math]

(X OR Y) = (¬Y => X)

(X OR Y) = (¬X => Y)

( X | Y ) ( ~ Y -> X ) ( ~ X -> Y )

programming.dojo.net.nz/study/truth-table-generator/index

There is a similar problem with "and":
"Students and pensioners pay half."
Would mean you have to be a student and a pensioner at the same time to pay half.
Conclusion: Don't mess up meta-language and object-language!

There are [math]2^2^n[/math] boolean functions [math] f: \{0,1\}^n \to \{0,1\} [/math]. This is just one of them for n=2 and we call it "or". Don't interpret to much, it's just a fomalism.

The rarely-mentioned "implies" gate will also work.

0 IMP 0 = 1
0 IMP 1 = 1
1 IMP 0 = 0
1 IMP 1 = 1

NAND, NOR, and IMPLIES all have an "asymmetrical" output pattern, making them universal.

Ah, I thought you didn't get the joke.

If we used OR to refer to "exclusive or" in programming and math, then we'd (almost) never use the term OR in programming or math, and so wouldn't get jokes about it. Be honest, when was the last time you seriously used an "exclusive or" function for logic?

>*

literally shit, use cdot

>intuitive
it's defined that way

then logic is a meme

What about using + for XOR, like in F2?

The fuck? If they used xor the answer would still be "yes", the problem is giving a boolean answer instead of selecting an element from the provided set.

I think its more about understanding than language (since dogs are able to use logic too) our understsnding is not perfect nor always correct, but by studying it we can get a lot better at it

source: sciencedirect.com/science/article/pii/S0003347207002126

see

language is about understanding

There are two aspects to the disjunction that you can consider: its structure and its interpretation. Structurally it is a binary operator where the inputs and outputs come from the same set that has a cardinality of two. It just so happens that the human idea of the word "or" seems have an intimate relationship with this structure when the inputs and outputs are interpreted to be the truth values of propositions.

When the angel came from heaven it entered a darkened room with two switches: A and B. When it flipped A the room was lit, flipped B the room was lit, flipped A and B the room was lit. Flipped neither, darkness.

k

I feel you, logic seems more than real sometimes

disgusting

There's a lot of different ways to view logic, each giving you a slightly different answer as to why it should be that way. Here's a nice one sort of motivated by topos theory: take any singleton, thought of as an event. The powerset of this set can be thought of as a set of truth values - emptyset being false, the whole set being true. Conj is intersection, disj is union. This lattice induces a Heyting algebra structure, giving implication, and then finally negation from x-->false.

The operator is defined that way

More abstractly, in a poset category, completeness is the same thing as being a complete lattice. Conj is the product, disj the coproduct, implication the exponent (right adjoint of conjunction), and negation of x is the value of x-->0.

In other words, if you are comfortable assuming that products are interesting, coproducts are the opposite, and implication is an adjoint of it, so everything can be sort of built off of them.

This is pretty much the same as the example above.

>Using logic notation for logic is "retard tier"
>Using Math, CS or Engineer notation for logic is not
B R A I N L E T

It doesn't make sense to call it "or" without the interpretation. Considered purely as a function, "and" has the same graph as or.

Because the overscore == NOT means you can have multiple NOTs over the same expression without having to put a fuckton of brackets. Especially useful when messing about with De Morgan's theorem or any time you have plenty of universal gates. It also makes algebra more intuitive as PEMDAS applies to the +, * signs.

typical pythonista, complain about simple brackets and replace them with brand new syntax to be learned, thinking this is "simpler"

Well I never said simpler, just better. It's more no simpler or more complex by hand, and is a pain to type out, but it takes less space. When you're expanding bracket by bracket and every damn expression has "–()" out the front, you have to trace each bracket to figure out what is under it and what isn't. Like why we prefer to use a square root sign to a "^1/2", it easily shows what it encompasses.

yeah such a no brainer