"SpringEmbedding" (Graph Layout Method)

Details & Suboptions

  • The spring embedding is a graph-drawing technique to position vertices of a graph so that they minimize the mechanical energy when each edge corresponds to a spring.
  • The spring embedding is typically used to lay out regular structured graphs.
  • The layout xi of the vertices i of the graph is calculated by minimizing the energy function
  • sum_(i=1)^(|V|-1)sum_(j=i+1)^(|V|)w_(ij) ( ||x_(i)-x_(j)||^2- l_(ij) )^2.
  • is the graph distance between vertex i and j and is the relative spring length.
  • Vertices can be embedded in .
  • The following graph parameters can be given:
  • "EdgeWeighted" whether to use edge weights
  • Possible settings to control the energy minimization process include:
  • "EnergyControl"how the energy function is controlled during minimization
    "InferentialDistance"cutoff distance for inference from faraway vertices
    "MaxIteration"maximum number of iterations
    "RandomSeed"seed for the random generator for initial vertex placement
    "StepControl"how step lengths are modified during energy minimization
    "StepLength"initial step length used in moving the vertices
    "Tolerance"tolerance used in terminating the process

Examples

open allclose all

Basic Examples  (2)

Place vertices so that they minimize mechanical energy when each edge corresponds to a spring:

"SpringEmbedding" works best for regular structured graphs:

Options  (8)

"EdgeWeighted"  (1)

With the setting "EdgeWeighted"True, edge weights are used:

"EnergyControl"  (1)

Use the option "EnergyControl"e to specify limitations on the total energy of the system during minimization:

"InferentialDistance"  (1)

Use "InferentialDistance"d to specify a cutoff distance beyond which the interaction between vertices is assumed to be nonexistent:

"MaxIteration"  (1)

Use "MaxIteration"it to specify a maximum number of iterations to be used in attempting to minimize the energy:

"RandomSeed"  (1)

Use "RandomSeed"int to specify a seed for the random number generator that computes the initial vertex placement:

"StepControl"  (1)

Use "StepControl"method to define how step length is modified during energy minimization:

"StepLength"  (1)

Use "StepLength"r to specify the initial step length used in moving the vertices around:

"Tolerance"  (1)

Use "Tolerance"r to specify the tolerance used in terminating the energy minimization process: