Skip to content

jkndrkn/erlang-tman

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

John David Eriksen
john DOT eriksen AT yahoo DOT com
http://www.jkndrkn.com

Overview:

An Erlang implementation of the T-Man algorithm detailed in the paper "T-Man: Gossip-based Overlay Topology Management" by Jelasity and Babaoglu. The network is conceptualized as nodes represented as vertices within a two-dimensional grid.

This implementation of the T-Man algorithm contained in the file tman.erl is able to successfully build a network with a sum of distances substantially lower than that of a purely random system (see plot-1.png and distances.dat).  The most dramatic changes happened in the first five generations, with only a very gradual improvement in sum of distances occurring after that interval.

These results are illustrated graphically in a series of image renderings of the mesh network (see GIF images in graphs directory). Note how the long and chaotic edges in the first generation gradually yield to a nearly perfectly converged grid-like mesh in subsequent generations. 

Usage:

1. Start the Erlang shell.
$ erl

2. Compile the source code.
> c(tman).

3. Run the T-Man algorithm with parameters Nodes = 900, Neighbors = 20, Cycles = 50, Size = 30 x 30.
> tman:init().

4. Run the T-Man algorithm user-specified nodes N and neighbors k
> tman:init(N,k).

5. Exit the Erlang shell.
> q().

File Listing:

distances.dat   Raw output generated by running T-Man algorithm with parameters as in Usage step 3.
graphs          Directory containing graphs generated by running T-Man algorithm using function init/5 with GraphOutput parameter true. 
Makefile        GNU Make Makefile. Provided here simply for cleaning up unneeded binaries. 
plot-1.png      Plot generated by gnuplot using distances.dat data file.
plot-data.gnu   gnuplot script used for generating plot-1.png.
tman.erl        Project source code.
tman.hrl        Project header file containing constant and macro definitions and the Erlang record definition of a node structure.

Dependencies:

To generate the images used by graphs, ImageMagick needs to be available. gnuplot or any other graphing software can be used to plot the raw distance output of this program.

About

An Erlang implementation of the Topology Management protocol by Jelasity and Babaoglu.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages