incremental grid-like layout using soft and hard ...skieffer.info/talks/gd13slides.pdfincremental...
TRANSCRIPT
Incremental Grid-Like Layout Using Soft and Hard Constraints
or...Grids for Dunnart
Steve Kieffer, Tim Dwyer, Kim Marriott, Michael WybrowMonash University
Graph Drawing 2013, Bordeaux, 23-25 Sep
Wednesday, 25 September 13
Grids for Dunnart?
Wednesday, 25 September 13
Grids StressMinimization
Can Dunnart have grids?
+ =
Why? How?
grid-snapforce
withconstraints
withforces
axis-aligned edges
⇓
Problems Problems ProblemsWednesday, 25 September 13
Why use a grid?
•People like grid layouts?
•Grids promote:
•Alignment
•Nonoverlap
•Distribution
Wednesday, 25 September 13
Nodes are either aligned
or not aligned
never almost aligned
Alignment
Wednesday, 25 September 13
Nonoverlap
If grid is coarse enough, promotes nonoverlap of nodes.
Wednesday, 25 September 13
Distribution
Nodes are distributed
or not
and there is a“global quasi-distribution”
L 2L
Wednesday, 25 September 13
Objection: Dunnart already provides for alignment,nonoverlap, and distribution, using constraints.
Reply: We want a more flexible apparatus, whichis more like “snap-to-grid” when used interactively.
Wednesday, 25 September 13
Grids StressMinimization
Can Dunnart have grids?
+ =
Why? How?
grid-snapforce
withconstraints
withforces
axis-aligned edges
⇓
Problems Problems ProblemsWednesday, 25 September 13
How are grids used in VGEs?
• “snap-to-grid” tool
• “snap lines” tool
• align, and distribute, but not globally
Wednesday, 25 September 13
Most obvious approach:add a “snap force”
Wednesday, 25 September 13
snap force:
Wednesday, 25 September 13
Problem: snap force and basic stress compete
So you can untangle OR land on grid, but not both.
Wednesday, 25 September 13
Solution?
Selectively deactivate grid-snap forcein response to user dragging.
Can make it local?
Wednesday, 25 September 13
Grids StressMinimization
Can Dunnart have grids?
+ =
Why? How?
grid-snapforce
withconstraints
withforces
axis-aligned edges
⇓
Problems Problems ProblemsWednesday, 25 September 13
Stress MinimizationPick an ideal distance L between neighbouring nodes.
Wednesday, 25 September 13
≈2L
≈3L≈L
Stress MinimizationPick an ideal distance L between neighbouring nodes.Then nodes separated by n links should be placedat a distance of about nL.
Wednesday, 25 September 13
≈2L
≈3L≈L
Stress MinimizationPick an ideal distance L between neighbouring nodes.Then nodes separated by n links should be placedat a distance of about nL.
Deviation is measuredby the stress function:
Wednesday, 25 September 13
Stress MinimizationSo when stress is minimized, neighbours are nearby
(under ideal conditions).
High stress Low stress
Wednesday, 25 September 13
Putting it together
Low stress (neighbours nearby)Grid placement
Preferred placement pattern
⇒Wednesday, 25 September 13
One Consequence:
Preferred placementpattern
⇒Axis-aligned edges(where possible)
Note: this abandons global quasi-distribution.
Wednesday, 25 September 13
Grids StressMinimization
Can Dunnart have grids?
+ =
Why? How?
grid-snapforce
withconstraints
withforces
axis-aligned edges
⇓
Problems Problems ProblemsWednesday, 25 September 13
Adaptive Constrained Alignment (ACA)
Idea: - make edges H- and V-aligned - don’t create node-edge overlaps - preserve FD shape if possible - make long H- and V- chains instead of bends
Wednesday, 25 September 13
Adaptive Constrained Alignment (ACA)
Greedy algorithm: Choose “best” edge, and axis-align it. Stop when any further alignment would create an overlap.where “best” = closest to axis-aligned already (preserve FD shape) - but - postpone alignments that create bends until no others remain
Wednesday, 25 September 13
Adaptive Constrained Alignment (ACA)
Problem: As alignment constraints are added, node-edge overlaps can be created and enforced if orthogonal ordering of nodes changes.
Wednesday, 25 September 13
Adaptive Constrained Alignment (ACA)
Solution: Apply a separation constraint along with each alignment constraint, in order to preserve orthogonal ordering.
Wednesday, 25 September 13
Problem
Constraints make graph too rigid.
Wednesday, 25 September 13
Idea: Want to use Lagrange multipliers (LM) to automatically remove ACA’s constraints when the
“tension” on them becomes great enough.
Problem: How to compute the right thresholdfor the LMs?
Is it a function of the number of nodes?
The number of edges?
The number of constraints currently in force?
Not just the number of these things, but their configuration?
Wednesday, 25 September 13
Grids StressMinimization
Can Dunnart have grids?
+ =
Why? How?
grid-snapforce
withconstraints
withforces
axis-aligned edges
⇓
Problems Problems ProblemsWednesday, 25 September 13
Node Snap (NS)
Idea: Allow the user to align edges interactively, by making neighbouring nodes snap into alignment with one another.
Node snap force:
Wednesday, 25 September 13
Idea: Make potential energy wells positioned relativeto nodes; let them move when nodes move?
Problem: Can we recover global quasi-distribution?
Wednesday, 25 September 13
Grids StressMinimization
Can Dunnart have grids?
+ =
Why? How?
grid-snapforce
withconstraints
withforces
axis-aligned edges
⇓
Problems Problems ProblemsWednesday, 25 September 13