Equal values of certain partition functions via Diophantine equations

Let $A\subset \N_{+}$ and by $P_{A}(n)$ denotes the number of partitions of an integer $n$ into parts from the set $A$. The aim of this paper is to prove several result concerning the existence of integer solutions of Diophantine equations of the form $P_{A}(x)=P_{B}(y)$, where $A, B$ are certain finite sets.


Introduction
Let N be the set of non-negative integers, N + the set of positive integers and for k ∈ N + we write N ≥k for the set of integers ≥ k.
Let A ⊂ N + be given and take n ∈ N. By an A-partition λ = (λ 1 , . . . , λ k ), of a non-negative integer n with parts in A, we mean representation of n in the form where λ i ∈ A. The representations of n differing only in order of the terms are counted as a one. We also put Part A (n) = {λ : λ is A-partition of n}, and consider the corresponding partition function P A (n) := # Part A (n).
It is well know that the ordinary generating function of the sequence (P A (n)) n∈N takes the form In particular, if A = N + , then P A (n), simply denoted as p(n), is the famous partition function introduced by L. Euler and extensively studied by S. Ramanujan. The function p(n) counts the number of partitions with parts in N + , i.e., unrestricted partitions of n. Many questions concerning arithmetic properties of p(n) is still unsolved. Probably, the most famous one, is the question whether the sequence {p(n) mod m} n∈N is equidistributed modulo m, i.e., whether, for any given m ∈ N ≥2 and each r ∈ {0, . . . , m − 1}, there is an equality lim sup N →+∞ #{n ≤ N : p(n) ≡ r (mod m)} N = 1 m .
For discussion on this topic see [1]. The literature concerning arithmetic properties of functions counting various partitions is enormous. One of the central problems in partition theory is to obtain partition identities [3]. More precisely, if W is a certain property which can be applied to the parts of a given A-partition λ of a positive integer n, then by P A (W, n) we denote the number of A-partitions of n which have the property W. Thus, by a partition identity we mean an identity of the form where A 1 , A 2 ⊂ N + and W 1 , W 2 are given properties. The basic identity of the kind is Euler's famous identity which gives the equality between the number of partitions into distinct parts and the number of partitions into odd parts. Equivalently P N+ (distinct parts, n) = P N+ (odd parts, n).
Euler's identity can be proved by a simple manipulation of infinite products. Much deeper partition identities are two (of many known) Rogers-Ramanujan type identities. These identities can be deduced from the equalities of the type: infinite product = infinite series, i.e., The first identity implies that the number of partitions of n such that the adjacent parts differ by at least 2 is the same as the number of partitions of n such that each part is congruent to either 1 or 4 modulo 5, i.e., P N+ (adjacent parts differ by at least 2, n) = P N+ (parts ≡ 1, 4 (mod 5), n).
The second one implies that the number of partitions of n such that the adjacent parts differ by at least 2 and such that the smallest part is at least 2 is the same as the number of partitions of n such that each part is congruent to either 2 or 3 modulo 5. Mentioned identities are only special cases of more general one which can be found in the literature. However, according to our best knowledge nothing is known about identities of the form where n, m are different positive integers. Of course, in the above, we are interested in non-trivial identities. More precisely, if the set of values of P Ai (W i , n) contains all positive integers for some i ∈ {1, 2} then the problem is trivial. For example, if A 1 = {2 j : j ∈ N} and the property W 1 says that at least two parts in A 1 -partition of n are equal, then, for s(n) := P A1 (W 1 , n) we clearly have (1 + x 2 n + x 2 n+1 ), and the sequence {s(n)} n∈N is a famous Stern sequence satisfying the recurrence relations s(0) = 1, s(2n) = s(n) + s(n − 1), s(2n + 1) = s(n).
One can easily prove that s(2 n ) = n + 1 and thus the sequence (s(n)) n∈N contains all positive integers. Thus the question concerning the existence of positive integer solutions of related equation is trivial.
Of great interests would be the proof of non-existence of A i , W i , i = 1, 2 such that the corresponding partition functions P Ai (W i , n), i = 1, 2, have exponential growth and equation (1) has infinitely many solutions in positive integers. Note that if P Ai (W i , n) has an exponential growth then the set A i is necessarily infinite.
A related question is to whether given partition function takes values in a given infinite set. Especially, in the set of values of a given polynomial. In other words we are interested in the solvability in non-negative integers of the equation is of positive degree and positive leading coefficient. Again we are interested in non-trivial situations only. Here if f is linear, then we enter in the realm of partition congruences. The Ramanujan congruences p(5n + 4) ≡ 0 (mod 5), p(7n + 5) ≡ 0 (mod 7), p(11n + 7) ≡ 0 (mod 11) and its various generalizations give some non-trivial examples when equation (2) has infinitely many solutions in positive integers. Indeed, each equation has infinitely many solutions in positive integers. In fact, one can prove that for each prime q = 3 the Diophantine equation p(n) = qm has infinitely many solutions in positive integers. Indeed, Nicolas, Ruzsa and Sárközy [13] proved this for q = 2, and Ono proved that such a statement is true for each q ≥ 5 [18]. In case of equation (2) more can be said provided we know some arithmetic properties of the partition function P A (W, n). For example, if A = {2 i : i ∈ N} then so called binary partition function b(n) := P A (n) counting the partitions with all parts being powers of 2, satisfies the recurrence relation then equation (2) has at least deg f solutions possibly coming from the integer solutions of the equation f (m) = 1.
Our discussion above shows that the problem of solvability of equation (1) or equation (2) is interesting, difficult and worth of further investigations. It is clear that our questions are on the intersection of discrete mathematics, combinatorics and Diophantine equations. This suggest to start investigations with the case of A finite. This is reasonable due to the fact that p A (n) is a quasi polynomial (see for example [14]). More precisely, if A = (a 1 , . . . , a k ) and L A := lcm(a 1 , . . . , a k ), then Thus, if A 1 , A 2 are finite, then solvability in positive integers of equation (1) or a more general equation (2), is equivalent with the solvability in non-negative integers, of at least one equation of the type respectively. Thus, we enter into realm of polynomial Diophantine equations with separable variables where great deal of methods are for our disposal.
In the rest of the paper, in case of the set A = {1, . . . , m} instead of writing P A (x) and Part A (n), we will simply write P m (x) and Part m (n), respectively. Let us describe the content of the paper in some details.
In Section 2 we prove that for each f ∈ Z[x] with positive degree and positive leading coefficient and A = {a 1 , a 2 } ⊂ N + with gcd(a 1 , a 2 ) = 1, the Diophantine equation P A (x) = f (y) has infinitely many solutions in positive integers (Theorem 2.1).
Section 3 is mainly devoted to the study of the equation P 3 (x) = P n (y) for n = 4, 5. In particular, we describe all positive integer solutions in both cases and present some related results (Theorem 3.1 and Theorem 3.2).
In Section 4 we study some equation involving P A (x), where A = {1, 2, a}, a ∈ N ≥3 . In particular, we obtain a general result concerning the existence of infinitely many positive integer solutions of the equation P A (x) = P 4 (y) (Theorem 4.3). We also obtain, under weak assumptions on a, b ∈ N ≥3 , a = b, that for A = {1, 2, a}, B = {1, 2, b}, the Diophantine equation P A (x) = P B (y) has infinitely many solutions in positive integers (Theorem 4.5).
In Section 5 we obtain several results concerning the square values of P A (x). In particular we describe the set of positive integer solutions of the equation y 2 = P n (x) for n = 3, 4, 5. We also discuss results of some computations. Finally, in the last section we collect some general questions and conjectures concerning various aspects of the Diophantine equations of the form P A (x) = P B (y) and report results of various computations.

The case of
In this short section we prove a general result concerning the existence of positive integer solutions of the Diophantine equation where A = {a 1 , a 2 }, a 1 < a 2 and f ∈ Z[y] is a non-constant polynomial with positive leading coefficient. More precisely, based on the formula obtained by Sertöz in [15] we easily prove the following. Proof. Without loss of generality we can assume that gcd(a 1 , a 2 ) = 1. Then, by Sertöz result [15], we know that the following formula holds where a i · a ′ i ≡ −n (mod a i+1 ) and 1 ≤ a ′ i (n) ≤ a i+1 for i = 1, 2 and if i = 2, then i + 1 is taken modulo 2. In particular, for each n ∈ N + P A (n) = n a 1 a 2 or P A (n) = n a 1 a 2 + 1.
Thus, let us take n = a 1 a 2 (f (m) − 1), with m ∈ N + chosen in such a way that f (m) > 1. We thus consider the congruence ) and due to co-primality condition and the bound for a ′ 1 , a ′ 2 , we get that a ′ i = a i+1 , i.e., we have that a ′ 1 = a 2 , a ′ 2 = a 1 . In consequence and our theorem is proved.
3. The equation P 3 (x) = P n (y) for n = 4, 5 In this section we are interesting in the characterization of positive integer solutions of the Diophantine equation for n = 4, 5.
Theorem 3.1. The Diophantine equation P 3 (x) = P 4 (y) has infinitely many solutions in integers.
In order to characterize all integers solutions of the Diophantine equation P 3 (x) = P 4 (y) we need to perform case by case analysis. More precisely, we consider all possible combinations of the equations (I) P i,6,3 (x) = P 2j+1,6,4 (y) or (II) P i,6,3 (x) = P 2j,12,4 (y), i.e., we deal with 54 equations. In each case we deal in the same way. Because the degree of P i,6,3 is 2, each equation of interests can be reduced to the equation of the type Y 2 = f (X) for some f ∈ Z[X] and the degree of f is 3. If f has no multiple roots, by classical Siegel result, we know that the curve defined by the equation Y 2 = f (X) has only finitely many integral points. On the other hand, if f has multiple roots then there is a chance that our equation has infinitely many integral solutions which can be parameterized via polynomials.
In the table below we give all integral solutions in these cases. Table. Values of (i, j) such that the corresponding equations of types (I), (II) have solutions in non-negative integers.
Having the form of solutions presented in the table above, we can easily back to our original Diophantine equation P 3 (X) = P 4 (Y ) and found that solutions take the form (X, Y ) = (6x + i, 6y + 2j) in the first type equation, and (X, Y ) = (6x + i, 12y + 2j + 1) in the second type equation.
In our next theorem we characterize the set of positive integer solutions of the Diophantine equation P 3 (x) = P 5 (y). Proof. Direct check reveals that P 5 (60n + i), i ∈ {0, . . . , 59} is a polynomial in variable n. Thus, one can perform the same analysis as in the case of the equation P 3 (x) = P 4 (y). However, here the situation is a bit more complicated because, after necessary simplifications, we need to work with the equations of the type Y 2 = f (X), where f is a polynomial of degree 4. We need to consider 6 · 60 = 360 equations in order to get the result. Here we may apply the Magma procedure IntegralQuarticPoints() based on the paper [19]. It worked well in all except the 8 cases, where the Magma function failed to determine the complete set of integral solutions. These 8 problematic equations are of the form (3,9), (3,12), (3,21), (3,24), (3,33), (3,36), (3,48), (3, 57)}.
The equations corresponding to (i, j) = (3, 48), (3,57) are of the following form respectively, where u = x + 1. In both cases we obtain that u is a square multiplied by a divisor of 18. Therefore we need to handle the equations where δ ∈ {±1, ±2, ±3, ±6, ±9, ±18}. One more time we use the MAGMA procedure IntegralPoints() to determine the integral points on these elliptic curves. We only need to consider points having first coordinate divisible by 60δ. It turns out that u = 0 is the only solution, that is (x, Y ) = (−1, 0).
In the remaining 6 cases, we observed that the discriminant of P 3 (6y + i) = P 5 (60x + j) with respect to y is equal to for suitable substitution of the form u = ax + b (depending on values of i, j). The expression for u are given below Therefore we only need to determine integral points on the curve We obtain that 3 divides u, so u = 3u 1 for some integer u 1 . We have that The factorization yields the following elliptic curves We determined the integral points on these curves and checked if X is divisible by 648δ, the only such solution corresponds to X = 0. Hence we do not obtain integral solution in case of these six curves.
In the light of the result one can ask for which sequences A of the form A = {1, 2, 3, a}, a ≥ 4, the Diophantine equation P 3 (x) = P A (y) has infinitely many solutions in positive integers. It is not difficult to find many values of a with this property. Indeed, for a fixed a the equation has the form that a quadratic polynomial is equal to a cubic polynomial, hence we may expect a genus 1 curve. However, we for certain values of a we may obtain infinitely many integral solutions. The strategy we follow is simple, we determine polynomials P A (6an + k) in n that are not square-free and then deal with the equation P 3 (6m + 3) = 3(m + 1) 2 = P A (6an + k). This works for a ∈ {4, 6, 12, 14, 20}. In these cases the equation P 3 (x) = P A (y) has a polynomial solution and hence infinitely many solutions in positive integers.
We close this section with the following Conjecture 3.3. There are infinitely many values of a ∈ N ≥4 such that for A = {1, 2, 3, a}, the Diophantine equation P 3 (x) = P A (y) has infinitely many solutions in positive integers.

, and related equations
In this section we obtain explicit expression for P A (n) in case of A = {1, 2, a}. As an application we deduce several results concerning Diophantine properties of P A (n). .
If a = 2c + 1 for some c ∈ N + then Proof. Let A = {1, 2, a} and recall that Thus, using the identity by comparison of coefficients of like powers on both sides of we get that P A (n) satisfies the following recurrence relation: Knowing that P A (n) satisfies recurrence relation of the presented form and using the (conjectural) form of the solution it is easy to perform the rest of the proof by induction. We omit the tiresome details.
There are many papers devoted to the explicit computation of the function P A (n) for given A = {a 1 , . . . , a k } under various conditions on a 1 , . . . , a k . Although the result above can also be deduced from known results (see for example [9,16]), the explicit form with exact values of coefficients is very useful in what follows.
Having the explicit form of the a} one can obtain certain results concerning polynomial values taken by the partition function P A (n), n ∈ N + . We start with the following simple (1) If a ≡ 0 (mod 2), then P A (2n) = P A (2n + 1) for each n ∈ N.
(2) Let us put a = 2c + 1, c ∈ N + . Because {2(2c + 1)n + i : n ∈ N, i ∈ {0, . . . , 4c + 1}} = N to get the solutions of P A (n) = P A (n + 1) it is enough to consider the solutions (in m ∈ N) of equations P A (2(2c + 1)m + 2i) = P A (2(2c + 1)m + 2i + 1) or P A (2(2c + 1)m + 2i + 1) = P A (2(2c + 1)m + 2i + 2). We consider the former equation first. If i < c then we deal with the equation The same analysis can be applied to the equation P A (2(2c + 1)m + 2i + 1) = P A (2(2c + 1)m + 2i + 2) and we easily get that it has no solutions in N. We omit the simple details. Thus, in order to show that the Diophantine equation P A (x) = P 4 (y) has infinitely many solutions it is enough to prove that for some i ∈ {0, . . . , 2a−1}, j ∈ {0, . . . , 11} the set U i,j is infinite. However, because deg P A (2am + i) has degree 2 and deg P 4 (12n + j) = 3, the set U i,j is infinite if and only if the discriminant (with respect to the variable m) of the polynomial is a square. Here, we treat i, j and n ∈ N as variables. Moreover, because P 4 (12n+j) is o degree three, then the discriminant is a polynomial of degree three in the variable n. Thus, the value of G i,j,a (n) is square for infinitely many values of n ∈ N if and only if G i,j,a , treated as a polynomial in the variable n, has double root. This, in turn, is equivalent with the vanishing of the discriminant of G i,j,a . Summing up we get the following implication U i,j,a is infinite =⇒ H i,j,a := Disc n (Disc m (F i,j,a (m, n))) = 0.
From our discussion it follows that we need to investigate the vanishing of H i,j . However, before we will go one, let us note that a priori U i,j,a can be finite and the condition H i,j,a = 0 can be still satisfied (in other words we can not expect to have equivalence between the conditions above). This is clear. Due to the form of the polynomial F i,j,a to get an element of U i,j,a some additional congruence conditions need to be satisfied (which are not seen in discriminant computations). Indeed, let us take a = 9, i = 0, j = 3, i.e., Then G 0,3,9 (n) = 108(n + 1)(2n + 1) 2 . Thus G 0,3,9 (n) is a square if and only if n = 3u 2 − 1. However, F 0,3,9 (m, 3u 2 − 1) = (3m− 18u 3 + 3u + 1)(3m+ 18u 3 − 3u + 1) and it is clear that our equation has no solutions. After this discussion let us back to the proof of the statement.
Thus, in order to make the above expression a square, we need to take n = 3su 2 −1. Then Because in the case a ≡ 1, 3 (mod 4) the reasoning goes in exactly the same way we present only the appropriate values of i, j and the corresponding solutions x, y.
If a ≡ 1 (mod 4), i.e., a = 4s + 1 then we take i = 2s − 1, j = 2 and u positive odd number and get To get the second part of our theorem we need to investigate the vanishing of Hi, j, 4s + 2. Because we have exact expression for P A (4(2s + 1)m + 2i) (which is equal to P A (4(2s + 1)m + 2i)) it is enough to consider H i,j,4s+2 for j = 0, . . . , 11 as a polynomial in two variables: s and i. Because we need to consider two cases i ∈ {0, . . . , 2s} and i ∈ {2s + 1, . . . , 4s − 1} we work with 24 polynomials H i,j,4s+2 . It is easy compute these polynomials. Each has the form where C(i, j) ∈ Z and Q j , R j are quadratic inhomogeneous polynomials. In each case the quadratic forms Q j , R j has no integer zeros. Because in each case the reasoning is the same we present only one typical example. So let us suppose that i ∈ {0, . . . , 2s} and take j = 0. Then H i,0,4s+2 = −27648(2s+1) 2 (4(i 2 +s 2 )−4i(2s−1)+3)(36(i 2 +s 2 )−36i(2s−1)−4s+25) and quick computation reveals that each factor is non-zero for s ∈ Z and i ∈ N. Performing the same analysis for the rest of polynomials we get the statement of our theorem.
The first part of the above result can be further generalized. In order to get the generalization we will need the following simple Proof. First we consider the case a is not a square.
In order to show that the equation P A (4cn) = y 2 has infinitely many integral solutions, we will follow the standard argument to parameterize (rational) solutions since we know that (n, y) = (0, 1) solves the equation. The lines through (0, 1) can be written as y = mn + 1. Therefore we get that 2cn 2 + (c + 2)n + 1 = (mn + 1) 2 , that is n = 0 or Here m = u/v is a rational parameter, so we have that n = (c + 2)v 2 − 2uv u 2 − 2cv 2 . For our assumption, a = 2c is not a square, then we consider the Pell-equation u 2 − 2cv 2 = 1 and denote the sequence of positive integer solutions by (u k , v k ). In this case it follows that n = (c + 2)v 2 k − 2u k v k and y = (c + 2)u k v k − 2u 2 k . Let us now consider the case with a = 2c + 1 odd. Applying the second formula in Theorem 4.1 with i = 0, we work with the Diophantine equation P A (2(2c + 1)n) = (2c + 1)n 2 + (c + 2)n + 1 = y 2 .
Again, in order to show that the equation P A (4cn) = y 2 has infinitely many integral solutions, we follow the standard argument. The pair (n, y) = (0, 1) solves the equation. The lines through (0, 1) can be written as y = mn + 1. Therefore, we get that (2c + 1)n 2 + (c + 2)n + 1 = (mn + 1) 2 , that is n = 0 or Here m = u/v is a rational parameter, so we have that For our assumption, a = 2c + 1 is not a square, then we consider the Pell-equation u 2 − (2c+ 1)v 2 = 1 and denote the sequence of positive integer solutions by (u k , v k ). In this case it follows that n = (c + 2)v 2 k − 2u k v k and y = (c + 2)u k v k − 2u 2 k .
Summing up: we proved that if a is not a square then the Diophantine equation y 2 = P A (x) has infinitely many solutions in positive integers.
It remains to deal with the case when a is a square (even or odd). We follow similar lines, so we only provide details in case of a = 4t 2 , that is when a is an even square. Again, using the first formula from Theorem 4.1 with c = 2t 2 , i = 2t 2 − 2 < c − 1 we get that P A (8t 2 n + 2t 2 − 2) = 4t 2 n 2 + 4t 2 n + t 2 = t 2 (2n + 1) 2 , and for each n ∈ N + the number P A (8t 2 n+ 2t 2 − 2) is a square and the Diophantine equation y 2 = P A (x) has infinitely many solutions in positive integers.
Suppose that a/2 = s is not a square. We have the solution (0, 0) of the equation P A (4sn) = P B (4tm) so we write n = km for some rational number k = u/v. Solving the equation for m provides that either m = 0 or Since s and t are even integers the numerator is divisible by 2 and we obtain the expression The integer s is not a square, hence we consider the sequence of positive solutions (u k , v k ) of the Pell-equation v 2 − su 2 = 1. For these solutions we have m = (s + 2)/2u k v k − (t + 2)/2v 2 k and n = (s + 2)/2u 2 k − (t + 2)/2u k v k .
In view of theorem above we formulate the following conjecture. Let us note that to prove the above conjecture it is enough to find a pair (i, j) of integers such that i ∈ {0, . . . , 2a − 1}, j ∈ {0, . . . , 2b − 1} and the Diophantine equation P A (2ax + i) = P B (2by + j) has infinitely many solutions in integers. Although for any fixed values of a, b it is easy to find suitable i, j we were unable to get the general result.

Remarks on the Diophantine equation y 2 = P A (x)
A difficult and still unsolved question is whether the number p(n) can be a perfect power. Let us recall that p(n) counts the number of all partitions of n, i.e., In other words, we do not know any example of n ≥ 2 such that y k = p(n) for some k ∈ N ≥2 . In fact Zhi-Wei Sun conjectured that the equation y k = p(n) has no solutions in positive integers n, y, k with k ≥ 2. Let us also note that Alekseyev checked that there are no solutions with n ≤ 10 8 [20].
A question arises whether some results concerning the equation y 2 = P k (x) can be proved for some values of k ∈ N + . We know that the Diophantine equation y 2 = P k (x) has infinitely many solutions in positive integers for k ≤ 4. Indeed, to get the result for k = 3 it is enough to back to the explicit form of P 3 (6n + i) presented in the proof of Theorem 3.1. It is easy to see that for i ∈ {0, 1, 4, 5} the Diophantine equation y 2 = P 3 (6n + i) has infinitely many solutions in positive integer. For example, if i = 4 we deal with the equation y 2 = (n + 1)(3n + 4). Thus, if (u k , v k ) is a solution of the Pell equation v 2 − 3u 2 = 1 then the pair (n, y) = (u 2 k − 1, u k v k ) solves our equation. If k = 4 then again we back to the explicit form of P 4 (6n + 2i + 1) for i = 0, 1, 2 and P 4 (12n + 2i) for i = 0, 1, . . . , 5. A quick inspection reveals that the equation y 2 = P 4 (6n + 2i + 1) has infinitely many solutions for i = 1, 2. For example, if i = 1 then it is enough to take n = 6u 2 − 2 and y = 3u(6u 2 − 1). Similarly, it is easy to see that equation y 2 = P 4 (12n + 2i) has infinitely many solutions for i = 3, 4.
The first non-trivial problem is characterization of the positive integer solutions of the Diophantine equation y 2 = P 5 (x). We prove the following Proof. We have 60 curves of the form y 2 = P 5 (60n + i), i ∈ {0, . . . , 59}. If i ∈ {5, 20, 25, 40} the corresponding quartic has no Q 5 -rational points, and thus has no rational points at all.
Similarly as in the proof of Theorem 3.1 and Theorem 3.2, we apply the procedure IntegralQuarticPoints() to determine all integral solutions in the remaining 56 cases. In particular, the solution (1, 1) comes from the equation y 2 = P 5 (60n + 1) with n = 0. The solution (2027, 77129) comes from the solution (n, y) = (33, 77129) of the equation y 2 = P 5 (60n + 47). The procedure works well, except in 6 special cases. Here we do not get any error message like in the special cases appearing in the proof of Theorem 3.2, but warnings about time-consuming final enumerations. The 6 problematic polynomials correspond to i ∈ {21, 24, 48, 51, 54, 57}. The equations (up to multiplication by 16) corresponding to i = 21, 24 give the following equations 5y 2 = u(36u 3 + 108u 2 + 34u + 12), u = 5(2n + 1), respectively. Hence we need to resolve the following elliptic equations where δ divides 60. We only get the trivial solution given by u = 0.
For i ∈ {48, 51, 54, 57} after the substitution u = 2(n + 1) we get the following quartic equations We obtain elliptic equations in a similar way as before, so we omit details. It turns out that we get only the trivial solution with u = 0 from these cases.
The case of the equation y 2 = P 6 (x) is far more difficult. To get the solutions we need to consider 60 genus 2 curves C i : y 2 = P 6 (60n + i), i = 0, . . . , 59.
Let J i = Jac(C i ) be the Jacobian of the curve C i and by r i denote the rank of J i . We checked that r i ≤ 5 for 0 ≤ i ≤ 59.  Table. Upper bounds for the Q-rank of the Jacobian J i of the curve C i : y 2 = P 6 (60x + i) for i = 0, . . . , 59. It is curious that the polynomial P 6 (60n + i) is reducible (in the ring Q[n]) for i ∈ {40, . . . , 59} and thus, instead of working with genus two curve we need to play with certain curves of the type y 2 = Q i (x), where Q i is a quartic polynomial.
If the rank of the Mordell-Weil group is less than the genus of the curve, that is 2 in these cases, then classical Chabauty's method [6] may be applied to determine all rational points on the hyperelliptic curves. If the rank is greater than or equal to 2, then there are two different approaches to compute the set of integral points on the curves (see [4,10]). The difficulty is that one needs a Mordell-Weil basis. Among the above curves there are some for which we were not able to obtain such bases, these are as follows C i with i ∈ {15, 16, 23, 24, 27, 28, 29, 31, 32, 33, 35, 36, 38, 39}.
The most interesting one may be the hyperelliptic curve given by y 2 = 12x 5 + 1125x 4 + 41960x 3 + 778050x 2 + 7171020x + 26276400, which, as computed with the help of Magma, is the minimal model of the curve C 27 : y 2 = P 6 (60n + 27). In this case the rank is 1, however we were unable to found a generator of the Mordell-Weil group.
We finish with the following In the table below we collect data concerning our search.
In case of #A = 6 there is a large number of sets such that P A (L A n + i) is a square of a polynomial (with rational coefficients) in n times a linear factor (note that this is only possibility to get infinitely many square values). However, in each case the values of a corresponding linear factor nor the value of P A (L A n + i) can be a square of an integer.
One can easily check that the factor (36n+13)(40n+13) is a square infinitely often.
The smallest values of n which makes this factor a square, are n = 0, 494, 712842, . . .. However, the factor (36n + 23)(40n + 27) takes square values for infinitely many values negative values of n and thus is not of interests for us.

Problems, questions and conjectures
Besides the conjectures stated in previous sections, we formulate now several question and conjectures which hopefully will stimulate further research. Question 6.1. Let k ∈ N ≥2 and f ∈ Z[x] be given. Does there exist an ascending sequence of sets A 2 = {a 1 , a 2 } ⊂ . . . ⊂ A k = {a 1 , . . . , a k } . . . ⊂ N + such that the Diophantine equation P A k (x) = f (y) has at least C k,f solutions in positive integers and C k,f → +∞ as k → +∞?
Let us observe that without the condition C k,f → +∞ the question is not difficult. Indeed, let us take A 2 = {a 1 , a 2 } ⊂ N + and suppose that gcd(a 1 , a 2 ) = 1. As we already proved in Theorem 2.1 the Diophantine equation P A2 (x) = f (y) has infinitely many solutions in positive integers. If C ∈ N is fixed let us take an increasing sequence {a 3 , a 4 , . . . , a k } of positive integers such that a 3 is grater then the smallest integer N such that there is at least C values of x for which there is an integer y satisfying P A2 (x) = f (y). Then, for A k = {a 1 , a 2 , a 3 , . . . , a k } the Diophantine equation P A k (x) = f (y) has at least C solutions in positive integers. Indeed, this is simple consequence of the recurrence relation satisfied by the sequence {P A k (n)} n∈N . Indeed, because P A k (n) = P A k−1 (n) for n < a k , then P A k (n) = P A2 (n) for n < min{a 3 , . . . , a k } = a 3 and hence the result.
Proof. Let us note that the sequence {P B (n)} n∈N satisfies the following recurrence relation where A = {1, 2, 3, 4}. We know the polynomial expressions for P A (12n + i), i ∈ {0, . . . , 11} and that P B (L b n + j), j ∈ {0, . . . , L b − 1}, where L b = LCM (1, 2, 3, 4, b), is a polynomial of degree 4 with rational coefficients. Using induction one can obtain the expression for the polynomials of interests. We omit tiresome details. Proof. Note that if a ≡ 1, 2, 5, 7, 11, 10 (mod 12), then a can be written in one of the following form: a = 6k + 1, a = 6k + 5, a = 12k + 2 a = 12k + 10. Thus, in each case, the value of b = 4a is exactly the value of b considered in Lemma 6.2. Following the idea of proof of Theorem 4.3 we present the values of i, j such that the polynomial P A (2am + i) − P B (3bn + j) is reducible and the coefficient in of the linear factor (in m) near m is equal to 1.
Because in each case we proceed in the same way we present only the values of a, i, b, j and the corresponding solution for m.
We proved that for many choices of sequences A, B, the corresponding Diophantine equation P A (x) = P B (y) has infinitely many solutions in positive integers. However, in each case under consideration we had min{#A, #B} ≤ 3. This observation lead us to the following. Let us explain what a trivial solution means. More precisely, if for example A = {1, pa 2 , ..., pa k } then if P A (pn) is a non-zero, then in each representation pa i x i = pn we need to have p|x 1 and thus we get a representation It is clear that this mapping can be reversed. Thus, by taking B = {1, a 2 , ..., a k } we have the boring identity P A (pn) = P B (n).
Thus, in regards to question above, we considered equations of the form P A (x) = P B (y), where A, B are sets having 5 elements from {1, 2, . . . , 10} and one of the elements is 1. We searched for reducible polynomials P A (x) − P B (y) having a linear or quadratic factor. We implemented a parallel algorithm and used SageMath on a machine having 16 cores. It took about 10 hours to determine the appropriate polynomials. There are 44982 such cases. Among these polynomials we looked for examples providing infinitely many integral solutions. To reduce the time of computation a timeout was set to be 60 seconds. There are 392 cases for which the 60 seconds were not sufficient to compute the result. There are 2338 quadratic equations that yield infinitely many integral solutions and 2100 linear equations that provide parametric solutions. However, even in the case of reducibility we sometimes get factors without positive integer solutions. We present several examples.
The equation f 1 (m, n) = 0 has no solution modulo 5. The equation f 2 (m, n) = 0 has infinitely many integral solutions. However, all are negative and are not of interest for us.
We obtain infinitely many integral solutions from the equation g 1 (m, n) = 0 (however, these are trivial solutions). The other two equations have no solutions modulo 5.
As a third example let A = {1, 2, 3, 4, 6}, B = {1, 2, 4, 5, 10}. It follows that P A (12m + 1) − P B (20n + 1) = 1/6h 1 (m, n)h 2 (m, n), where h 1 (m, n) = 6m 2 + 10n 2 + 9m + 12n + 5 h 2 (m, n) = 6m 2 − 10n 2 + 9m − 12n. For given A ∈ N + the function P A (n) has a dual nature: from one side it is a quasi-polynomial and hance an algebraic object. On the other side P A (n) is counting function and thus live in a realm of combinatorics. In this paper we mainly operated on the former side. Thus, it is natural to state the following general question. It is clear that the above problem can be stated in a grater generality. More precisely, we can ask whether there are some combinatorial conditions which guarantee that for not necessarily finite sets A 1 , A 2 , and corresponding properties W 1 , W 2 , the equation p A1 (W 1 , x) = p A2 (W 2 , y) has only finitely many solutions in positive integers.
As we mentioned above, the partition functions count combinatorial objects. Thus, equality between different partition functions at certain integer arguments is equivalent with the statement that certain finite sets have the same number of elements. This suggest the following Problem 6.6. Let A, B ⊂ N + and suppose that the Diophantine equation p A (x) = p B (y) has infinitely many solutions in integers. Moreover, let x = ϕ(n), y = ψ(n) be parametrization of one (of possibly many) infinite part of the solution set, i.e., p A (ϕ(n)) = p B (ψ(n)) for each n ∈ N + . Describe the bijection (in combinatorial or other way) between the sets Part(ϕ(n)) = Part(ψ(n)).
Motivated by our findings presented in Theorem 3.2 and related results we formulate the following Conjecture 6.7. Let m, n ∈ N + . If (m, n) = (3, 4) and 3 ≤ m < n, then the Diophantine equation P m (x) = P n (y) has only finitely many solutions in non-negative integers.
Remark 6.8. Let us note that from the recurrence relation satisfied by the sequence {P m (k)} k∈N , i.e., P m (k) = P m−1 (k), k < m, P m (k) = P m−1 (k) + P m (k − m), k ≥ m, we know that the equation P m (x) = P n (y) has trivial solutions x = y = i, i ≤ m. So, it is reasonable to consider the set C m,n := {(x, y) ∈ Z × Z : P m (x) = P n (y) ∧ y ≥ n}.