Cells and clusters

This week I have been working on cell and cluster layout.

Cell layout

It is pretty easy to imagine this layout. Based on number of elements and their sizes, the drawing space is divided into invisible cells. Each of those is occupied by a vertex, which are then connected with edges.

Cluster layout

In this type of layout we position vertices in such positions that they form a cluster, which represents a group of objects that are positioned close together. Let's put it in another perspective. In context of servers, cluster is a group of computers that are connected with each other and operate closely, as if they were one computer.

In order to implement this layout, firstly I needed to add some methods into the root class of all layouts:

Then I implemented necessary classes and methods for the layout itself:

Beside the layouts, I added better explanations to some methods, changed method classifications and adopted some expected results.