aa r X i v : . [ m a t h . C O ] J u l Counting multiple graphs in generalized Tur´an problems
D´aniel GerbnerJuly 24, 2020
Abstract
We are given graphs H , . . . , H k and F . Consider an F -free graph G on n vertices.What is the largest sum of the number of copies of H i ? The case k = 1 has attracteda lot of attention. We also consider a colored variant, where the edges of G are coloredwith k colors. What is the largest sum of the number of copies of H i in color i ?Our motivation to study this colored variant is a recent result stating that theTur´an number of the r -uniform Berge- F hypergraphs is at most the quantity definedabove for k = 2, H = K r and H = K .In addition to studying these new questions, we obtain new results for generalizedTur´an problems and also for Berge hypergraphs. For graph H and G , let N ( H, G ) denote the number of subgraphs of G that are isomorphicto H . Let ex( n, H, F ) denote the largest N ( H, G ) among F -free graphs G on n vertices.In case H = K , the Tur´an number ex( n, F ) := ex( n, K , F ) is one of the most studiedparameters in extremal graph theory. The systematic study of the general version has beeninitiated by Alon and Shikhelman [1], after several sporadic results.In this paper we study a variant, where instead of counting copies of a subgraph H , wecount copies of several different subgraphs. Let us given graphs H , . . . , H k . Let N ( H , . . . , H k ; G ) = P ki =1 N ( H i , G ) and let ex( n, ( H , . . . , H k ) , F ) denote the largest value of N ( H , . . . , H k ; G )if G is an F -free graph on n vertices.The first thing to observe is that in case for every i the same graph G maximizes N ( H i , G )among n -vertex F -free graphs, then we are done, the sum is also maximized by that graph.This is the case for cliques. The Tur´an graph T r ( n ) is a complete r -partite graph where eachpart has size ⌊ n/r ⌋ or ⌈ n/r ⌉ . Tur´an [30] showed that ex( n, K k ) = | E ( T k − ( n )) | and Zykov[31] showed that ex( n, K r , K ℓ ) = N ( K r , T ℓ − ( n )). This implies ex( n, ( H , . . . , H k ) , K ℓ ) = N ( H , . . . , H k ; T ℓ − ( n )) in case each H i is a clique.1ne could also consider a weighted version, where we are also given α , . . . , α k and wewant to maximize P ki =1 α i N ( H i , G ). This was studied by Bollob´as [3], who showed that incase each H i is a clique, then a complete multipartite graph gives the maximum, but notnecessarily the Tur´an graph (note that α i < k = 2, butthe proof easily extends for larger k . Schelp and Thomason [28] extended it to inducedcopies of complete multipartite graphs H i , in case for every i either α i ≥
0, or H i is acomplete graph. They remark that we can assume that the clique number is bounded,i.e. some K r is forbidden. Note that we deal with not necessarily induced copies of H i .However, all complete ( ℓ − K ℓ -freegraph, thus we have that in case each H i is a complete ( ℓ − n, ( H , . . . , H k ) , K ℓ ) = N ( H , . . . , H k ; G ) for some complete ( ℓ − G .For any particular integer ℓ and graphs H i , a straightforward optimization would find theextremal graph, but we cannot handle it in this generality. Other results that fit into thissetting are when we count structures that correspond to multiple subgraphs, for examplewalks. Another example is the second Zagreb index of a graph P uv ∈ E ( G ) d ( u ) d ( v ) (see [5] fora survey), which is equal to N ( P , G ) + 3 N ( K , G ). We denote by P ℓ the path on ℓ verticesand by S ℓ the star on ℓ vertices.In what follows, we do not deal with weights (with the exception of one remark). Manyof our proofs immediately extend to a weighted version, but we feel the most importanteffect of adding weights would be the even more complicated notation. Similarly, we avoidforbidding multiple graphs at the same time, just for the sake of simplicity.Let us mention that there are results on forbidding a subgraph and counting multiplesubgraphs where all graphs belonging to an infinite family are counted, for example all thecycles, see [24] and the references in it.We also consider a colored variant. Our main motivation to study this variant is itsconnection to Berge hypergraphs, that we will describe later. Let G be a graph with edgescolored by 1 , . . . , k . Then we denote by G i the subgraph of G having the edges of color i .Let N c ol ( H , . . . , H k ; G ) = P ki =1 N ( H i , G i ). Let ex col ( n, ( H , . . . , H k ) , F ) denote the largest N c ol ( H , . . . , H k ; G ) if G is an F -free graph on n vertices. In case k = 2, we call the firstcolor blue and the second color red.We will refer to ex col ( n, ( H , . . . , H k ) , F ) as the colored variant, and ex( n, ( H , . . . , H k ) , F )as the uncolored variant. Let us start with some simple observations. Proposition 1.1.
For any i we have ex( n, H i , F ) ≤ ex col ( n, ( H , . . . , H k ) , F ) ≤ ex( n, ( H , . . . , H k ) , F ) ≤ k X i =1 ex( n, H i , F ) . Corollary 1.2.
We have ex( n, ( H , . . . , H k ) , F ) = Θ(max i ≤ k ex( n, H i , F )) and similarly ex col ( n, ( H , . . . , H k ) , F ) = Θ(max i ≤ k ex( n, H i , F )) . n, H i , F ) for every i , then we know the order of magnitude ofex( n, ( H , . . . , H k ) , F ) and ex col ( n, ( H , . . . , H k ) , F ). We conjecture that in the colored vari-ant, the same lower bound is asymptotically sharp. Conjecture 1.3. ex col ( n, ( H , . . . , H k ) , F ) = (1 + o (1)) max i ≤ k ex( n, H i , F ) . Observe that if the order of magnitude of ex( n, H j , F ) is larger than the order of mag-nitude of ex( n, H ℓ , F ) for any ℓ = j , then the asymptotic result immediately follows usingProposition 1.1, even in the uncolored variant. We will see an example in Section 4 showingthat the analogue of Conjecture 1.3 does not hold in the uncolored case.In light of the above observations, the interesting results are asymptotic ones in thefew cases they are non-trivial, and exact results. We say that the ( k + 1)-tuple of graphs( H , . . . , H k , F ) is color-resistant for an integer n if ex col ( n, ( H , . . . , H k ) , F ) = max i ≤ k ex( n, H i , F ),i.e. a monochromatic graph attains the maximum.Let i and G be such that N ( H i , G ) = max i ≤ k ex( n, H i , F ). Note that ex( n, ( H , . . . , H k ) , F )can be equal to max i ≤ k ex( n, H i , F ) only if G contains no copies of H j with j = i (we will seeseveral examples of this later). What happens more often is that G also gives the maximumfor our problem, i.e. ex( n, ( H , . . . , H k ) , F ) = N ( H , . . . , H k ; G ). In this case we say thatthe ( k + 1)-tuple of graphs ( H , . . . , H k , F ) is resistant .Our main motivation to study the colored variant is its application in the theory ofBerge hypergraphs. We say that a hypergraph H is a Berge copy of a graph F (in short: H is a Berge- F ) if V ( F ) ⊂ V ( H ) and there is a bijection f : E ( F ) → E ( H ) such that forany e ∈ E ( F ) we have e ⊂ f ( e ). This definition was introduced by Gerbner and Palmer[16], extending the well-established notion of Berge cycles and paths. The largest numberof hyperedges in an r -uniform Berge- F -free hypergraph is denoted by ex r ( n, Berge- F ), seeChapter 5.2.2 of [19] for a short survey on this function.Gerbner and Palmer [17] connected Berge hypergraphs and generalized Tur´an problemsby showing ex( n, K r , F ) ≤ ex r ( n, Berge- F ) ≤ ex( n, K r , F ) + ex( n, F ). This was improved byF¨uredi, Kostochka and Luo [11] and independently by Gerbner, Methuku and Palmer [14]to ex r ( n, Berge- F ) ≤ ex col ( n, ( K r , K ) , F ).Let us briefly state their results in our setting. F¨uredi, Kostochka and Luo [11] gave anupper bound on ex col ( n, ( K r , K ) , C ℓ ), where C ℓ denotes the set of cycles of length at least ℓ .This upper bound is sharp in case k − n − k ≥ r + 3. In [12] they determinedex col ( n, ( K r , K ) , C ℓ ) for every n if k ≥ r + 4. Gerbner, Methuku and Palmer [14] showed( K r , K , K m ) is color-resistant for any n , r and m . They also showed that for any graph F ,if F ′ is obtained by deleting a vertex of F , and f ( n ) is such that ex( n, K r − , F ′ ) ≤ f ( n ) n for every n , then ex col ( n, ( K r , K ) , F ) ≤ max { f ( n ) /r, } ex( n, F ). With this, they couldgave bounds on the Tur´an number of several different Berge hypergraphs; those results alsoextend to our setting. 3n particular the proofs in [14] imply ex col ( n, ( K r , K ) , T ) ≤ nk (cid:0) kr (cid:1) for every tree T on k + 1 vertices if k > r + 1 >
3, assuming the Erd˝os-S´os conjecture on the Tur´an num-ber of trees holds for every subtree of T (for example if T is a path, spider or star).Also ex col ( n, ( K , K ) , K ,t ) = (1 + o (1))( t − / n / / col ( n, ( K , K ) , C k ) ≤ (2 k − n, C k ) / t ≥ k ≥ uv of a graph G is a color-critical edge if deleting it from G decreasesits chromatic number. An m -chromatic graph F with a color-critical edge often behavessimilarly to K m in extremal problems. In particular, Simonovits [29] showed that for n largeenough, the Tur´an graph T m − ( n ) contains the most edges among F -free graphs, and it wasextended by Ma and Qiu [23], who showed that T m − ( n ) also contains the most copies of K r for r < m . We prove that there is also stability here. Lemma 1.4.
Let F be an ( m + 1) -chromatic graph with a color-critical edge and r < m + 1 .If G is an n -vertex F -free graph with chromatic number more than m , then ex( n, K r , F ) −N ( K r , G ) = Ω( n r − ) . For Berge hypergraphs, we obtain the following.
Proposition 1.5.
Let χ ( F ) > r . Then ex r ( n, Berge- F ) = ex( n, K r , F ) + o ( n ) . In Section 3, we deal with the colored variant. We show that each tuple of cliques iscolor-resistant for every n , and show some tuples that are not color-resistant.In Section 4 we deal with the uncolored variant. We show that the analogue of Conjecture1.3 does not hold, and also examine some particular instances of the problem, where we countsome graphs on five vertices in triangle-free graphs. Let us describe an approach to show that a tuple ( H , . . . , H k , F ) is resistant and/or colorresistant for n large enough. Assume without loss of generality that max i ≤ k ex( n, H i , F ) =ex( n, H , F ) = N ( H , G ), where G is F -free and has n vertices. Moreover, assumeex( n, H , F ) is way larger than ex( n, H i , F ) for every i >
1. Assume furthermore that there isa stability result concerning ex( n, H , F ), stating that if G is F -free on n vertices, and has atleast ex( n, H , F ) − x copies of H , then G is a subgraph of G . Now if x > P i =2 k ex( n, H i , F ),then the graph which maximizes N ( H , . . . , H k , G ′ ) has to be a subgraph of G , hence we4an assume it is G . Thus we solved the uncolored variant, and in the colored variant wereduced the problem to show that the best coloring of G is when every edge has color 1.Unfortunately, there are not many stability results for generalized Tur´an problems. Weare aware of only two such results.Gerbner and Palmer [18] showed that for n large enough, we have ex( n, P , C ) = N ( P , T ( n )). Moreover, if a C -free graph G has α edges that are contained in triangles,then N ( P , G ) ≤ N ( P T ( n )) − (1 + o (1)) αn /
12. This result shows that a C -free graphwhich has almost the largest possible number of P s must be close to T ( n ), but it measuresthe “distance” from T ( n ) in an unusual way. For us, this is a very useful way though, as itimplies the following. Proposition 2.1. ( P , K , C ) is resistant and color-resistant for every n large enough. We will also use a result of Bollob´as and Gy˝ori [4] that states ex( n, K , C ) = O ( n / ). Proof.
Let G be a C -free graph. If there is a triangle in G , then N ( K , G ) + N ( P , G ) ≤ ex( n, K , C ) + ex( n, P , C ) − (1 + o (1)) αn / < ex( n, P , C ) for n large enough.Let us return to the weighted variant for an observation. The above proof shows that ifwe add up the number of P ’s plus three times the number of triangles in G , we obtain thesame upper bound. Therefore, for n large enough, among n -vertex C -free graphs T ( n ) hasthe largest second Zagreb index. Another stability result is due to Ma and Qiu [23], whoshowed the following. Lemma 2.2 (Ma, Qiu [23]) . Let F be a graph with χ ( F ) = m + 1 > r ≥ . If G is an n -vertex F -free graph with N ( K r , G ) ≥ N ( K r , T m ( n )) − o ( n r ) , then G can be obtained from T m ( n ) by adding and deleting a set of o ( n ) edges. Corollary 2.3.
Let χ ( F ) = m + 1 > r , H = K r and for every i > , | V ( H i ) | ≤ p < r .Then ex col ( n, ( H , . . . , H k ) , F ) = ex( n, H , F ) + o ( n p ) .Proof. Let G be an F -free graph with N col ( H , . . . , H k ; G ) = ex col ( n, ( H , . . . , H k ) , F ). If N ( K r , T m ( n )) − N ( K r , G ) = Ω( n r ), then N col ( H , . . . , H k ; G ) < N ( K r , T m ( n )) (a contradic-tion), as there are O ( n r − ) copies of H , . . . , H k in G . Otherwise we can apply Lemma 2.2,thus we can obtain G by adding and deleting a set of o ( n ) edges from T χ ( F ) − ( n ).Let G ′ be the common part of G and T m ( n ) (thus it can be obtained from either G or T m ( n ) by deleting o ( n ) edges). If | E ( T m ) | − | E ( G ′ ) | = Ω( n ), then G ′ has N ( K r , T m ( n ) − Ω( n r ) copies of K r . Every other copy of H in G contains at least one of the o ( n ) edges addedto T χ ( F ) − ( n ), thus there are o ( n r ) of them. Again, there are O ( n r − ) copies of H , . . . , H k in G , thus N col ( H , . . . , H k ; G ) < N ( K r , T m ( n )), a contradiction.Therefore, there are o ( n ) edges in G ′ that are not of color 1, and there are o ( n ) edges of G not in G ′ . Therefore, there are o ( n ) edges of each other color, thus there are o ( n | V ( H i ) | ) = o ( n p ) copies of H i in G i , for every i >
1. There are at most ex( n, H , F ) copies of H in G ,thus we are done. 5sing the connection to Berge hypergraphs, described in Section 1, this implies Propo-sition 1.5. However, Lemma 2.2 is not strong enough to obtain a sharp result in our settingwith the approach described above it. Therefore, we prove Lemma 1.4 for graphs witha color-critical edge, that is stronger in a certain range. We restate Lemma 1.4 here forconvenience. Lemma.
Let F be an ( m + 1)-chromatic graph with a color-critical edge and r < m + 1.If G is an n -vertex F -free graph with chromatic number more than m , then ex( n, K r , F ) −N ( K r , G ) = Ω( n r − ).This follows easily from a result of Erd˝os and Simonovits [10]. They, extending a resultof Andr´asfai, Erd˝os and S´os [2], showed that if F has a color-critical edge and is ( m + 1)-chromatic, and G is an F -free graph on n vertices with chromatic number greater than m ,then G has a vertex of degree at most (1 − m − / ) n . We also use the following result of Alonand Shikhelman [1]: if χ ( H ) = t > s , then ex( n, K s , H ) = (1 + o (1)) (cid:0) t − s (cid:1) (cid:0) nt − (cid:1) s . Proof.
By the above, G has a vertex x of degree at most d = (1 − m − / ) n . Let uv be an edgeof F whose deletion decreases the chromatic number, and let F ′ be the graph we obtain from F by deleting v . Then χ ( F ′ ) = m . The neighborhood of x is obviously F ′ -free, thus containsat most (1 + o (1)) N ( K r − , T m − ( d )) copies of K r − by the result of Alon and Shikhelmanmentioned before the proof. Therefore, in G the number of copies of K r containing x is atmost (1 + o (1)) N ( K r − , T m − ( d )), while the number of copies of K r not containing x is atmost N ( K r , T m ( n − y be a vertex in a largest class of the Tur´an graph T m . Thenthe number of copies of K r containing y is (1 + o (1)) N ( K r − , T m − ( ⌊ (1 − m ) n ⌋ ) , while thenumber of copies of K r not containing y is N ( K r , T m ( n − n r − ), finishing the proof.Note that the bound Ω( n r − ) is sharp, at least for F = K m +1 , as shown by the followingexample. We take T m ( n ), and take vertices a, a ′ in part A and b in part B . We delete theedges between a and vertices of B , except we keep ab , and then add the edge aa ′ . It is easyto see that the resulting graph G is K m +1 -free and its chromatic number is m + 1. Comparedto the Tur´an graph, every K r that got deleted contains a , thus there are O ( n r − ) of them.In case r = 2, Simonovits [29] gave stronger bounds on the smallest possible value of ex ( n, K r , F ) − N ( K r , G ): he showed it is between n/k + c and n/k + c for some constants c and c . In case r = 2 and F = K k +1 , Brouwer [6] determined the above difference exactly.It would be of interest to obtain a stronger bound than Lemma 1.4. Still, it is enough for usto obtain the following. Proposition 2.4.
Let χ ( F ) = m + 1 > r and assume F has a color-critical edge, H = K r and for every i > , | V ( H i ) | < r − . If n is large enough, then ex col ( n, ( H , . . . , H k ) , F ) =ex( n, H , F ) = N ( K r , T m ( n )) and ex( n, ( H , . . . , H k ) , F ) = N ( H , . . . , H k ; T m ( n )) . roof. Let G be an F -free graph. If G has chromatic number more than χ ( F ) −
1, then byLemma 2.4 we have N ( K r , G ) ≤ N ( K r , T χ ( H ) − ( n ) − Ω( n r − ). As there are O ( n r − ) copiesof the other graphs H i , we are done.If G has chromatic number at most χ ( F ) −
1, then we can assume it is a complete( χ ( F ) − G is not the Tur´an graph, thenwe have N ( K r , G ) ≤ N ( K r , T χ ( H ) − ( n ) − Ω( n r − ). As there are O ( n r − ) copies of the othergraphs H i , we are done. Corollary 2.5.
Let χ ( F ) = m + 1 > r ≥ and F have a color-critical edge. If n is largeenough, then ex r ( n, Berge − F ) = |T rm ( n ) | . Note that the above corollary is already known, for every r . The r -uniform expansion F + r of a graph F is the specific r -uniform Berge copy that contains the most vertices, i.e.the r − F are distinct for different edges, and distinct fromthe vertices of F . Mubayi [25] proved ex r ( n, K + rm +1 ) = (1 + o (1)) |T rm ( n ) | , and Pikhurko [27]proved ex r ( n, K + rm +1 ) = |T rm ( n ) | for n large enough. According to the survey [26] of Mubayiand Verstra¨ete on expansions, Alon and Pikhurko observed that Pikhurko’s proof generalizesto the case F is ( m + 1)-chromatic with a color-critical edge, showing ex r ( n, F + r ) = |T rm ( n ) | for n large enough. It implies the same for Berge hypergraphs, which is Corollary 2.5.Another corollary of Theorem 2.4 is that any ( k + 1)-tuple of cliques where the orderof one of the cliques is larger that the order of any other clique by at least three, is color-resistant for large enough n . In the next section we show that the same holds for every n ,without the restriction on the order of the cliques. Theorem 3.1.
Any ( k + 1) -tuple of cliques is color-resistant for every n , i.e. if H , . . . , H k are cliques, then N ( H , . . . , H k ; K m ) is maximized by a monochromatic T m − ( n ) . Note that it depends on the parameters which color gives the maximum, but obviouslyif n is large enough, then it is the color i such that H i is the largest clique.The case k = 2, H = K r and H = K was proved in [14]. Gerbner, Nagy, Patk´os andVizer [15] considered a variant, where in a K m -free graph G we count the blue copies of K r ,add t times the red edges, and subtract t − G . They proved thatagain a monochromatic T m − ( n ) attains the maximum. Both of those proofs use Zykov’ssymmetrization method [31] in a straightforward but involved way. We follow the steps from[15] in the first half of the proof. Proof.
Let G be a K m -free graph with the largest value of x ( G ) := N ( H , . . . , H k ; G ), whereevery H i is a clique. Among such graphs, we pick one with the smallest number of colors.7or a vertex v , we let d i ( v, G ) denote the number of copies of H i in G containing v , and let d ∗ ( v ) := d ∗ ( v, G ) := P ki =1 d i ( v, G ).For two vertices u and v , we say that we symmetrize u to v if we delete all the edgesincident to u , and then for every edge vw , we add the edge uw of the same color. We willapply this to non-adjacent vertices. It is well-known and easy to see that no K m is createdthis way. It is also easy to see that if d ∗ ( u ) ≤ d ∗ ( v ), then x ( G ) does not decrease, while if d / ( u ) < d ∗ ( v ), then x ( G ) increases, which is a contradiction. Which means that when weapply such symmetrization steps, unconnected vertices always have the same d ∗ -value.We will change the graph with symmetrization steps to other graphs G ′ , but with anabuse of notation, we will use the same notation d ∗ ( v ) for d ∗ ( v, G ′ ). It should not causeconfusion, as we always deal with one graph at a time.We will apply several symmetrization steps in the next part of the proof. In the firstphase, we pick a vertex v . Recall that each vertex not connected to v has the same d ∗ -value.Then one by one we symmetrize to v every vertex that is not connected to it.After this, we obtain an independent set A of vertices such that each vertex w A isconnected to each vertex u ∈ A , by edges of the same color. Observe that this property doesnot change in further symmetrization steps.In the second phase we pick a vertex not in A and do the same what we did in the firstphase. This way we obtain another independent set, and so on. After at most m − G ′ with at most m − d ∗ -value. Obviously x ( G ′ ) = x ( G ). We can assume G ′ has m − x ( G ′ ).For a part A , let d ∗ ( A ) = | A | d ∗ ( a ) for some a ∈ A .Let us introduce a symmetrization operation on classes of G ′ . When we symmetrize A to B , for every third class C , we recolor the edges between A and C with the colors of theedges between B and C . We mimic the previous part of the proof now, with classes of G ′ playing the role of the vertices. However, any two classes are connected, so one of the colorswill play the role of the non-edges. We pick the color such that the smallest clique, say K p we count is of that color. If there are no edges of that color, we pick the second smallestclique and so on. Let blue be the first color in this ordering such that there exist blue edgesin G ′ and we always symmetrize two classes connected by blue edges. Then we obtain firsta set of classes each connected by blue edges, then another set, and so on, i.e. at the end ofthis process, being either connected by blue edges or not connected is an equivalence relationon the vertices. Let G ′′ be the graph obtained this way.Let A denote an equivalence class of this relation, then A induces a complete multipartitegraph itself. Then every vertex of A and every vertex of another class B are connected,with edges of the same color. Moreover, every vertex in A has the same d ∗ -value. Let d ∗ ( A ) = |A| d ∗ ( a ) for an a ∈ A . Then we pick an arbitrary other color which actuallyappears in G ′′ , say red, which corresponds to cliques K q (thus q > p ). We introduce a8ymmetrization operation on equivalence classes, exactly the same way as earlier. For twoclasses A and B connected by red edges, and every third class C , we recolor all the edgesfrom C to B to the color of the edges from C to A or the other way around.Again, at the end of this process, in the resulting graph G ′′′ , being unconnected orconnected by red or blue edges is an equivalence relation. This means that the blue p -cliquesare inside the equivalence classes of G ′′ , and several such equivalence classes are connectedby red edges, that is where we can find red q -cliques. Now we have three kind of classes,so we name them to help distinguish. We call the partite sets of G ′ a small pack , these areindependent sets in each of G ′ , G ′′ and G ′′′ . We call the equivalence classes of G ′′ mediumpacks , these induce monoblue complete multipartite graphs in G ′′ and G ′′′ , where each partiteset is a small pack. Finally, we call the equivalence classes of G ′′′ large packs . These are red-blue complete multipartite graphs, where each partite set is a small pack. Large packs consistof multiple medium packs, where two vertices from different medium packs are connected bya red edge. We remark that we could continue this procedure with other colors and obtaineven larger packs, but this will suffice for us.As there are red edges in G ′′′ , there is a medium pack that is incident to red edges. Ifthere are less than q − K q , thus without decreasing x ( G ). Thenwe repeat this to the other red edges. As deleting a color would contradict our assumptions,we can find a medium pack A such that at least q − A by rededges. Let F denote the family of these small packs.Let us recolor all the edges inside A to red. Then x ( G ) decreases by the number of blue p -cliques inside that medium pack, but increases by some red q -cliques. We need that thenumber of new red q -cliques is larger than the number of blue p -cliques inside A . But itis trivial, as for each blue p -clique inside A , we can find a new red q -clique by picking avertex from each of q − p small packs in F (and for distinct p -cliques, we obtain distinct q -cliques this way). As q − > q − p >
0, there are more than one ways to pick the smallpacks, finishing the proof (even without considering that small packs may have more thanone vertices).Let us continue with some examples for tuples that are not color-resistant. First we showan example for infinitely many n . Chase [7] showed that for the star S ℓ with ℓ vertices, wehave ex( n, K r , S ℓ ) = N ( K r , G ), where G consists of ⌊ n/ ( ℓ − ⌋ vertex disjoint copies of K ℓ − ,and a clique on the remaining vertices. Let n = 6 p + 2 and consider ex col ( n, ( K , K ) , S ).Then it is obvious that the best is taking p copies of blue K , but the remaining single edgeshould be red.Let us show an example where ex col ( n, ( H , H ) , F ) > max { ex( n, H , F ) , ex( n, H , F ) } holds for every n large enough. Let F be the , which consists of two triangles sharing avertex. Erd˝os, F¨uredi, Gould, and Gunderson [9] showed ex ( n, F ) = ⌊ n / ⌋ + 1, where the9onstruction is T ( n ) with an arbitrary edge added. Moreover, this is the only F -free graphwith that many edges. Gerbner and Palmer [18] showed ex( n, C , F ) = N ( C , T ( n )) = ⌊ n/ ⌋⌈ n/ ⌉ ( ⌊ n/ ⌋ − ⌈ n/ ⌉ − Proposition 3.2. If n is large enough, we have ex col ( n, ( C , K ) , F ) = ⌊ n/ ⌋⌈ n/ ⌉ ( ⌊ n/ ⌋ − ⌈ n/ ⌉ −
1) + 1 .Proof.
For the lower bound, one can take a blue T ( n ) and add an arbitrary edge in red.For the upper bound, we follow the proof of the bound on ex( n, C , F ) by Gerbner andPalmer [18]. If G is an F -free graph on n vertices, and it has ⌊ n / ⌋ + 1 edges, we aredone by the uniqueness of the extremal graph in the result of Erd˝os, F¨uredi, Gould, andGunderson [9]. If G has at most ⌊ n / ⌋ edges, Gerbner and Palmer showed that every edgeis in at most ⌊ ( n − / ⌋ copies of C . If we have x blue edges, then N ( C , K ; G ) ≤ x ⌊ ( n − / ⌋ / ⌊ n / ⌋ − x ≤ ⌊ n/ ⌋⌈ n/ ⌉ ( ⌊ n/ ⌋ − ⌈ n/ ⌉ − G that isextremal for ex( n, H, F ) and has some edges not contained in any copy of H . Then wecan take a blue G and recolor those edges to red. In the above examples, the two-coloredconstruction was larger by one than the monocolored one, but we could easily modify thefirst example to obtain a larger constant difference.Let S r denote the star on r vertices. We denote by F n the graph we obtain from S n by adding a matching of size ⌊ ( n − / ⌋ on the leaves of the star. Let F ∗ n be the blue-redgraph with the same set of edges, where the edges of the star are blue, and the edges ofthe matching are red. Gerbner [13] showed that if n is large enough, then for r ≥ ex ( n, S r , C ) = (cid:0) n − r − (cid:1) = N ( S r , S n ), while ex( n, S , C ) = N ( S , F n ). In case r ≥ F ∗ n shows that ex col ( n, ( S r , K ) , C ) ≥ max { ex( n, S r , C ) , ex( n, K , C ) } + ⌊ ( n − / ⌋ if n islarge enough. This shows the difference can be linear, but we can do better by taking redmatchings instead of red edges.Let M t denote the matching with t edges. It was shown in [13] that ex( n, M t , C ) =(1 + o (1))ex( n, C ) t /t ! = Θ( n t/ ). Let us describe the simple argument here, as we will useit below. In fact, any graph with f ( n ) = ω ( n ) edges contains (1 + o (1)) f ( n ) t /t ! copies of M t .The upper bound follows from the fact that we pick t edges, each at most f ( n ) ways, andwe count each copy of M t exactly t ! times. For the lower bound, we again pick the edgesone by one. Observe that each time we can pick at least f ( n ) − t − n = (1 − o (1)) f ( n )edges, as we only have to subtract those that are incident to a previously picked edge.Thus if t < r − / n is large enough, then max { ex( n, S r , C ) , ex( n, M t , C ) } ≥ ex( n, S r , C )+ (cid:0) ⌊ n/ ⌋ t (cid:1) . Therefore, F ∗ n shows ex col ( n, ( S r , M t ) , C ) ≥ max { ex( n, S r , C ) , ex( n, M t , C ) } + (cid:0) ⌊ ( n − / ⌋ t (cid:1) if 2 ≤ t < r − / n is large enough, hence the difference can be above anypolynomial.Let us examine this example in more detail. Observe that determining ex col ( n, ( S r , M t ) , C )completely for every r and t and large enough n would include the case r = 2, t = 1, which10s ex( n, C ). Despite significant effort by many researchers, this problems is still unsolved.However, in every case we can either determine ex col ( n, ( S r , M t ) , C ), or show that a monoredgraph gives the maximum. Theorem 3.3.
We have ex col ( n, ( S r , M t ) , C ) = N ( S , M ; F n ) if r = 3 and t = 1 , N c ol ( S r , M t ; F ∗ n ) if r ≥ , t < r − / and n is large enough , N c ol ( S r , M t ; F ∗ n ) if r = 4 , t = 2 and n is large enough , ex( n, M t , C ) for other values of t and r , if n is large enough . Proof.
Let G be an n -vertex blue-red C -free graph which contains the most blue S r plusred M t . Assume first that r = 3 and t = 1. In this case we use induction on n , the basecases n = 3 and n = 4 are trivial. Let us asume n ≥
5. If there is a red edge uv , we canrecolor it to blue, decreasing the number of red edges by one, and increasing the number ofblue S ’s by at least one, unless both u and v have no blue edge incident to them. Moreover,if there is a red cycle, we can recolor its edges, and again the number of blue S ’s increasesby at least the number of deleted red edges.Therefore, after executing this recoloring for every red edge and red cycle, each connectedcomponent is monochromatic in the resulting graph G ′ , and the red components are trees. Byreplacing a red component on m ≥ F ∗ m , we delete m − m − S ’s, a contradiction. If there are ℓ > F ∗ ℓ to obtain a contradiction. Finally, if there is a singlered edge, then N c ol ( S , M ; G ) ≤ col ( n − , ( S , M ) , C ) = 1 + (cid:0) n − (cid:1) + 2 ⌊ ( n − / ⌋ bythe induction hypothesis, which finishes the proof.Assume now that r ≥ t < r − /
3. Let ∆ be the largest blue degree in G , i.e.the largest d blue ( v ), where d blue ( v ) is the number of blue edges incident to v . We count theblue stars the following way. We pick two vertices u and v , (cid:0) n (cid:1) ways. They have at most onecommon neighbor w . We count the blue copies of S r containing u and v as leaves. Thereare at most (cid:0) d blue ( w ) − r − (cid:1) ≤ (cid:0) ∆ − r − (cid:1) such copies. If we count these for every pair of vertices, wecount every blue copy of S r exactly (cid:0) r − (cid:1) times. Therefore, there are at most (cid:0) n (cid:1)(cid:0) ∆ − r − (cid:1) / (cid:0) r − (cid:1) blue copies of S r , and O ( n t/ ) = o ( n r − ) red copies of M t in G . If ∆ ≤ n −
3, then the sumof these two quantities is less than (cid:0) n − r − (cid:1) , finishing the proof in this case.If ∆ = n −
2, then let x be a vertex of degree n − y be the only vertex not adjacentto x . As x and y have at most one common neighbor z , we know that y has degree at most1. Observe that z has degree at most three, and vertices different from x, y, z have degree atmost two. This shows that the number of blue S r ’s is at most (cid:0) n − r − (cid:1) + 1, where we have theplus 1 only if r = 4 and yz is a blue edge. Observe that we have at most ⌊ ( n − / ⌋ edgesbetween the neighbors of x , and those plus potentially yz are the only red edges. Therefore, N c ol ( S r , M t ; G ) ≤ (cid:0) n − r − (cid:1) + 1 + (cid:0) n/ t (cid:1) < (cid:0) n − r − (cid:1) + (cid:0) ⌊ ( n − / ⌋ t (cid:1) , finishing the proof in this case.11f ∆ = n − u has degree n −
1, then there can only be independent edges in itsneighborhood. Those edges cannot appear in any blue S r , thus we have at most (cid:0) n − r − (cid:1) blue S r ’s, and the additional matching can contain at most (cid:0) ⌊ ( n − / ⌋ t (cid:1) red M t ’s.Assume now r = 4 and t = 2. The same calculation as above shows that there are atmost (cid:0) n (cid:1) (∆ − / S . Let x be a vertex of degree ∆. Let a = n − ∆ −
1, and A be the set of a vertices not connected to and different from x . If a = 0, then we are done.Observe that every other vertex is connected to at most one neighbor of x , thus there are O ( n ) edges incident to x or its neighbors. This shows that | E ( G ) | ≤ (1 + o (1)) ( n − ∆) / ,thus there are at most | E ( G ) | / ≤ (1 + o (1))( n − ∆) / M . If a = Ω( n ), thenwe have N c ol ( S , M ; G ) ≤ (cid:0) n (cid:1) (∆ − / o (1))( n − ∆) / < (cid:0) n − (cid:1) / ≤ N c ol ( S , M ; F ∗ n ),a contradiction.Hence we can assume that a = o ( n ). Observe that every vertex y = x has degree at most a + 2. Indeed, y is connected to at most one neighbor of x . The a vertices in A are incidentto O ( a / ) edges, as each of them is connected to at most one neighbor of x , and there are O ( a / ) edges inside A because of the C -free property. There are O ( n + a / ) red edgesaltogether, thus there are O ( a / n + a ) = o ( an ) red copies of M containing a vertex from A . We claim that there are o ( an ) blue copies of S containing a vertex from A . Indeed, thenumber of copies totally inside A is O ( a ). Otherwise we have to pick one of the a edgesconnecting A to V ( G ) \ A , and then two more neighbors of one of the endpoints of that edge.Let us delete all the edges incident to A . By the above, we deleted o ( an ) red copies of M and blue copies of S . Then we connect each vertex of A to x by a blue edge, creatingΩ( an ) new blue copies of S . As the resulting graph is C -free, this is a contradiction.Assume now that t ≥ r − /
3. Observe that in this case ex( n, M t , C ) = (1 + o (1)) n t/ t !2 t and ex( n, S r , C ) = (1 + o (1)) n r − ( r − . In case t > r − /
3, the first has a larger order ofmagnitude. In case t = 2( r − / r >
4, they have the same order of magnitude, but theconstant factor is larger for the first one. Moreover, recall that G contains at most | E ( G ) | t copies of M t . If G has o ( n / ) red edges, then we are done, since it has o (ex( n, M t , C )) redcopies of M t , and the number of S r ’s is less than (1 + o (1)) n t/ t .We will show that G is monored. Assume indirectly that G contains a blue edge uv .First we show that there is a blue star of size Ω( n / ) and t is close to 2( r − /
3. Observethat uv is in at most (cid:0) d ( u ) − r − (cid:1) + (cid:0) d ( v ) − r − (cid:1) (blue) copies of S r . On the other hand, there areΘ( n / ) red edges in G , thus Θ( n / ) red edges in G are independent from uv , hence thereare Θ( n t − / ) red copies of M t − in G that extend to an M t with uv . Thus, recoloring uv to red increases N c ol ( S r , M t ; G ) in case (cid:0) d ( u ) − r − (cid:1) + (cid:0) d ( v ) − r − (cid:1) = o ( n t − / ), in particular if r − < t − / d ( u ) and d ( v ) are o ( n t − r − ). This shows that in fact every blueedge must be contained in a blue star S q with q = Ω( n t − r − ) = Ω( n r − r − ) = Ω( n / ).Now we will show that there is a star of size Θ( n ) and t = 2( r − /
3. Let u , . . . , u ℓ be the centers of blue stars with at least q vertices. We claim that ℓ = O ( n / ). Indeed, if12e go through those centers in an arbitrary order, the first star has at least q vertices, thesecond star contains at least q − q − qℓ − P ℓi =1 i , but at most n , which proves the claimed upper bound.Let q i be the order of the blue star with center u i , i.e. q i = d blue ( u i ) + 1. Withoutloss of generality, let q ≥ q i for every i , and let v , . . . , v q − be the vertices connected to u by a blue edge. Observe that v i and v j does not have any common neighbor besides u , and v i has at most one neighbor among the v j s, thus P q − i =1 d ( v i ) ≤ n + q −
2. The q − S q are contained altogether in at most (cid:0) q − r − (cid:1) + P q − i =1 (cid:0) d blue ( v i ) − r − (cid:1) bluecopies of S r . Given that P q − i =1 ( d blue ( v i ) − ≤ n and d blue ( v i ) ≤ q , it is easy to see that P q − i =1 (cid:0) d blue ( v i ) − r − (cid:1) ≤ nq − (cid:0) q − r − (cid:1) = O ( nq r − ) = o ( q r − ), where we use q = Ω( n / ).Let us now delete all the edges incident to any of u , v , . . . , v q − to obtain G ′ . By theabove, we deleted (1 + o (1)) (cid:0) q − r − (cid:1) blue copies of S r . On the other hand, we deleted at most n + q edges, thus O ( n t − +1 ) red copies of M t . Now we add a red C -free graph G ′′ withex( q , C ) = (1 + o (1)) q / / q vertices u , v , . . . , v q − . The resulting graph G ′′′ is obviously C -free, since it consists of two C -free components. Let us consider the redcopies of M t that are in G ′′′ but not in G . We can pick an edge from G ′′ and a red M t − from G ′ . There are Θ( q / n t − / ) ways to do this. Indeed, we have shown G has Θ( n / ) rededges, and then so does G ′ , as we deleted O ( n ) red edges. Observe that q / = Ω( n / ), thusthe number of deleted red copies of M t is o ( q / n t − / ). The number of deleted blue copiesof S r is (1 + o (1)) (cid:0) q − r − (cid:1) = O ( q / q t − / ). This shows that if q = o ( n ) or t > r − / M t then the number of deleted red copies of M t and bluecopies of S r , a contradiction.Let us now assume q = Θ( n ) and t = 2( r − / G . We do it by going through the stars with centers U i as i increases. For each star, any vertex is incident to at most one of its leaves, thus we delete O ( n ) edges each time, thus altogether O ( n / ) edges. This shows that we deleted o ( n t/ )red copies of M t . Let q ′ be the number of vertices deleted and q ′′ = 1 + P ℓi =1 ( q i − q ′ ≤ q ′′ ≤ q ′ + (cid:0) ℓ (cid:1) , since any two of the ℓ stars S q i share at most one leaf. Let us considerthe blue stars deleted. There are P ℓi =1 (cid:0) ( q i − r − (cid:1) ≤ (cid:0) q ′ − r − (cid:1) copies with center u i for some i . Forevery other blue star, its leaves are among the u i ’s, thus there are at most n (cid:0) ℓr − (cid:1) = o ( n t/ )such copies.This way we obtained 13 c ol ( S r , M t ; G ) ≤ (1 + o (1)) (cid:18) q ′′ − r − (cid:19) + N c ol ( S r , M t ; G ) = (1 + o (1)) (cid:18) q ′ − r − (cid:19) + N c ol ( S r , M t ; G )= (1 + o (1)) (cid:18) q ′ − r − (cid:19) + N ( M t , G ) ≤ (1 + o (1)) (cid:18) q ′ − r − (cid:19) + ex( n − q ′ , M t , C )= (1 + o (1)) (cid:18) q ′ − r − (cid:19) + (1 + o (1)) ( n − q ′ ) t/ t !2 t = (1 + o (1))( q ′ r − ( r − n − q ′ ) r − t !2 t ) . As q ′ = Θ( n ), this is asymptotically smaller than(1 + o (1))( q ′ r − t !2 t + ( n − q ′ ) r − t !2 t ) ≤ (1 + o (1)) n r − t !2 t = ex( n, M t , C ) , a contradiction finishing the proof.Let us remark that in case of two colors, there is a natural way to improve the triviallower bound ex( n, H i , F ) on ex col ( n, ( H , H ) , F ). We take an n -vertex F -free graph withex( n, H , F ) copies of H , and consider the unused edges, those that are not contained inany copy of H . We color those edges red, and the other edges blue (and we can do the samefor H ). In case of more colors, the same approach can also give an improvement, but it isnot obvious how to color the unused edges.All the examples above are of this type, thus one could think this lower bound might bealways sharp. However, we can modify the first example to show that this is not the case.Consider ex col (8 p +5 , ( K , K ) , S ). Then the extremal construction for both ex(8 p +5 , K , S )and ex(8 p + 5 , K , S ) consists of p copies of K and one copy of K , and there are no unusededges, thus the lower bound is given by a monochromatic (in fact, monoblue) graph. On theother hand, it is obvious that the K should be red, and the K ’s should be blue to maximizethe number of blue K ’s and red K ’s. First we show that an analogue of Conjecture 1.3 does not hold in the uncolored case. Moreprecisely, we show examples such that for none of the F -free graphs G with N ( H i , G ) =(1 + o (1))ex( n, H i , F ) for some i have N ( H , . . . , H k ; G ) = (1 + o (1))ex( n, ( H , . . . , H k ) , F ).Let us consider ex( n, ( K a,b , K s,t ) , K ). As we have mentioned, this is attained by a com-plete bipartite graph G due to the result of Schelp and Thomason, but not necessarily abalanced one. In fact, if a = b , s = 1 and t = 2 a −
1, then the complete bipartite graph G ′ with the most copies of K a,b is balanced, while the complete bipartite graph G ′′ with themost copies of K s,t is very unbalanced. It is not surprising that G must be between G ′ and14 ′′ . For ex( n, ( K , , K , ) , K ) a simple calculation shows that indeed, G is very far fromboth G ′ and G ′′ .One of the main conjectures (Erd˝os [8]) of generalized Tur´an problems was that thelargest number of pentagons among triangle-free graphs is in the balanced blow-up of thepentagon. It was proved in [20, 22]. Here we study what happens if we count another graphas well. We pick some other five-vertex graphs, so that there can be Θ( n ) copies of themin K -free graphs. Also, the extremal graph for many of them are very different from theblow-up of the pentagon.We will use a result of Gy˝ori, Pach and Simonovits [21]. They showed ex( n, P ℓ , K ) = N ( P ℓ , T ( n )). Let M be the five-vertex graph consisting of two independent edges and anindependent vertex, and M ′ be the graph consisting of a P and an independent edge. Proposition 4.1. ex( n, M, K ) = N ( M, T ( n )) and ex( n, M, K ) = N ( M, T ( n )) .Proof. When counting M , we pick an edge at most | E ( T ( n )) | ways, we pick another, inde-pendent edge at most | E ( T ( n − | ways and then a fifth vertex at most n − M ′ , we pick an edge at most | E ( T ( n )) | ways, and then an independent copy of P at most ex( n, P , K ) = N ( P , T ( n ))ways (using the result of Gy˝ori, Pach and Simonovits [21] mentioned above). Again, we haveequality everywhere in the Tur´an graph.Let C ′ be the graph obtained by joining a vertex to one of the vertices of a C . We willalso consider the path P . Observe first that the colored variant is trivial: every copy of C contains five copies of P and every copy of P is counted at most once. Therefore, recoloringthe edges of the color corresponding to the C increases the total number, hence ( P , C , K )is color-resistant. We show that this 3-tuple is also resistant. Proposition 4.2. ex( n, ( P , C ) , K ) = N ( P , C ; T ( n )) = N ( P , T ( n )) and ex( n, ( C ′ , C ) , K ) = N ( C ′ , C ; T ( n )) = N ( C ′ , T ( n )) .Proof. Observe first that each of P , C ′ and C is built such a way that we pick an M andextend it.In a triangle-free graph G , there is at most one way to build a C from M , at most 4ways to build a C ′ , and at most 4 ways to build a P .If a copy of M extends to a C in G , it means we also have 3 copies of P containing thatcopy of M . If a copy of M does not extend to a C , then it extends to a subgraph of K , and there are at most 4 copies of C ′ and at most 4 copies of P containing that M .On the other hand, we counted every copy of C ′ three times, every copy of P C T ( n ), for every M we find 4 copies of C ′ and count them 4 times, and also 4 copies of P and count every copy of P four times, thus N ( M, T ( n )) = N ( C ′ , T ( n )) = N ( P , T ( n )).15et x be the number of copies of M that extend to C in G , and y be the number ofother copies. Then x + y is the number of copies of M in G , thus x + y ≤ N ( M, T ( n )) usingProposition 4.1. Therefore, the number of copies of C and C ′ in G is at most x/ y ≤ x + y ≤ N ( M, T ( n )) = N ( C ′ , T ( n )). The number of copies of C and P in G is at most x/ x/ y ≤ x + y ≤ N ( M, T ( n )) = N ( P , T ( n )), finishing the proof.Let us continue with K , . Gy˝ori, Pach and Simonovits [21] showed ex( n, K , , K ) = N ( K , , T ( n )). We have already mentioned a result of Andr´asfai, Erd˝os and S´os [2], aspecial case of which states that a triangle-free graph that is not bipartite has a vertex ofdegree at most 2 n/ Proposition 4.3. ex( n, ( K , , C ) , K ) = N ( K , , C ; T ( n )) .Proof. We apply induction on n . The base cases n ≤ n ≥
6. Let G be a K -free graph. If G is bipartite, we are done. Otherwise G has a vertex v of degreeat most 2 n/
5. Let us delete v and let G ′ be the graph obtained this way. By induction G ′ contains at most N ( K , , T ( n − C or K , .Let x denote the number of copies of K , and C in G containing v . Let w be a vertexfrom the larger part of T ( n ) and y denote the number of copies of K , in T ( n ) that contain w . Claim 4.4. x ≤ y Proof.
We can count the copies of C and K , containing v the following way. We pick anedge incident to v (at most 2 n/ | E ( T ( n − | ways) and a fifth vertex ( n − K , or C , as any edge added to K , or C would create a triangle.Every K , where v is in the larger part is counted four times this way, and every K , where v is in the smaller part is counted six times, while every C is counted four times.Thus we have that4 x ≤ (cid:22) n (cid:23) ( n − | E ( T ( n − | ≤ n n − | E ( T ( n − | . (1)Let us consider now T ( n ) and w . Let y denote the number of those copies of K , where w is in the smaller part, and y = y − y . We can count the copies of K , just like in G . First,for y , we pick an incident edge ⌊ n/ ⌋ ways, an independent edge exactly | E ( T ( n − | waysand a fifth vertex ⌊ ( n − / ⌋ ways. Thus we have 6 y ≥ ⌊ n/ ⌋⌊ ( n − / ⌋| E ( T ( n − | ≥ ( n − n − n − ( n − | E ( T ( n − y ≥ ⌊ n ⌋⌈ ( n − / ⌉| E ( T ( n − | ≥ ( n − n − n − ( n − | E ( T ( n − y ≥ x ( n − n − n − and y ≥ x ( n − n − n − ,thus y + y ≥ x ( n − n − n − ≥ x if 24( n − ≤ n − n − n ≥ K , and C in G is at most x + N ( K , , T ( n − ≤ y + N ( K , , T ( n − N ( K , , T ( n )), finishing the proof.A similar proof deals with M and M ′ . Proposition 4.5.
We have ex( n, ( M, C ) , K ) = N ( M, C ; T ( n )) and ex( n, ( M ′ , C ) , K ) = N ( M ′ , C ; T ( n )) .Proof. Just as in the proof of Proposition 4.3, we use induction on n , and the base cases n ≤ G be an n -vertex triangle-free graph. If G is bipartite, we are done byProposition 4.1.Thus we can assume G has a vertex v of degree at most 2 n/
5. Let x denote the numberof copies of M where v is not the isolated vertex, plus the number of copies of C in G . Let x ′ denote the number of copies of M ′ plus the number of copies of C in G . Let w be avertex of the larger class and y be the number of copies of M containing an edge incident to w in T ( n ). Let y ′ denote the number of copies of M ′ containing w ′ in T ( n ). Claim 4.6.
We have x ≤ y and x ′ ≤ y ′ . Proof.
First we show a simple argument that works in case n is even, and afterwards weshow how to improve it for the missing case n is odd. We pick M such that v is not theisolated vertex at most n ( n − | E ( T ( n − | ways by picking an edge incident to v , thenan edge on the remaining n − C containing that M , and each C containing v is counted this way exactly four times. Thuswe have that the number of copies of C containing v is at most n ( n − | E ( T ( n − | / x ≤ n ( n − | E ( T ( n − | . On the other hand, the same calculation in the Tur´angraph yields y = ⌊ n ⌋ ( n − | E ( T ( n − | . This finishes the proof of the first statement if n is even.Similarly, we pick M ′ by picking an edge incident to v , an independent edge, a fifth vertex,and finally connect the fifth vertex to an endpoint of one of the two edges picked earlier.There are at most two ways to pick that last edge because of the triangle-free property,thus we pick M ′ at most n ( n − | E ( T ( n − | ways. There is at most one C containingthat M ′ , and we count every C five times. Thus we have that the number of copies of C containing v is at most n ( n − | E ( T ( n − | /
5, thus x ′ ≤ n ( n − | E ( T ( n − | . On theother hand, the same calculation in the Tur´an graph yields y ′ = 2 ⌊ n ⌋ ( n − | E ( T ( n − | .This finishes the proof of the second statement if n is even or n ≥ x . The improvement would work foreven n , but for simplicity assume n is odd. After we pick the first edge vv ′ when picking acopy of M or M ′ , let G ′ be the graph on the remaining vertices and assume first G ′ is notbipartite. Then a theorem of Brouwer [6] shows that | E ( G ′ ) | ≤ | E ( T (( n − − ( n − / x by n ( n − n − /
2, thusit becomes smaller than y . Similarly, the upper bound on x ′ becomes smaller than y ′ .17ssume now G ′ is bipartite with parts A and B , and let d be the smallest degree in G . Assume first d ≥ ( n + 2) /
3. If v is connected to a vertex a ∈ A , observe that all theother neighbors of a are in B , and then v cannot be connected to any of those at least d − v is also connected to a b ∈ B , then v is not connected to the at least d − b either. As those vertices are in A , it means the degree of v is at most n − − (2 d − < d , a contradiction. Thus v cannot be connected to vertices both in A and B . That means G is bipartite, a contradiction.Assume now that d < ( n + 2) /
3. That means we can replace 2 n/ ⌊ ( n + 1) / ⌋ inthe calculations when picking copies of M , M ′ and C . Then we obtain the bound x ≤ ⌊ n +13 ⌋ ( n − | E ( T ( n − | . We have ⌊ n +13 ⌋ ≤ ( n − / n ≥
11, and ⌊ n +13 ⌋ ≤ ( n − / n = 7 and n = 9. Thus we have x ≤ ⌊ n ⌋ ( n − | E ( T ( n − | = y .Similarly, we have x ′ ≤ n +13 ( n − | E ( T ( n − | ≤ ⌊ n ⌋ ( n − | E ( T ( n − | = y ′ if n ≥
5, finishing the proof.The number of copies of M and C in G is at most x + N ( M, T ( n − ≤ y + N ( M, T ( n − N ( M, T ( n )), and similarly the number of copies of M ′ and C in G is at most x + N ( M ′ , T ( n − ≤ y + N ( M ′ , T ( n − N ( M ′ , T ( n )), finishing the proof. Corollary 4.7.
Let k ≥ and T be a k -tuple consisting of graphs M , M ′ , C ′ , P , K , and C . Then ex( n, T , K ) = N ( T ; T ( n )) .Proof. We have proved the statement for k = 2. Taking any H of the graphs M , M ′ , C ′ , P together with C shows that a monochromatic T ( n ) contains the most copies of H amongtriangle-free n -vertex graphs. Therefore, the case k > k -tuple T (including C , if it is in T ) are maximized by T ( n ), and anyadditional graph in the tuple is also maximized by T ( n ). References [1] N. Alon and C. Shikhelman. Many T copies in H-free graphs.
Journal of CombinatorialTheory, Series B , , 146–172, 2016.[2] B. Andr´asfai, P. Erd˝os and V. T. S´os. On the connection between chromatic number,maximal clique and minimum degree of a graph, Discrete Math. , 205–218, 1974.[3] B. Bollob´as. On complete subgraphs of different orders. Mathematical Proceedings ofthe Cambridge Philosophical Society , (1), 19–24, 1976.[4] B. Bollob´as, E. Gy˝ori. Pentagons vs. triangles. Discrete Mathematics , (19), 4332–4336, 2008. 185] B. Borovicanin, K. C. Das, B. Furtula, I. Gutman. Bounds for Zagreb indices. MATCHCommun. Math. Comput. Chem , (1), 17–100, 2017.[6] A. Brouwer. Some lotto numbers from an extension of Tur´an’s theorem. Afdeling ZuivereWiskunde [Department of Pure Mathematics] , , 1981.[7] Z. Chase. A Proof of the Gan-Loh-Sudakov Conjecture, arXiv preprint ,arXiv:1911.08452[8] P. Erd˝os. Problems and results in graph theory and combinatorial analysis. Proc. BritishCombinatorial Conj. , 5th, 169–192, 1975.[9] P. Erd˝os, Z. F¨uredi, R. J. Gould, D. S. Gunderson. Extremal Graphs for IntersectingTriangles,
J. Combin. Theory Ser. B, (1), 89–100, 1995.[10] P. Erd˝os, M. Simonovits. On a valence problem in extremal graph theory. Discrete Math. , 323–334, 1973.[11] Z. F¨uredi, A. Kostochka, R. Luo. Avoiding long Berge cycles. Journal of CombinatorialTheory, Series B , n . arXiv preprint arXiv:1807.06119, 2018.[13] D. Gerbner. Generalized Tur´an problems for small graphs, arXiv preprint ,arXiv:2006.16150 2020.[14] D. Gerbner, A. Methuku, C. Palmer. General lemmas for Berge-Tur´an hypergraph prob-lems. European Journal of Combinatorics , , 103082, 2020.[15] D. Gerbner, D.T. Nagy, B. Patk´os, M. Vizer, t -wise Berge and t -heavy hypergraphs, SIAM Journal on Discrete Mathematics , to appear[16] D. Gerbner, C. Palmer. Extremal Results for Berge Hypergraphs.
SIAM Journal onDiscrete Mathematics , (4), 2314–2327, 2017.[17] D. Gerbner, C. Palmer. Counting copies of a fixed subgraph in F -free graphs. EuropeanJournal of Combinatorics , , 103001, 2019.[18] D. Gerbner, C. Palmer. Some exact results for generalized Tur´an problems, arXivpreprint arXiv:2006.03756, 2020.[19] D. Gerbner, B. Patk´os. Extremal Finite Set Theory, 1st Edition, CRC Press, 2018.1920] A. Grzesik, On the maximum number of five-cycles in a triangle-free graph. Journal ofCombinatorial Theory, Series B , , 1061–1066, 2012.[21] E. Gy˝ori, J. Pach, and M. Simonovits. On the maximal number of certain subgraphs in K r -free graphs. Graphs and Combinatorics , (1), 31–37, 1991.[22] H. Hatami, J. Hladk´y, D. Kr´al’, D. Norine, A. Razborov. On the number of pentagonsin triangle-free graphs. Journal of Combinatorial Theory, Series A , 722–732, 2012.[23] J. Ma, Y. Qiu. Some sharp results on the generalized Tur´an numbers.
European Journalof Combinatorics , , 103026, 2020.[24] N. Morrison, A. Roberts, and A. Scott. Maximising the number of cycles in graphs withforbidden subgraphs. arXiv preprint arXiv:1902.08133, 2019.[25] D. Mubayi. A hypergraph extension of Tur´an’s theorem. Journal of Combinatorial The-ory, Series B , , 122-134, 2006.[26] D. Mubayi, J. Verstra¨ete. A survey of Tur´an problems for expansions. Recent Trends inCombinatorics , 117–143, 2016.[27] O. Pikhurko. Exact computation of the hypergraph Tur´an function for expanded com-plete 2-graphs.
Journal of Combinatorial Theory, Series B , (2) 220–225, 2013.[28] Richard H. Schelp, Andrew Thomason. A Remark on the Number of Complete andEmpty Subgraphs. Comb. Probab. Comput. (2), 217–219, 1998.[29] M. Simonovits, A method for solving extremal problems in graph theory, stability prob-lems, in: Theory of Graphs, Proc. Colloq., Tihany, 1966, Academic Press, New York ,279–319, 1968.[30] P. Tur´an. Egy gr´afelm´eleti sz´els˝o´ert´ekfeladatr´ol. Mat. Fiz. Lapok , Matematicheskii sbornik ,66