Papers
Topics
Authors
Recent
Search
2000 character limit reached

Quadratic Wiggle Height Minimization

Updated 9 July 2026
  • Quadratic wiggle height minimization is a quadratic optimization framework that penalizes large vertical displacements using squared curvature and roughness measures.
  • It underpins applications such as ordered storyline visualization, discrete smoothing, and stacked area charts by enforcing smooth and structured transitions.
  • The approach leverages convex quadratic programming to efficiently optimize coordinate assignments under linear constraints, balancing performance and accuracy.

Quadratic wiggle height minimization denotes a family of quadratic optimization problems in which “wiggle” is penalized by a sum of squared vertical displacements, a curvature energy, or a roughness functional. In ordered storyline visualization, the canonical objective is

QWH(y)=t=11cA(t)A(t+1)(yt+1,cyt,c)2,\mathrm{QWH}(y)=\sum_{t=1}^{\ell-1}\sum_{c\in \mathcal{A}(t)\cap \mathcal{A}(t+1)} (y_{t+1,c}-y_{t,c})^2,

where yt,cy_{t,c} is the yy-coordinate of character cc at time tt (Dobler et al., 27 Aug 2025). In quadratic smoothing, the same idea appears as

f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,

with AA chosen to encode curvature or roughness, for example A=DDA=D^\top D for a second-difference operator DD (Levi et al., 2018). In Hilbert-space formulations, a canonical wiggle functional is

Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,

represented by a positive semidefinite operator yt,cy_{t,c}0 (Pappas, 2010). In stacked area charts, the quadratic objective is the sum of squared border changes over time (Dobler et al., 26 Jun 2025).

1. Formal problem classes

Several mathematically distinct models instantiate the same basic principle: large vertical changes are penalized more heavily than small ones because the penalty is quadratic. In storyline visualization, the decision variables are the layer-wise character coordinates yt,cy_{t,c}1, constrained by per-layer orderings and spacing rules. In smoothing and regularization, the variables are either vectors yt,cy_{t,c}2 or functions in a Hilbert space, and the objective is a quadratic form induced by a difference, Laplacian, or derivative operator. In stacked area charts, the optimization variable is typically the ordering yt,cy_{t,c}3, and the quadratic objective is defined on the resulting cumulative borders (Dobler et al., 27 Aug 2025, Levi et al., 2018, Pappas, 2010, Dobler et al., 26 Jun 2025).

Setting Variables Quadratic wiggle objective
Storylines yt,cy_{t,c}4 yt,cy_{t,c}5
Discrete smoothing yt,cy_{t,c}6 yt,cy_{t,c}7
Hilbert-space smoothing yt,cy_{t,c}8 yt,cy_{t,c}9
Stacked area charts ordering yy0, borders yy1 yy2

The discrete and continuous versions are closely aligned. A second-difference penalty in yy3 and the Sobolev-space energy yy4 both penalize curvature; the storyline objective yy5 penalizes temporal displacement rather than second derivative, but it is likewise a positive semidefinite quadratic objective (Levi et al., 2018, Pappas, 2010, Dobler et al., 27 Aug 2025).

2. Ordered storyline formulation

A storyline instance is a 4-tuple yy6, where yy7 is the set of characters, yy8 is an ordered set of discrete time steps, yy9 is the set of meetings, and cc0 is the set of time steps for which character cc1 is active. Each active character cc2 has a coordinate cc3 at time cc4. An ordered storyline instance specifies, for each cc5, a permutation cc6 of the active characters cc7, with the requirement that every meeting at time cc8 appears as a consecutive block in cc9. A coordination is valid if tt0 whenever tt1 (Dobler et al., 27 Aug 2025).

The paper defines tt2-nice coordinations by two spacing parameters tt3 and tt4. If two consecutive characters in tt5 belong to the same meeting, then tt6; otherwise tt7. With neighbor sets

tt8

the full QWHMin model uses variables tt9 and the linear constraints

f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,0

f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,1

optionally together with f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,2. The direct quadratic objective is

f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,3

This is a convex quadratic program: the objective is a sum of squares, the constraints are linear, and in matrix form the Hessian is block-diagonal with nonnegative diagonal elements, i.e., positive semidefinite. The formulation is explicitly downstream of ordering, because crossing minimization is NP-hard and QWHMin assumes that the permutations f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,4 are already fixed (Dobler et al., 27 Aug 2025).

3. Solver model, routing geometry, and empirical behavior

For the alignment phase, QWHMin is solved as a continuous convex QP. The implementation described in the paper uses Gurobi (12.0.2); the LP for linear wiggle height minimization (LWHMin) and the ILP for wiggle count minimization (WCMin) use the same coordinate variables, but QWHMin requires no binary variables, and branch-and-bound appears only for WCMin (Dobler et al., 27 Aug 2025).

After computing the optimal coordinates f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,5, the routing phase replaces each vertical move by two circular arcs with radii f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,6 and f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,7 meeting tangentially at a crossover point. Writing

f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,8

and f(x)=xAx+bx+c,f(x)=x^\top A x + b^\top x + c,9 for the horizontal width of transition block AA0, the exact geometric relation is

AA1

A curve segment is AA2-monotone iff AA3, equivalently AA4. For each transition AA5, the paper solves an LP that minimizes AA6 subject to this relation, lower bounds AA7, and additional linear constraints that enforce monotone radial distance for neighboring curves running in parallel.

The comparison among objective functions is structurally important. LWHMin minimizes AA8 and tends to distribute vertical movement more uniformly; QWHMin minimizes AA9 and therefore penalizes large movements more strongly, preferring many small movements over a few big ones; WCMin minimizes the number of nonzero movements and can therefore force some remaining movements to become large. On the reported benchmark instances, LP/QP runtimes were typically A=DDA=D^\top D0–A=DDA=D^\top D1s on most instances, whereas ILP runtimes for WCMin ranged from sub-second to hours and sometimes did not finish within 24 hours. The case study spans novels, blockbusters, publication data, and rolling stock schedules; QWHMin achieved the minimum quadratic wiggle, but the paper notes that with the two-arc rendering style it could increase width and perceived oscillation relative to LWHMin (Dobler et al., 27 Aug 2025).

4. Smoothing, curvature penalties, and constrained formulations

Outside storyline visualization, quadratic wiggle height objectives are standard quadratic roughness penalties. A general unconstrained form is

A=DDA=D^\top D2

and a sphere-constrained version is

A=DDA=D^\top D3

A “wiggle height” penalty can be modeled by choosing A=DDA=D^\top D4 to encode curvature or roughness. For second-difference smoothing, with second-difference matrix A=DDA=D^\top D5, one sets A=DDA=D^\top D6 with A=DDA=D^\top D7, giving

A=DDA=D^\top D8

which penalizes curvature. For graph-based signals, one may set A=DDA=D^\top D9 or DD0 with DD1 a graph Laplacian, thereby penalizing variation across edges (Levi et al., 2018).

In Hilbert spaces, the same principle is expressed through positive operators. Let DD2 be a complex Hilbert space, DD3 bounded, self-adjoint, and positive semidefinite, and consider the quadratic objective DD4. Under linear constraints DD5, the feasible set is DD6. If DD7 is positive semidefinite with closed range, minimization is performed on DD8, and the minimal-energy minimizer is

DD9

For a canonical wiggle functional on Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,0,

Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,1

one sets

Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,2

Then Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,3 consists of polynomials of degree Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,4, so nonuniqueness arises unless the constraints fix that affine space. If Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,5, then the minimum value is Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,6; otherwise the minimizer is unique in Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,7 (Pappas, 2010).

This operator-theoretic view makes clear that quadratic wiggle height minimization is not tied to a single application domain. It includes minimum-curvature interpolation, minimum-variation smoothing on graphs, and discrete trust-region subproblems, all under a common positive-semidefinite quadratic structure (Levi et al., 2018, Pappas, 2010).

5. Sublinear-time approximation for very large quadratic objectives

When the wiggle objective is encoded as a large quadratic form, one can approximate its minimizer in sublinear time under a random-access model. The input is Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,8, Wiggle(f)=abf(t)2dt,\mathrm{Wiggle}(f)=\int_a^b |f''(t)|^2\,dt,9, yt,cy_{t,c}00, and the algorithm assumes random access to entries yt,cy_{t,c}01 and yt,cy_{t,c}02, with bounded entries such as yt,cy_{t,c}03. It samples a random index set yt,cy_{t,c}04 by including each index independently with probability yt,cy_{t,c}05, where

yt,cy_{t,c}06

The unconstrained algorithm forms yt,cy_{t,c}07 and yt,cy_{t,c}08, solves the sampled quadratic, and optionally lifts the sampled minimizer by zero-padding. The sphere-constrained variant solves the sampled trust-region problem with scaled radius

yt,cy_{t,c}09

The query complexity is yt,cy_{t,c}10 for yt,cy_{t,c}11 and yt,cy_{t,c}12 for yt,cy_{t,c}13, and the solve time is polynomial in yt,cy_{t,c}14, for example yt,cy_{t,c}15 (Levi et al., 2018).

The key technical tool is a decomposition

yt,cy_{t,c}16

where yt,cy_{t,c}17 is block-constant with a polylogarithmic number of blocks and yt,cy_{t,c}18 has small spectral norm. More precisely, for yt,cy_{t,c}19, yt,cy_{t,c}20, and any yt,cy_{t,c}21, the number of blocks in yt,cy_{t,c}22 is

yt,cy_{t,c}23

and

yt,cy_{t,c}24

This is stronger than the Frieze–Kannan decomposition for the purposes of quadratic minimization, because the analysis needs spectral-norm control rather than cut-norm control. The residual contributes at most

yt,cy_{t,c}25

so the pseudorandom part is small on any vector of bounded norm.

For the unconstrained problem, if yt,cy_{t,c}26 is the full minimizer and yt,cy_{t,c}27 is the sampled minimizer, then with probability at least yt,cy_{t,c}28,

yt,cy_{t,c}29

This improves the Hayashi–Yoshida dependence on yt,cy_{t,c}30 by replacing it with yt,cy_{t,c}31, with yt,cy_{t,c}32. For the sphere-constrained problem, if yt,cy_{t,c}33 is the full optimum and yt,cy_{t,c}34 the sampled optimum, then with probability at least yt,cy_{t,c}35,

yt,cy_{t,c}36

The same paper also gives a sublinear-time approximation algorithm for computing top singular values, connecting the wiggle-minimization setting to Rayleigh-quotient computations (Levi et al., 2018).

The computational status of quadratic wiggle objectives depends sharply on which variables remain free. In ordered storylines, the combinatorial ordering has already been fixed, so both LWHMin and QWHMin are polynomial-time solvable: the former is an LP and the latter is a convex QP. By contrast, wiggle count minimization is NP-complete, and the paper gives a reduction from Planar Monotone 3-SAT. It also identifies a special case in which yt,cy_{t,c}37, for which WCMin is polynomial (Dobler et al., 27 Aug 2025).

In stacked area charts, the discrete quadratic wiggle objective is attached to border changes generated by an ordering yt,cy_{t,c}38. With cumulative borders

yt,cy_{t,c}39

the unweighted quadratic objective is

yt,cy_{t,c}40

The weighted version is

yt,cy_{t,c}41

For arbitrary yt,cy_{t,c}42, including yt,cy_{t,c}43, both yt,cy_{t,c}44-WiggleMin and Weighted-yt,cy_{t,c}45-WiggleMin are strongly NP-complete. The paper further states that there is no PTAS unless a subexponential-time algorithm for SAT exists, and no constant-factor approximation under the Small-Set Expansion Hypothesis. An exact MILP is given for the weighted yt,cy_{t,c}46 objective, and replacing the linear objective by squared absolute-border-change terms yields an exact MIQP for Weighted-2-WiggleMin (Dobler et al., 26 Jun 2025).

A recurring pattern therefore separates combinatorial and continuous difficulty. Once the vertical order is fixed, quadratic wiggle height minimization often reduces to convex quadratic programming; when the order itself must be optimized, strong NP-hardness can reappear even for the quadratic yt,cy_{t,c}47 objective. This suggests that in visualization applications the dominant difficulty often lies in layer ordering, while the coordinate-assignment phase remains tractable and structurally quadratic (Dobler et al., 27 Aug 2025, Dobler et al., 26 Jun 2025).

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Quadratic Wiggle Height Minimization.