New Ramsey Multiplicity Bounds and Search Heuristics

,


Introduction
In Extremal Combinatorics, the application of computer assistance in formulating proofs is exemplified by flag algebras [67], which allow one to establish bounds through a double-counting argument by solving Semidefinite Programming (SDP) problems.These bounds are sometimes complemented by explicit constructions derived from human combinatorial insights.However, as for example noted in [65], there is a growing interest in computer-based approaches that can complement flag algebras and surpass human intuition.In this work we investigate how the objective of finding constructive bounds can be formulated as a discrete optimization problem and explore the suitability of metaheuristics, such as Simulated Annealing [49] and Tabu Search [33,34,35], as well as more recent Reinforcement Learning methods [6,91], for these problems.To illustrate the potential of this approach, we make significant progress on well-known problems in Extremal Graph Theory that go back to questions of Erdős.Our investigations also lead us to introduce new directions where many questions remain open.to c 4 < 0.030285.Here we establish the following more substantial improvement. 1heorem 1.1.We have The best known lower bound stands at 0.0296 < c 4 , and was proved by Grzesik, Lee, Lidický and Volec [39] using flag algebras, so Theorem 1.1 reduces the gap between upper and lower bounds by more than 20%.Perhaps more relevant than the actual values are the methods used to find them.The best of Thomason's initial constructions [83] were based on the blow-up of a 'core' graph on 272 vertices, which were constructed using quadratic forms in an appropriate finite geometric setting.The core graphs of Franek and Rödl [29] were defined on 1024 vertices, over the subsets of a 10-element set using intersection sizes.The improvement of Thomason [84] built on insights from the work of Jagger, Št ovíček, and Thomason [45] about the construction in [83], and employed an extensive brute force computer search over XOR products of small graphs to find its core graph on 288 vertices.The improved bound by Even-Zohar and Linial [21] was obtained by identifying a different, iterative blow-up hidden in the construction of Thomason.We will discuss the particularities of the upper bounds and the underlying constructions in more detail in Section 3.3.1.
The core graphs of all these constructions happen to be Cayley graphs, yet they were not really sought for as such.For our improvement, we directly construct Cayley graphs via various computer search heuristics which target to find their generating set.A key advantage of this approach is that the size of the search space is only roughly the square root of the size of the produced outcome.Hence our heuristics can efficiently explore and produce relatively large core graphs from the great wealth of good ones among all Cayley graphs over a given group (and not only consider a small portion of them, as before).With our approach, we can find core graph constructions on as few as 192 vertices that improve upon the previous best bound and that can be found with very moderate computational effort.The upper bound for c 4 in Theorem 1.1 is obtained from the sequence of blow-ups of a Cayley graph on 768 vertices, though we also found a construction on 384 vertices that likewise beats 0.03015, hence performing just marginally worse than the construction on 768 vertices.
Much of the effort made by several researchers to optimize Thomason's approach for t = 4 materialized in improvements for t ≥ 5.The best known upper bound for t = 5 is c 5 < 0.001720, due to Thomason [84], improving on his bound in [83].For t ∈ {6, 7, 8} the best known bounds are given by Deza, Franek, and Liu [17] using the intersection graph idea of [29].
Our method can also be employed to improve the best known upper bound in the K 5multiplicity problem.We also complement this with a lower bound using flag algebras.
Our improved upper bound is based on the sequence of blow-ups of a Cayley graph on 192 vertices, just like Thomason's.We will go more into about our bounds and how they were found in Section 3.

Independent set density for graphs with bounded clique number
A related question, likewise raised by Erdős [19], concerns the minimum number k ′ s,t (n) = min{k s (G) : |G| = n, k t (G) = 0} of independent sets of size s in a graph of order n with clique number bounded by t − 1.The associated limit, whose existence again follows by monotonicity [62], is defined as Note that obviously g t,t ≥ c t for any t ≥ 2. We trivially have g s,2 = 1 and the fact that g 2,t = 1/(t−1) is established by Turán's theorem [85].Erdős [19] asked if the upper bound given by the Turán graphs T t−1 (n) as n → ∞ is also tight in general, that is if g s,t = (t − 1) 1−s .This holds for s = t = 3, as an easy consequence of the previously mentioned result of Goodman [36] and the value of k ′ 3,3 (n) was settled precisely by Lorden [55].Nikiforov [62] however showed that the Turán graph upper bound can be sharp only for a finite number of pairs s, t ≥ 3. Das et al. [15] and Pikhurko and Vaughan [66] established tight values when one of the parameters is three and the other at most seven.In particular this confirmed Erdős' intuition for g 3,t when 4 ≤ t ≤ 7 and disproved it for g s,3 when 4 ≤ s ≤ 7.They also determine the unique extremal constructions in these cases.Moreover, Pikhurko and Vaughan [66] found a construction based on non-balanced blow-ups of a (3,4)-Ramsey graph of order 8 bounding g 4,4 away from the value given by T 3 (n) that is conjectured to be tight.Here we present the first tight value for g s,t when s, t ≥ 4. Furthermore, we show that any graph that comes close to the optimum of g 4,5 must be close to a balanced blow-up of C R (3,5) , the unique (3,5)-Ramsey graph of order 13, i.e., the Cayley graph on Z 13 whose edge relations are given by the cubic-non-residues.
The upper bound is given by the sequence of balanced blow-ups of C R (3,5) , the lower bound matching that construction was established using the flag algebra approach.The notion of perfect stability was introduced by Pikhurko, Sliačan, and Tyros [65] and strengthens the standard notion of stability.We will formally state it in Definition 4.8 in Section 4.2.For the details of the proofs see Section 4.
The fact that Ramsey graphs are a good source of constructions for this problem was previously already noted by Nikiforov [62] and Das et al. [15].We found several more such graphs whose sequence of (sometimes non-balanced) blow-ups give good upper bounds for additional values of g s,t , but were unable to establish matching lower bounds.The most reasonable open conjecture out of all studied values seems to be that g 5,5 = 61•13 −4 , where the upper bound also comes from C R (3,5) .We list all other bounds in Section 3.3.We also remark that more general bounds for g s,t were given by Nikiforov [62] and Sawin [76], who studied the close connection to (multicolor) Ramsey numbers.

Off-diagonal Ramsey multiplicity
There is a stark contrast between the difficulty of counting homogeneous triples and counting homogeneous 4-subsets.This is demonstrated by the relatively straightforward proof of c 3 = 1/4 and the slow progress towards determining the value of c 4 .To get a grip on the latter, we propose to investigate the question when we count K 4 only in the graph and triangles in the complement.This problem proves to be more manageable, as we can not only derive an exact solution but also demonstrate the stability of a unique construction on 27 vertices.
Formally, for arbitrary s, t ≥ 3, we propose to study the following off-diagonal version of the Ramsey multiplicity parameter: Observe that clearly c t,t = c t as well as c s,t ≤ min{g s,t , g t,s }.From a result of Reiher [69] it follows that c 2,t = g 2,t for every t ≥ 3.Here we establish the first exact results when t > s ≥ 3.
Note that c s,t < g s,t for each of these values of s and t.The upper bound for c 3,4 is uniquely given by the sequence of balanced blow-ups of the Schläfli graph.The upper bound for c 3,5 is more easily described as an upper bound of c 5,3 , in which case it is given by the sequence of balanced blow-ups of the complement of the Schläfli graph.The upper bound for c 4,5 is given by the sequence of blow-ups of a vertex-transitive graph on 128 vertices.Lower bounds are again established using the flag algebra approach.The proof of stability largely follows the template laid out by Pikhurko et al. [65], but also requires additional ideas.
A central question in the symmetric Ramsey multiplicity problem is whether a tight upper bound can be achieved through the sequence of (possibly weighted or iterated) blow-ups of a finite-sized graph.For c 3 , this is true, with Goodman's bound reached by, among others, the blow-ups of K 2 .However, for c 4 , the question remains open.Theorem 1.4, which states the extremality and stability of blow-ups of a single finite graph (on 27 vertices) for the c 3,4 problem, may suggest the existence of such a finite graph for c 4 .Our results for c 4 however suggest that any such finite construction might be of considerable size.
There is no specific reason for our choice to weight the contributions from both terms equally in c s,t .Other choices, such as the weighting given by linearly connecting the points indicated by g s,t and g t,s , would also be reasonable.In fact, the previously introduced problems are part of a broader question aiming to understand which pairs of clique and independent set densities can be realized as the limit of some sequence of graphs.We introduce this problem and our results in the next section.
Outline.We first explore the broader question of realizable pairs of clique and independent set densities and their relation to earlier introduced parameters in Section 2. Next, we describe the constructions for upper bounds and their discovery methods in Section 3. We then outline Razborov's flag algebra approach and its application for stability results in Section 4. Finally, we discuss related problems and recent learning-based optimization heuristics in Section 5.

The full tradeoff between cliques and independent sets
The study of c s,t and g s,t are part of a broader question in which one would like to understand the full tradeoff between the number of cliques of size t and independent sets of size s in a graph.The goal is to characterise the region Ω s,t ⊆ [0, 1] 2 of pairs of clique and independent set densities that can occur in the limit of a sequence of graphs.We say that a tuple (x, y) ∈ [0, 1] 2 is realised by a sequence of graphs (G n ) n∈N with lim n→∞ v(G n ) = ∞, where w.l.o.g. and to simplify notation we assume v( We formally define Ω s,t ⊆ [0, 1] 2 to be the set of all tuples that are realised by some sequence of graphs.For s = 2 and with K t replaced by any quantum graph, that is an arbitrary linear combination of graphs, this set was already systematically studied by Liu, Mubayi, and Reiher [54].Similar to them, let us define c s,t (x) = inf{y : (x, y) ∈ Ω s,t } and C s,t (x) = sup{y : (x, y) ∈ Ω s,t }.
We can show that Ω s,t behaves nicely for any s, t ≥ 2, that is it is completely characterised by its lower and upper bounding curves c s,t (x) and C s,t (x).Proposition 2.1.Ω s,t is compact and defines a simply connected region for any s, t ≥ 2.
Proof.We start by establishing compactness of Ω s,t as in Proposition 1.3 from [53].Let (x m , y m ) m∈N be a sequence in Ω s,t such that lim m→∞ (x m , y m ) = (x, y) and let us show that (x, y) ∈ Ω s,t .For each m ∈ N there exists a sequence of graphs (G n,m ) n∈N that realises (x m , y m ).With x n,m = k s (G n,m )/ n s and y n,m = k t (G n,m )/ n t we have a sequence (x n,m , y n,m ) with lim n→∞ (x n,m , y n,m ) = (x m , y m ).Therefore, by Lemma 2.2 from [53], there exists (n k ) k∈N such that lim k→∞ (x n k ,k , y n k ,k ) = (x, y) and, thus, the sequence (G n k ,k ) k∈N realises (x, y).Now let us show that the region Ω s,t is simply connected by showing that for any (x, y 1 ), (x, y 2 ) ∈ Ω s,t we must also have (x, y) ∈ Ω s,t for any y 1 ≤ y ≤ y 2 .We generalise the argument in Proposition 2.2 from [54] and consider sequences (G n ) n∈N and (G ′ n ) n∈N that realise (x, y 1 ) and (x, y 2 ) respectively.For each n ∈ N we iteratively construct a sequence of n-vertex graphs ) in the former case and removing one of E(G n,i )\E(G ′ n ) in the latter.We note that adding or removing a single edge adds or removes a fraction of cliques of a given size that is o(1), so that lim It follows that it suffices to study c s,t (x) and C s,t (x) in order to fully understand Ω s,t and we can in fact replace the infimum and supremum in their definition by a minimum and maximum.Let us establish some properties of these curves.
Proposition 2.2.The curves c s,t (x) and C s,t (x) are decreasing, continuous, and almost everywhere differentiable for any s, t ≥ 2.
Proof.We start by arguing that both c s,t (x) and C s,t (x) are decreasing, similarly to Lemma 2.3 in [54].Let (G n ) n∈N be a sequence of graphs of order n realizing a point (x, y) ∈ [0, 1] 2 with x < 1.Consider the sequence (G ′ n ) n∈N obtained by fully connecting a clique of size ⌈β n⌉ to G n for some fixed β > 0 and any n ∈ N. Let us determine the tuple (x ′ , y ′ ) realized by that sequence.As no new independent sets of size s are created in G ′ n we have k s (G ′ n ) = k s (G n ).On the other hand, for each 0 ≤ ℓ ≤ t − 1, we get at least k ℓ (G) As every copy of K t in G ′ n was already contained in G n or contains at least one of the new vertices, we have . Combining this, dividing by n+⌈βn⌉ s and n+⌈βn⌉ t respectively, and taking limits, we get where for the last inequality we use that lim inf n→∞ k ℓ (G n ) ⌈βn⌉ t−ℓ / n t ≥ x t ℓ β t−ℓ .Using these bounds we can easily find a β = β(ε) > 0 for any ε > 0 such that x < x ′ ≤ x + ε, where x < x ′ holds as β t + tβ t−1 + t ℓ=2 t ℓ xβ t−ℓ > x(1 + β) t by the binomial Theorem.Since y ′ < y for β > 0, the fact that c s,t (x) is decreasing follows.A similar argument likewise establishes that C s,t (x) is decreasing.
Given the monotonicity of c s,t (x) and C s,t (x) as well as their bounded domain of [0, 1], the fact that they are almost everywhere differentiable immediately follows.Regarding continuity, we note that both left-and right-hand limits exist due to monotonicity.Since c s,t is the decreasing lower bounding curve of a compact domain, it must also be right-continuous and left-continuity of C s,t (x) likewise follows.To establish left-continuity for c s,t (x) (and rightcontinuity of C s,t (x)) we let x 0 ∈ (0, 1) and y 0 = lim xրx 0 c s,t (x).By monotonicity c s,t (x 0 ) ≤ y 0 , so let us assume that c s,t (x 0 ) = y ′ < y 0 .Let β > 0 be small enough such that y 0 /(1 + β) s > y ′ .Then, in view of Equation (2), choose α > 0 small enough such that which is again possible by the binomial Theorem.As c s,t (x 0 − α) ≥ y 0 we get with monotonicity and Equation (2) that c s,t (x 0 ) ≥ y 0 /(1 + β) s > y ′ .This contradicts our assumption and establishes left-continuity of c s,t (x).
C s,t (x) is the easier of the two to establish and when min{s, t} = 2 is precisely given by the Kruskal-Katona theorem, which states that if . It was more generally determined for arbitrary s, t ≥ 2 by Huang et al. [44], who showed that the maximum is always achieved either by a clique with additional isolated vertices or by the complement of this graph.More precisely, where z is the unique root of . Note that this is differentiable except for at the point where the curves given by the two constructions meet.On the other hand, much less is known about c s,t (x).Clearly c s,t (0) = g s,t and c s,t (x) = 0 if and only if x ≥ g t,s , that is (0, g s,t ) and (g t,s , 0) are the points where the curve c s,t (x) intersects the axes when 0 ≤ x ≤ g t,s .Moreover, c s,t = min x c s,t (x) + x and therefore c s,t (x) ≥ c s,t − x.Given Proposition 2.1 and Proposition 2.2, we can also equivalently define it without needing to introduce Ω s,t as For s = 2 one is interested in the minimum possible density of cliques of size t in a graph of given edge density and in this case c 2,t (x) was completely determined; Razborov [68] gave an answer for t = 3, Nikiforov [63] for t = 4, and Reiher [69] for arbitrary t.See Figure 1 for an illustration of c 2,t (x) and C 2,t (x).We note that Liu, Pikhurko, and Staden [52] establish stability and exactness of c 2,3 (x) for x ∈ [1/2, 1] improving on previous results of Pikhurko and Razborov [64] and Lovász and Simonovits [56], where the latter also covers c 2,t (x) at and slightly below the Turán constructions.A simple deterministic construction also shows that the lower bound by Goodman for s = t = 3 is tight in this more general case, establishing that c 3,3 (x) is in fact linear and can be obtained by interpolating between extremal constructions similar as for c 2,t (x).(1, 0)  Proof.A possible construction of a sequence of n-vertex graphs goes as follows.For some η ∈ [0, 1/2] we take two cliques of size ⌈ηn⌉ and two independent sets of size ⌊(1/2 − η)n⌋.Each clique is fully connected to a different one of the independent sets and also the independent sets are fully connected.The density of triangles in this graph approaches 2η3 + 6η2 (1/2 − η) and the density of independent sets of size three approaches 2(1/2 − η) 3 + 6(1/2 − η) 2 η.Each of these quantities covers [0, 1/4] for η ∈ [0, 1/2] and together they sum up to 1/4.
Together with C 3,3 (x) as given by [44], this determines Ω 3,3 as illustrated in Figure 2.This region was in fact already earlier established by Huang et al. [43], who relied on a probabilistic construction for every point in the region, rather than interpolating between the two bounding curves as in the proof of Proposition 2.1.Beyond that very little is known about the shape of c s,t (x), providing some additional motivation for studying the parameters c s,t and g s,t stated in the introduction.
Recall that c s,t (x) ≥ c s,t − x, so Theorem 1.1, Theorem 1.2, and Theorem 1.4 imply linear lower bounds of c s,t (x) for some specific values of s and t.Let us take a closer look at the smallest open case, that is s = 3 and t = 4. Calculating the K 3 and K 4 density of the sequence of blow-ups 2 of the Schläfli graph, we get that c 3,4 (41 • 3 −6 ) = 320 • 3 −8 , establishing one precise value of the curve besides the ones on the axes.Additionally, we can show that c 3,4 (x) is not differentiable at this point by establishing a second tight lower bound using a differently weighted version of c 3,4 , see Section 4.3 for more details.
Noting that by Das et al. [15] and Pikhurko and Vaughan [66] the value of g 3,4 = c 3,4 (0) = c 4,3 (1/9) is determined by the sequence of blow-ups of K 3 and the value of g 4,3 = c 3,4 (3/25) = c 4,3 (0) by that of a C 5 with loops at all vertices, it also seems reasonable to ask if the Schläfli graph could mark a first 'extremal point' of the curve c 3,4 (x) that does not lie on either axis, the same way that K t does for c 2,t (x), or if alternatively the blow-up sequence of another vertex-transitive graph on fewer than 27 vertices marks such a point.Surprisingly, some experimentation reveals that neither option seems to hold true: there is no sequence of blow-ups of a vertextransitive graph on up to 47 vertices that determines a point in convex position with the points given by the Schläfli graph and K 3 , where one might expect points of discontinuity to be more easily described.There are however various blow-up sequences of vertex transitive graphs on at least 112 vertices that are in convex position with those points.On the other hand, between the points given by the Schläfli graph and the looped C 5 , where we would expect constructions to become increasingly complex, we first find a vertextransitive graph on only 24 vertices determining a point in convex position with the two other points.Lest one assume that this might indicate a pattern, there also exists a vertextransitive graph on 40 vertices that determines a point in convex position with this point and the one given by the looped C 5 .Our results are illustrated in Figure 3.We note that stability also holds for g 3,4 and g 4,3 [15,66] and Theorem 1.4 establishes the same for the Schläfli graph.

Constructive upper bounds
All upper bounds on c t , c s,t , g s,t , and c s,t (x) described in the introduction and previous section rely on explicit constructions.When only the asymptotic value is of interest, this usually implies considering the blow-up of a fixed finite graph to obtain a sequence of graphs with increasing order that have some desired property.
This means that a vertex of C is replaced by an independent set of size m in C[m] if that vertex does not have a loop, or by a clique of size m otherwise.Note that our definition ensures that the blow-up is always a simple graph even when C contains loops.It follows that the complement of the blow-up of a graph C is equal to the blow-up of the complement of C with loops added at every vertex.We denote this type of complement as the looped complement of a graph. 4he blow-up of a graph has certain properties that are favorable to this type of problem.In particular, if the graph has no loops then its clique number is equal to that of C, that is ω(C[m]) = ω(C) for any m ∈ N.More broadly, we have the following result due to Thomason [83].Lemma 3.2.For any simple graph C of order n and for m ∈ N going to infinity, we have as well as where S(t, j) = j i=0 (−1) i j i (j − i) t /j! is the Stirling number of the second kind.
This is a direct consequence of the fact that the fraction of not necessarily injective homomorphic copies of cliques of size t in a graph stays the same under blow-up.The number of homomorphic copies asymptotically matches the number of injective copies, accounting for the 1 + o(1) term.This statement also readily generalizes to arbitrary graphs and not just cliques as well as to non-balanced blow-ups.From a more practical perspective, Lemma 3.2 gives an efficient way to compute an upper bound on c s,t from any graph C, as well as an upper bound on g s,t from any graph C with ω(C) ≤ t − 1, through the blow-up sequence (C[m]) m∈N .We will describe several different approaches that we employed in order to find constructions whose blow-up sequence give good upper bounds for the problems presented in the introduction.

The discrete optimization problems
where we are minimizing a cost c : {0, 1} N → R over a discrete search space consisting of binary vectors {0, 1} N for some N ∈ N. In particular, we considered encoding both simple graphs as well as Cayley graphs through binary vectors, though many other combinatorial structures can expressed this way, see for example the recent work of Wagner [90].
The graph search space.When constructing arbitrary graphs on n vertices, a state s ∈ {0, 1} N represents the edges of that graph, so that we have N = n 2 .We associate with each edge an entry s i in s that indicates whether the edge is in the graph or not.Denoting the constructed graph by C = C(s), the cost function is simply given by where λ = 1 in the case of c s,t , except when searching for particular improvements on the bounds on c s,t (x), and λ ≫ 1 in the case of g s,t to act as a Lagrangian multiplier to ensure that the constraint k t (C[m]) = 0 is fulfilled.This cost function is easily calculated through Lemma 3.2.
The Cayley graph search space.The effectiveness of any search method will primarily be governed by the number N of variables used to construct the graph.However, at least for the motivating K 4 -Ramsey multiplicity problem, we found that the quality of a construction was strongly dependent on its number of vertices n.Since in the general graph space N = n 2 is quadratic in n, searching for constructions becomes intractable when the number of vertices reaches the fourties.In order to access graphs beyond that, we explored the family of Cayley graphs, for which more efficient description is available.
Given a group G and a set S ⊆ G \ {1} satisfying S = S −1 , the corresponding Cayley graph C = C(G, S) has vertex set G and two vertices g 1 , g 2 are connected by an edge if g 1 s = g 2 for some s ∈ S. A state s ∈ {0, 1} N represents the generating set s A =1 A where each subset A = {g, g −1 } for g ∈ G corresponds to an entry s A in s.Denoting the Cayley graph constructed this way by C = C(s), the relevant cost function is again given by Equation (5).
The number N of variables needed to encode a Cayley graph is between |G|/2 and |G| − 1.This is only linear in the number of vertices, which allows us to search for graphs an order of magnitude larger.Additionally, Cayley graphs form a substantial subset of vertex-transitive graphs [40,41], making them a highly relevant source of constructions.Both circumstantial evidence and the following lemma, stating that in an optimal construction, the number of K 4 and K 4 at each vertex is asymptotically the same, support this relevance.Given a graph G and set of vertices S ⊆ V (G), let k t (G, S) denote the number of cliques of size t in G containing all vertices of S. The proof is based on that of [3,Proposition 8].Lemma 3.3.For any t ≥ 3 and sequence of graphs Consider the sequence of graphs G ′ n obtained by deleting u n from G n and duplicating v n as v ′ n along with its relations, where we choose to include where the o(1) term comes from all cliques containing both v n and u n or v ′ n .This contradicts the assumption that lim n→∞ k t (G) + k t (G) = c t .

Heuristic search methods.
Since the early 80s, many heuristic methods have been suggested for solving NP-hard optimization problems, particularly for combinatorial problems with discrete search spaces.We focus on two well-established methods that gained traction in the search for Ramsey numbers [22,23,59] and provide an accessible introduction to both, complementing a recent growing interest in computational means in Extremal Combinatorics [51,71,90,91].Although heuristics inherently lacking global optimality guarantees, matching flag algebra lower bounds and stability results can, in this particular case, establish the optimality and uniqueness of heuristic solutions.For more information on the subject of heuristic search methods, we refer the interested reader to the handbook of Gendreau and Potvin [31].We also discuss the efficacy of a more recent Machine Learning-based approach compared to these methods in Section 5.3.Simulated Annealing.Simulated Annealing (SA) is a probabilistic technique that can be interpreted as a modified local search.It accepts worse states according to a probabilistic acceptance criterion, which is modified over time to reject worse states and avoid getting trapped in local minima.SA was originally proposed by Kirkpatrick, Gelatt and Vecchi [49], and its impact has been significant; in 2014, the original paper was listed as one of the 100 most cited scientific papers of all time [86].Algorithm 1 describes the algorithm in pseudocode.
To more precisely describe the algorithm, let N : {0, 1} N → P({0, 1} N ) denote some notion of neighborhoods of the states.We restricted ourselves to considering states as neighboring if their Hamming distance is 1.The algorithm starts with a random state s 0 and executes a fixed number of iterations I, where in each iteration 1 ≤ i ≤ I we pick a candidate state s c uniformly at random from N (s i−1 ) and accept it based on the probabilistic Metropolis' criterion [60].See also Dueck and Scheuer [18] for a variant that avoids the probabilistic nature of SA.The temperature sequence (t i ) 1≤i≤I typically converges to 0, and SA functions more like a local search as it does.There are many details when implementing SA, and the presentation here should not be considered authoritative.Due to the relatively cheap computation of c(s ′ ) for any s ′ ∈ N (s), we implemented a variant of SA that avoids rejecting states by directly sampling Algorithm 1: Simulated Annealing candidates from an appropriate distribution dictated by Metropolis' criterion, as previously suggested by Greene and Supowit [38].
Tabu Search.Tabu Search, an even simpler search heuristic than SA, was suggested by Glover [33,34,35].Like SA, it can be viewed as a modified local search aimed at avoiding local optima and cycles.We start with a randomly initialized state s 0 and require a notion of neighborhood N : {0, 1} N → P({0, 1} N ).We execute I iterations, where in each iteration 1 ≤ i ≤ I, we pick the neighboring state s ∈ N (s i−1 ) with the lowest associated cost and that has not been visited recently, regardless of whether it improves upon c(s i−1 ).Algorithm 2 contains the pseudo-code for Tabu Search.

(s) end
There are many degrees of freedom when implementing this algorithm.One modification we made was to the history implementation: instead of storing a history of the last ℓ states and excluding those from the update, we store a list of the last ℓ modified bits and exclude any state that differs from the current one in one of those bits.This slightly increases the number of excluded states but drastically reduces the computational and implementation effort required to determine which states to exclude.
It is crucial to have an efficient implementation of the cost function c for both methods, particularly since they are often run in parallel for various initial states.In our application, we precomputed the relevant indices for all cliques, considering multiplicity, and stored the results in a matrix format.This approach allowed us to evaluate c using only elementary matrix operations on a GPU, substantially improving efficiency when assessing multiple states in parallel.

Constructions
We implemented all search methods in Python and Pytorch and logged the results using Weights & Biases [7].We relied on the GAP [30] component in SageMath and in particular the Small Groups library for Cayley graph constructions.We will represent graphs using their graph6 representation, a 6-bit encoding of the upper triangle of the graph adjacency matrix.This representation can be most easily decoded using SageMath and a formal description is available at cs.anu.edu.au/~bdm/data/formats.txt.Graph descriptions too large to be included in this paper are available at doi.org/10.5281/zenodo.6364588.We also provide a survey of the derivation of previous constructions and describe the process we used to obtain our bounds for additional context.Previous constructions.The original counterexample by Thomason [83] to Erdős' conjecture for t ≥ 4 was given by the blow-up sequence of graphs formed by vectors in orthogonal geometries.This construction gives c 4 < 0.03050 and c 5 < 0.001769 and Thomason improved the bound for t = 4 to c 4 < 0.03030 through a computer based local search around its two-fold blow-up.Franek and Rödl [29] presented a class of more simply describable Cayley graphs containing a construction on 2 10 = 1024 vertices, also found through a computer search, whose blow-up sequence likewise disproves Erdős' conjecture for t = 4 by giving an upper bound of c 4 < 0.03052.This was generalised by Franek [27] and Deza, Franek, and Liu [17], giving the currently best known bounds for c 6 , c 7 , and c 8 .
Thomason [84] slightly improved upon his constructions for t ∈ {4, 5} by noticing that the XOR graph product ⊗ 5 has some favorable properties for this problem, which were previously already observed by Chung and Graham [13].In particular, by simply computing a particular vector of graph densities for two given graphs G 1 , G 2 , one can determine the corresponding vector of G 1 ⊗G 2 as the element-wise product of those two vectors from which one can then easily determine the relevant upper bound on c s,t through a vector product with some appropriate weight vector.Computationally, this gives one the opportunity to pre-calculate these density vectors for small or medium sized graphs and then cheaply compute the upper bounds given by even very large graph products.The best upper bound found this way for c 4 is given by the blow-up sequence of K 4 ⊗ M 4 ⊗ G 18 , where M 4 denotes a perfect matching of order 4 and G 18 the complement of K ⊗2 3 ⊗ K 2 , giving roughly c 4 < 0.03029, and the best upper bound for 5 Given two graphs G1 = (V1, E1) and G2 = (V2, E2), their XOR graph product G1 ⊗ G2 has vertex set V1 × V2 and two vertices (v1, v2), Here we consider loops in the graph, that is in particular vv / ∈ Ei for v ∈ Vi unless Gi has a loop at v for i ∈ {1, 2}.Thomason calls this graph product the tensor product and Wolf [92] states that it is also known as the Cartesian product.It seems however that the tensor product is more commonly used for the case v1v ′ 1 ∈ E1 and v2v ′ 2 ∈ E2 and the Cartesian product for the case either v1v ′ 1 ∈ E1 and v2 = v ′ 2 or v1 = v ′ 1 and v2v ′ 2 ∈ E2, so to avoid confusion we use the unambiguous terminology of Alon and Lubetzky [2].We will also write G ⊗k for the k-fold XOR graph product of a graph G. c 5 < 0.001720 is given by the blow-up sequence of K 3 ⊗ M ⊗3 4 .Thomason also observed that his original constructions from [83] can be described as K 4 ⊗ M ⊗(t−1) 4 for t ≥ 5 and as a subgraph of this for t = 4.Note that the XOR graph product in some sense works as a generalisation of the blow-up, since G[m] = G ⊗ K m for a loopless graph G.
The improvement of Even-Zohar and Linial [21] was based on the observation that G 18 can also be seen as a blow-up of K 2 with a copy of K 3 ⊗ K 3 inserted at every vertex, rather than an independent set.This motivates the composition G ⊙ H of two graphs G and H, where a copy of G is placed at every vertex of H 6 , e.g.
) ⊙n for n tending to infinity, where G ⊙n is the n-fold composition of G with itself.This is the only example of a construction that is not a standard blow-up and it remains unclear what the role of K 4 ⊗ M 4 is.While a similar decomposition followed by replacing some part with an n-fold composition could possibly enhance other bounds, it is computationally challenging to identify a suitable decomposition with XOR products for larger graphs, if such a decomposition even exists.
We finally note that we pushed both the approaches of Franek and Rödl in [29], Thomason in [84], and Even-Zohar and Linial [21] to what we found feasible using our capabilities and computational resources.We found no or only the most marginal of improvements, implying that these approaches have probably exhausted their full potential.
Constructions in Theorem 1.1 and Theorem 1.2.We ran heuristic searches to construct graphs on up to 40 vertices that minimize the cost function given by Equation (5).The smallest graph we found whose blow-up sequence establishes a value below 1/32 was of order 33, giving a value of 0.03118.The smallest previously known such graph was described by Thomason [83] and was of order 36.We also found a graph on 32 vertices whose weighted blow-up gives a value slightly below 1/32.We found no further constructions on less than 40 vertices giving any significantly better values.
Given that the blow-up sequences of small graphs seem to yield little of interest, we considered Cayley graphs next.We have already noted that the best construction given by a blow-up sequence (c 4 < 0.03029) is based on a Cayley graph in Z ×2 3 × Z ×5 2 (order 288) and a Tabu Search in that particular group yielded no improvement.However, already in Z 3 × Z ×6 2 (order 192) we were able to find a graph whose blow-up sequence even improves upon the previous best value found by Even-Zohar and Linial (c 4 < 0.3028), giving an upper bound of c 4 < 0.03027.Going to Z 3 × Z ×8 2 (order 384) allows us to already achieve a bound if c 4 < 0.03015 and going up to Z 3 × Z ×8 2 (order 768) produced the graph whose blow-up sequence gives the upper bound We note that there seems to be no particular significance to the fact that we derived these constructions in groups defined only through direct products.In fact, running the Tabu Search on all groups of order at most 192 revealed (1) that in general decent constructions seem to be found in groups of order 3 • 2 n and (2) many groups of that order perform significantly better 6 Formally, given two graphs G1 = (V1, E1) and G2 = (V2, E2), their composition G1 ⊙ G2 has vertex set V1 × V2 and two vertices (v1, v2), than the group Z 3 × Z ×n 2 .For example, for groups of order 192 the best value we found was around 0.03021.Unfortunately we were unable to determine any patterns indicating which groups might be preferable when going to groups of order 384 or 768.The sheer number of these groups and the amount of cliques to consider unfortunately makes it impossible to run a Tabu Search on anything more than a small selection of them.
Regarding the value for c 5 , the previous best construction can be described as the blow-up sequence of a Cayley graph in Z 3 × Z ×6 2 (order 192).A search run on Cayley graphs in this group yielded the slight improvement presented in Theorem 1.2.Due to the fact that we need to consider cliques of size 5, we were unable to go up Cayley graphs of order 384 or 768 as we did for c 4 .

Bounded clique number -Theorem 1.3
Previous constructions.Complete graphs are obvious candidates to consider as constructions in this context, as the Turán graph T t−1 (n) can be described as K t−1 [n/(t − 1)] whenever t − 1 divides n, that is the blow-up sequences of K t−1 give tight upper bounds for g 2,t for arbitrary t ≥ 2. The same holds for g 3,3 as the blow-up sequence of K 2 gives an upper bound of 1/4 and g 3,3 ≥ c 3 = 1/4 by [36].Das et al. [15] showed that the upper bound given by the blow-up sequence of K 3 for g 3,4 is tight and the results of Pikhurko and Vaughan [66] imply that the same is true for K t−1 and g 3,t for t ∈ {5, 6, 7}.
However, Nikiforov [62] showed this can only cover finitely many cases of g s,t when s, t ≥ 3 and for the Ramsey multiplicity problem, the blow-up sequences of complete graphs are in general far from even the performance of random graphs.Das et al. [15] showed that for g 4,3 the tight upper bound is given by the blow-up sequence of C 5 and Pikhurko and Vaughan [66] proved the same for g 5,3 and that the the blow-up sequence of the Clebsch graph on 16 vertices establishes tight upper upper bounds for g 6,3 and g 7,3 .Note that both C 5 and the Clebsch graph are vertex-transitive and in fact can be realized as Cayley graphs, which of course is also true of complete graphs.
Pikhurko and Vaughan [66] also found a construction for g 4,4 that relies on the weighted blow-up sequence of a non-vertex-transitive graph of order 8 where the weights of the blow-up align with the two vertex orbits of size 4 of the graph.This graph is in fact one of three (3, 4)-Ramsey graphs of order 9 and has the graph6 representation GK^d}w.The upper bound of (14 • 2 1/3 − 11)/2 7 ≈ 0.034578 given by this construction seemingly aligns with the lower bound indicated by the flag algebra approach, but they were unable to turn this into a rigorous proof.
Constructions in Theorem 1.3.The construction used to establish g 4,5 is given by the blow-up sequence of the unique vertex-transitive graph of order 13, degree 8, clique number 4 and independence number 2, referred to as C R (3,5) in the introduction.This is the only (3, 5)-Ramsey graph of order 13 and has the graph6 representation

LJ]lmZRnn]]\v[
This construction can be easily found using a search heuristic in the graph space or through an exhaustive search of all Cayley graphs of Z 13 .
The construction used to establish the upper bound for g 5,5 is the same used to establish g 4,5 , that is it is given by the blow-up sequence of the unique (3, 5)-Ramsey graph of order 13 which has the graph6 representation

LJ]lmZRnn]]\v[
The construction used to establish the upper bounds for g 4,6 and g 5,6 is given by the weighted blow-up sequence of a (3, 6)-Ramsey graphs of order 17 which has 9 vertex orbits and the graph6 representation

P~TktL|vdu{{^]vl[z|v]B~{
The construction used to establish the upper bounds for g 4,7 and g 5,7 is given by the weighted blow-up sequence of a (3, 7)-Ramsey graphs of order 22 which has 11 vertex orbits and the graph6 representation

U'K~vj\zff\Zt]rlzv^Zm}z^v]r~^r}~m}~kn^vG
We also checked a library of small vertex-transitive graphs [40] but found no additional constructions improving upon the upper bounds.For g 5,4 and g 5,5 we additionally ran search heuristics both in the graph and Cayley graph space and also found no improvements.

Off-diagonal Ramsey multiplicity -Theorem 1.4
The construction used to establish the upper bound for c 3,4 is given by the blow-up sequence of the Schläfli graph, a vertex-transitive graph of order 27, with the graph6 representation

ZBXzz|z^Z|tFixjTtp|mFk\uqm|gz}]FbHvHqjh]WzFy[RmtSUztaLvyF'vw
The construction used to establish c 3,5 is better described as a construction for c 5,3 in which case it is given by the blow-up sequence of the complement of the Schläfli graph, that is the graph with the graph6 representation Z??G'@?@wrDSLGQoigbKO]CA?^{VDsjIqehgmK[EM[OzIqCyegO|FO_^{?_?
Both of these constructions can be found through search heuristics of graphs of order 27.The construction used to establish the upper bound for c 4,5 is given by the blow-up sequence of vertex-transitive graph on 128 vertices.It was found using a search of Cayley graphs of order at most 128.
Additional constructions in Figure 3.The graph on 40 vertices is vertex-transitive, has degree 17, clique number 3 and independence number 12.The graph on 24 vertices is vertextransitive, has degree 11, clique number 3 and independence number 6 and has the graph6 representation W@TBOkkJBBAoSCW?Qv{V}jRrhfC{UEfaRPtAw\_ckqGt'oL The graph on 128 vertices is vertex-transitive, has degree 78, clique number 5 and independence number 16. Lastly, the graph on 112 vertices is vertex-transitive, has degree 68, clique number 5 and independence number 14.The two smaller graphs were found using a vertex-transitive graph library [40,41] and the two larger using a search of Cayley graphs of order at most 128 where the λ parameter was adjusted accordingly in Equation ( 5).

Lower bounds and stability through flag algebras
Razborov [67] proposed using finite model theory to describe the algebraic structure underlying many techniques in Extremal Combinatorics.This approach allows one to derive lower bounds for problems like those studied in this paper through a semi-definite program (SDP).This method has been widely used over the past decade and there exist not only several very good introductions to the topic [24,66,79] but also a tool in the form of flagmatic [87].
If the lower bound obtained with this approach matches a constructive upper bound it is sometimes possible to additionally infer the uniqueness of the construction from the flag algebra based proof.We improve the toolset developed in [65,66] used to derive such stability results in order to show that several of the constructive bounds found using search heuristics in fact represent global optima.We start with a summary of the theory behind the approach based on [65,66], then turn to the stability aspect, and finally go into some detail about the practical aspects of how our proofs can be verified.

The theory behind the flag algebra approach
Suppose we have a (possibly empty) family X of forbidden graphs.Let G n = G n (X ) denote set of all graphs up to isomorphism of some given order n not containing any graph in X as an induced subgraph and write G = G(X ) = n∈N G n (X ).For two graphs G and H we let d H (G) denote the induced subgraph density of H in G, that is the probability that |V (H)| vertices chosen uniformly at random in G induce a copy of H. Consider a graph parameter λ : G → R for which there exists some n 0 ∈ N such that λ satisfies the averaging equality for any n ≥ n 0 and G ∈ G of order at least n.We note that the results in this paper are limited to families of forbidden graphs X = ∅ and X = {K t } as well as the graph parameter λ(G) = d Ks (G) + d Kt (G), which clearly satisfies Equation ( 6) with n 0 = max{s, t}.
For any infinite subset H ⊆ G, we write where for notational convenience λ(n, H) = ∞ when H ∩ G n = ∅.We are of course primarily interested in studying λ(G), though we keep the notation general, as we will need it when establishing stability.Note that a trivial lower bound that follows from Equation ( 6) is λ(G) ≥ λ(m, G) for any arbitrary m ≥ n 0 .
The goal of the flag algebra approach is to establish the existence of coefficents a H ∈ R for some fixed m ∈ N satisfying the inequality for any G of order at least m, as this implies the, hopefully improved, lower bound of In order to establish the type of coefficients commonly achieved through the solution of an SDP, we will need some additional notation.Note that the term strong (graph) homomorphism between two (potentially looped) graphs G 1 and G 2 refers to any map ψ : Definition 4.1.A type τ = (T, ϕ) consists of a graph T ∈ G of order v that is fully and distinctly labelled through ϕ : [v] ֒→ V (T ).Note that we can have v = 0, in which case τ is the empty type ∅.A τ -flag (F, ψ) consists of a graph F ∈ G of order at least v that is a partially labelled through the injective map ψ : [v] ֒→ V (F ) that also satisfies that ψ •ϕ −1 : V (T ) ֒→ V (F ) defines an injective strong homomorphism of T into F .
We will denote the set of all τ -flags of order l ≥ v by F l τ .Let F, F ′ ∈ F l τ be two τ -flags of same order and H ∈ G an arbitrary graph of order at least 2l − v. Let θ : [v] ֒→ V (H) be an arbitrary injective map implying a partial labelling of H (but not necessarily turning (H, θ) into a τ -flag) and write d θ F (H) for the probability that l − v vertices selected uniformly at random in V (H) \ θ([v]) together with the vertices labelled by θ induce a flag isomorphic to F .Obviously this value is 0 whenever (H, θ) is not a τ -flag.We will write d F (H) = E θ d θ F (H) for the flag density, where we are taking the uniform distribution over all possible injective maps θ.We will likewise write d θ F,F ′ (H) for the probability that a subset S 1 of V (H) \ θ([v]) of size l − v chosen uniformly at random together with the vertices labelled through θ is isomorphic to F and that another subset S 2 of V (H) \ θ([v]) ∪ S 1 of size l − v chosen uniformly at random together with the vertices labelled through θ is isomorphic to F ′ .We will write d F,F ′ (H) = E θ d θ F,F ′ (H) for the flag pair density.
Example.There is exactly one type τ of order 1, i.e., that based on a graph with a single labelled vertex.There are also exactly two τ -flags of order 2, that consisting of an edge with a labelled vertex and that consisting of two isolated vertices with one labelled, and six τ -flags of order 3.
We note that Equation ( 6) holds for the flag pair density when m ≥ 2l − v, that is for arbitrary G ∈ G.We also note that Using this notation, we can now state the heart of the SDP-based flag algebra approach.
Proposition 4.2.For any integer m ∈ N, types τ i of order 0 ≤ v i ≤ m − 2 satisfying v i ≡ m mod 2, and positive semi-definite matrices , where we will use flags F ∈ F l i τ i as indices for Q (i) , we have Proof.Let us establish that for any graph G of order n.By rearranging and then applying both Equation ( 9) and Equation (10), we have for all 1 ≤ i ≤ r.Equation ( 12) therefore follows from the fact that the Q (i) are positive semi-definite and by summing over 1 ≤ i ≤ r.By Equation ( 12) the terms can serve as a H in Equation ( 7), establishing the claim of through Equation ( 8).
This proposition motivates the following SDP formulation: given two symmetric matrices A and B of equal size, we will use the inner product A, B = tr(A T B).Write D (i) (H) for the symmetric matrix of size whose entries are given by d F,F ′ (H) when using flags F ∈ F l i τ i as indices.Write D H for the symmetric block diagonal matrix with the integer 1 as its first and D (i) (H) as the following blocks for 1 ≤ i ≤ r.Finally, let C denote the matrix of equal size to D H with all-zero entries except for the first, which is 1.We are now interested in solving max Finding a positive semi-definite matrices X that solves this SDP is equivalent to finding Q (i) that maximize the right hand side of Equation (11).Of course, most actual solvers will take advantage of the block-diagonal structure that we may assume for X given the problem formulation, rather than optimizing over the whole space of positive semi-definite matrices.
Example.For our toy example of c 3 let us choose r = 1 and suppress the index i.We let τ be the only type on one vertex and set l = 2 and m = 3.Then F 2 τ consists of the two graphs on two vertices, j edges and one labelled vertex, where 0 ≤ j ≤ 1.Likewise, H 3 consists of the four graphs H j on 3 vertices with exactly j edges, where 0 ≤ j ≤ 3. We only require one positive-semidefinite matrix of size 2 × 2 here and write it as Note that Q is positive-semidefinite if and only if a ≥ 0 and ab − c 2 ≥ 0. By Proposition 4.2 we need to maximize the minimum of the four expressions It is easy to see that this minimum is attained when a = b = 3/4 and c = −3/4, in which case all four expressions attain the value of 1/4.

Establishing stability and exactness
After finding matching upper and lower bounds, it is natural to ask whether the construction is unique and stability holds, i.e., if anything that comes close to the optimal value must be close to the extremal construction.Statements like this can usually be derived by extracting additional information from a flag algebra based proof and appealing to the Induced Removal Lemma of Alon et al. [1].Pikhurko et al. [65] formalized this process, establishing sufficient criteria for various stability forms.We will present this succinctly while highlighting two improvements: introducing and strengthening the notion of reconstructors to derive stability from smaller Flag-Algebra-based proofs, and formalizing an argument for establishing the optimal weighting of a blow-up.Let us start by establishing some additional notions relating to Proposition 4.2.
) a certificate of the bound given by Proposition 4.2.Assuming a certificate establishes equality in Equation (11), that is it is a certificate of λ(G), we call a graph A graph that is not sharp asymptotically does not appear as a subgraph in any extremal sequence, see for example Lemma 4.1 in [66] for a proof of this statement.
Sharp graphs therefore usually give a good indication of which graphs can occur as subgraphs in an extremal sequence and have in the past been used to find novel constructions.
Example.Briefly returning to our toy example of c 3 , we had a certificate with m = 3 in which all graphs were sharp, indicating that there might be (and in fact are) extremal sequnces for c 3 containing any subgraph of order 3 with positive density.
If a certificate (m, (τ i ), (Q (i) )) is sufficiently large in relation to our believed extremal construction C, say m ≥ |V (C)| + 1, and stability is believed to hold, then establishing it is often a reasonably straight-forward matter of verifying that the only sharp graphs are those that occur with positive density in the blow-up sequence of C and then invoking the Induced Removal Lemma.This is often far beyond the realm of being computationally feasible, so we need a way to establish the structure of a construction C using only graphs of order m, where m is preferably as small as possible.This was already done implicitly in [66] and the same ideas can also be found in [65], where some sufficient requirements are part of the general criteria stated there.We find it helpful though to state the exact requirements separately from the statements used to establish the stability result, as this is the place were the most can be achieved using ad-hoc arguments invoking the structure of C.This motivates the following definition.Definition 4.5.A graph T is an ℓ-reconstructor of a given graph C if there exists a strong homomorphism from G to C for any graph G satisfying the following: Let us introduce some additional notions.For a given graph C, we say that a graph T uniquely embeds into C if there exists a strong homomorphism ψ : V (T ) → V (C) and ψ is unique up to automorphism, that is for any additional strong homomorphism It is easy to see that a graph C is an ℓ-reconstructor of itself if |V (C)| ≤ ℓ − 1.More commonly though, the following lemma is used, which is also implicit in Theorem 4.1 in [65].Lemma 4.6.For a given graph C and set of vertices uniquely embeds into C, and (iii) X defines unique neighborhoods in C.
A more technical but stronger condition was previously already implicitly formulated in [66] to establish stability of the Clebsch graph for g 6,3 using a certificate with m = 7.Here we further strengthen it in the form of the following lemma.Lemma 4.7.Let a graph C be given.If there exists Proof.Let some arbitrary graph G satisfying the assumptions of Definition 4.5 be given.Fix a copy of C[X] in G that is guaranteed to exist by assumption (i) of Definition 4.5, that is fix and let ψ : Y ֒→ X be the corresponding graph isomorphism.
The goal is to construct a strong homomorphism ϕ : V (G) → V (C) satisfying ϕ| Y ≡ ψ given the requirements of the lemma and the assumptions of a reconstructor.Let us first assume that By assumption (ii) of Definition 4.5, there exists a strong homomorphism be arbitrary but fixed and write y = ψ −1 (x) ∈ Y \ Y ′ .By assumption (ii) of Definition 4.5, there exists a strong homomorphism ϕ v : Y ′ ∪ {y, v} → V (C) for any vertex v ∈ V (G) since |Y ′ ∪ {y, v}| ≤ ℓ by (1b).As C[X ′ ∪ {x}] uniquely embeds into C by (1b), we can again w.l.o.g.assume that ϕ v | Y ′ ∪{y} ≡ ψ| Y ′ ∪{y} .Since X ′ defines unique neighborhoods in C by (2), it likewise follows that ϕ v (v) is uniquely defined for every v ∈ V (G) and its adjacencies in X ′ ∪ {x} match those of v in Y ′ ∪ {y} under ψ.Since this is actually independent of our choice of x, we in fact also have that the adjacencies of Let us now establish that in either case ϕ is in fact a strong homomorphism from G to C. For arbitrary w 1 , w 2 ∈ V (G), let X ′′ ⊂ X be as given by (3) has at most ℓ vertices, so by assumption (ii) of Definition 4.5 there exists a strong homomorphism ϕ ′ : for any i ∈ {1, 2} by construction of ϕ and since C[X ′′ ∪ {v i }] uniquely embeds into C for some i ∈ {1, 2} by (3), we can w.l.o.g.assume that ϕ ′ | Y ′′ ≡ ψ| Y ′′ ≡ ϕ| Y ′′ .We distinguish the cases v 1 = v 2 and v 1 = v 2 .In the former, [v 1 ] X ′′ = {v 1 } by (3a).Since ϕ ′ is a strong homomorphism, we have ϕ ′ (w i ) ∈ [v 1 ] X ′′ for i ∈ {1, 2} and it follows that ϕ ′ (w 2 ) = v 2 = v 1 = ϕ ′ (w 1 ).Since ϕ ′ is a strong homomorphism and C simple, w 1 and w 2 are therefore not adjacent in as the set of all blow-ups of C where the parts are weighted according to w where w i denotes the i-th entry of w.
While theoretically the problem of establishing arg min w∈Sn λ(B w (C)) could be stated as a polynomial minimization problem over n − 1 variables, the usual approach relies on studying if any of the matrices Q i have unique zero eigenvectors and then invoking the subsequent proposition to relate them to graph densities, assuming the associated types τ i are present in C and fulfill certain properties.We will need the following result, c.f. Lemma 3.4 in [65].Before stating it, assume some 1 ≤ i ≤ r and ψ : [v i ] ֒→ V (C) us given, where v i is the order of τ i , such that (C, ψ) is a τ i -flag and w j = 0 for all j ∈ ψ([v i ]).Let δ ψ F (C, w) now denote the probability that l i − v i vertices chosen not-necessarily-injectively and at random according to w in V (C) \ ψ([v i ]) together with the vertices labelled by ψ induce a flag isomorphic to F .Note that this generalizes the previous definition of d ψ F (C), where the vertices were selected uniformly at random.Lemma 4.10.Assume we have the following: 1.A set of forbidden graphs X , G = G(X ), and λ : for any G of large enough order n.
Then denoting all τ i -flags of order l i = (m + v i )/2 by F 1 , . . ., F g i in the same order that they are used as indices for Q i , the vector is a zero eigenvector of Q i .
Using this, one can formulate some sufficient criteria to establish the uniqueness of a given optimal weighting.The following is a generalization of Lemma 6.2 in [65] that is based on ideas previously used in [66].Proposition 4.11.Assume we have the following: for any G of large enough order n.
3. C ∈ G n and w ∈ S n satisfying λ(B w (C)) = λ(G) and w v = 0 for all v ∈ V (C).

A sequence of sets
Then w is the unique minimizer of λ(B w ′ (C)) for w ′ ∈ S n .
uniquely embeds into C, it follows that w.l.o.g.w ′ v = 0 for any v ∈ X 1 .Let us now inductively argue over 1 We can apply Lemma 4.10 since {v} and therefore w ′ v = 0 for any v ∈ X i by inductive assumption.Let x i and x ′ i therefore be as given for w and w ′ , where ψ : [v i ] ֒→ X i is chosen such that (C[X i ], ψ) = τ i and where v i is the order of τ i .Since Q i has co-rank 1 by assumption, it follows that in fact 4.3 Practical aspects of using the flag algebra approach flagmatic, developed by Emil Vaughan and hosted on github.com/jsliacan/flagmatic,calculates graph densities and passes SDP formulations to solvers like CSDP [9] and SDPA [93].In order to obtain rigorous mathematical proofs, the floating point-based solutions from the SDPs need to be rounded to (fractional) values while ensuring the matrices remain positive semidefinite.flagmatic handles this rounding process and produces verifiable certificates for the proofs, allowing anyone with access to the software to verify the results independently.The certificates for our lower bounds can be found at doi.org/10.5281/zenodo.6364588.We do not supply certificates of stability and symmetry from [65], as they are incompatible with our ad-hoc arguments in Lemma 4.7 and Theorem 4.9.Below we describe some specifics regarding the bounds for each problem.
Bounds and stability for c s,t .For the lower bounds of c 3,4 and c 3,5 , we used m = 6 and were able to reduce the number of types to 4 for each problem.The certificates for these proofs are contained in the files c 34.json and c 35.json.
In order to derive stability for c 3,4 , we also obtained a certificate for m = 7 and verified that all sharp graphs are those with a strong homomorphism into the Schläfli graph.The certificate for this proof is contained in the file c 34 7.json.Perfect stability now follows from Theorem 4.9 using the uniquely embeddable subgraph T of C S consisting of two triangles joined by an edge.The fact that T is a 7-reconstructor of the Schläfli graph follows by computationally verifying the requirements of Lemma 4.7.The certificate for the proof that λ(G({T }) > λ(G) is contained in the file c 34 reconstructor.json.The fact that the balanced blow-up of the Schläfli graph is the unique optimal weighting follows by applying Proposition 4.11.Here let the Schläfli graph be as ordered in the graph6 representation stated in Section 3.3 with vertices labelled 1, . . ., 27 and use X 1 = {1, 2, 4, 6, 7}, X 2 = {1, 2, 12, 13, 14} and X 3 = {1, 2, 4, 6, 12}.The certificate for the proof that λ(G(C S [X 1 ])) > λ(G) is contained in the file c 34 symmetry.json.
Regarding the non-differentiability of c 3,4 (x) at x = 41 • 3 −6 , we considered a differently weighted version of Equation ( 1).For w s , w t ≥ 0 satisfying w s + w t = 2, let c (ws,wt) and note that clearly c s,t = c (1,1) s,t .We used flagmatic to establish a lower bound for c Bounds and stability for g s,t .For g 4,5 , we used m = 7 and also used the full 38 types to establish this bound as the rounding failed when attempting to reduce the number of types involved.In general, this problem seemed more demanding and for example required the double precision solver.The certificate for the proof is contained in the file g 45.json.We can also easily derive perfect stability from this certificate by verifying that all sharp graphs are those with a strong homomorphism into C R (3,5) and noting that the graph T of order 5 obtained by joining two triangles at a vertex is a 7-reconstructor of C R(3,5) by Lemma 4.6.The certificate for the proof that λ(G({K 5 , K + 4 }) > λ(G({K 5 }) is contained in the file g 45 reconstructor.json.The fact that the balanced blow-up of C R (3,5) is the unique optimal weighting also easily follows by applying Proposition 4.11 with T as C[X 1 ] and k = 1 after verifying that the associated matrix Q indeed has co-rank 1.
All of the reported lower bounds for g s,t when (s, t) = (4, 5) were obtained using m = 8.The certificates for these proofs are contained in the files g st.json.

Remarks and open problems 5.1 Symmetric Ramsey multiplicity
The crucial question regarding the Ramsey multiplicity of K 4 is whether it whether there exists a graph whose blow-up sequence determines its value.Our answer to the c 3,4 and c 3,5 problem supports this possibility for c 4 .Our efforts for Theorem 1.1 however show that this construction could be unexpectedly complex.
In any case, the deeper understanding of the generating sets of our Cayley graphs on 192, 384, and 768 vertices, to the extent that they can be generalized, for arbitrary large k, to (semi-)direct products of the 3-element cyclic group Z 3 with k copies of Z 2 , would be extremely interesting.Besides that they would of course improve the upper bound on c 4 , more importantly they might shed light on how to count cliques in blow-ups of certain Cayley graphs.This could also lead to identifying the right choice of generating sets and help in constructing new Cayley graph sequences that improve the value of c t for t ≥ 5.This would be particularly desirable, since the best known general upper bound for the Ramsey multiplicity problem still comes from the original construction of Thomason [83], the analysis of which was improved by Jagger, Št ovíček, and Thomason [45] to c t < 0.835 • 2 1−( t 2 ) for t ≥ 7 via a direct counting of the homogeneous sets in the blow-up with Fourier analytic methods.
For large t Rödl conjectured (cf.[27]) that c t 2 ( t 2 ) → 0, possibly even exponentially fast.Yet, no t is known where the value of the quotient is less than 1/2.The best known general lower bound is due to Conlon [14] who showed that c t ≥ C −t 2 (1+o(1)) where C ≈ 2.18.Conlon comments, that his proof is the Ramsey multiplicity analogue of the Erdős-Szekeres proof for the symmetric Ramsey number.Hence it seems plausible that the approach of the recent improvements of Campos, Griffiths, Morris, and Sahasrabudhe [12] on the upper bound of the symmetric Ramsey number could be adapted to improve Conlon's constant C, though likely not to the best possible √ 2.

Asymmetric Ramsey multiplicities
Additionally, we explored graphs with small clique densities of order s and given independent set densities of order t.It is a tantalizing open problem to determine, or just obtain a better idea about the lower bounding curve c 3,4 (x) of the region of realizable K 3 -and K4 -density pairs in graphs.Given the results in Figure 3, even formulating a conjecture seems challenging.The properties of the curve, such as the number of non-differentiable points, what constructions they would be determined by, and convexity or concavity, remain unclear.The argument of Bollobás [8] giving a piece-wise linear lower bound for c 2,t (x) does not seem to generalize easily.Nikiforov [62] established that g s,t = (t−1) 1−s holds only for a finite number of pairs s, t ≥ 3, that is for all but a finite number of such pairs the construction given by Turán graphs is not optimal.Das et al. [15] established that equality does not hold for s > 3 and arbitrary t as well as for t ≥ 2074 when s = 3.The results of Pikhurko and Vaughan [66] establish that equality holds when s = 3 and t ≤ 7. The following proposition shows that there must exist a smallest 7 < t 0 ≤ 2074 such that g 3,t = 1/(t − 1) 2 for t < t 0 and g 3,t < 1/(t − 1) 2 for t ≥ t 0 .It would be interesting to precisely determine this value and to therefore determine all pairs of s, t for which Erdős' original intuition about the Turán graph holds true.Proposition 5.1.Given s, t 0 ≥ 2, we have g s,t ≤ (t − t 0 + g 1/(1−s) s,t 0 ) 1−s for all t ≥ t 0 .In particular, if g s,t 0 < (t 0 − 1) 1−s then g s,t < (t − 1) 1−s for all t ≥ t 0 Proof.Let γ = g 1/(s−1) s,t and (G n ) n∈N a sequence of graphs on n vertices with clique number at most t 0 − 1 satisfying lim n→∞ k s (G n )/ n s = g s,t 0 .By adding an independent set of ⌊γn⌋ vertices to each G n and fully connecting it to all other vertices, we get a sequence of graphs with clique number at most t 0 that establishes Recursively applying this gives us the desired result.

Learning-based optimization
Recent interest has emerged in using Machine Learning approaches to tackle combinatorial optimization problems.Specifically, Wagner [91] proposed finding constructions in Extremal Combinatorics by framing the underlying optimization problems within a Reinforcement Learning context, an idea similar to the 'active learning' approach suggested earlier by Bello et al. [6].In the context of round-based games and Reinforcement Learning, states are constructed bitby-bit, using a Neural Network to decide for each bit whether it should be 1 or 0 based on previous decisions.After sampling several discrete states through this procedure, the Neural Network's parameters are updated to produce states closer to the best ones sampled.The update procedure in [91] employs the Cross-Entropy (CE) method by Rubinstein [72,73].
We experimented a fair amount with Reinforcement Learning-based methods, including different network architectures and learning methods from the ones suggested in [91], but found their performance inferior to both SA and Tabu Search (TS) in terms of solution quality and computation time for medium and large-sized problems: • Finding the 13-vertex graph for g 4,5 takes TS 1s, SA 10s, and CE around 8min.
• Finding the (presumably unique) Cayley graph in Z 3 × Z ×6 2 giving an upper bound of c 4 < 0.03027 takes TS around 1 min, SA around 4 min, and CE just under one hour.
• For the 27-vertex graph for c 3,4 TS tends to get stuck in local minima, only very rarely finding it in around 30s, SA consistently finds it in 30s, and CE did not find it in any reasonable timeframe.
• For c 4 CE also found meaningful improvement over the previous best upper bound by constructing Cayley graphs on 192 vertices, but the corresponding value of 0.03022 is weaker than what TS found in the same search space and significantly weaker than what TS found on 768 vertices, a search space where CE could not feasibly be run.
While the values above do no constitute fully rigorous and definitive benchmarking of the three methods, they do reflect a fair amount of (hyper)parameter tuning as well as our anecdotal experience for these particular problems.We find it notable that for the problems studied here Tabu Search, with its straightforward idea and implementation, emerged as perhaps the most preferable method, fairly reliably finding good solutions in a short amount of time while requiring essentially zero tuning.
The idea of pretraining-free learning-based meta-heuristics using neural networks has a long history [42,80], but seems to so far not yet outperform simple baselines.There is a fair amount of ongoing research focused on improving optimization methods by training their behavior on dedicated training datasets, which are hoped to reflect real-world applications prior to the actual usage of these methods.However, this approach strongly differs from our use case, where we are predominantly interested in solving singular, difficult problems rather than a large pool of small or moderately-sized ones.It should be further noted that an RL-based approach is inherently wasteful in our particular context, that is for attacking simple black-box discrete optimization problems given by Equation (4); it models a distribution over the states {0, 1} N through N consecutive evaluations of a neural network.This round-based approach is artificially imposed, since, unlike with playing chess or Go, we do not have any opponent's choices to respond to and our distribution will ultimately collapse to a single state.This effectively means that rather than trying to find (an approximation of) a strategy, i.e., a still very large sub-tree of the full game tree, we are merely looking for a single path from the root to a leaf.

Classifying common and uncommon graphs
Before it was disproved, the conjecture of Erdős mentioned in the introduction was generalised to arbitrary graphs by Burr and Rosta [10].For graphs H and G we let t(H, G) be the number of copies of H in G and We note that c t = c(K t ) and while Burr and Rosta conjectured that the minimum is always attained by the random graph, we say that a graph H is common if c(H) = 2 1−|E(H)| and uncommon otherwise.A triangle is common by Goodman's result and Thomason's [83] result implies that K t is uncommon for t ≥ 4. Since then large families of common and uncommon graphs have been found and for an overview we refer to the recent paper of Grzesik, Lee, Lidicky, and Volec [39] and the references therein.Only recently the first uncommon graphs H were found, for which c(H) is known [26].Also an off-diagonal variant of common and uncommon pairs of graphs was studied by Behague, Morrison, and Noel [4,5].Lower bounds for common graphs are usually obtained through the flag algebra approach and upper bounds rely on constructions that beat 2 1−|E(H)| .There is also an interesting connection to the famous and still open conjecture of Sidorenko [78], which implies that every bipartite graph is common.

Parallels to problems in Additive Combinatorics
Similar problems to the ones considered in this paper have been studied in Additive Combinatorics, where one is interested in minimizing the number of monochromatic solutions to some system of linear equations in a coloring of the integers [n] = {1, . . ., n}, the cyclic group Z n or the repeated product of a fixed small finite field F n q .Graham, Rödl and Ruciński [37] asked this question regarding Schur triples in two-colorings of [n], which was independently resolved by Datskovsky [16], Robertson and Zeilberger [70], and Schoen [77], who showed that the true answer lies far below the number expected in a random coloring.In contrast to this, Cameron, Cilleruelo and Serra [11] showed that in finite groups the number of monochromatic solutions to any equation in an odd number of variables, which includes Schur triples, is minimized by the random coloring.Wolf [92] as well as Lu and Peng [57] studied the question of how many 4term arithmetic progressions a two-coloring of Z n can contain.Interestingly, the upper bounds given for this type of problem likewise consist of a type of 'blow-up' of a finite construction, indicating that the methods used here are also applicable in this context.In fact, denoting the minimum fraction of monochromatic k-term arithmetic progressions in a 2-coloring of Z n by m k (Z n ), it is easy to derive the following lemma from their work (see the proof of Lemma 4.1 and Theorem 1.5 in [57]).Lemma 5.2.Let k ≥ 3 be an integer and A be a partial coloring of Z m , where ℓ distinct elements in arithmetic progression are uncolored for some ℓ dividing m.If for all colorings of these ℓ elements there are no monochromatic k-APs in Z m using both elements colored in A and in the coloring of the ℓ elements, then for any integer t we have where m k (A) denotes the maximum fraction of monochromatic k-term arithmetic progressions for any coloring of the ℓ remaining elements in A. In particular, if m k (A) = 1/n and therefore m k (ℓ) = 1/ℓ, we get  [57], who also conjectured their construction for k = 4 to be tight.We believe that our constructions for k = 5, 6 provide tight bounds as well.
Lastly, we note that Saad and Wolf [75] also initiated a more systematic study of the question when the answer is given by random colorings, with recent results by Fox, Pham and Zhao [25], Kamčev, Liebenau and Morrison [46,47] as well as Versteegen [88,89].Rué and the third author also recently extended the flag algebra framework to additive problems in vector spaces over finite fields [74].[58] experimented with various local search strategies in order to further improve the upper bound on c 4 .Starting from our best Cayley graph on 768 vertices, his search iteratively switches the edge/non-edge status of certain pairs of vertices.The most successful attempt created a graph with value 10486266368/768 4 = 0.0301422734319, which is an improvement over Theorem 1.1 of the order 10 −6 .McKay's graph has 768 vertices, 148724 edges, 536 vertices of degree 387, 232 vertices of degree 388, and, unlike our construction, has a trivial automorphism group.
upper bound given by the Schläfli graph when ǫ = 10 −4 , implying the nondifferentiability of c 3,4 (x) at that point.The certificate for this proof is contained in the file c 34 epsilon.jsonand uses m = 6 as well as the same types as the proof of c 3,4 .For the lower bounds of c 5 and c 4,5 , we used m = 8 and the values obtained after rounding are reasonably close to those indicated by the SDP solver.The certificates for these proofs are contained in the files c 5.json and c 45.json.

Lu and Peng [ 57 ]
found a construction for k = 4 with n = 11 and ℓ = 1 giving lim inf m 4 (Z n ) ≤ 1/12.Using Tabu Search we found the following partial colorings of Z 44 Lemma 5.2 establish lim inf n→∞ m 5 (Z n ) ≤ 1/48 as well as lim inf n→∞ m 6 (Z n ) ≤ 1/228 with the former improving upon a bound found by Lu and Peng