r/EncapsulatedLanguage • u/AceGravity12 Committee Member • Jul 28 '20
Basic arthimatic through basic algebra
NOTE: <add>, <multiply>, <power>, and <?> are placeholders that will be replaced when an official phonotactic system is chosen.
Math System:
Taught by example version:
What is “1 1 ? <add>”? It's “2”. (1 + 1 = 2)
What is "2 1 ? <add>”? It's “3”. (2 + 1 = 3)
What is "1 2 ? <add>”? It's “3”. (1 + 2 = 3)
What is "2 ? 1 <add>”? It's “-1”. (2 + X = 1, X = -1)
What is "3 ? 1 <add>”? It's “-2”. (3 + X = 1, X = -2)
What is "3 ? 2 <add>”? It's “-1”. (3 + X = 2, X = -1)
What is "? 1 1 <add>”? It's “0”. (X + 1 = 1, X = 0)
What is "? 2 1 <add>”? It's “-1”. (X + 2 = 1, X = -1)
What is "? 1 2 <add>”? It's “1”. (X + 1 = 2, X = 1)
Is "1 1 1 <add>” true? No. (1 + 1 ≠ 1)
Is "1 2 3 <add>” true? Yes. (1 + 2 = 3)
What is “ 1 1 ? <multiply>”? It's “1”. (1 × 1 = 1)
What is "2 1 ? <multiply>”? It's “2”. (2 × 1 = 2)
What is "1 2 ? <multiply>”? It's “2”. (1 × 2 = 2)
What is "2 ? 1 <multiply>”? It's “1/2”. (2 × X = 1, X = 1/2)
What is "3 ? 1 <multiply>”? It's “1/3”. (3 × X = 1, X = 1/3)
What is "3 ? 2 <multiply>”? It's “2/3”. (3 × X = 2, X = 2/3)
What is "? 1 1 <multiply>”? It's “1”. (X × 1 = 1, X = 1)
What is "? 2 1 <multiply>”? It's “1/2”. (X × 2 = 1, X = 1/2)
What is "? 1 2 <multiply>”? It's “1”. (X × 1 = 2, X = 2)
Is "1 1 1 <multiply>” true? Yes. (1 × 1 = 1)
Is "1 2 3 <multiply>” true? No. (1 × 2 ≠ 3)
What is "1 1 ? <power>”? It's “1”. (1 ^ 1 = 1)
What is "2 1 ? <power>”? It's “2”. (2 ^ 1 = 2)
What is "1 2 ? <power>”? It's “1”. (1 ^ 2 = 1)
What is "2 ? 4 <power>”? It's “2”. (2 ^ X = 4, X = 2)
What is "3 ? 1 <power>”? It's “0”. (3 ^ X = 1, X = 0)
What is "3 ? 2 <power>”? It's “log3(2)”. (3 ^ X = 2, X = log3(2) ≈ 0.631)
What is "? 1 1 <power>”? It's “1”. (X ^ 1 = 1, X = 1)
What is "? 2 1 <power>”? It's “1 and -1”. (X ^ 2 = 1, X = 1, -1)
What is "? 1 2 <power>”? It's “2”. (X ^ 1 = 2, X = 2)
Is "1 11 1 <power>” true? Yes. (1 ^ 11 = 1)
Is "2 2 5 <power>” true? No. (2 ^ 2 ≠ 5)
Now for some hard ones:
What is “1 2 ? 3 <add> ? <add>”? It's “2”. (2 + X = 3, X = 1, => 1 + X =2)
Is “1 1 ? <power> 1 ? <multiply> 1 2 <add>” true? Yes. (1 ^ 1 = X, X = 1 => 1 × X = Y, Y=1 => 1 + Y = 2 )
Nitty-gritty version:
This system uses reverse polish notation and a number question word to construct arithmetic from 4 words. Because of this, parentheses are never needed. Three of the words are ternary relations:
“<add>” states that its first two arguments added together equals the third. “<Multiply>” states that its first two arguments multiplied together equals the third. “<power>” states that its first argument to the power of its second argument equals the third. The final word “<?>” asks you to take the trianary relation and figure out what number “<?>” has to be to make it true (all “<?>”s in a single relationship are the same so “<?> <?> 2 <add>” is 1, “<?>” is technically purely formatting not a variable, that system will come later). Whenever one of these three words has “<?>” in it the entire relation can be treated as a single number for grammatical purposes, if it has no “<?>”s in it then it can be treated as either True or False. Because of this, relations are able to nest inside of each other allowing for more complicated numbers to be represented. IMPORTANT NOTE: This is the backbone of a full mathematical system, while it can express everything needed to teach basic algebra, that does not mean more features cannot be added in the future to make things more convenient. Big thanks to Omcxjo, who kept me on track preventing feature creep, helped clean up the system, and pointed out many errors.
Edit: formatting
3
u/ArmoredFarmer Committee Member Jul 28 '20
Overall i like system an I think that this is a very good start on mathematics I did want to point out something that had been discussed about powers roots and logs before. I had found this video about the topic: https://www.youtube.com/watch?v=sULa9Lc4pck and everyone I showed it to agreed that we should pursue this so I was wondering how you might do this or something similar in this system?
2
u/Haven_Stranger Jul 28 '20
Parentheses might not be needed, but delimiters are. As presented, you're using spaces for delimiters.
How do you intend to delimit those formulae that are baked into single words? Are we limited to single-syllable numbers in that case?
How do you intend to present coefficients and variables?
Do you see any impact to prepositions (or postpositions) and particles in the base language?
You've presented subtraction as an addition with an unknown, and division as multiplication with an unknown. What impact is that likely to have to preposition-like words such as "less/without" and "over"?
This seems to be purely evaluative. I'm much more interested in seeing a clearly representational structure. For example, how do we turn the quadratic formula into representational phonemes, with the goal of having the word for "quadratic root" decompose to a high-utility presentation of the quadratic formula?
2
u/Haven_Stranger Jul 29 '20 edited Jul 30 '20
So, using decimal instead of the dozenal, using symbols instead of words ...
12 0 1 ^
12 1 12 ^
12 2 144 ^
12 3 1728 ^
There's the unit, the dozen, the gross and the ... great gross? Well, surely the conlang will have a better name.
It looks simpler in dozenal, of course:
10 0 1 ^
10 1 10 ^
10 2 100 ^
10 3 1000 ^
Regarding speech, this implies something resembling "a dozen to two is a gross when raised".
To my eye, those don't look like identities -- and maybe they shouldn't. They do reasonably represent true evaluations. I'm starting to suspect that true evaluation and relationship don't collapse into the same concept.
A x ? ^ A y ? ^ A x y ? + ? ^ *
A ? y ^ A ? x ^ A ? x y ? * +
To my eye, these don't look like identities, either. I don't see how to tell that they state a generic equivalence. I don't see how a generic inequality can be stated, either -- not with operators limited to +, * and ^ and with values that are simply numbers.
I can't see it, but that doesn't mean it's not there. There should be some way to represent a comparative evaluation with a subtraction: a difference of zero is equality, and differences other than zero must be greater than or less than.
So, what about ...
A x ? ^ A y ? ^ ? * 0 A x y ? + ? ^ +
I still can't see it. The postfix notation means that the mathematical statement is unambiguous, never needing parentheses to get the order of operations right. But, it also means that I can't simply see that this statement means something like "these two evaluations have no difference". That meaning is there. Everything to the left of the zero collapses into one evaluation. Everything between that zero and the final plus collapses. But, I have to play a slow and painful stack-tracing game before I can see how they collapse.
Like most of us, I have an intuition honed on infix notation. The identity Ax * Ay = Ax+y looks like it's an identity at a glance because I've been trained to see how those components collapse. I simply know that the comparator = has a higher precedence than any operation on either side.
What kind of at-a-glance rule-of-thumb is there to just intuit A x ? ^ A y ? ^ A x y ? + ? ^ * as a statement of equality? Is there one?
One more comparison:
Going from Ax * Ay = Ax+y to Ax+y = Ax * Ay is trivial in infix. What's the methodology for going from
A x ? ^ A y ? ^ A x y ? + ? ^ *
to
A x y ? + A x ? ^ A y ? ^ ? * ^
Oh, wait. I almost see it:
{ A x ? ^ A y ? ^ } [ A x y ? + ] ? [^] {*}
[ A x y ? + ] { A x ? ^ A y ? ^ } ? {*} [^]
I don't understand why the brackets contain something incomplete (an A and one complete operation), or why the braces contain independent two operations. But it almost looks like a "placeholder operation operation" sequence at the end implies that the results of the first operation equals the results of the second. And maybe (almost certainly) there's one clear set of rules for making this transformation. And, hmm, I might not be enclosing the right chunks for the swap.
Is there a way to know whether placeholder-operation-operation always and only represents an identity between the two outermost operations? Or, if not that, what?
If postfix algebra is the right way to go, if the <pow> operation (rather, operations in general) can be seen as "middle term acting on first term to yield result term by this action", then it makes sense to structure any factitive verb with a [patient agent result verb] canonical order. As in, we should make the default for language parsing the same as the default for algebraic parsing.
Or, hmm, as in something like "language parsing[patient] we[agent] should[modal aux] to match algebraic parsing[result] make[factitive verb]"
So far, it looks promising. Gotta love the idea that, by the time a native-speaking student even hears about algebra, the order of operations already makes sense. That's the sort of intuitive understanding we all want embedded in the structure and essence of the conlang.
2
u/Haven_Stranger Jul 30 '20
From the perspective of integer arithmetic, there is a natural and inherent order to the operations:
Operation level zero is increment: add exactly one.
Operation level one is addition: add one repeatedly; that is, use a given count/amount of incrementing.
Operation level two is multiplication: add things repeatedly.
Operation level three is exponentiation: multiply things repeatedly.
Level zero is the basis of counting.
How can we embed this fact into the names/symbols for increment (if we bother with that), add, multiply and raise?
Yes, I realize this is starting to look recursive. It implies embedding a number inside an operation that also needs to take numbers as its arguments. That's why I'm bothering to mention it, and why we shouldn't avoid it. An embedding language that embeds knowledge at different levels is going to be a recursive structure.
Oh, and I'm starting this numbering with zero because:
12 0 1 ^
12 1 12 ^
12 2 144 ^
12 3 1728 ^
starting with zero keeps us aligned with how exponentiation works, and with how I imagine ordered differentials will work (like the time differentials of position0 velocity1 acceleration2, jerk3, &c).
Given the inherent recursion, and using "inc" to represent the base idea:
dozen two gross inc3
5 6 inc0 is increment, with five as patient, no explicit agent, and six as result.
5 3 8 inc1 is addition, with five as patient, three as agent, and eight as result.
2 3 6 inc2 is multiplication, 'nuff said.
2 3 8 inc3 is exponentiation -- where the difference between agent and patient becomes quite clear: the three acts on the two, but not vice-versa. Unlike addition and multiplication, exponentiation is not a commutative operation. Agent and patient can't simply switch places with the same result.
And a reminder: the fixed and absolute order of the arguments of these operations should match the canonical order of arguments for verbs and postpositions and such. If there is an overriding reason for agent-first ordering in the conlang in general, that needs to be reflected here. For those of us who think in English, Yoda-speech seems backwards -- but it works. However, we've got agent-free operations here, just as we'll have labile verbs in the plain conlang. So far, this algebraic grammar looks like it supports the utility of an patient-agent-result ordering, so Yoda's in the lead.
1
u/nadelis_ju Committee Member Jul 29 '20
I like this system, it doesn't indicate one of the argumants of the operation is the thing we're fucusing on implicitly, rather you how to indicate what you're focusing on.
One problem that might come from this system would be that you only learn about what operation is being performed at the very end. Perhaps if the operation particle is at the beginning it might be a little easier to understand what's happening.
1
u/Akangka Jul 31 '20
I actually prefer the way our current mathematics handles it. Believe it or not, our current mathematic symbols have an excellent encapsulation property. In modern mathematics notation, + and * are treated as a function with the left and the right sides as the arguments. This reflects the definition of a ring, where these operators are defined as a function, not as a ternary relation.
2
u/Omcxjo Jul 29 '20
Thanks for posting this, OP.
I wrote an expression evaluator for this system in python:
https://colab.research.google.com/drive/1Ea_CysvG_bYrcXrWIsge4HSLwZ8Lwk2Q
Keep in mind that this system can express expressions as well as theorems (when you allow for variables and logical quantification), because the third argument is equal to the operation on the first two.