Menu
Close
Theme
Close

Themes

Languages 语言

中文

Graph Layout

The graph drawing problem is about, in my understanding, given the connections between nodes, how to assign each node a physical position such that their physical distances reflect their "in graph" distances.

What did I do

Timeline

Idea

The idea of the graph layout is fairly simple: we recursively extract the backbone structure of a graph until it is simple enough, visualize the simplest version, recursively put the graph "flesh" back, and tune the position of nodes accordingly during the process.

In addition to that, how to design the graph storage file for the web and, locally, for a natural experience of managing the results of different programming languages is also an interesting problem to think about.

Graph Representation

We need to think about a graph representation that is natural and easy for web, Three.js 3D display, and local calculations.

Graph Coarsening: Maximum Independent Vertex Set

How to get the backbone of a graph that generally preserves the original imaginary positions of nodes can be important. I guess selecting vertices with less degree can be helpful to get the outer boundary "framework" of the original graph.

Graph Refinement

How to put the original graph's fresh back onto the backbone of visualized coarsed graph is an interesting problem to think about. Sometimes, multiple vertices of the same set of neighbors might to put into the same position, causing numerical issue of zero division.

Barnes-Hut Tree

This is a very interesting data structure that accelerates the N-body force calculation. To some extent, the tree is an intriguing bridge between areas of numeric calculations and data structures. In general, for a node, the mass point, the tree tries to treat a large group of relatively far away nodes as one single super node. In this way, we no longer need to loop through all the other nodes and calculate forces. In the visualization below, we can see how nodes in a single cell are treated as a supernode. And the supernode becomes small when its nodes are close to the target node.

1771445321832