Vous êtes sur la page 1sur 31

Algorithms

for media-artists
D Perevalov
perevalovds@gmail.com
Contents

1. Algorithms everywhere
2. Work and structure visualization
3. Algorithms-transcoders
4. Generative algorithms
5. Collective algorithms
6. Aesthetics of discontinuity
Algorithms everywhere
What is an algorithm
Algorithm - A sequence of actions.

Algorithms can be
- human actions
- nature events
- inside the computer
Algorithm for human action when
crossing the street

http://inf5-7.gym5cheb.ru/images/blok_sh_primer.jpg
Algorithm for human action in the game

http://1mmofun.ru:8138/WWW/content/grafic/2009/june/rogue.jpg
Algorithms in nature
Algorithm is combinatorial concept, invented and used by humans. For the nature
the notion of algorithm is apparently unfamiliar.
The nature respects the laws of physics. For example, the rebound of particles in a collision with each other -
is the fulfillment of physical law, not the algorithm. Nevertheless, the complex phenomena in the animate and
inanimate nature is sometimes possible to describe the algorithms. For example, the mechanisms for
constructing the protein of the cell's DNA. At the physical level, they are simply manifestations of the forces
of molecular attraction, but the "large" time interval visible stage of this process, which can be called an
algorithm.

DNA Transcription and Protein Assembly


http://www.youtube.com/watch?v=983lhh20rGY
Algorithms in computer
In programming - algorithms are atomic units for constructing
modules and programs.
Work and structure visualization
Sorting algorithm
The task is to order list of numbers:
3, 2, 5, 3, 1, 4 -> 1, 2, 3, 3, 4, 5
Display of work sorting algorithm

Video + Audio performance of the algorithm


Video of the working algorithm
http://www.youtube.com/watch?v=t8g-iYGHpEA- Each
http://www.sorting-algorithms.com/
permutation defines the sinusoid modulation

Representation of the algorithm on the image, each number A dance movement that defines the sorting algorithm
shown by its color. http://www.youtube.com/watch?v=CmPA7zE8mx0
http://flowingdata.com/wp-content/uploads/2010/07/quicksort-
algorithm-visualized.png
Structure visualization program
Maintaining the big programs, in which the number of lines of code more than 1 million, require special
tools for analysis and visualization of their structure and development process.

Structure visualization program. The rings show modules, lines show the calls.

http://www.complex-software.com/
Structure visualization program

Visualization of the the structure of connections for parallel and distributed systems

mCRL2 Toolset
http://www.laquso.com/services/analysis/model.html
Algorithms - transcoders
Transcoding
Almost all types of data (visual, auditory, tactile) - except odors
can now be represented in digital form.

Therefore, using algorithms, you can convert and process


information of different types.

In particular, it is possible to convert from one data type to


another. For example, Image in Sound.
Image in the sound
Brightness of the pixels scanned row by row,
from bottom to top and turn in the amplitude of
the sound.

Video:http://www.youtube.com/watch?v=2GMxaJrTyPs
Original image:
http://thumbs.dreamstime.com/thumblarge_503/127366232431XqYB.jpg
Generative algorithms
Generative algorithms
Algorithms that do not convert the information, and generate it can be called
generating.

"Simple" algorithms are able to generate complex structures.


It is possible if the algorithm simulates an unstable process, or building a self-similar
structure (fractal), or uses a random number generator.

http://3.bp.blogspot.com/_bm3yHeUJ0M4/R1RPURdfXMI/AAAAAAAAAG0/aoSPpVpYj_c/
s1600-R/http---a
Algorithm 1
1. Draw a short line.
2. Rotate right on 10 degrees
3. Go to step 1.

What figure will be drawn?


Algorithm 1
1. Draw a short line.
2. Rotate Left 10 degrees
3. Go to 1.

This is Circle!
Algorithm 2
A= 0 // rotation angle
B= 0 // velocity changing of the rotation angle

1. Draw a short line.


2. Rotate right on A degrees
3. A = A + B
4. B = B + 0.5
5. Change the color of paint every 100 steps
6. Go to step 1.

Which figure will be drawn?


Algorithm 2

First second
Algorithm 2

Second second
Algorithm 2

Tenth of second
Algorithm 2
If in line

4. B = B + 0.5 ?

instead of 0.5 use different numbers?

What happens?
Algorithm 2
0.5 4

17 21
Conclusions
For unstable algorithms people have unable to predict the outcome of
their work. It can only roughly estimate the result of tuning parameters.

This is whole new direction of "programming" -


Creative Coding: Experimenting with algorithms
without knowing exactly what is (and what should be) the result.
Collective algorithms
Collective algorithms
Collective algorithms - a phenomenon that occurs when you run multiple algorithms
simultaneously.

Even if the algorithms does not interact, we can obtain interesting effects.

Most often with the help of such algorithms the behavior of physical phenomena such as
water, fire and fog is simulating. Each particle is described by an algorithm special tuned
parameters.

Fire, 50 particles. The effect of changing images of particles on the overall


picture is shown.
http://www.youtube.com/watch?v=JQbAqzBd2I4
Aesthetics of discontinuity
Aesthetics of discontinuity
Discontinuity is normal for digital information, and today it is normal for modern media-art.
Features of Aesthetics of discontinuity:
1) The discontinuity, discreteness due to the digital representation of information.
2) Avoiding the smooth graphics and sound.
3) Avoiding the continuity of images in time.

In particular, the sign is the use of the imperfection of algorithms:


- "Aliasing", "pixelizing" in the graphics,
and "glitch" and "8-bit“ in sound.

Vadim Smakhtin, Unity Deform Skyence - INSCT


http://vimeo.com/7580344 http://vimeo.com/16219591

Vous aimerez peut-être aussi