IDE AS
IDEAS

Designing digital tools
for algorithmic writing
in a creative work

Hugo Sainte-Marie
Research paper – 2018
DSAA (Master 1) Interactive Design
Pôle supérieur de Design – Villefontaine

This is a shortened version of my final year dissertation. For the full text, please refer to the French version.

Introduction

In the last few years, algorithms have entered our lives, and we now meet them everywhere daily, without actually noticing them. In the book “Le temps des algorithmes”, French researchers and teachers Serge Abiteboul and Gilles Dowek list many examples of various uses of algorithms, embedded into our digital devices: calculation, managing information, communication, exploration and analysis of data, but also signal treatment, driving objects, manufacturing goods, scientific research, etc.

The growing presence of algorithms in our lives might raise anxiousness and can enter the political debate. Although, we tend to forget a fundamental characteristic of algorithms: they are written by human beings. The programs we use everyday are or have been developed by programmers, who use specific tools to achieve this job. These tools are the core field of study of this dissertation, which of course will be led with a design approach – that is to say, focusing on uses and users.1

I will tackle this topic with a very empirical way of thinking: I’m one of those people who need to experiment to understand. Considering the technical dimension of algorithmic writing, its practice is a method for me to give the study a concrete aspect by providing applied solutions. The possibilities are quite endless: musical creation, learning an algorithmic way of thinking, visualizing immateriality, playing with a machine, etc. Among other disciplines, those matters are addressed by creative coding2, live coding3 and more.

If I had to give an example of a designer whose practice inspires me, I would probably mention John Maeda. Altogether an artist, designer, teacher and researcher at the MIT, Maeda has acquired an international reputation as a pioneer of a discipline mixing visual arts, design, typography and interaction design, often using computers and programming. At the heart of his process lies the will to create devices and tools, that he uses to produce artworks. As Paola Antonelli wrote in the foreword of Maeda’s book “Design By Numbers”, “The most important part of Maeda’s production […] is not the final object, but rather the process. […] Maeda’s fundamental idea is that to successfully design with a computer, one has to design, or at least understand, the program one uses.”4

After defining and illustrating the main notions put into play – algorithms, writing, programming, code –, I will establish different categories of algorithmic writing interfaces and what they enable users to do. The final goal is to question the interfaces themselves, considering algorithmic writing as a material.

The algorithmic material

What is an algorithm?

Instructions and result

An algorithm is a finite sequence of instructions, which aims to be executed in order to produce a result. To understand the notion of algorithm easily, we often use concrete examples that we meet in our everyday lives. A cooking recipe, for instance, is an algorithm: it involves inputs (the ingredients, quantities, tools), and instructions (break in small pieces, cook in a bain-marie, cut into dices, etc.). By following the recipe thoroughly, the outcome is, obviously, the prepared dish.

Symbolic algorithms

This general definition includes a more specific kind of algorithms, which is called symbolic algorithms. These manipulate written symbols: digits, letters, numbers, words or sentences. Etymologically, the term algorithm itself comes from the combination of the latin word algorismus – from the name of the mathematician Al-Khwarizmi5 – and the Greek word arithmos, which means “number”. This proximity between the notions of algorithmic and mathematics has been confirmed thanks to the technical progress of the last two centuries.

Historical approach

From the hand to the machine

Let’s head back to the origins of symbolic algorithms, 5,000 years ago. At that time, mathematicians had already developed algorithms to solve simple algebraic calculations such as additions and multiplications, but these had to be executed by the hand of a scribe: repetitive tasks that could be delegated to machines.

Five thousand years of technical innovation followed. The first abacus6 assisted human beings in calculating but weren’t autonomous yet. In the Middle Age, the bells at the top of cathedrals rang every hour without any human assistance: these are the first machines capable of executing symbolic algorithms. In 1642, French inventor Blaise Pascal7 came up with the first calculating machine, that he called “arithmetic machine”.

Jacquard’s programmed weaving

In 1801, Joseph Jacquard, an inventor from Lyon in France, creates a weaving machine that will bear his name: in French, “le métier Jacquard”. It combines classic weaving machines with punched cards, a contraption invented in 1728 by Jean-Baptiste Falcon. By punching a whole at a specific spot of a piece of cardboard, one is able to program a machine. This device is often considered the first form of binary information storage, binary being a two-state value, often called true or false. Jacquard’s weaving machine is therefore contemplated as the ancestor of computers.

But these machines are not yet computers, strictly speaking. They lack a major characteristic to reach this status: universality. In fact, the examples cited above are only capable of one specific function, whereas a computer is multipurpose, universal, that is to say, capable of executing any imaginable symbolic algorithm: in short, an all-purpose machine.

Babbage’s analytical machine

In 1834, British visionary Charles Babbage8 started working on a new concept of machine, that he called an “analytical machine”. Based on mechanical computing machines that had existed for a few centuries, Babbage’s contraption uses punched cards, similarly to Jacquard’s. The components of his invention are quite similar to those you may find in a modern computer.

While working on this project, Babbage started writing to Ada Lovelace, a pioneer in computer science. In 1843, Lovelace originated the first algorithm to be executed on a machine, Charles Babbage’s “differential machine”. This algorithm computes the Bernoulli numbers sequence9 and is considered the first computer program in history, turning Lovelace into the first known programmer.

The Turing revolution

The works of Lovelace and Babbage are rediscovered a century later, in the 1930s, especially thanks the research of Alan Turing10. This inventor, an emblematic figure of the scientific research of the twentieth century, designed his “Turing machine” in 1936, so as to give a precise definition to the concept of algorithm, and to propose a formal and technical representation of a “mechanical procedure”.

Thereby, Turing illustrates the notion of universality as Lovelace and Babbage framed it. Turing’s machine is viewed as the genesis of John von Neumann’s works, whose model, although designed in 1945, is still used in modern computers: we call it the “Von Neumann architecture”. Transposing the hardware used back then into latter-day vocabulary confirms this proximity:

  • a processor performs operations ;
  • the Random Access Memory (RAM) stores the data in use ;
  • hard drives – and other storing devices – hold sustainable data ;
  • all kinds of peripherals allow interaction as inputs (keyboard, mouse, touchscreen, microphone, camera, USB ports, etc.) and outputs (screen, speakers, etc.)

Fundamental approach

Algorithms are alike: they are made of a restrained amount of structuring expressions that are similar to one another. According to Abiteboul and Dowek, any algorithm can be conceived with only four basic instructions: sequence, assignment, iteration and condition.11

Sequence

Sequence

The sequence is the very order in which instructions are laid out, that is to say, the structure of the algorithm itself: “do this, then that”. When represented – either written or drawn –, an algorithm is usually read from top to bottom, in accordance to the usual reading direction in many languages.

Assignment

Assignment

An assignment is the fact of allocating a value to a variable – for instance, “a takes the value of b”. A variable is made of a noun (its identifier) and a unique value at any time. This value can be numerical, textual or even a boolean: true or false.12

Iteration

Iteration

Commonly referred to as loop, an iteration is the fact of repeating a set of instructions. This concept is essential, since algorithms are generally designed to automate repetitive tasks. There are different kinds of loops depending on their purpose, such as the for loop, the for each loop or the while loop.

Condition

Condition

Finally, the condition, or conditional test, allows to perform an instruction or not, depending on the value of a given variable: for instance, “if this is true, then do that”. The layout “if, then, else) is generally referred to as a conditional expression. These enable an algorithm to take different “paths”, and therefore to be more flexible and adapt to the complexity of real data.

Algorithmic writings

What is writing?

Writing and language

Writing is a communication method that consists in representing a language through marking down graphic symbols on various materials. Writing was born four thousand years before our era, in Mesopotamia, in order to keep track of trades – in particular commercial ones – because of the human brain’s unreliability to remember a large amount of information for a long time.

Writing involves languages. The term “language” can mean two things, either the faculty and the system, or the means of expression, the use. A language is usually composed of semantics, and, most of the time, syntax. Those two notions are the symmetrically opposite: semantics is a branch of linguistics which focuses on the signified – what one talks about – whereas syntax deals with the signifier – the language, the graphic representation, the grammar used, etc. In short, the content is opposed to the format.

Types of writings

Writing usually involves at least two people: the writer, the one who produces the writing, and the reader, who receives it – by reading. So far, I’m not necessarily talking about text. In fact, the wider notion of writing includes various ways of representing information graphically: drawings, symbols, digits, letters, etc. Nevertheless, the generally admitted meaning of the term “writing” refers to three main categories of systems: logographic – which employs logograms to represent an object or a notion –, syllabic – which uses symbols representing one syllable each – and alphabetical – the one we know the best, composed of phonemes, the smallest linguistic unit.

Alternative writings

There is no need for me to go into further details about the writing forms that we already know: from page to page, putting words end to end in a Latin alphabet, from left to right and top to bottom. To question the notion of writing, I would rather focus on less usual representations. According to French author Anne-Marie Christin, the most relevant example, which freed the western way of writing, is a piece of work by Stéphane Mallarmé, a French poet of the nineteenth century. In the “Coup de dés”, he spatializes letters and words, leading to what is known as a “typographic poem” – one of the first.

Excerpt of Mallarmé's "Coup de Dés"

French poet Guillaume Apollinaire played with a similar principle in his book “Calligrammes” published in 1918. This particular form of poetry is sometimes named “graphical poetry”.

Apollinaire's "Il Pleut"

By transposing these distinctions to the field of algorithms, one could easily question the form that could take an “alternative writing” of an algorithm, such as a poetic writing. The book “./code-poetry” by Daniel Holden and Chris Kerr, as well as its website, give a few examples of programs that break free from the usual conventions of code writing, and the results are essentially aesthetic: in short, poetic code.

Flocking.go, a poetic animated program in Go language

Computer writing

From the algorithm to the program

A computer program is a sequence of instructions that performs specific tasks when executed on a computer.13 French academic Franck Varenne draws our attention onto a possible origin of the confusion between algorithms and programs. In fact, even if a written algorithm seems functional, its execution might give unsuspected results, because of several possible errors, either from the software – unassigned variables, overflowed memory – or the hardware – damaged processor, etc. This uncertainty between the program one sees and what happens when it’s executed has been named WYSINWYX, for What You See Is Not What You Execute14. This acronym is a reference to the paronym it’s inspired of: in computer science, the term WYSIWYG —What You See Is What You Get – refers to interfaces where the desired end result is directly composed on screen.15

Natural languages and formal languages

In the field of linguistics, we call “natural language” any language that has naturally evolved through human use and repetition, without particular planning or conscious premeditation. The opposite is called “formal language”, sometimes “constructed language” or “artificial language”. It refers to a language made up from scratch in a relatively short period of time, by a much smaller population – possibly the work of a single person. We can distinguish three categories among these constructed languages:

  • engelangs (for engineered languages), once again divided into logic languages (such as programming languages), philosophical or experimental languages ;
  • auxlangs (for auxiliary languages), created for international communication – one of the best known being Esperanto ;
  • artlangs (for artistic languages), like those from a work of science fiction or fantasy (like the languages ​​created by the author J. R. R. Tolkien).

Programming languages

There is a wide variety of programming languages. They all have syntax rules, vocabulary, semantics, vocabulary and identifiers of their own. The choice of one programming language to start a project with depends on a handful of parameters. For instance, all programming languages can be considered as tools, and are more or less suitable for a given task. Moreover, programmers have different skills and tastes, and pick a language consequently.

Let me focus on two types of languages ​​that seem to stand out from “classic” programming languages, the most popular nowadays being JavaScript, Python, Ruby, Java, PHP or C ++, according to a study16 conducted by the collaborative development platform GitHub17. The first one is a way to describe an algorithm using a natural language, without referring to a particular programming language: we call it pseudocode. It has no rule or established convention, and is usually employed in order to measure the difficulty of designing a specific algorithm.

An example of pseudo-code

Another category of language that questions the limits of programming languages ​​is one called “esoteric” languages, or esolangs. The term “esoteric” refers to a form of secret or hermetic teaching. In fact, whether they are used as software works, intellectual exercises or even jokes18, these languages require a good knowledge of classical programming languages prior to manipulating them. One of the best known is called Brainfuck. By using only eight distinct characters, this language leads to particularly obfuscated code.19 Another particularly interesting example is Piet, named after the famous Dutch painter Piet Mondrian. This language is not textual but graphic: the programs are images that could be confused with abstract art, freely inspired by the works of the eponymous painter.

Examples of esoteric languages

Algorithmic writing systems

Development environments

An “Integrated Development Environment” (IDE) is a set of tools a developer uses to produce a computer program. An IDE generally is a software whose interface includes tools and functions: usually a text editor where the programmer writes down lines of code, a debugger to find and correct bugs, and sometimes – if the language needs it – a compiler to “translate” the programming language into machine language, that is to say instructions that the computers understands.

Screenshot of the programing software AtomScreenshot of the programing software Atom

Lines of code

Code, as French archaeologist and linguist Clarisse Herrenschmidt defines it, is “a way to encipher, specific to the machine that encrypts and decrypts.”20 Lines of code are the best known and most used form of programming. Almost any digital device or application that we use daily have been coded in a text editor, line by line, one symbol at a time.

Visual programming

Programming can also take a graphic, visual form. For instance, it is the case when representing algorithms with diagrams, also called flowcharts. The instructions are divided into various geometric shapes – a rectangle for an operation, a diamond for a conditional test, etc. –, which are linked altogether to symbolize the sequence of instructions. This modeling, particularly used in education, is employed in programming software such as Flowgorithm.

Screenshot of Flowgorithm softwareScreenshot of Flowgorithm software

Visual programming can also break free from the standardized representation of a flowchart. The best-known example is Scratch, a software that researchers of the MIT have been developing for about fifteen years. Scratch depicts algorithmic programming as a puzzle game, made up different kind of “blocks”, each representing a particular type of operation. The blocks are nested to shape the structure of the program. Its simple and colorful interface and its intuitiveness make it the perfect tool for young creative pupils, and Scratch is overall a great way to understand logical thinking.

Screenshoft of Scratch softwareScreenshoft of Scratch software

Singular modes of algorithmic programming

These examples transpose classic algorithmic writing into a more empirical and physical way of thinking: the components that make up the algorithm are directly manipulated, mentally. This opens the way towards wide creative possibilities: what would be a material algorithm, out of the screen? What kind of “manipulation” opportunities would that allow?

For the future of my project, I aim to point out such opportunities by taking a step back on the different ways of writing algorithms, to then produce a few concrete applications, especially creative ones.


  1. Numerous examples of algorithms being used in the field of design are listed on the website algorithms.design, especially those involving artificial intelligence, a branch standing in the spotlight nowadays. ↩︎

  2. Creative coding is a kind of computer programming where languages are used in order to produce an expressive or artistic outcome rather than a functional one. ↩︎

  3. Live coding is a practice in which programming becomes an improvised performance – often a musical one. ↩︎

  4. John Maeda, Design By Numbers (2001), MIT Press, p. 10–11 ↩︎

  5. Muhammad Ibn Mūsā al-Khuwārizmī was a Persian mathematician, geographer, astrologer and astronomer. He’s the author of a book classifying existing algebraic processes of his time. ↩︎

  6. The term abacus means any mechanical device that helps calculation. ↩︎

  7. Blaise Pascal was a French mathematician, physicist, inventor and philosopher. At the age of 19, he invented the first computing machine. ↩︎

  8. Charles Babbage was a British mathematician and inventor during the nineteenth century. He was one of the first researchers in computer science. ↩︎

  9. In mathematics, the Bernoulli numbers are a sequence of numbers that were first studied by Jacques Bernoulli, a Swiss mathematician and physicist during the eighteenth century. ↩︎

  10. Alan Turing was a British mathematician and cryptologist, whose works founded modern computer science. After designing the Turing machine, he took part in the decryption of the German “Enigma machine” during World War II – which played a significant role in the victory of the Allies. Turing carried on with his studies in computer science and formulates the “Turing test”, a key notion in the field of artificial intelligence. Judicially pursued for his homosexuality, Turing chose chemical castration to avoid imprisonment. He died in 1954 of cyanide poisoning, presumably by suicide. ↩︎

  11. Serge Abiteboul & Gilles Dowek, Le temps des algorithmes (2017), Essai le Pommier, p. 18–19 ↩︎

  12. Un Boolean is a two-state kind of variable. Its name comes from the works of George Boole, a famous British mathematician and logistician who establishes the basics of “Boolean logic”, which deals with two numeric values only: 0 and 1. This way of thinking is of capital importance in computer science and is still widely used nowadays. ↩︎

  13. Computer program on Wikipedia ↩︎

  14. G. Balakrishnan, T. Reps, D. Melski, et T. Teitelbaum, WYSINWYX: What You See Is Not What You eXecute (2005) ↩︎

  15. WYSIWYG on Wikipedia ↩︎

  16. GitHub Octoverse 2017 ↩︎

  17. GitHub is a collaborative hosting platform for file versioning. Based of the utility git, that allow to save checkpoints of one’s work – called commits –, GitHub lets everyone share his code and anyone can get involved: this practice is called open-source. ↩︎

  18. The website esoteric.codes gathers several creative examples involving esoteric languages. ↩︎

  19. In programming, to “obfuscate” means making a program unreadable for human beings. ↩︎

  20. 9:395 ↩︎

It's getting late.The page has automatically switched to night mode.
Go back to day mode.

FREN