Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Haskell
Wiki community
Recent changes
Random page
HaskellWiki
Search
Search
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Lojban
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Special pages
Page information
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Analogies of [[combinatory logic]] combinators == The Lojban sentence examples are taken from ([http://lojban.org/publications/level0/brochure/diagsumm.html NC:WhLoj, Chapter 3. Diagrammed Summary of Lojban Grammar]). Sometimes, I modified the sentences slightly, if the [[combinatory logic]] analogies made it necessary. Predicates {| border=5 | Somebody | sells | something | to somebody | for some price |- | <math>x_1</math> | predicate | <math>x_2</math> | <math>x_3</math> | <math>x_4</math> |} A little vocabulary: ; <code>mi</code> : I, me ; <code>do</code> : you ; <code>ta</code> : that ; <code>vecnu</code> : sell Syntax: {| border=5 |+ you sell that to me for some price. | <code>do</code> | rowspan=2 | <code>cu</code> | <code>vecnu</code> | <code>ta</code> | <code>mi</code> | <code>zo'e</code> | rowspan=2 | <code>vau</code> |- | <math>x_1</math> | predicate | <math>x_2</math> | <math>x_3</math> | <math>x_4</math> |} <code>cu</code> and <code>vau</code> are separators (and they are optional). <code>zo'e</code> is only a place-keeper: the argument whose place is filled in but it is not specified. For didactical reasons, sometimes its meaning is rendered as “some…”, “unspecified…” etc. But in fact, most natural languages do not use such a place-keeper (because they are not based on predicate logic the way Lojban is), so in most cases, <code>zo'e</code> is not translated into English directly. An analogy with translating a decimal number representation into English: 2001 becomes “two thousand one”, so the notion of zero is not translated directly -- in fact, notion of zero is a rather late innovation (compared to language). === Flipping (is it something like “voice”?) === {| border=5 |+ That is sold by you to me for some price | <code>ta</code> | rowspan=2 | <code>cu</code> | <code>se vecnu</code> | <code>do</code> | <code>mi</code> | <code>zo'e</code> | rowspan=2 | <code>vau</code> |- | <math>x_1</math> | predicate | <math>x_2</math> | <math>x_3</math> | <math>x_4</math> |} Comparing <code>vecnu</code> and <code>se vecnu</code>, it is of taste <math>\mathbf C</math> combinator of [[combinatory logic]]. Comparing structure: {| border=5 ! <math>x_1</math> | rowspan=3 | <code>cu</code> ! predicate ! <math>x_2</math> ! <math>x_3</math> ! <math>x_4</math> | rowspan=3 | <code>vau</code> |- | <code>do</code> | <code>vecnu</code> | <code>ta</code> | rowspan=2 | <code>mi</code> | rowspan=2 | <code>zo'e</code> |- | <code>ta</code> | <code>se vecnu</code> | <code>do</code> |} To illustrate this analogy, I write a semi-Lojban-semi-CL version: <code>do cu vecnu ta mi zo'e vau</code> <code>ta cu</code> (<math>\mathbf C</math> <code>vecnu</code>) <code>do mi zo'e vau</code> === Repeating === Words <code>mi</code>, <code>do</code> correspond to English personal pronouns I (me), you. Lojban has other similar words, e.g. <code>ri</code>. Word <code>ri</code> fills in an argument (of the predicate) which repeats the previous argument. {| border=5 | Somebody | talks | to somebody | about something | in some language |- | <math>x_1</math> | predicate | <math>x_2</math> | <math>x_3</math> | <math>x_4</math> |} A little vocabulary: ; <code>mi</code> : I, me ; <code>do</code> : you ; <code>la lojban.</code> : Lojban ; <code>tavla</code> : talk Syntax: {| border=5 |+ I talk to you about the Lojban language in Lojban | <code>mi</code> | rowspan=2 | <code>cu</code> | <code>tavla</code> | <code>do</code> | <code>la lojban.</code> | <code>la lojban.</code> | rowspan=2 | <code>vau</code> |- | <math>x_1</math> | predicate | <math>x_2</math> | <math>x_3</math> | <math>x_4</math> |} <code>mi cu tavla do la lojban. la lojban. vau</code> The word <code>ri</code> helps us avoiding repeating the argument of predicate in this case: <code>mi cu tavla do la lojban. ri vau</code> I think, it is a rather imperative solution (using some notion of state / memory), compared to the <math>\mathbf W</math> combinator of [[combinatory logic]], but in this case, it has the same effect. If Lojban used combinators, I should write (using the elementary duplicator <math>\mathbf W</math>): <math>\mathbf W</math>(<code>mi cu tavla do</code>) <code>la lojban. vau</code> It seems to me even better to modify only the predicate directly, not an arbitrary subexpression of the sentence -- if it is possible. Thus the deferred combinator <math>\mathbf W_{\left(2\right)}</math> helps us even more here: <code>mi cu</code> (<math>\mathbf W_{\left(2\right)}</math> <code>tavla</code>) <code>do la lojban. vau</code> <math>\mathbf W</math>-sequences could be used also for avoiding the many-many repeating zo'e words (of course, if Lojban used combinators): I talk. (Not specified, to whom, about what topic, in what language!) <code>mi cu tavla zo'e zo'e zo'e vau</code> What could help us in lambda calculus? :<math>\lambda f x y . f x y y y</math> <code>mi cu</code> (<math>\left(\lambda f x y . f x y y y\right)</math> <code>tavla</code>) <code>zo'e vau</code> In [[combinatory logic]], <math>\mathbf W^2_{\;\left(1\right)}</math> makes that (let us note the little slant of the indices: powered combinator <math>\mathbf W^2</math> is deferred here, not deferred combinator <math>\mathbf W_{\left(1\right)}</math> is powered!): <code>mi cu</code> (<math>\mathbf W^2_{\;\left(1\right)}</math> <code>tavla</code>) <code>zo'e vau</code> Lojban does not use combinators this way, it uses also rather imperative solutions. Despite of that, Lojban makes me think of [[combinatory logic]] and [[Libraries and tools/Linguistics/Applicative universal grammar|applicative universal grammar]].
Summary:
Please note that all contributions to HaskellWiki are considered to be released under simple permissive license (see
HaskellWiki:Copyrights
for details). If you don't want your writing to be edited mercilessly and redistributed at will, then don't submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
DO NOT SUBMIT COPYRIGHTED WORK WITHOUT PERMISSION!
Cancel
Editing help
(opens in new window)
Toggle limited content width