Titan is a development platform for incremental optimisable search and enumeration. In Titan, programs are defined as relations between values, which can be defined by formulae according to rules for application and search. For this, Titan defines:
Titan's reference language is extremely simple: conceptually, programs are databases of relations specified as sums of rows, each row relating the values in its columns together. The major tricks added to this, however, are:
(gcd 111 259)
=> 37
(gcd 111 259 37)
=> []
(gcd)
=> { [@_1 0 @_1] [@_1 @_2 (gcd @_2 (% @_1 @_2))] }
(gcd 111)
=> { [0 111] [@_2 (gcd @_2 (% 111 @_2))] }
(gcd @_1 259)
=> [@_1 (gcd 259 (% @_1 259))]
The alphabet of the Titan reference language is in the Unicode 10 character set. Several subsets are named here for future reference:
0123456789
, named digit,0
;01
, named bdigit;01234567
, named odigit;0123456789ABCDEF
, named hdigit;()[]{}'"@
;`.\/%^*+-#&|~=<>!?:;,
, named symbol;_
.() [] {}
;_
|letter|symbol)(_
|alpha|symbol)*
@
name
-
?ndigit(digit +(.
digit +)?|(.
digit +)?(e-
?ndigit digit *)?)?0
(.
digit+|b
bdigit+|o
odigit+|x
hdigit+)?'
((\
|'
)-|\
(\
|'
))'
"
("
-|\
("
|\
))*"
\*
(*\
)-*\
\\
(newline)-newline
The full grammar of the Titan reference language is:
E ::= | AE
A ::= name | variable | number | string | [
E]
| {
E}
| (
E)
Note that there are no reserved identifiers.
Titan's standard library is divided into three major parts: Language, Environment, and Algorithms. All definitions in the standard library are abstract data/negative types, meaning they are defined in terms of their projection relations. Only the Language part is mandatory, and the two other parts can be defined in terms of it.
The Language part contains the abstract data types of the core constructs of the language.
The Algorithms part contains the abstract data types for complex operations on the core constructs of the language.
The Environment part contains data types for interfacing with other systems.
Titan's reference implementation will be code-named Othrys, after the mountain home of the Greek titans (as opposed to Olympus, the home of the Olympian deities).
Titan's bootstrap implementation, in progress, is code-named Chaos, after the root deity of the Greek Pantheon.
Daniel Campos do Nascimento © 2025-