This is a preprint of: “Non–equivalence between the Melnikov and the averaging methods for nonsmooth differential systems”, Zhifei Guo, Jaume Llibre, Qual. Theory Dyn. Syst., vol. 21, 114:1–13, 2022. DOI: [10.1007/s12346-022-00643-5] NON–EQUIVALENCE BETWEEN THE MELNIKOV AND THE AVERAGING METHODS FOR NONSMOOTH DIFFERENTIAL SYSTEMS ZHIFEI GUO1 AND JAUME LLIBRE2 Abstract. It is known that for smooth differential systems in the plane R2 the Melnikov and the averaging methods for studying the limit cycles produce the same results. Here we prove that this is not the case for nonsmooth differential systems in the plane. More precisely, we prove that the linear center ẋ = y, ẏ = −x, can pro- duce at most 5 limit cycles using the first order averaged function and also produce at most 5 limit cycles using the second order averaged function, when it is perturbed by a discontinuous piecewise differential systems of two pieces separated by the cubic curve y = x3 , and having in each piece a quadratic polynomial differential system. While using the Melnikov method up to order two these discontinuous piecewise differential systems already produce 7 limit cycles having in each piece a linear polynomial differential system. 1. Introduction and statement of the main results In the past few decades, nonsmooth differential systems with discontinuous right- hand sides have received a lot of attentions because they play a crucial role in differ- ent fields, such as control systems, economy, electrical circuits and mechanics (see the books [3, 29] and the survey [27]). The vector fields at each point of the phase space are unique for a smooth differential system. A nonsmooth differential system with discontinuous right-hand sides is multivalued in its discontinuous boundary. For a nonsmooth differential system we use the Filippov’s convention to define the vector fields at points of its discontinuous boundary (see [11]). In recent years many authors focus on the number of limit cycles or the cyclicity of the Hopf bifurcation for a nonsmooth differential system (see [8–10, 16, 23, 25]). The method of averaging and the Melnikov method are two classical and mature tools to study the dynamics of nonlinear differential systems (see [5, 12, 21, 28] for smooth differential systems and [13, 15, 20, 22, 30] for nonsmooth differential systems). It is well-known that planar smooth linear differential systems may have periodic orbits but no limit cycles. A planar polynomial differential system having a linear center is equivalent to the linear system (ẋ, ẏ)T = (y, −x)T . The linear differential system perturbed by discontinuous piecewise polynomials of two zones Σ± = R2 \Σ, 2010 Mathematics Subject Classification. 34C29, 34C25, 34A36. Key words and phrases. Limit cycles, the method of averaging, discontinuous piecewise differ- ential systems. 1 2 ZHIFEI GUO AND JAUME LLIBRE where Σ is the switching boundary, takes the form   i ± ! ẋ y + Σm i=1 ε fi (x, y) (1) = if (x, y) ∈ Σ± , ẏ −x + Σm i ± i=1 ε gi (x, y) where fi± and gi± (i = 1, . . . , m) are real polynomials. The perturbed system (1) can have limit cycles even if fi± and gi± (i = 1, . . . , m) are real polynomials of degree 1. Attentions were made to investigate limit cycles of system (1) using the method of averaging or the Melnikov method (see [1, 2, 6, 7, 19, 20, 24]). When the switching boundary Σ is the x-axis, i.e. Σ = {y = 0}, Buzzi, Pessoa and Torregrosa [6] used the Melnikov functions up to order 7 to prove that system (1) with linear perturbations has at most 3 limit cycles. For the same switching boundary Σ as [6], Llibre and Tang [24] applied the method of averaging up to order 5 to obtain that system (1) has at most 8 crossing limit cycles for quadratic perturbations and 13 crossing limit cycles for cubic perturbations, respectively. When the switching boundary Σ = Σα is nonregular, for example, Σ is the nonnegative x-axis and the ray x = y cot α with α ∈ (0, π) and y > 0, Cardin and Torregrosa [7] used the Melnikov functions up to order 6 to obtain that system (1) with linear perturbations has at most 5 limit cycles. Moreover they proved again using the Melnikov functions up to order 6 that the maximum number of crossing limit cycles is 2 for discontinuous piecewise linear Liénard system (1), where g± = 0 and f± are only functions of x. Later on Li and Llibre [19] used the averaging method up to any order, which was developed in [17], to provide an upper bound for the maximum number of limit cycles of system (1). Recently, Llibre, Mereu and Novaes [20] discussed crossing limit cycles of system (1) with quadratic perturbations for the nonlinear switching boundary Σ = {y = x2 }, and obtained that the maximum number of crossing limit cycles is 6 using the method of averaging up to order 2. Bastos, Buzzi, Llibre and Novaes [2] proved that the maximum number of limit cycles is 7 for system (1) with linear perturbations and Σ = {y = x3 } using the Melnikov functions up to order 2. This last result together with our results will prove that the Melnikov and the averaging methods do not produce the same result on the number of limit cycles when the differential systems are nonsmooth. Later on Andrade, Cespedes, Cruz and Novaes [1] con- sidered the case Σ = {y = xn } for system (1) with linear perturbations using the higher order Melnikov methods, and obtained that H(2) ≥ 4, H(3) ≥ 8, H(n) ≥ 7, for n ≥ 4 even, and H(n) ≥ 9, for n ≥ 5 odd, where H(n) denotes an upper bound of the maximum number of limit cycles for system (1) with linear perturbations and Σ = {y = xn }. In this paper stimulated by the references [2, 20], we use the method of averaging to investigate the number of crossing limit cycles for system (1) in the case that Σ = {y = x3 } but with perturbations of order two in a small parameter ε, i.e. the 3 following system  !   y + εA1 (x, y) + ε2 A2 (x, y)     ẋ  −x + εB1 (x, y) + ε2 B2 (x, y) if h(x, y) ≥ 0, (2) = ! ẏ   y + εC (x, y) + ε 2 C (x, y)   1 2  −x + εD (x, y) + ε2 D (x, y) if h(x, y) ≤ 0, 1 2 where h(x, y) := y − x3 and for i = 1, 2, 2 X 2 X Ai (x, y) := aijk xj y k , Bi (x, y) := bijk xj y k , j+k=0 j+k=0 2 X 2 X Ci (x, y) := cijk xj y k , Di (x, y) := dijk xj y k . j+k=0 j+k=0 Let Q1 be the set of the following conditions a110 = −b101 − c110 − d101 , a120 = c120 , (3) a111 = 3a100 − b120 − 3c100 + c111 + d120 , a102 = −b111 + c102 + d111 , b100 = d100 , b102 = d102 , and Q2 the set of the following conditions a100 = a120 = b100 = b102 = c100 = c110 = c120 = d100 = d101 = d102 = 0, (4) a102 = −b111 , a110 = −b101 , a111 = −b120 , c101 = −d110 , c111 = −d120 , c102 = −d111 , where Q2 is a subset of Q1 . Our main results are the following. Theorem 1. For |ε| sufficiently small system (2) using the averaging theory of first order has at most 5 crossing limit cycles when the condition Q1 does not hold. Moreover we can choose parameters aijk , bijk , cijk and dijk such that system (2) has exactly 0, 1, 2, 3, 4 or 5 limit cycles. Theorem 2. For |ε| sufficiently small system (2) using the averaging theory of sec- ond order has at most 5 crossing limit cycles when the condition Q2 holds. Moreover we can choose parameters aijk , bijk , cijk and dijk such that system (2) has exactly 0, 1, 2, 3, 4 or 5 limit cycles. Theorems 1 and 2 are proven in Section 3. In this paper we study the maximum number of crossing limit cycles for system (2) using the method of averaging up to order 2. We prove that system (2) produces at most 5 crossing limit cycles using the first order averaging theory. Here the second order averaging theory produces the same result as the first order averaging theory. However, Bastos, Buzzi, Llibre and Novaes [2] using the Melnikov functions up to order 2 proved that system (1) with linear perturbations and Σ = {y = x3 } has at most 7 limit cycles. Their results together with our results show that the Melnikov and the averaging methods do not produce the same result on the number of limit cycles when the differential systems are nonsmooth, while the number of limit cycles obtained by these two methods coincide for smooth systems (see [14]). 4 ZHIFEI GUO AND JAUME LLIBRE 2. Preliminaries In order to prove our results we state some necessary elements. Let A and D be open subsets of S1 × Rd and S1 = R/T be the circle with period T . We denote the characteristic function by χA (t, x) = 1 (resp. 0) if (t, x) ∈ A (resp. ̸∈ A). Given the following discontinuous piecewise differential system (5) ẋ = εF1 (t, x) + ε2 F2 (t, x) + ε3 R(t, x, ε), j j where Fi := ΣM M j=1 χS̄j (t, x)Fi (t, x) for i = 1, 2, R := Σj=1 χS̄j (t, x)Ri (t, x, ε), and j j Fi : S1 ×D → Rd , Ri : S1 ×D ×(−ε0 , ε0 ) → Rd with ε0 > 0, i = 1, 2, j = 1, . . . , M , are all continuous functions and are all T -periodic in the variable t. From [20] the averaged functions of orders 1 and 2 for system (5) are Z T Z T  ∂F1 (t, z) (6) f1 (z) = F1 (t, z)dt, f2 (z) = y1 (t, z) + F2 (t, z) dt, 0 0 ∂x Z t respectively, where y1 (t, z) = F1 (s, z)ds. 0 A point p ∈ Σ is called a generic point of discontinuity if there exists a neigh- borhood U of p such that Sp = U ∩ Σ is a C k embedded hypersurface. The crossing hypothesis (HC) given in [20] for system (5) is (HC) There exists an open bounded set C ⊂ D such that for each z ∈ C the curve {(t, z) : t ∈ S1 } reaches transversally the set Σ and only at generic points of discontinuity. In what follows we state the averaging theory for computing periodic orbits up to order one and two for discontinuous piecewise differential systems that we need for studying system (5), where the notation dB (fi , U, 0) (i = 1, 2) denote the Brouwer degree of the function fi in the neighborhood U of zero (see [4] or the Appendix A of [20]). Theorem 3 ([20, Theorem A]). In addition to the crossing hypothesis (HC) assume the following conditions. (Ha1) For i = 1, 2 and j = 1, 2, . . . , M , the continuous functions Fij and Rij are locally Lipschitz with respect to x, and T-periodic with respect to the time t. Furthermore, for j = 1, 2, . . . , M , the boundaries of Sj are piecewise C k embedded hypersurfaces with k ≥ 1. (Ha2) For a∗ ∈ C with f1 (a∗ ) = 0, there exists a neighborhood U ⊂ C of a∗ such that f1 (z) ̸= 0 for all z ∈ U \{a∗ } and dB (f1 , U, 0) ̸= 0. Then for |ε| = ̸ 0 sufficiently small, there exists a T -periodic solution x(t, ε) of system (5) such that x(0, ε) → a∗ as ε → 0. Theorem 4 ([20, Theorem B]). Suppose that f1 (z) ≡ 0. In addition to the crossing hypothesis (HC) assume the following conditions. (Hb1) For j = 1, 2, . . . , M , the functions F1j (t, ·) are of class C 1 for all t ∈ R; for j = 1, 2, . . . , M , the functions Dx F1j , F2j and R are locally Lipschitz with respect to x. Furthermore, for j = 1, 2, . . . , M , the boundaries of Sj are piecewise C k embedded hypersurfaces with k ≥ 1. 5 (Hb2) If (t, z) ∈ Σ then (0, y1 (t, z)) ∈ T(t,z) Σ. (Hb3) For a∗ ∈ C with f2 (a∗ ) = 0, there exists a neighborhood U ⊂ C of a∗ such that f2 (z) ̸= 0 for all z ∈ U \{a∗ } and dB (f2 , U, 0) ̸= 0. Then for |ε| = ̸ 0 sufficiently small, there exists a T -periodic solution x(t, ε) of system (5) such that x(0, ε) → a∗ as ε → 0. It is known that if a function f is C 1 then it is sufficient to check that the determinant of the Jacobian matrix D(f ) is non-zero in order to have that the Brouwer degree dB (f, U, 0) ̸= 0, for more details see [26]. Besides we also resort to the ECT-system that we shall use in the proof of our results. Let I denote a proper real interval of R. An ordered set of complex- valued functions F = (f0 , f1 , . . . , fn ) defined on I is called an Extended Chebyshev system or ET-system on I if and only if any nontrivial linear combination of fi (i = 0, 1, . . . , n) has at most n zeros counting multiplicities. Furthermore F becomes an Extended Complete Chebyshev system or an ECT-system on I if and only if for any 0 ≤ k ≤ n, (f0 , f1 , . . . , fk ) is an ET-system. We can see the monograph [18] for more details. The set F is an ECT-system on I if and only if W (f0 , f1 , . . . , fk )(t) ̸= 0 on I for 0 ≤ k ≤ n, where W (f0 , f1 , . . . , fk )(t) denotes the Wronskian of the functions (f0 , f1 , . . . , fk ) with respect to t, i.e. f0 (t) f1 (t) ··· fk (t) f0′ (t) f1′ (t) ··· fk′ (t) W (f0 , f1 , . . . , fk )(t) = .. .. .. .. . . . . . (k) (k) (k) f0 (t) f1 (t) · · · fk (t) 3. Proofs of Theorems 1 and 2 Proof of Theorem 1. In the polar coordinates x = r cos θ and x = r sin θ system (2) takes the form      ε A1 (x, y) cos θ + B1 (x, y) sin θ        +ε2 A2 (x, y) cos θ + B2 (x, y) sin θ ,         if h̃(θ, r) ≥ 0,    −1 + ε B (x, y) cos θ − A (x, y) sin θ /r !   1 1  ṙ  +ε2 B2 (x, y) cos θ − A2 (x, y) sin θ /r (7) =    θ̇   ε C1 (x, y) cos θ + D1 (x, y) sin θ           +ε2 C2 (x, y) cos θ + D2 (x, y) sin θ ,           if h̃(θ, r) ≤ 0,    −1 + ε D 1 (x, y) cos θ − C 1 (x, y) sin θ /r    +ε2 D2 (x, y) cos θ − C2 (x, y) sin θ /r where x = r cos θ, y = r sin θ and h̃(θ, r) := r sin θ − r3 cos3 θ. Taking θ as the new time variable and expanding it as a power series of ε, system (7) is equivalent to the following ( P (θ, r) := εP1 (θ, r) + ε2 P2 (θ, r) + O(ε3 ) if h̃(θ, r) ≥ 0, (8) ṙ = Q(θ, r) := εQ1 (θ, r) + ε2 Q2 (θ, r) + O(ε3 ) if h̃(θ, r) ≤ 0, 6 ZHIFEI GUO AND JAUME LLIBRE where now ṙ denotes the derivative with respect to the variable θ, Qi (θ, r) := Pi (θ, r)|aijk =cijk , bijk =dijk for i = 1, 2, j, k = 0, 1, 2, 0 ≤ j + k ≤ 2, and P1 (θ, r) := − a120 r2 cos3 θ − (r2 (a111 + b120 ) sin θ + a110 r) cos2 θ − (r2 (a102 + b111 ) sin2 θ + r(a101 + b110 ) sin θ + a100 ) cos θ − b102 r2 sin3 θ − b101 r sin2 θ − b100 sin θ, P2 (θ, r) := {−a120 b120 r4 cos6 θ − (r4 (a111 b120 − a2120 + a120 b111 + b2120 ) sin θ + r3 (a110 b120 + a120 b110 + a220 )) cos5 θ − (r4 (a102 b120 − 2a111 a120 + a111 b111 + a120 b102 − a120 b120 + 2b111 b120 ) sin2 θ + r3 (a101 b120 − 2a110 a120 + a110 b111 + a111 b110 + a120 b101 + 2b110 b120 + a211 + b220 ) sin θ + r2 (a100 b120 + a110 b110 + a120 b100 + a210 )) cos4 θ + (r4 (2a102 a120 − a102 b111 + a2111 − a111 b102 + a111 b120 + a120 b111 − 2b102 b120 − b2111 ) sin3 θ + r3 (2a101 a120 − a101 b111 − a102 b110 + 2a110 a111 − a110 b102 + a110 b120 − a111 b101 + a120 b110 − 2b101 b120 − 2b110 b111 − a202 − a220 − b211 ) sin2 θ + r2 (2a100 a120 − a100 b111 − a101 b110 + a2110 − a110 b101 − a111 b100 − 2b100 b120 − b2110 − a201 − b210 ) sin θ − r(a100 b110 + a110 b100 + a200 )) cos3 θ + (r4 (2a102 a111 − a102 b102 + a102 b120 + a111 b111 + a120 b102 − 2b102 b111 ) sin4 θ + r3 (2a101 a111 − a101 b102 + a101 b120 + 2a102 a110 − a102 b101 + a110 b111 + a111 b110 + a120 b101 − 2b101 b111 − 2b102 b110 − a211 − b202 − b220 ) sin3 θ + r2 (2a100 a111 − a100 b102 + a100 b120 + 2a101 a110 − a101 b101 − a102 b100 + a110 b110 + a120 b100 − 2b100 b111 − 2b101 b110 − a210 − b201 ) sin2 θ + r(2a100 a110 − a100 b101 − a101 b100 − 2b100 b110 − b200 ) sin θ − b100 a100 ) cos2 θ + (r4 (a2102 + a102 b111 + a111 b102 − b2102 ) sin5 θ + r3 (2a101 a102 + a101 b111 + a102 b110 + a110 b102 + a111 b101 − 2b101 b102 − a202 − b211 ) sin4 θ + r2 (2a100 a102 + a100 b111 + a2101 + a101 b110 + a110 b101 + a111 b100 − 2b100 b102 − b2101 − a201 − b210 ) sin3 θ + r(2a100 a101 + a100 b110 + a110 b100 − 2b100 b101 − a200 ) sin2 θ + (a100 − b100 )(a100 + b100 ) sin θ) cos θ + a102 b102 r4 sin6 θ + r3 (a101 b102 + a102 b101 − b202 ) sin5 θ + r2 (a100 b102 + a101 b101 + a102 b100 − b201 ) sin4 θ + r(a100 b101 + a101 b100 − b200 ) sin3 θ + a100 b100 sin2 θ}/r. We write  r if θ = π/2 or −r if θ = 3π/2, h̃(θ, r) = r sin θ − r3 cos3 θ = tan3 θ + tan θ − r2 r cos θ  ̸ π/2, 3π/2. if θ = 1 + tan2 θ 7 Solving h̃(θ, r) = 0 (i.e. tan3 θ + tan θ − r2 = 0) yields θ = θ1 (r) or θ = θ2 (r), where θ1 ∈ [0, π/2) and θ2 := θ1 + π, θ1 := arctan(ϖ(r)), s r s r (9) 3 r 2 r4 1 3 r2 r4 1 ϖ := + + − − + + . 2 4 27 2 4 27 Then the discontinuous set of system (8) is given by Σ e := {(θ1 (r), r) : r > 0} ∪ {(θ2 (r), r) : r > 0}. Moreover one can check that h̃(r, θ) > 0 (resp. < 0) if θ ∈ (θ1 , θ2 ) (resp. θ ∈ [0, θ1 ) ∪ (θ2 , 2π]). Computation shows that D ED E ∇h̃(θ1 (r), r), (1, P (θ1 (r), r)) ∇h̃(θ1 (r), r), (1, Q(θ1 (r), r)) r2 (3ϖr2 + ϖ2 + 1)2 = + O(ε) > 0, (ϖ2 + 1)3 D ED E ∇h̃(θ2 (r), r), (1, P (θ2 (r), r)) ∇h̃(θ2 (r), r), (1, Q(θ2 (r), r)) r2 (3ϖr2 + ϖ2 + 1)2 = + O(ε) > 0. (ϖ2 + 1)3 Hence the hypothesis (HC) below (6) holds for system (8). From (6) the averaged function of order 1 is Z 2π dṙ f1 (r) = dθ 0 dε ε=0 Z θ1 Z θ2 Z 2π = Q1 (θ, r)dθ + P1 (θ, r)dθ + Q1 (θ, r)dθ 0 θ1 θ2 = − {−4(2a120 + b111 + a102 − 2c120 − c102 − d111 )r2 ϖ3 + 12(b102 − d102 )r2 ϖ2 − 12(a120 − c120 )r2 ϖ + 4(a111 + b120 + 2b102 − c111 − d120 − 2d102 )r2 + 3π(a110 + b101 + c110 + d101 )(ϖ2 + 1)3/2 r − 12(a100 − c100 )ϖ3 + 12(b100 − d100 )ϖ2 − 12(a100 − c100 )ϖ + 12(b100 − d100 )}/{6(ϖ2 + 1)3/2 }, p where θi (i = 1, 2) are given in (9). Introducing new √ variable u = ϖ(r) = r − (1/2)r5 + (11/8)r9 + O(|r|13 ), equivalently r = u 1 + u4 = u + (1/2)u5 − (1/8)u9 + O(|u|13 ) we reduce f1 (r) to k1 + k2 u + k3 u2 + k4 u4 + k5 u5 + k6 u6 + k7 u8 f˜1 (u) := f1 (r(u)) = √ , 6 1 + u4 where k5 := k2 and k1 := −12(b100 − d100 ), k2 := −3π(c110 + d101 + a110 + b101 ), k3 := 4(3a100 − 3c100 − 2b102 − a111 − b120 + 2d102 + d120 + c111 ), k4 := 12(a120 − c120 ), k6 := −12(b102 − d102 ), k7 := 4(a102 + 2a120 + b111 − c102 − 2c120 − d111 ). Obviously the zeros of f˜1 (u) are determined by its numerator, which is a polynomial of degree at most 8. From Theorem 3 we know that every simple zero of f˜1 (u) on 8 ZHIFEI GUO AND JAUME LLIBRE the interval (0, +∞) corresponds to a crossing limit cycle of system (2). We take g1 := 1, g2 := u2 , g3 := u4 , g4 := u6 , g5 := u8 , g6 := u + u5 . One can compute the six Wronskians W1 (g1 ) := 1, W2 (g1 , g2 ) := 2u, W3 (g1 , g2 , g3 ) := 16u3 , W4 (g1 , g2 , g3 , g4 ) := 768u6 , W5 (g1 , g2 , g3 , g4 , g5 ) := 294912u10 , W6 (g1 , g2 , g3 , g4 , g5 , g6 ) := 4423680u6 (3u4 + 7). Note that none of the six Wronskians is zero for u > 0. It implies that the set of functions {g1 , g2 , g3 , g4 , g5 , g6 } is an ECT-system on the interval (0, +∞). Then f˜1 (u) has at most 5 simple zeros on the interval (0, +∞). Hence system (2) has at most 5 crossing limit cycles bifurcated from the center annulus. Furthermore one can compute that   0 0 0 0 −12 0 −3π 0 0 0 0 0    ∂(k1 , k2 , k3 , k4 , k6 , k7 )  0 0 −4 0 0 −8  det = det   0  ∂(a110 , a120 , a111 , a102 , b100 , b102 )  12 0 0 0 0    0 0 0 0 0 −12 0 8 0 4 0 0 = 82944π ̸= 0, which implies that k1 , k2 , k3 , k4 , k6 and k7 are linearly independent with respect to a110 , a120 , a111 , a102 , b100 and b102 . Thus we can choose parameters aijk , bijk , cijk and dijk (i = 1, 2 and 0 ≤ j + k ≤ 2) such that system (2) has exactly 0, 1, 2, 3, 4 or 5 crossing limit cycles. This completes the proof of Theorem 1. Proof of Theorem 2. We compute the averaged function of order 2. Solving f˜1 (u) ≡ 0, equivalently k1 = . . . = k7 = 0, yields the condition Q1 given in (3). Let Φ1 (r) := ⟨∇h(θ1 (r), r), (s, y1 (θ1 (r), r))⟩, Φ2 (r) := ⟨∇h(θ2 (r), r), (s, y1 (θ2 (r), r))⟩, where θi (i = 1, 2) are given in (9) and Z θ dṙ y1 (θ, r) := (ε,θ)=(0,φ) dφ 0 dε with ṙ in (8). Computations show that   Z θ1   Φ1 (r) = ∇h θ1 (r), r , s, Q1 (t, r)dt 0 3 2 (sin θ1 − 3r2 cos3 θ1 )Ψ1 (r) = s(3r sin θ1 cos θ1 + r cos θ1 ) + , 12   Z θ1 Z π+θ1   Φ2 (r) = ∇h π + θ1 , r , s, Q1 (t, r)dt + P1 (t, r)dt 0 1 θ 2 3  3 2 (sin θ 1 − 3r cos θ1 ) Ψ1 (r) + Ψ2 (r) = −s(3r sin θ1 cos θ1 + r cos θ1 ) − , 12 where Ψ1 (r) := − 12d100 − 3(c101 + d110 )r − 12c100 sin θ1 + 3(c101 + d110 )r cos(2θ1 ) − 3(c102 + 3c120 + d111 )r2 sin θ1 + (c102 − c120 + d111 )r2 sin(3θ1 ) − 6(c110 + d101 )rθ1 − 3(c110 − d101 )r sin(2θ1 ) + 12d100 cos θ1 9 + 3(c111 + 3d102 + d120 )r2 cos θ1 + (c111 − d102 + d120 )r2 cos(3θ1 ) − 4(c111 + 2d102 + d120 )r2 , Ψ2 (r) := − 6π(a110 + b101 )r + 24a100 sin θ1 + 6(a102 + 3a120 + b111 )r2 sin θ1 − 2(a102 − a120 + b111 )r2 sin(3θ1 ) − 6(a111 + 3b102 + b120 )r2 cos θ1 − 2(a111 − b102 + b120 )r2 cos(3θ1 ) − 24b100 cos θ1 . In order to ensure that Φi = 0 if and only if s = 0, we need to eliminate Ψi for i = 1, 2, equivalently that all coefficients of Ψi are equal to zero, from which we obtain a100 = a120 = b100 = b102 = c100 = c110 = c120 = d100 = d101 = d102 = 0, (10) a102 = −b111 , a110 = −b101 , a111 = −b120 , c101 = −d110 , c111 = −d120 , c102 = −d111 . Under (10) the assumption (Hb2) in Theorem 4 holds for system (8). Taking the intersection between Q1 and (10) yields the condition Q2 given in (4), where Q2 is actually (10) because (10) is a subset of Q1 . From (6) the averaged function of order 2 is Z 2π ( Z θ ! ) ∂ 2 ṙ ∂ ṙ 1 ∂ 2 ṙ f2 (r) = dφ + dθ 0 ∂r∂ε ε=0 0 ∂ε (ε,θ)=(0,φ) 2 ∂ε2 ε=0 Z θ1 ( Z ) ∂Q1 (θ, r) θ = Q1 (φ, r)dφ + Q2 (θ, r) dθ 0 ∂r 0 Z θ2 ( Z θ1 Z θ ! ) ∂P1 (θ, r) + Q1 (φ, r)dφ + P1 (φ, r)dφ + P2 (θ, r) dθ θ1 ∂r 0 θ1 Z 2π ( Z θ1 Z θ2 Z θ ! ∂Q1 (θ, r) + Q1 (φ, r)dφ + P1 (φ, r)dφ + Q1 (φ, r)dφ θ2 ∂r 0 θ1 θ2 ) + Q2 (θ, r) dθ. p √ Using the change u = ϖ(r) (i.e. r = u 1 + u4 ) we reduce f2 (r) to k̃1 + k̃2 u2 + k̃3 u4 + k̃4 u6 + k̃5 u8 + k̃6 (u + u5 ) f˜2 (u) := f2 (r(u)) = √ , 6 1 + u4 where k̃1 := 12(d200 − b200 ), k̃2 := 4(3a200 − a211 − b101 b111 − a101 b120 − b110 b120 − 2b202 − b220 − 3c200 + c211 + 2d202 + d220 ), k̃3 := 12(a220 − b101 b120 − c220 ), k̃4 := −12(b101 b111 + b202 − d202 ), k̃5 := 4(a202 + 2a220 + a101 b111 + b110 b111 − b101 b120 + b211 − c202 − 2c220 − d211 ), k̃2 := −3π(a210 + b201 + c210 + d201 ). Note that f˜2 (u) has the same form as f˜1 (u). Combining that {g1 , . . . , g6 } is an ECT-system, which is proven in the proof of Theorem 1, we obtain f˜2 (u) has at 10 ZHIFEI GUO AND JAUME LLIBRE most 5 simple zeros. Furthermore one can compute the determinant   0 0 0 0 12 0  0 −3π 0 0 0 0   ∂(k̃1 , k̃2 , k̃3 , k̃4 , k̃5 , k̃6 ) 12 0 0 0 0 8 det = det  0  ∂(a200 , a210 , a202 , a220 , d200 , d202 )  0 0 12 0 0 0 0 0 0 0 12 0 0 4 8 0 0 = 248832π ̸= 0, implying that k̃i (i = 1, . . . , 6) are linearly independent. Hence there exist param- eters aijk , bijk , cijk and dijk (i = 1, 2 and 0 ≤ j + k ≤ 2) such that system (2) has exactly 0, 1, 2, 3, 4 or 5 limit cycles. This completes the proof of Theorem 2. Acknowledgements The first author is partially supported by the grant CSC #202106240110 from the P. R. China. The second author is partially supported by the Agencia Estatal de Investigación grant PID2019-104658GB-I00, and the H2020 European Research Council grant MSCA-RISE-2017-777911. Data availability This paper has no data. References [1] K. d. S. Andrade, O. A. R. Cespedes, D. R. Cruz, D. D. Novaes, Higher order Melnikov analysis for planar piecewise linear vector fields with nonlinear switching curve, J. Differential Equations 287 (2021), 1–36. [2] J. R. Bastos, C. A. Buzzi, J. Llibre, D. D. Novaes, Melnikov analysis in nonsmooth differential systems with nonlinear switching manifold, J. Differential Equations 267 (2019), 3748–3767. [3] M. di Bernardo, C. J. Budd, A. R. Champneys, P. Kowalczyk, Piecewise-Smooth Dynamical Systems, Theory and Applications, Springer-Verlag, London, 2008. [4] F. Browder, Fixed point theory and nonlinear problems, Bull. Amer. Math. Soc. 9 (1983), 1–39. [5] A. Buică, L. Llibre, Averaging methods for finding periodic orbits via Brouwer degree. Bull. Sci. Math. 128 (2004), 7–22. [6] C. A. Buzzi, C. Pessoa, J. Torregrosa, Piecewise linear perturbations of a linear center, Discrete Contin. Dyn. Syst. 9 (2013), 3915–3936. [7] P. T. Cardin, J. Torregrosa, Limit cycles in planar piecewise linear differential systems with nonregular separation line, Physica D 337 (2016), 67–82. [8] X. Chen, J. Llibre, W. Zhang, Averaging approach to cyclicity of Hopf bifurcation in planar linear-quadratic polynomial discontinuous differential systems, Discrete Con- tin. Dyn. Syst. Ser. B 22 (2017), 3953–3965. [9] X. Chen, J. Llibre, W. Zhang, Cyclicity of (1, 3)-switching FF type equilibria, Dis- crete Contin. Dyn. Syst. Ser. B 24 (2019), 6541–6552. [10] X. Chen, V. G. Romanovski, W. Zhang, Degenerate Hopf bifurcations in a family of FF-type switching systems, J. Math. Anal. Appl. 432 (2015), 1058–1076. 11 [11] A. F. Filippov, Differential Equation with Discontinuous Right-Hand Sides, Kluwer Academic, Amsterdam, 1988. [12] J. Giné, M. Grau, J. Llibre, Averaging theory at any order for computing periodic orbits, Phys. D 250 (2013), 58–65. [13] M. Han, On the maximum number of periodic solutions of piecewise smooth periodic equations by average method, J. Appl. Anal. Comput. 7 (2017), 788–794. [14] M. Han, V. G. Romanovski, X. Zhang, Equivalence of the Melnikov function method and the averaging method, Qual. Theory Dyn. Syst. 15 (2016), 471–479. [15] M. Han, L. Sheng, Bifurcation of limit cycles in piecewise smooth systems via Mel- nikov function, J. Appl. Anal. Comput. 5 (2015), 809–815. [16] M. Han, W. Zhang, On Hopf bifurcation in non-smooth planar systems, J. Differen- tial Equations 248 (2010), 2399–2416. [17] J. Itikawa, J. Llibre, D. D. Novaes, A new result on averaging theory for a class of discontinuous planar differential systems with applications, Rev. Mat. Iberoam. 33 (2017), 1247–1265 [18] S. J. Karlin, W. J. Studden, Tchebycheff systems: With Applications in Analysis and Statistics, Pure Appl. Math., Interscience Publishers, New York, London, Sidney, 1966. [19] T. Li, J. Llibre, Limit cycles in piecewise polynomial systems allowing a non-regular switching boundary, Physica D 419 (2021), 132855. [20] J. Llibre, A. C. Mereu, D. D. Novaes, Averaging theory for discontinuous piecewise differential systems, J. Differential Equations 258 (2015), 4007–4032. [21] J. Llibre, D. D. Novaes, M. A. Teixeira, Higher order averaging theory for finding periodic solutions via Brouwer degree, Nonlinearity 27 (2014), 563–583. [22] J. Llibre, D. D. Novaes, M. A. Teixeira, On the birth of limit cycles for non-smooth dynamical systems, Bull. Sci. math. 139 (2015), 229–244. [23] J. Llibre, E. Ponce, Three nested limit cycles in discontinuous piecewise linear dif- ferential systems with two zones, Dynam. Contin. Discrete Impuls. Systems. Ser. B Appl. Algorithms 19 (2012), 325–335. [24] J. Llibre, Y. Tang, Limit cycles of discontinuous piecewise quadratic and cubic poly- nomial perturbations of a linear center, Discrete Contin. Dyn. Syst. Ser. B 24 (2019), 1769–1784. [25] J. Llibre, X. Zhang, Limit cycles for discontinuous planar piecewise linear differential systems separated by one straight line and having a center, J. Math. Anal. Appl. 467 (2018), 537–549. [26] N. G. Lloyd, Degree Theory, Cambridge Tracts in Mathematics, vol. 73, Cambridge University Press, Cambridge-New York-Melbourne, 1978. [27] O. Makarenkov, J. S. W. Lamb, Dynamics and bifurcations of nonsmooth systems: a survey, Phys. D 241 (2012), 1826–1844. [28] J. A. Sanders, F. Verhulst, J. Murdock, Averaging Method in Nonlinear Dynamical Systems, Appl. Math. Sci., vol. 59, Springer, New York, 2007. [29] D. J. W. Simpson, Bifurcations in Piecewise-Smooth Continuous Systems, World Scientific Series on Nonlinear Science A, vol 69, World Scientific, Singapore, 2010. [30] L. Wei, X. Zhang, Averaging theory of arbitrary order for piecewise smooth dif- ferential systems and its application, J. Dynam. Differential Equations 30 (2018), 55–79. 1 School of Mathematics, Sichuan University, Chengdu, Sichuan 610064, P. R. China Email address: mathgzf@gmail.com 12 ZHIFEI GUO AND JAUME LLIBRE 2 Departament de Matemàtiques, Universitat Autònoma de Barcelona, Bellaterra 08193, Barcelona, Catalonia, Spain Email address: jllibre@mat.uab.cat