Abstract Using graphs and Laplacian eigenvalues to evaluate block designs Consider an experiment to compare v treatments in b blocks of size k.

R. A. Bailey Statisticians use various criteria to decide which design is best. University of St Andrews / QMUL (emerita) It turns out that most of these criteria are defined by the Laplacian eigenvalues of one of the two graphs defined by the : I the Levi graph, which has v + b vertices, Ongoing joint work with Peter J. Cameron I or the concurrence graph, which has v vertices.

The algebraic approach shows that sometimes all the criteria Modern Trends in Algebraic Graph Theory, prefer highly symmetric designs but sometimes they favour Villanova, June 2014 very different ones.

1/52 2/52

An experiment on detergents Experiments in blocks

In a consumer experiment, twelve housewives volunteer to test new detergents. There are 16 new detergents to compare, but it I have v treatments that I want to compare. is not realistic to ask any one volunteer to compare this many I have b blocks, with k plots in each block. detergents. blocks b k treatments v Each housewife tests one detergent per washload for each of housewives 12 4 detergents 16 four washloads, and assesses the cleanliness of each washload. How should I choose a block design The experimental units are the 48 washloads. for these values of b, v and k? The housewives form 12 blocks of size 4. What makes a block design good? The treatments are the 16 new detergents.

3/52 4/52

Two designs with v = 5, b = 7, k = 3: which is better? Two designs with v = 15, b = 7, k = 3: which is better?

Conventions: columns are blocks; order of treatments within each block is irrelevant; 1 1 2 3 4 5 6 1 1 1 1 1 1 1 order of blocks is irrelevant. 2 4 5 6 10 11 12 2 4 6 8 10 12 14 3 7 8 9 13 14 15 3 5 7 9 11 13 15 1 1 1 1 2 2 2 1 1 1 1 2 2 2 2 3 3 4 3 3 4 1 3 3 4 3 3 4 replications differ by 1 queen-bee design 3 4 5 5 4 5 5 2 4 5 5 4 5 5 ≤

The replication of a treatment is its number of occurrences. binary non-binary A design is a queen-bee design if there is a treatment that A design is binary if no treatment occurs more than once in any occurs in every block. block.

5/52 6/52 Two designs with v = 7, b = 7, k = 3: which is better? Experimental units and matrix

There are bk experimental units. If ω is an experimental unit, put

f (ω) = treatment on ω 1 2 3 4 5 6 7 1 2 3 4 5 6 7 2 3 4 5 6 7 1 2 3 4 5 6 7 1 g(ω) = block containing ω. 4 5 6 7 1 2 3 3 4 5 6 7 1 2 For i = 1, . . . , v put

balanced (2-design) non-balanced r = ω : f (ω) = i = replication of treatment i. i |{ }| For i = 1, . . . , v and j = 1, . . . , b, let A binary design is balanced if every pair of distinct treaments occurs together in the same number of blocks. n = ω : f (ω) = i and g(ω) = j ij |{ }| = number of experimental units in block j which have treatment i. The v b N has entries n . × ij 7/52 8/52

Levi graph Example 1: v = 4, b = k = 3

1 2 1 3 3 2 The Levi graph G˜ of a block design ∆ has 4 4 2

I one vertex for each treatment, I one vertex for each block, I one edge for each experimental unit, with edge ω joining vertex f (ω) (the treatment on ω) 4 ¨H to vertex g(ω) (the block containing ω). ¨ H ¨¨ x HH ¨¨ HH It is a , HH ¨¨  H ¨ 1Hx¨2 x with nij edges between treatment-vertex i and block-vertex j. H ¨ H¨ 3x

9/52 10/52

Example 2: v = 8, b = 4, k = 3 Concurrence graph

The concurrence graph G of a block design ∆ has 1 2 3 4 2 3 4 1 I one vertex for each treatment, 5 6 7 8 I one edge for each unordered pair α, ω, with α = ω, 6 g(α) = g(ω) (in the same block) and f (α) = f (ω): 6 this edge joins vertices f (α) and f (ω). 5 8 1 x There are no loops.  @ @ = x@ x @ If i j then the number of edges between vertices i and j is  2 6 x b λ = n n ; 4  ij ∑ is js @ @ s=1 x@ @  this is called the concurrence of i and j, x63 x 7 and is the (i, j)-entry of Λ = NN>. x 11/52 12/52 Example 1: v = 4, b = k = 3 Example 2: v = 8, b = 4, k = 3

1 2 1 1 2 3 4 3 3 2 2 3 4 1 4 4 2 5 6 7 8

4 1 2 5 5 ¨H 8 1 ¨ H @ x ¡A ¨¨ x HH x@ x  ¡ xA ¨ H @ @ 1 2 ¨ H @ x@ x @ ¡ A H ¨  2 ¨¨ HH H ¨ @  ¨ H H1H ¨2¨ @ 8H x x ¨ 6 xH ¨ x x H ¨ H¨ @ xH ¨ x 4  A ¡ 3 @ @ 4 3 x 3x 4x x@ @ xA ¡ x  A¡

x63 x Levi graph concurrence graph 7 7x can recover design may have more symmetry x more vertices Levi graph concurrence graph more edges if k = 2 more edges if k 4 ≥ 13/52 14/52

Example 3: v = 15, b = 7, k = 3 Laplacian matrices

The Laplacian matrix L of the concurrence graph G is a v v matrix with (i, j)-entry as follows: 1 1 2 3 4 5 6 1 1 1 1 1 1 1 × I if i = j then 2 4 5 6 10 11 12 2 4 6 8 10 12 14 6 L = (number of edges between i and j) = λ ; 3 7 8 9 13 14 15 3 5 7 9 11 13 15 ij − − ij I Lii = valency of i = ∑ λij. j=i 8 9 6 13 7 8 11 7 10 The Laplacian matrix L˜ of the Levi graph G˜ is a D ¤ bb 4 "" bb 5 "" D ¤ (v + b) (v + b) matrix with (i, j)-entry as follows: b" b" JJ xD ¤ x @ × x" b x x" b x 6 x x@ 11 ˜ " b " b QQ J D ¤  I Lii = valency of i x T  x x Q J D ¤  x 10 1 T  2 14 5 ````Q  12 k if i is a block x x x x ``Q JD  ¤` = T3 x Q``` x replication r of i if i is a treatment T  J Q `` ( i 4  1xJ Q 13  xT I if i = j then Lij = (number of edges between i and j) 12 9 x J QQ x 6 − T  6 3 14 x x x @ J T x@ J x 0 if i and j are both treatments 15 2 15 x x x = 0 if i and j are both blocks   nij if i is a treatment and j is a block, or vice versa. 15/52 − 16/52 

Connectivity Generalized inverse

All row-sums of L and of L˜ are zero, so both matrices have 0 as eigenvalue on the appropriate all-1 vector. Under the assumption of connectivity, the Moore–Penrose generalized inverse L− of L is defined by Theorem 1 The following are equivalent. 1 − 1 L− = L + J J , v v − v v 1. 0 is a simple eigenvalue of L;   2. G is a connected graph; where J is the v v all-1 matrix. v × 3. G˜ is a connected graph; 1 (The matrix J is the orthogonal projector onto the null space 4. 0 is a simple eigenvalue of L;˜ v v of L.) 5. the design ∆ is connected in the sense that all differences between treatments can be estimated. The Moore–Penrose generalized inverse L˜ − of L˜ is defined similarly. From now on, assume connectivity. Call the remaining eigenvalues non-trivial.

They are all non-negative. 17/52 18/52 Estimation Variance: why does it matter?

We want to estimate all the simple differences τi τj. We measure the response Yω on each experimental unit ω. −

Put Vij = variance of the best linear unbiased estimator for If experimental unit ω has treatment i and is in block m τi τj. (f (ω) = i and g(ω) = m), then we assume that −

The length of the 95% confidence interval for τi τj is Yω = τi + βm + random noise. − proportional to Vij. (If we always present results using a 95% confidence interval, then our interval will contain the true p We will do an experiment, collect data yω on each experimental value in 19 cases out of 20.) unit ω, then want to estimate certain functions of the treatment The smaller the value of Vij, the smaller is the confidence parameters using functions of the data. interval, the closer is the estimate to the true value (on average), and the more likely are we to detect correctly We want to estimate contrasts ∑ xiτi with ∑ xi = 0. i i which of τi and τj is bigger. In particular, we want to estimate all the simple differences We can make better decisions about new drugs, about new τ τ . varieties of wheat, about new engineering materials . . . if we i − j make all the Vij small. 19/52 20/52

How do we calculate variance? . . . Or we can use the Levi graph

Theorem Assume that all the noise is independent, with variance σ2. Theorem If ∑ x = 0, then the variance of the best linear unbiased estimator of i i The variance of the best linear unbiased estimator of the simple ∑i xiτi is equal to 2 difference τi τj is (x>L−x)kσ . − In particular, the variance of the best linear unbiased estimator of the ˜ ˜ ˜ 2 Vij = Lii− + Ljj− 2Lij− σ . simple difference τ τ is − i − j   (Or βi βj, appropriately labelled.) 2 − V = L− + L− 2L− kσ . ij ii jj − ij   (This follows from assumption

Y = τ β˜ + random noise. (This follows from assumption ω i − m by using standard theory of linear models.) Yω = τi + βm + random noise.

by using standard theory of linear models.) 21/52 22/52

How do we calculate these generalized inverses? Electrical networks

We can consider the concurrence graph G as an electrical network with a 1-ohm resistance in each edge. We need L− or L˜ −. Connect a 1-volt battery between vertices i and j. Current flows in the network, according to these rules. I Add a suitable multiple of J, 1. Ohm’s Law: use GAP to find the inverse with exact rational coefficients, In every edge, voltage drop = current resistance = × subtract that multiple of J. current. I If the matrix is highly patterned, 2. Kirchhoff’s Voltage Law: guess the eigenspaces, The total voltage drop from one vertex to any other vertex then invert each non-zero eigenvalue. is the same no matter which path we take from one to the I Direct use of the graph: coming up. other. 3. Kirchhoff’s Current Law: Not all of these methods are suitable for generic designs with a At every vertex which is not connected to the battery, the variable number of treatments. total current coming in is equal to the total current going out. Find the total current I from i to j, then use Ohm’s Law to define the effective resistance Rij between i and j as 1/I. 23/52 24/52 Electrical networks: variance Example 2 calculation: v = 8, b = 4, k = 3

23 V = 23 I = 24 R = 24 5 [9] Theorem ¡A The effective resistance Rij between vertices i and j in G is ¡ zA 3 ¡ UA 3 ¡ A Rij = Lii− + Ljj− 2Lij− . [6] ¡ A [12] − ¡ -6 A   3 ¨ H 11 ¨¨ HH So *¨ z1 2 z jH 2 ¨¨ HH Vij = Rij kσ . H ¨ × 8H 6 6 62 ¨ 6 [3z] zHYH ¨*¨ [23] H 4 3 ¨ Effective resistances are easy to calculate without 3 H - ¨ 13 A ¡ matrix inversion if the graph is sparse. [0] zA 10 ¡ z[10] AU ¡ 5 A ¡ 5 A ¡ A¡[5] 7 25/52 z 26/52

. . . Or we can use the Levi graph Example 2 yet again: v = 8, b = 4, k = 3

1 2 3 4 23 V = 23 I = 8 R˜ = 2 3 4 1 8 5 6 7 8

˜ If i and j are treatment vertices in the Levi graph G 5 ˜ ˜ 5 and Rij is the effective resistance between them in G then 8 1 - x ¡A  x ˜ 2 @ 3 R@ 1¡ A 2 Vij = Rij σ . x@  3 x 3 @ ¡ A × 2 ¨¨ HH  ¨ H x? 8H x x ¨ 6 63 3 H ¨ xxH ¨ 4 [0] [15] A ¡ R@ 5 5 R@ 4 3 x@ -5  8 @ xA ¡ x  [23] A¡

xx 63 7 7x x Levi graph concurrence graph

27/52 28/52

Optimality: Average pairwise variance A-Optimality

The variance of the best linear unbiased estimator of the simple difference τ τ is i − j 2 2 V = L− + L− 2L− kσ = R kσ . ij ii jj − ij ij A block design is called A-optimal if it minimizes the average   of the variances Vij; —equivalently, it maximizes the harmonic mean of the We want all of the V to be small. ij non-trivial eigenvalues of the Laplacian matrix L; over all block designs with block size k and the given v and b. Put V¯ = average value of the Vij. Then

2kσ2 Tr(L ) 1 V¯ = − = 2kσ2 , v 1 × harmonic mean of θ1,..., θv 1 − − where θ1,..., θv 1 are the nontrivial eigenvalues of L. −

29/52 30/52 Optimality: Confidence region D-Optimality

When v > 2 the generalization of confidence interval is the A block design is called D-optimal if it minimizes the volume confidence ellipsoid around the point (τˆ1,..., τˆv) in the v of the confidence ellipsoid for (τˆ1,..., τˆv) ; hyperplane in R with ∑i τi = 0. The volume of this confidence ellipsoid is proportional to —equivalently, it maximizes the geometric mean of the non-trivial eigenvalues of the Laplacian matrix L; v 1 —equivalently, it maximizes the number of spanning trees for − 1 (v 1)/2 = (geometric mean of θ1,..., θv 1)− − the concurrence graph G; v∏ θ − ui=1 i —equivalently, it maximizes the number of spanning trees for u t 1 the Levi graph G˜ ; = . v number of spanning trees for G over all block designs with block size k and the given v and b. × p

31/52 32/52

Optimality: Worst case E-Optimality

v If x is a contrast in R then the variance of the estimator of x>τ 2 is (x>L−x)kσ . If we multiply every entry in x by a constant c then this 2 variance is multiplied by c ; and so is x>x. A block design is called E-optimal if it maximizes the smallest non-trivial eigenvalue of the Laplacian matrix ; The worst case is for contrasts x giving the maximum value of L over all block designs with block size k and the given v and b. x L x > − . x>x

These are precisely the eigenvectors corresponding to θ1, where θ1 is the smallest non-trivial eigenvalue of L.

33/52 34/52

BIBDs are optimal D-optimality: spanning trees

A spanning tree for the graph is a collection of edges of the graph which form a tree (connected graph with no cycles) and which include every vertex. Theorem (Kshirsagar, 1958; Kiefer, 1975) Cheng (1981), after Gaffke (1978), after Kirchhoff (1847): If there is a balanced incomplete-block design (BIBD) (2-design) for v treatments in b blocks of size k, product of non-trivial eigenvalues of L then it is A-, D- and E-optimal. = v number of spanning trees. Moreover, no non-BIBD is A-, D- or E-optimal. × So a design is D-optimal if and only if its concurrence graph G has the maximal number of spanning trees.

This is easy to calculate by hand when the graph is sparse.

35/52 36/52 What about the Levi graph? Example 2 one last time: v = 8, b = 4, k = 3

1 2 3 4 2 3 4 1 Theorem (Gaffke, 1982) 5 6 7 8 Let G and G˜ be the concurrence graph and Levi graph for a connected incomplete-block design for v treatments in b blocks of size k. 5 5 8 1 Then the number of spanning trees for G˜ is equal to x ¡A  x b v+1 @ @ 1¡ A 2 k − times the number of spanning trees for G. x@ x ¡ A @ 2 ¨ H  ¨¨ HH 8H x x ¨ 6 So a block design is D-optimal if and only if x H ¨ xH ¨ x its Levi graph maximizes the number of spanning trees. 4  A ¡ @ @ 4 3 x@ @ xA ¡ x  A¡ If v b + 2 it is easier to count spanning trees in the Levi graph ≥ x63 x than in the concurrence graph. 7 7x x Levi graph concurrence graph 8 spanning trees 216 spanning trees

37/52 38/52

E-optimality: the edge-cutset lemma E-optimality: the vertex-cutset lemma

A design is E-optimal if it maximizes the smallest non-trivial A design is E-optimal if it maximizes the smallest non-trivial eigenvalue θ1 of the Laplacian L of the concurrence graph G. eigenvalue θ1 of the Laplacian L of the concurrence graph G. Lemma Lemma Let G have a vertex-cutset of size c Let G have an edge-cutset of size c (set of c vertices whose removal disconnects the graph) (set of c edges whose removal disconnects the graph) whose removal separates the graph into components of sizes m and n, whose removal separates the graph into components of sizes m and n. with m0 and n0 edges between them and the vertices in the cutset. Then Then 1 1 2 2 θ1 c + . m0n + n0m ≤ m n θ1 ,   ≤ mn(n + m) which is at most c if no multiple edges are involved. If c is small but m and n are both large, then θ1 is small. If m0 << m and n0 << n then θ1 is small.

39/52 40/52

Minimal connectivity Optimality of minimally connected designs

If the block design is connected then bk b + v 1. ≥ − If the block design is connected and b(k 1) = v 1 then − − the Levi graph is a tree and The Levi graph is a tree, the concurrence graph is a b-tree of k-cliques. so all connected designs are equally good under the D-criterion. The Levi graph is a tree, D ¤ so effective resistance = graph distance, bb "" bb "" J xD ¤ x @ b" b" @ x" b x x" b x Q xJ D ¤ x so the only A-optimal designs are the queen-bee designs. " b " b Q J D ¤  x x x Q  x TT  `` J D ¤ The concurrence graph is a b-tree of k-cliques, x x x x ```Q  T ` QJD ¤ `` so the Cutset Lemmas show that x  JQ ``` x TT  Q `  x  xJ Q the only E-optimal designs are the queen-bee designs. T  Q   J Q xx TT  x x x @ J T x@ J x x x x

41/52 42/52 Can we use the Levi graph to find E-optimal designs? Large blocks; many unreplicated treatments

∑ r Suppose that r¯ = i i < 2. v New conventions: blocks are rows, and block size = k + n. For binary designs with equal replication, θ1(L) is a monotonic increasing function of θ1(L˜). k plots n plots But, queen-bee designs are E-optimal under minimal connectivity,  . .  . . and some non-binary designs are E-optimal. b blocks  whole design ∆   For general block designs, we do not know if we can use the v treatments bn treatments Levi graph to investigate E-optimality.  all single replication    Whole design ∆ has v + bn treatments in b blocks of size k + n; the subdesign Γ has v core treatments in b blocks of size k; call the remaining treatments orphans.

43/52 44/52

Levi graph: 10 + 5n treatments in 5 blocks of 4 + n plots Pairwise resistance

1 2 3 4 A1 An ··· B1 H ¨ Bn H···¨ 1 5 6 7 B1 Bn An . 1x¨H 5x . C1 ··· .@ ¨ ¢ B H . .x@ ¨¨ 2 HH .x 2 5 8 9 C1 Cn A ¢ B C ··· 1 QQ x7 6 x  n A Q ¢ B  ¡ 3 6 8 0 D1 Dn x A Q¢ x B ¡ x ··· 4 A ¢ xQxB ¡ 8 4 7 9 0 E E 3 Q 9 1 ··· n xA ¢ x xQB ¡ x En   D1 . @ . .x 0x .x B1 H ¨ Bn @ H···¨ E1 Dn An 1x¨H 5x C1 .@ ¨ ¢ B H . x x .x@ ¨ ¢2B H .x ¨ ¢ B H A1 x x  Cn Resistance(A1, A2) = 2 AQQ 7 ¢ B 6 ¡ x Q x  x A Q¢ B ¡ Resistance(A1, B1) = 2 + Resistance(block A, block B) in Γ 4 A ¢ xQxB ¡ 8 3 Q 9 xA ¢ x xQB ¡ x Resistance(A1, 8) = 1 + Resistance(block A, 8) in Γ E D n .   . 1 Resistance(1, 8) = Resistance(1, 8) in Γ . 0 @ . x x @x E1 Dn x x 45/52 46/52

Sum of the pairwise variances A less obvious consequence

Theorem (cf Herzberg and Jarrett, 2007) The sum of the variances of treatment differences in ∆

= constant + V + nV + n2V , 1 3 2 Consequence where If n or b is large,

V1 = the sum of the variances of treatment differences in Γ and we want an A-optimal design, it may be best to make Γ a complete block design for k0 controls, V2 = the sum of the variances of block differences in Γ even if there is no interest in V3 = the sum of the variances of sums of comparisons between new treatments and controls, one treatment and one block in Γ. or between controls.

(If Γ is equi-replicate then V2 and V3 are both increasing functions of V1.) Consequence For a given choice of k, make Γ as efficient as possible.

47/52 48/52 Spanning trees D-optimality under very low replication

A spanning tree for the Levi graph is a collection edges which provides a unique path between every pair of vertices. Consequence B1 H ¨ Bn H···¨ The whole design ∆ is D-optimal An 1x¨H 5x C1 .@ ¨ ¢ B H . for v + bn treatments in b blocks of size k + n .x@ ¨ ¢2B H .x ¨ ¢ B H if and only if the core design Γ is D-optimal A1 x x  Cn AQQ 7 ¢ B 6 ¡ x Q x  x for v treatments in b blocks of size k. A Q¢ B ¡ 4 A ¢ xQxB ¡ 8 3 Q 9 Consequence xA ¢ x xQB ¡ x En .   . D1 Even when n or b is large, . 0 @ . x x @x D-optimal designs do not include uninteresting controls. E1 Dn x x The orphans make no difference to the number of spanning trees for the Levi graph.

49/52 50/52

Conjectures Main References

I R. A. Bailey and Peter J. Cameron: Conjecture (Underpinned by theoretical work by C.-S. Cheng) Combinatorics of optimal designs. If the A-optimal design is very different from the D-optimal design, In Surveys in Combinatorics 2009 then the E-optimal design is (almost) the same as the A-optimal (eds. S. Huczynska, J. D. Mitchell and design. C. M. Roney-Dougal), Conjecture (Underpinned by theoretical work by C.-S. Cheng) London Mathematical Society Lecture Note Series, 365, Cambridge University Press, Cambridge, 2009, pp. 19–73. If the connectivity is more than minimal, then all D-optimal designs I R. A. Bailey and Peter J. Cameron: have (almost) equal replication. Using graphs to find the best block designs. Conjecture (Underpinned by theoretical work by J. R. Johnson In Topics in Structural Graph Theory and M. Walters) (eds. L. W. Beineke and R. J. Wilson), If r¯ > 3.5 then designs optimal under one criterion are (almost) Cambridge University Press, Cambridge, 2013, optimal under the other criteria. pp. 282–317.

51/52 52/52