# Lojban

(Difference between revisions)
 Revision as of 20:03, 7 August 2006 (edit) (Lojban analogies of C and W combinators of combinatry logic)← Previous diff Current revision (19:41, 3 September 2006) (edit) (undo) (→Introduction: Links to notions: Valency, applicative voice) (26 intermediate revisions not shown.) Line 5: Line 5: Lojban is a constructed language. “Lojban was not designed primarily to be an international language, however, but rather as a linguistic tool for studying and understanding language. Its linguistic and computer applications make Lojban unique among international languages...” ([http://www.lojban.org/tiki/tiki-index.php?page=What+Is+Lojban%3F%2C+The+Book&bl NC:LojPer], page 15 par 1) -- the entire book is available also online, see the very bottom of the linked page. Lojban is a constructed language. “Lojban was not designed primarily to be an international language, however, but rather as a linguistic tool for studying and understanding language. Its linguistic and computer applications make Lojban unique among international languages...” ([http://www.lojban.org/tiki/tiki-index.php?page=What+Is+Lojban%3F%2C+The+Book&bl NC:LojPer], page 15 par 1) -- the entire book is available also online, see the very bottom of the linked page. - It is an artificial language (and, unlike the more a posteriori Esperanto, it is rather of an a priori taste ([http://www.lojban.org/files/why-lojban/moody.txt Moo:LojPer])). It is a human language, capable of expressing everything. Its grammar uses (among others) things taken from mathematical logic, e.g. predicate-like structures. Although its does not make use combinatory logic directly (even, from a category logic / functional programming point of view, it uses also rather imperative ideas), but it may give hints and analogies, how combinatry logic can be useful in [[Libraries and tools/Linguistics|linguistics]]. I like searching Lojban examples illustrating the learned statements when learning about [[Libraries and tools/Linguistics/Applicative universal grammar|applicative universal grammar]]. + It is an artificial language (and, unlike the more ''a posteriori'' Esperanto, it is rather of an ''a priori'' taste ([http://www.lojban.org/files/why-lojban/moody.txt Moo:LojPer])). It is a human language, capable of expressing everything. Its grammar uses (among others) things borrowed from mathematical logic, e.g. predicate-like structures. (Confer also notions [http://en.wikipedia.org/wiki/Valency_%28linguistics%29 valency] and [http://en.wikipedia.org/wiki/Applicative_voice applicative voice].) Although it does not make direct use of [[combinatory logic]] (even, from a combinatory logic / functional programming point of view, it uses also rather imperative ideas), but it may give hints and analogies, how combinatory logic can be useful in [[Libraries and tools/Linguistics|linguistics]]. I like searching Lojban examples illustrating the learned statements when learning about [[Libraries and tools/Linguistics/Applicative universal grammar|applicative universal grammar]] (although [[Libraries and tools/Linguistics/Applicative universal grammar|applicative universal grammar]] is ''not'' restricted to explain only a set of well-selected languages). See [http://www.lojban.org its official homepage here]. See [http://www.lojban.org its official homepage here]. Line 21: Line 21: | sells | sells | something | something - | to sombebody + | to somebody | for some price | for some price |- |- Line 32: Line 32: A little vocabulary: A little vocabulary: - ; mi + ; mi - : I + : I, me - ; vecnu + ; do - : sell + - ; do + : you : you - ; ta + ; ta : that : that + ; vecnu + : sell Syntax: Syntax: {| border=5 {| border=5 - |+ I sell this to you for some price. + |+ you sell that to me for some price. - | do + | do - | rowspan=2 | cu + | rowspan=2 | cu - | vecnu + | vecnu - | ta + | ta - | mi + | mi - | zo'e + | zo'e - | rowspan=2 | vau + | rowspan=2 | vau |- |- | $x_1$ | $x_1$ Line 60: Line 60: |} |} - cu and vau are separators (and they are optional). + cu and vau are separators (and they are optional). - zo'e is only a place-keeper: the argument whose place is fiiled in by it is not specified. + - == Filipping == + zo'e 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, zo'e 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 {| border=5 |+ That is sold by you to me for some price |+ That is sold by you to me for some price - | ta + | ta - | rowspan=2 | cu + | rowspan=2 | cu - | se vecnu + | se vecnu - | do + | do - | mi + | mi - | zo'e + | zo'e - | rowspan=2 | vau + | rowspan=2 | vau |- |- | $x_1$ | $x_1$ Line 82: Line 83: |} |} - Coparing vecnu and se vecnu, it is of taste $mathbf C$ combinator of [[combinatory logic]]. + Comparing vecnu and se vecnu, it is of taste $\mathbf C$ combinator of [[combinatory logic]]. Comparing structure: Comparing structure: {| border=5 {| border=5 ! $x_1$ ! $x_1$ - | rowspan=3 | cu + | rowspan=3 | cu ! predicate ! predicate ! $x_2$ ! $x_2$ ! $x_3$ ! $x_3$ ! $x_4$ ! $x_4$ - | rowspan=3 | vau + | rowspan=3 | vau |- |- - | do + | do - | vecnu + | vecnu - | ta + | ta - | rowspan=2 | mi + | rowspan=2 | mi - | rowspan=2 | zo'e + | rowspan=2 | zo'e |- |- - | ta + | ta - | se vecnu + | se vecnu - | mi + | do |} |} - == Repeating == + To illustrate this analogy, I write a semi-Lojban-semi-CL version: - Words mi, do correspond to Enlish personal pronouns I (me), you. Lojban has other simi;ar words, e.g. ri. Word ri can be regarded as an argument (of the prediate) which repeats the previous argument. + do cu vecnu ta mi zo'e vau + + ta cu ($\mathbf C$ vecnu) do mi zo'e vau + + === Repeating === + + Words mi, do correspond to English personal pronouns I (me), you. Lojban has other similar words, e.g. ri. Word ri fills in an argument (of the predicate) which repeats the previous argument. {| border=5 {| border=5 | Somebody | Somebody | talks | talks - | to sombebody + | to somebody | about something | about something | in some language | in some language Line 124: Line 131: A little vocabulary: A little vocabulary: - ; mi + ; mi - : I + : I, me - ; tavla + ; do - : talk + - ; do + : you : you - ; la lojban. + ; la lojban. : Lojban : Lojban + ; tavla + : talk Syntax: Syntax: Line 137: Line 144: {| border=5 {| border=5 |+ I talk to you about the Lojban language in Lojban |+ I talk to you about the Lojban language in Lojban - | mi + | mi - | rowspan=2 | cu + | rowspan=2 | cu - | tavla + | tavla - | do + | do - | la lojban. + | la lojban. - | la lojban. + | la lojban. - | rowspan=2 | vau + | rowspan=2 | vau |- |- | $x_1$ | $x_1$ Line 152: Line 159: |} |} - The word ri helps us avoiding repeating the argument of predicate in this case: + mi cu tavla do la lojban. la lojban. vau - Mi cu tavla do la lojban. ri vau + The word ri helps us avoiding repeating the argument of predicate in this case: - I think, it is more imperative solution, that the \mathbf W combinator of [[combinatory logic]], but in this case, it has the same effect. If Lojban used combinators, I should write: + mi cu tavla do la lojban. ri vau - $\mathbf W$(Mi cu tavla do) la lojban. + I think, it is a rather imperative solution (using some notion of state / memory), compared to the $\mathbf W$ combinator of [[combinatory logic]], but in this case, it has the same effect. If Lojban used combinators, I should write (using the elementary duplicator $\mathbf W$): - $\mathbf W$ could be used for avoiding the many-many reeating zo'e words (of course, if Lojban used combinators): + $\mathbf W$(mi cu tavla do) la lojban. vau - I talk. + 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 $\mathbf W_{\left(2\right)}$ helps us even more here: + + mi cu ($\mathbf W_{\left(2\right)}$ tavla) do la lojban. vau + + $\mathbf W$-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!) (Not specified, to whom, about what topic, in what language!) - mi cu tavla zo'e zo'e zo'e vau + mi cu tavla zo'e zo'e zo'e vau What could help us in lambda calculus? What could help us in lambda calculus? - :$\lambda f x . f x x x$ + :$\lambda f x y . f x y y y$ - mi cu ($\left(\lambda f x . f x x x\right)$ tavla) zo'e vau + - In combinatory logic, $\mathbf W^2$ makes that: + mi cu ($\left(\lambda f x y . f x y y y\right)$ tavla) zo'e vau - mi cu ($\mathbf W^2$ tavla) zo'e vau + In [[combinatory logic]], $\mathbf W^2_{\;\left(1\right)}$ makes that (let us note the little slant of the indices: powered combinator $\mathbf W^2$ is deferred here, not deferred combinator $\mathbf W_{\left(1\right)}$ is powered!): + + mi cu ($\mathbf W^2_{\;\left(1\right)} tavla) zo'e vau 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]]. 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]]. + + == Meta vs object language == + + When searching natural language analogies illustrating deep mathematical things versus to construct a natural language capable of showing some mathematical things, see + * Wikipedia's [http://en.wikipedia.org/wiki/Indirect_self-reference Indirect self-reference] and [Hof:GEB] show us natural language examples illustrating many interesting things in the foundations of mathematics. + * [http://www.lojban.org/tiki/tiki-download_wiki_attachment.php?attId=192 Cow:CompLoj, Chapter 6] shows us how a natural language can have a rich set of tools, clear and unambiguous notions for clearly separating things at the meta versus object level. + Maybe a good didactic material (or more) could be made by joining the above two (complementary?) approaches together. + + Is it related also to the notion of object vs meta language, and to the handling the distinction unambigously? + + Returning to the topic of “Meta vs object language”: when writing a quine in combinatory logic, we solved the problem of ''quotation'': we make something similar to Tarski's “structural descriptive name” notion [Tar:BizIg, pp. 61–62] — in terms of combinatory logic. A summary in an informal notation: + :[itex]\left\lceil\mathbf K\right\rceil \equiv \mathbf{leaf}\;\mathbf{true}$ + :$\left\lceil\mathbf S\right\rceil \equiv \mathbf{leaf}\;\mathbf{false}$ + :$\left\lceil\left(x\;y\right)\right\rceil \equiv \mathbf{branch}\;\left\lceil x\right\rceil\;\left\lceil y\right\rceil$ + where + * $\mathbf{leaf}$, $\mathbf{branch}$ are representation of binary tree concept in combinatory logic (e.g. by using catamorphism) + * $\mathbf{true}$, $\mathbf{false}$ are the well-known representation of booleans in combinatory logic, e.g. by using continuation. + Haskell analogy (without resorting to catamorhism): + + type CL = Tree BaseSymbol + data Tree a = Leaf a | Branch (Tree a) (Tree a) + type BaseSymbol = Bool + + + Of course, less modularized representations can work well, too: we can “burn in” the base into the tree. Then our quotation solution will become something similar to + :$\left\lceil\mathbf K\right\rceil \equiv \mathbf{kay}$ + :$\left\lceil\mathbf S\right\rceil \equiv \mathbf{ess}$ + :$\left\lceil\left(x\;y\right)\right\rceil \equiv \mathbf{cat}\;\left\lceil x\right\rceil\;\left\lceil y\right\rceil$ + Haskell analogy: + + data CL = K | S | Cat CL CL + + and let $\mathbf{kay}$, $\mathbf{ess}$, $\mathbf{cat}$ be the corresponding implementation in combinatory logic (using catamorphism). + == Others == + + An interesting discussion e.g. on the sociology of how people choose (“adopt”) a programming language: [http://lambda-the-ultimate.org/node/1358 Social science research about programming language adoption?]. (Some similar questions are discussed also in [http://www.paulgraham.com/avg.html Beating the Averages] written by [http://www.paulgraham.com/ Paul Graham]). In the mentioned discussion, [http://lambda-the-ultimate.org/node/1358#comment-15497 one of the comments] compared Haskell (among programming languages) to Lojban (among human languages). == References == == References == ;NC:WhLoj ;NC:WhLoj - :Nicholas, Nick and Cowan, John (ed.): What is Lojban? [http://www.lojban.org/ Logical Language Group], 2003. Available also [http://www.lojban.org/tiki/tiki-index.php?page=What+Is+Lojban%3F%2C+The+Book&bl online]. + :Nicholas, Nick and Cowan, John (ed.): What is Lojban? [http://www.lojban.org/ Logical Language Group], 2003. Available also [http://www.lojban.org/tiki/tiki-index.php?page=What+Is+Lojban%3F%2C+The+Book&bl online], see the very bottom of the linked page. ;Moo:LojPer ;Moo:LojPer - :Todd Moody: Lojban in Perspective + :Todd Moody: Lojban in Perspective. Available from [http://www.lojban.org/files/why-lojban/moody.txt here, part of Lojban's official homepage] - Available from [http://www.lojban.org/files/why-lojban/moody.txt here, part of Lojban's official homepage] + ;CowNC:CompLoj + :John Woldemar Cowan: The Complete Lojban Language. The Logical Language Group, Inc., ISBN 0-9660283-0-9. [http://www.lojban.org/tiki/tiki-index.php?page=The+Lojban+Reference+Grammar&bl Draft version (called The Lojban Reference Grammar) available free here]. + ;Hof:GEB + :Hofstadter, D. R., Goedel, Escher, Bach: an Eternal Golden Braid, NY: Basic Books, 1979 + ;Tar:BizIg: + :Tarski, Alfred: Bizonyítás és igazság / Válogatott tanulmányok. Gondolat, Budapest, 1990. (Title means: Proof and truth / Selected papers.) [[Category:Theoretical foundations]] [[Category:Theoretical foundations]]

## 1 Introduction

Lojban is a constructed language. “Lojban was not designed primarily to be an international language, however, but rather as a linguistic tool for studying and understanding language. Its linguistic and computer applications make Lojban unique among international languages...” (NC:LojPer, page 15 par 1) -- the entire book is available also online, see the very bottom of the linked page.

It is an artificial language (and, unlike the more a posteriori Esperanto, it is rather of an a priori taste (Moo:LojPer)). It is a human language, capable of expressing everything. Its grammar uses (among others) things borrowed from mathematical logic, e.g. predicate-like structures. (Confer also notions valency and applicative voice.) Although it does not make direct use of combinatory logic (even, from a combinatory logic / functional programming point of view, it uses also rather imperative ideas), but it may give hints and analogies, how combinatory logic can be useful in linguistics. I like searching Lojban examples illustrating the learned statements when learning about applicative universal grammar (although applicative universal grammar is not restricted to explain only a set of well-selected languages).

## 2 Analogies of combinatory logic combinators

The Lojban sentence examples are taken from (NC:WhLoj, Chapter 3. Diagrammed Summary of Lojban Grammar). Sometimes, I modified the sentences slightly, if the combinatory logic analogies made it necessary.

Predicates

 Somebody sells something to somebody for some price x1 predicate x2 x3 x4

A little vocabulary:

mi
I, me
do
you
ta
that
vecnu
sell

Syntax:

 do cu vecnu ta mi zo'e vau x1 predicate x2 x3 x4

cu and vau are separators (and they are optional).

zo'e 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, zo'e 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).

### 2.1 Flipping (is it something like “voice”?)

 ta cu se vecnu do mi zo'e vau x1 predicate x2 x3 x4

Comparing vecnu and se vecnu, it is of taste $\mathbf C$ combinator of combinatory logic. Comparing structure:

 x1 predicate x2 x3 x4 cu vau do vecnu ta mi zo'e ta se vecnu do

To illustrate this analogy, I write a semi-Lojban-semi-CL version:

do cu vecnu ta mi zo'e vau

ta cu ($\mathbf C$ vecnu) do mi zo'e vau

### 2.2 Repeating

Words mi, do correspond to English personal pronouns I (me), you. Lojban has other similar words, e.g. ri. Word ri fills in an argument (of the predicate) which repeats the previous argument.

 Somebody talks to somebody about something in some language x1 predicate x2 x3 x4

A little vocabulary:

mi
I, me
do
you
la lojban.
Lojban
tavla
talk

Syntax:

 mi cu tavla do la lojban. la lojban. vau x1 predicate x2 x3 x4

mi cu tavla do la lojban. la lojban. vau

The word ri helps us avoiding repeating the argument of predicate in this case:

mi cu tavla do la lojban. ri vau

I think, it is a rather imperative solution (using some notion of state / memory), compared to the $\mathbf W$ combinator of combinatory logic, but in this case, it has the same effect. If Lojban used combinators, I should write (using the elementary duplicator $\mathbf W$):

$\mathbf W$(mi cu tavla do) la lojban. vau

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 $\mathbf W_{\left(2\right)}$ helps us even more here:

mi cu ($\mathbf W_{\left(2\right)}$ tavla) do la lojban. vau

$\mathbf W$-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!)

mi cu tavla zo'e zo'e zo'e vau

What could help us in lambda calculus?

λfxy.fxyyy

mi cu ($\left(\lambda f x y . f x y y y\right)$ tavla) zo'e vau

In combinatory logic, $\mathbf W^2_{\;\left(1\right)}$ makes that (let us note the little slant of the indices: powered combinator $\mathbf W^2$ is deferred here, not deferred combinator $\mathbf W_{\left(1\right)}$ is powered!):

mi cu ($\mathbf W^2_{\;\left(1\right)}$ tavla) zo'e vau

Lojban does not use combinators this way, it uses also rather imperative solutions. Despite of that, Lojban makes me think of combinatory logic and applicative universal grammar.

## 3 Meta vs object language

When searching natural language analogies illustrating deep mathematical things versus to construct a natural language capable of showing some mathematical things, see

• Wikipedia's Indirect self-reference and [Hof:GEB] show us natural language examples illustrating many interesting things in the foundations of mathematics.
• Cow:CompLoj, Chapter 6 shows us how a natural language can have a rich set of tools, clear and unambiguous notions for clearly separating things at the meta versus object level.

Maybe a good didactic material (or more) could be made by joining the above two (complementary?) approaches together.

Is it related also to the notion of object vs meta language, and to the handling the distinction unambigously?

Returning to the topic of “Meta vs object language”: when writing a quine in combinatory logic, we solved the problem of quotation: we make something similar to Tarski's “structural descriptive name” notion [Tar:BizIg, pp. 61–62] — in terms of combinatory logic. A summary in an informal notation:

$\left\lceil\mathbf K\right\rceil \equiv \mathbf{leaf}\;\mathbf{true}$
$\left\lceil\mathbf S\right\rceil \equiv \mathbf{leaf}\;\mathbf{false}$
$\left\lceil\left(x\;y\right)\right\rceil \equiv \mathbf{branch}\;\left\lceil x\right\rceil\;\left\lceil y\right\rceil$

where

• $\mathbf{leaf}$, $\mathbf{branch}$ are representation of binary tree concept in combinatory logic (e.g. by using catamorphism)
• $\mathbf{true}$, $\mathbf{false}$ are the well-known representation of booleans in combinatory logic, e.g. by using continuation.

Haskell analogy (without resorting to catamorhism):

type CL = Tree BaseSymbol
data Tree a = Leaf a | Branch (Tree a) (Tree a)
type BaseSymbol = Bool

Of course, less modularized representations can work well, too: we can “burn in” the base into the tree. Then our quotation solution will become something similar to

$\left\lceil\mathbf K\right\rceil \equiv \mathbf{kay}$
$\left\lceil\mathbf S\right\rceil \equiv \mathbf{ess}$
$\left\lceil\left(x\;y\right)\right\rceil \equiv \mathbf{cat}\;\left\lceil x\right\rceil\;\left\lceil y\right\rceil$

data CL = K | S | Cat CL CL

and let $\mathbf{kay}$, $\mathbf{ess}$, $\mathbf{cat}$ be the corresponding implementation in combinatory logic (using catamorphism).

## 4 Others

An interesting discussion e.g. on the sociology of how people choose (“adopt”) a programming language: Social science research about programming language adoption?. (Some similar questions are discussed also in Beating the Averages written by Paul Graham). In the mentioned discussion, one of the comments compared Haskell (among programming languages) to Lojban (among human languages).

## 5 References

NC:WhLoj
Nicholas, Nick and Cowan, John (ed.): What is Lojban? Logical Language Group, 2003. Available also online, see the very bottom of the linked page.
Moo:LojPer
Todd Moody: Lojban in Perspective. Available from here, part of Lojban's official homepage
CowNC:CompLoj
John Woldemar Cowan: The Complete Lojban Language. The Logical Language Group, Inc., ISBN 0-9660283-0-9. Draft version (called The Lojban Reference Grammar) available free here.
Hof:GEB
Hofstadter, D. R., Goedel, Escher, Bach: an Eternal Golden Braid, NY: Basic Books, 1979
Tar:BizIg
Tarski, Alfred: Bizonyítás és igazság / Válogatott tanulmányok. Gondolat, Budapest, 1990. (Title means: Proof and truth / Selected papers.)