Short reference distance

Claim: each concept sits close to the places that use it, and the order of a document is chosen so that prerequisites come first and the total distance between definitions and uses is small.

What it asks

  • Define a concept in the part that first needs it (define before use), not in a glossary far away.
  • When a definition is far from a use, give a one-line reminder at the use and link back.
  • Order the parts by their prerequisites; among the orders that respect them, prefer the one with the shorter total distance.

Why

Linking a word to a distant head costs more with each new discourse referent in between (Gibson 1998), and languages keep dependencies shorter than random reorderings in all 37 languages tested (Futrell et al. 2015).

The order can be computed. Write the concepts as a graph, an edge u → v meaning v uses u, and an order π that puts u before v. The total distance is

D(π)=∑u→v(π(v)−π(u))=∑xπ(x)(in(x)−out(x)).D(\pi) = \sum_{u \to v} \big(\pi(v) - \pi(u)\big) = \sum_x \pi(x)\,\big(\mathrm{in}(x) - \mathrm{out}(x)\big).

For example, with three prerequisite edges:

A graph of prerequisites: B and D use A, and C uses B.
Graphviz source
digraph reference_graph {
  graph [rankdir=LR, nodesep=0.4, ranksep=0.5, bgcolor="white", pad=0.2, fontname="Inter"];
  node  [shape=box, style="rounded,filled", fontname="Inter", fontsize=13, margin="0.2,0.1", penwidth=1.5, fontcolor="#1F2328"];
  edge  [fontname="Inter", fontsize=11, color="#3D434B", fontcolor="#55575F", penwidth=1.3, arrowsize=0.8];
  A [label=<<b>A</b>>, fillcolor="#FFFFFF", color="#3D434B", shape=circle, style="filled", margin="0.05"];
  B [label=<<b>B</b>>, fillcolor="#FFFFFF", color="#3D434B", shape=circle, style="filled", margin="0.05"];
  C [label=<<b>C</b>>, fillcolor="#FFFFFF", color="#3D434B", shape=circle, style="filled", margin="0.05"];
  D [label=<<b>D</b>>, fillcolor="#FFFFFF", color="#3D434B", shape=circle, style="filled", margin="0.05"];
  A -> B;
  B -> C;
  A -> D;
}
Order A→B B→C A→D Total
A B C D 1 1 3 5
A B D C 1 2 2 5
A D B C 2 1 1 4, the shortest

In general it is a weighted sum of positions under precedence, that is single-machine scheduling. It is solvable in polynomial time when the prerequisites form a rooted forest, or more generally are series-parallel (Lawler 1978, read in its 1976 report). Without precedence it is Minimum Linear Arrangement, NP-complete in general (Garey et al. 1976) and polynomial on trees (Chung 1984).

Limits

In natural reading, distance costs weakly outside nouns (Demberg & Keller 2008). Whether the general precedence case with these weights is NP-hard is not known to this review. A document is reread and searched, which no sentence experiment measured.