Questions about some relational operator definitions and comments about the DIVIDEBY operation
Quote from dandl on March 25, 2020, 11:09 pmDandl, you correctly anticipate where I was leading.
I don't think Erwin saw it coming.
Regarding the FORALL x(exp): Both the Small Divide and Codd's divide satisfy the quantifier. Codd's divide satisifies it with the suppliers who supply parts (IE. per the predicate: the suppliers in relation SP). The Small Divide satisfies it with the suppliers in relation S. I am not saying that one is more 'right' than the other.
DTATRM says:
By contrast, the following expression (which involves a Small Divide) is guaranteed
to give the right answer in all cases:But I'm in your camp. I've never been happy with language such as used by D&D, that contains all kinds of implicit assumptions and decorations. The query is ambiguous. There is no 'right answer'. My view: first improve the English, to make it clear which sense is intended. If lack of purple parts is a possibility, then make it clear in the query whether you expect to see all suppliers or none.
It seems to me that this belongs in the same camp as the Barber paradox and the average of an empty set. Everything works fine if there are purple parts, the town has a barber and the set contains at least one member. If not, TILT! And you need to deal with it.
Dandl, you correctly anticipate where I was leading.
I don't think Erwin saw it coming.
Regarding the FORALL x(exp): Both the Small Divide and Codd's divide satisfy the quantifier. Codd's divide satisifies it with the suppliers who supply parts (IE. per the predicate: the suppliers in relation SP). The Small Divide satisfies it with the suppliers in relation S. I am not saying that one is more 'right' than the other.
DTATRM says:
By contrast, the following expression (which involves a Small Divide) is guaranteed
to give the right answer in all cases:
But I'm in your camp. I've never been happy with language such as used by D&D, that contains all kinds of implicit assumptions and decorations. The query is ambiguous. There is no 'right answer'. My view: first improve the English, to make it clear which sense is intended. If lack of purple parts is a possibility, then make it clear in the query whether you expect to see all suppliers or none.
It seems to me that this belongs in the same camp as the Barber paradox and the average of an empty set. Everything works fine if there are purple parts, the town has a barber and the set contains at least one member. If not, TILT! And you need to deal with it.
Quote from Greg Klisch on March 26, 2020, 12:53 amQuote from dandl on March 25, 2020, 11:09 pmDandl, you correctly anticipate where I was leading.
I don't think Erwin saw it coming.
Regarding the FORALL x(exp): Both the Small Divide and Codd's divide satisfy the quantifier. Codd's divide satisifies it with the suppliers who supply parts (IE. per the predicate: the suppliers in relation SP). The Small Divide satisfies it with the suppliers in relation S. I am not saying that one is more 'right' than the other.
DTATRM says:
By contrast, the following expression (which involves a Small Divide) is guaranteed
to give the right answer in all cases:But I'm in your camp. I've never been happy with language such as used by D&D, that contains all kinds of implicit assumptions and decorations. The query is ambiguous. There is no 'right answer'. My view: first improve the English, to make it clear which sense is intended. If lack of purple parts is a possibility, then make it clear in the query whether you expect to see all suppliers or none.
It seems to me that this belongs in the same camp as the Barber paradox and the average of an empty set. Everything works fine if there are purple parts, the town has a barber and the set contains at least one member. If not, TILT! And you need to deal with it.
I believe the criticism by D&D that Codd's divide does not handle the case of an empty set for parts was due to a mistake in their handling of the RESTRICT operation. They got an answer of {S1,S2,S3,S4} because there were tuples in SP for those suppliers when the last MINUS was executed. Their error, as I see it, is that they failed to apply the RESTRICT operation to the parts in SP as well as to the parts in P. If they had applied the RESTRICTion to all the relations containing parts (i.e.: to both 'sides of the equation' as it were) they would have gotten an answer of {} for the set of suppliers. Instead they added relation S to the implementation to ensure they got all suppliers when what was needed was to get rid of the non-relevant tuples from SP. They also unnecessarily [in my opinion] carried relation S forward into some of their examples when they introduced the image relation operator. To summarize: in my opinion the error was not in Codd's divide but an incomplete application of the RESTRICT operation in attempt to show it didn't handle the case of 'no parts at all'.
Quote from dandl on March 25, 2020, 11:09 pmDandl, you correctly anticipate where I was leading.
I don't think Erwin saw it coming.
Regarding the FORALL x(exp): Both the Small Divide and Codd's divide satisfy the quantifier. Codd's divide satisifies it with the suppliers who supply parts (IE. per the predicate: the suppliers in relation SP). The Small Divide satisfies it with the suppliers in relation S. I am not saying that one is more 'right' than the other.
DTATRM says:
By contrast, the following expression (which involves a Small Divide) is guaranteed
to give the right answer in all cases:But I'm in your camp. I've never been happy with language such as used by D&D, that contains all kinds of implicit assumptions and decorations. The query is ambiguous. There is no 'right answer'. My view: first improve the English, to make it clear which sense is intended. If lack of purple parts is a possibility, then make it clear in the query whether you expect to see all suppliers or none.
It seems to me that this belongs in the same camp as the Barber paradox and the average of an empty set. Everything works fine if there are purple parts, the town has a barber and the set contains at least one member. If not, TILT! And you need to deal with it.
I believe the criticism by D&D that Codd's divide does not handle the case of an empty set for parts was due to a mistake in their handling of the RESTRICT operation. They got an answer of {S1,S2,S3,S4} because there were tuples in SP for those suppliers when the last MINUS was executed. Their error, as I see it, is that they failed to apply the RESTRICT operation to the parts in SP as well as to the parts in P. If they had applied the RESTRICTion to all the relations containing parts (i.e.: to both 'sides of the equation' as it were) they would have gotten an answer of {} for the set of suppliers. Instead they added relation S to the implementation to ensure they got all suppliers when what was needed was to get rid of the non-relevant tuples from SP. They also unnecessarily [in my opinion] carried relation S forward into some of their examples when they introduced the image relation operator. To summarize: in my opinion the error was not in Codd's divide but an incomplete application of the RESTRICT operation in attempt to show it didn't handle the case of 'no parts at all'.
Quote from Erwin on March 26, 2020, 11:50 amQuote from Greg Klisch on March 25, 2020, 10:25 pmQuote from Erwin on March 25, 2020, 10:09 pmQuote from Greg Klisch on March 25, 2020, 7:33 pmThe premises are:
a) If a supplier s supplies a part p then there will be a tuple {s,p,..} in relation SP. This premise follows directly from the predicate for SP.
b) If there is not a tuple for {s,p,...} in relation SP then supplier s does not supply that part p. This follows from the predicate for SP as well as from the CWA.
c) There is is a tuple for {s,p,..} if and only if supplier s supplies part p. This follows from a) and b).
It follows from c) that if s supplies a purple part p then there would be a tuple {s,p,...} in SP for that pair of attributes. There is not such a pair.
Logic error.
Mathematical convention says that FORALL x : P(x) ===== NOT EXISTS x : NOT P(x)
The consequence is that if `NOT EXISTS <some hypothetical purple part>` is true in and of itself, then surely any further restriction ("such that <some given supplier> does _NOT_ supply that purple part") of that empty set will be empty too, so it will have no members, so the `NOT EXISTS` is indeed true, and for the tautology expressed in the equation above, it means that the FORALL must be true.
Get it out of your head that stating a universal quantification _presumes_ the very existence of at least one `x` in the first place. It does not.
Not so long ago I was pointed to a paper "the traditional square of opposition". It explains the views that have been held about this issue throughout the centuries ever since Aristofocles (sorry), and the key phrase to remember from that doc went something like "If you ***want*** to make that presumption of the very existence of at least one `x` [as a precondition for your universal quantification to be true], then the device of logic per se can ***easily*** express this by saying FORALL x : P(x) ===== NOT EXISTS x : NOT P(x) *** & EXISTS x ***. It's not a problem of logic per se.". It's a problem of being precise about expressing what your presumptions are. (And the derived ensuing problem is one of the lengths of the resulting logical formulae and possibility of the "& EXISTS x" part leading to combinatorial explosion of cases if we find we have to apply laws of distributivity of logical AND and OR.)
I'm not sure what I said to make you think that I was presuming that universal qualification required at least one 'x'. I don't think that. What I was awkwardly attempting to say was that all of the suppliers in SP (after the RESTRICT operation left no suppliers) actually supplied all of the P(x) which, of course, was empty.
There are no "suppliers in SP". SP states facts about suppliers supplying some part.
The fact of the matter is just : even if supplier S5 supplies no parts at all, then he must still appear in the answer to the query "get the suppliers who supply all purple parts" in the case where S5 indeed exists and there are indeed no purple parts at all. That is not for you to decide, that is for you to accept and deal with it. Logic says so, period. S5 is a supplier that exists (relvar S says so) and there does not exist any purple part such that S5 does not supply that purple part. So S5 supplies all purple parts. And the ***only*** way to achieve that result is by performing some operation that looks at all three of {S, P, SP}. Have to look at SP because obviously that's where you find whether some given supplier supplies some given part. Have to look at P because obviously that's the place to go to to figure what that set of "all parts" (/"all purple parts") is. And you HAVE TO look at S for the reasons both Date and me (and who knows who else) seem consistently to fail to explain, though not for not trying.
I'm just saying this because your case with PP and SPP ***is a different question***. It appears to be the query "get the suppliers who supply ***some purple part and*** indeed all of them". If what you're after is exposing an "error" in the treatment of some given specific case, then it is no use to come up with a ***different*** case.
I'm also a bit uncertain whose English it is that [you think] needs "get fixed", but there certainly seems nothing that needs fixing in "get the suppliers who supply all purple parts".
"They added a third relation to the division specifically to support their choice that all suppliers supply non-existent parts." No they didn't. And it was not "their choice". It was a "choice" made by logicians a long time ago. Date and Codd weren't even born and computers existed only in crazy dreams of crazy people. It is explained in that "square of opposition" paper.
And it is not the case that "all suppliers supply non-existent parts". They simply can't. It is only the case that "all suppliers supply ***all*** non-existant parts". That's a ***different*** proposition.
And I suspect you are indeed making one of the "wrong" inferences pointed out by the paper : namely that the non-existence of, say, foobars, makes it impossible for suppliers to "supply all foobars" or "all types of foobar" or whatever. If something doesn't exist, then how can anyone supply all of those somethings ? Right ? Well I'd say go read it here : https://plato.stanford.edu/entries/square/
Quote from Greg Klisch on March 25, 2020, 10:25 pmQuote from Erwin on March 25, 2020, 10:09 pmQuote from Greg Klisch on March 25, 2020, 7:33 pmThe premises are:
a) If a supplier s supplies a part p then there will be a tuple {s,p,..} in relation SP. This premise follows directly from the predicate for SP.
b) If there is not a tuple for {s,p,...} in relation SP then supplier s does not supply that part p. This follows from the predicate for SP as well as from the CWA.
c) There is is a tuple for {s,p,..} if and only if supplier s supplies part p. This follows from a) and b).
It follows from c) that if s supplies a purple part p then there would be a tuple {s,p,...} in SP for that pair of attributes. There is not such a pair.
Logic error.
Mathematical convention says that FORALL x : P(x) ===== NOT EXISTS x : NOT P(x)
The consequence is that if `NOT EXISTS <some hypothetical purple part>` is true in and of itself, then surely any further restriction ("such that <some given supplier> does _NOT_ supply that purple part") of that empty set will be empty too, so it will have no members, so the `NOT EXISTS` is indeed true, and for the tautology expressed in the equation above, it means that the FORALL must be true.
Get it out of your head that stating a universal quantification _presumes_ the very existence of at least one `x` in the first place. It does not.
Not so long ago I was pointed to a paper "the traditional square of opposition". It explains the views that have been held about this issue throughout the centuries ever since Aristofocles (sorry), and the key phrase to remember from that doc went something like "If you ***want*** to make that presumption of the very existence of at least one `x` [as a precondition for your universal quantification to be true], then the device of logic per se can ***easily*** express this by saying FORALL x : P(x) ===== NOT EXISTS x : NOT P(x) *** & EXISTS x ***. It's not a problem of logic per se.". It's a problem of being precise about expressing what your presumptions are. (And the derived ensuing problem is one of the lengths of the resulting logical formulae and possibility of the "& EXISTS x" part leading to combinatorial explosion of cases if we find we have to apply laws of distributivity of logical AND and OR.)
I'm not sure what I said to make you think that I was presuming that universal qualification required at least one 'x'. I don't think that. What I was awkwardly attempting to say was that all of the suppliers in SP (after the RESTRICT operation left no suppliers) actually supplied all of the P(x) which, of course, was empty.
There are no "suppliers in SP". SP states facts about suppliers supplying some part.
The fact of the matter is just : even if supplier S5 supplies no parts at all, then he must still appear in the answer to the query "get the suppliers who supply all purple parts" in the case where S5 indeed exists and there are indeed no purple parts at all. That is not for you to decide, that is for you to accept and deal with it. Logic says so, period. S5 is a supplier that exists (relvar S says so) and there does not exist any purple part such that S5 does not supply that purple part. So S5 supplies all purple parts. And the ***only*** way to achieve that result is by performing some operation that looks at all three of {S, P, SP}. Have to look at SP because obviously that's where you find whether some given supplier supplies some given part. Have to look at P because obviously that's the place to go to to figure what that set of "all parts" (/"all purple parts") is. And you HAVE TO look at S for the reasons both Date and me (and who knows who else) seem consistently to fail to explain, though not for not trying.
I'm just saying this because your case with PP and SPP ***is a different question***. It appears to be the query "get the suppliers who supply ***some purple part and*** indeed all of them". If what you're after is exposing an "error" in the treatment of some given specific case, then it is no use to come up with a ***different*** case.
I'm also a bit uncertain whose English it is that [you think] needs "get fixed", but there certainly seems nothing that needs fixing in "get the suppliers who supply all purple parts".
"They added a third relation to the division specifically to support their choice that all suppliers supply non-existent parts." No they didn't. And it was not "their choice". It was a "choice" made by logicians a long time ago. Date and Codd weren't even born and computers existed only in crazy dreams of crazy people. It is explained in that "square of opposition" paper.
And it is not the case that "all suppliers supply non-existent parts". They simply can't. It is only the case that "all suppliers supply ***all*** non-existant parts". That's a ***different*** proposition.
And I suspect you are indeed making one of the "wrong" inferences pointed out by the paper : namely that the non-existence of, say, foobars, makes it impossible for suppliers to "supply all foobars" or "all types of foobar" or whatever. If something doesn't exist, then how can anyone supply all of those somethings ? Right ? Well I'd say go read it here : https://plato.stanford.edu/entries/square/
Quote from dandl on March 26, 2020, 12:31 pmThe fact of the matter is just : even if supplier S5 supplies no parts at all, then he must still appear in the answer to the query "get the suppliers who supply all purple parts" in the case where S5 indeed exists and there are indeed no purple parts at all.
No, that's not a fact, that's an inference you have drawn.
I'm also a bit uncertain whose English it is that [you think] needs "get fixed", but there certainly seems nothing that needs fixing in "get the suppliers who supply all purple parts".
Ordinary English usage is a bit of a slippery beast, and there is 'many a slip' in converting ordinary English into logic. My expectation of ordinary English is that any supplier you propose in answer to this query must (as a matter of fact) have supplied at least one purple part. No purple parts? Fine, then definitely not a supplier of purple parts, any or all. My guess is that if you told an ordinary English speaker that you have a list of "suppliers who supply all purple parts", and then you told them that none of the suppliers on that list has actually supplied any kind of purple part, and this is all perfectly logical, they would smile politely and write you off as crazy.
And I might even agree. Or not.
The fact of the matter is just : even if supplier S5 supplies no parts at all, then he must still appear in the answer to the query "get the suppliers who supply all purple parts" in the case where S5 indeed exists and there are indeed no purple parts at all.
No, that's not a fact, that's an inference you have drawn.
I'm also a bit uncertain whose English it is that [you think] needs "get fixed", but there certainly seems nothing that needs fixing in "get the suppliers who supply all purple parts".
Ordinary English usage is a bit of a slippery beast, and there is 'many a slip' in converting ordinary English into logic. My expectation of ordinary English is that any supplier you propose in answer to this query must (as a matter of fact) have supplied at least one purple part. No purple parts? Fine, then definitely not a supplier of purple parts, any or all. My guess is that if you told an ordinary English speaker that you have a list of "suppliers who supply all purple parts", and then you told them that none of the suppliers on that list has actually supplied any kind of purple part, and this is all perfectly logical, they would smile politely and write you off as crazy.
And I might even agree. Or not.
Quote from johnwcowan on March 26, 2020, 3:40 pmQuote from Erwin on March 26, 2020, 11:50 amLogic error.The fact of the matter is just : even if supplier S5 supplies no parts at all, then he must still appear in the answer to the query "get the suppliers who supply all purple parts" in the case where S5 indeed exists and there are indeed no purple parts at all. That is not for you to decide, that is for you to accept and deal with it. Logic says so, period.
Logic does not say so, only a simplistic mapping of the natural-language sentence schema "All Ses are Ps" onto the formula ∀x: S(x) → P(x), adequate for formal purposes but not always the real world. If I tell you "Go to Room 101 and bring back all the purple eyeballs there", and you go and find none, then you are far more likely to raise an exception "Sorry, boss, no purple eyeballs" than to report "Okay, boss, here are all zero eyeballs."
Quote from dandl on March 26, 2020, 12:31 pmMy guess is that if you told an ordinary English speaker that you have a list of "suppliers who supply all purple parts", and then you told them that none of the suppliers on that list has actually supplied any kind of purple part, and this is all perfectly logical, they would smile politely and write you off as crazy.
And I might even agree. Or not.
Exactly.
Quote from Erwin on March 26, 2020, 11:50 amLogic error.
The fact of the matter is just : even if supplier S5 supplies no parts at all, then he must still appear in the answer to the query "get the suppliers who supply all purple parts" in the case where S5 indeed exists and there are indeed no purple parts at all. That is not for you to decide, that is for you to accept and deal with it. Logic says so, period.
Logic does not say so, only a simplistic mapping of the natural-language sentence schema "All Ses are Ps" onto the formula ∀x: S(x) → P(x), adequate for formal purposes but not always the real world. If I tell you "Go to Room 101 and bring back all the purple eyeballs there", and you go and find none, then you are far more likely to raise an exception "Sorry, boss, no purple eyeballs" than to report "Okay, boss, here are all zero eyeballs."
Quote from dandl on March 26, 2020, 12:31 pmMy guess is that if you told an ordinary English speaker that you have a list of "suppliers who supply all purple parts", and then you told them that none of the suppliers on that list has actually supplied any kind of purple part, and this is all perfectly logical, they would smile politely and write you off as crazy.
And I might even agree. Or not.
Exactly.
Quote from Erwin on March 26, 2020, 7:35 pmQuote from dandl on March 26, 2020, 12:31 pmthey would smile politely and write you off as crazy.
Etre tenu pour un idiot par un imbécile est un savour de fin gourmet.
And even Blaise Pascal "smiled politely and wrote them off as crazy", the people who proposed an arithmetic with numbers that could be negative. Arguing "I cannot imagine how one could take away 4 things from no things at all and end up with something different than still just no things at all".
Quote from dandl on March 26, 2020, 12:31 pmthey would smile politely and write you off as crazy.
Etre tenu pour un idiot par un imbécile est un savour de fin gourmet.
And even Blaise Pascal "smiled politely and wrote them off as crazy", the people who proposed an arithmetic with numbers that could be negative. Arguing "I cannot imagine how one could take away 4 things from no things at all and end up with something different than still just no things at all".
Quote from johnwcowan on March 26, 2020, 7:50 pm
Quote from Erwin on March 26, 2020, 7:35 pmEtre tenu pour un idiot par un imbécile est un savour de fin gourmet.
O sancta simplicitas!
And even Blaise Pascal "smiled politely and wrote them off as crazy", the people who proposed an arithmetic with numbers that could be negative. Arguing "I cannot imagine how one could take away 4 things from no things at all and end up with something different than still just no things at all".
Pascal was quite right, since the main application for integers in his day was as cardinals. (Mesa, descended from Pascal-the-language, calls its unsigned type CARDINAL.). But if he had talked to his father, the commissioner of taxes in Rouen, he might have understood it better as a matter of monies paid and moneys owing.
Historically, the Chinese had a good grasp on negative numbers by the 3C, and the idea spread to India by the 5C or so ("A debt cut off from nothingness becomes a credit; a credit cut off from nothingness becomes a debt.") The Arabs could state the rules of signed multiplication by the 12C, and Fibonacci was using them too to solve financial problems. By the 15C they were in France and Italy, though referred to as "absurd numbers" (the name is hardly worse than "imaginary numbers", after all). Not until Leibniz did Western mathematicians fully accept them.
Quote from Erwin on March 26, 2020, 7:35 pm
Etre tenu pour un idiot par un imbécile est un savour de fin gourmet.
O sancta simplicitas!
And even Blaise Pascal "smiled politely and wrote them off as crazy", the people who proposed an arithmetic with numbers that could be negative. Arguing "I cannot imagine how one could take away 4 things from no things at all and end up with something different than still just no things at all".
Pascal was quite right, since the main application for integers in his day was as cardinals. (Mesa, descended from Pascal-the-language, calls its unsigned type CARDINAL.). But if he had talked to his father, the commissioner of taxes in Rouen, he might have understood it better as a matter of monies paid and moneys owing.
Historically, the Chinese had a good grasp on negative numbers by the 3C, and the idea spread to India by the 5C or so ("A debt cut off from nothingness becomes a credit; a credit cut off from nothingness becomes a debt.") The Arabs could state the rules of signed multiplication by the 12C, and Fibonacci was using them too to solve financial problems. By the 15C they were in France and Italy, though referred to as "absurd numbers" (the name is hardly worse than "imaginary numbers", after all). Not until Leibniz did Western mathematicians fully accept them.
Quote from Erwin on March 26, 2020, 9:19 pmQuote from johnwcowan on March 26, 2020, 7:50 pmPascal was quite right, since the main application for integers in his day was as cardinals. ... Not until Leibniz did Western mathematicians fully accept them.
At least that goes to show where you end up if you let science be led by what the applicationists think the scientists should do (and it is nothing more than just "solve the main practical problems of their day").
Quote from johnwcowan on March 26, 2020, 7:50 pmPascal was quite right, since the main application for integers in his day was as cardinals. ... Not until Leibniz did Western mathematicians fully accept them.
At least that goes to show where you end up if you let science be led by what the applicationists think the scientists should do (and it is nothing more than just "solve the main practical problems of their day").
Quote from Erwin on March 26, 2020, 9:33 pmQuote from johnwcowan on March 26, 2020, 3:40 pmAll Ses are Ps" onto the formula ∀x: S(x) → P(x), adequate for formal purposes but not always the real world.
The idea that there is any kind of mismatch between "formal purposes" and "the real world" is exactly the supreme prevailing problem of this industry.
Quote from johnwcowan on March 26, 2020, 3:40 pmAll Ses are Ps" onto the formula ∀x: S(x) → P(x), adequate for formal purposes but not always the real world.
The idea that there is any kind of mismatch between "formal purposes" and "the real world" is exactly the supreme prevailing problem of this industry.
Quote from johnwcowan on March 26, 2020, 10:13 pmQuote from Erwin on March 26, 2020, 9:19 pmAt least that goes to show where you end up if you let science be led by what the applicationists think the scientists should do (and it is nothing more than just "solve the main practical problems of their day").
You've probably heard of Pascal's triangle, but perhaps not Pascal's theorem or Pascal's identity? Pascal was not just an applied mathematician, though (as with Leonardo's design of the Swiss Guards' uniform) when he did something, he did it well.
And without Fermat and Pascal, Leibniz's work would probably have come much later, with massive butterfly effects right up to the present.
Quote from Erwin on March 26, 2020, 9:19 pm
At least that goes to show where you end up if you let science be led by what the applicationists think the scientists should do (and it is nothing more than just "solve the main practical problems of their day").
You've probably heard of Pascal's triangle, but perhaps not Pascal's theorem or Pascal's identity? Pascal was not just an applied mathematician, though (as with Leonardo's design of the Swiss Guards' uniform) when he did something, he did it well.
And without Fermat and Pascal, Leibniz's work would probably have come much later, with massive butterfly effects right up to the present.