Chaining operators and relations: Difference between revisions

From Why start at x, y, z
No edit summary
No edit summary
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
[[Category:Inconsistencies]]
[[Category:Inconsistencies]]


<ref>[https://twitter.com/ZenoRogue/status/798923050842324992 Tweet by ZenoRogue]</ref>
When you have several terms with operators in between, some kind of associativity is normally implied, so that the expression can be evaluated as a sequence of binary operations:


<ref>[https://twitter.com/christianp/status/1046721351288000512 Tweet by Christian Lawson-Perfect]</ref>
\[ a \cdot b \cdot c =  (a \cdot b) \cdot c \]
 
That isn't usually the case when terms are joined with relation symbols<ref>[https://twitter.com/ZenoRogue/status/798923050842324992 Tweet by ZenoRogue]</ref><ref>[https://twitter.com/christianp/status/1046721351288000512 Tweet by Christian Lawson-Perfect]</ref>:
 
<blockquote>
Let \(a=1\), \(b=2\), \(c=3\).
 
\( (a \lt b) \lt c = \text{True} \lt c \)
 
Doesn't make sense!
</blockquote>
 
It doesn't make sense to evaluate this as a sequence of binary operations. Instead, a chain of \(n\) relations could be interpreted as a set of \(n\) statements:
 
\[ a \lt b \lt c \iff (a \lt b) \wedge (b \lt c)  \]

Latest revision as of 14:23, 14 July 2021


When you have several terms with operators in between, some kind of associativity is normally implied, so that the expression can be evaluated as a sequence of binary operations:

\[ a \cdot b \cdot c = (a \cdot b) \cdot c \]

That isn't usually the case when terms are joined with relation symbols[1][2]:

Let \(a=1\), \(b=2\), \(c=3\).

\( (a \lt b) \lt c = \text{True} \lt c \)

Doesn't make sense!

It doesn't make sense to evaluate this as a sequence of binary operations. Instead, a chain of \(n\) relations could be interpreted as a set of \(n\) statements:

\[ a \lt b \lt c \iff (a \lt b) \wedge (b \lt c) \]