1 Introduction and statement of results

A partition of a positive integer n is a non-increasing sequence of positive integers \(\uplambda _1 \ge \uplambda _2 \ge \dots \ge \uplambda _{\ell } > 0\), called its parts, such that \(\uplambda _1 + \uplambda _2 + \cdots + \uplambda _{\ell }=n\). Let p(n) count the number of partitions of n. In 1918, Hardy and Ramanujan [8] gave the following asymptotic formula for p(n):

$$\begin{aligned} p(n) \sim \frac{1}{4\sqrt{3}n}e^{\pi \sqrt{\frac{2n}{3}}} \end{aligned}$$

as \(n\rightarrow \infty \).

Ramanujan [13, 14] also proved the following famous congruences for the partition function: for any \(l\in \mathbb {Z}_{\ge 0}\) we have

$$\begin{aligned} p(5l + 4)&\equiv 0 \pmod 5,\\ p(7l + 5)&\equiv 0 \pmod 7,\\ p(11l + 6)&\equiv 0 \pmod {11}. \end{aligned}$$

Atkin and Watson [1, 15] proved generalizations of Ramanujan’s congruences modulo any integer of the form \(5^a7^b11^c\), where \(a,b,c \in \mathbb {N}\). Ono [12] proved that there are infinitely many new partition congruences for any prime modulus \(Q\ge 5\).

Dyson [6] conjectured that Ramanujan’s congruences modulo 5 and 7 could be explained using a function he called the rank. The rank of a partition \(\uplambda \) is defined to be its largest part minus the number of its parts; namely,

$$\begin{aligned} \text {rank}(\uplambda ) := \uplambda _1 - \ell . \end{aligned}$$

Let N(rQn) be the number of partitions of n with rank congruent to r modulo Q. Dyson conjectured that:

  • For each \(r\pmod 5\),

    $$\begin{aligned} N(r,5;5l+4) = \frac{p(5l+4)}{5}. \end{aligned}$$
  • For each \(r\pmod 7\),

    $$\begin{aligned} N(r,7;7l+5) = \frac{p(7l+5)}{7}. \end{aligned}$$

In 1954, Atkin and Swinnerton-Dyer [3] proved this conjecture.

Dyson observed that the rank fails to explain Ramanujan’s congruence modulo 11. He instead conjectured the existence of another statistic which he called the crank which would explain all three congruences. In 1988, Andrews and Garvan [2] found such a crank. More precisely, let \(o(\uplambda )\) be the number of 1’s in \(\uplambda \) and \(\nu (\uplambda )\) be the number of parts of \(\uplambda \) larger than \(o(\uplambda )\). The crank of \(\uplambda \) is then defined to be

$$\begin{aligned}\text {crank}(\uplambda ) := {\left\{ \begin{array}{ll} \uplambda _1 &{} \text {if } o(\uplambda )=0, \\ \nu (\uplambda ) - o(\uplambda ) &{} \text {if } o(\uplambda )>0. \end{array}\right. } \end{aligned}$$

Remark 1.1

Garvan et al. [7] found different cranks which also explain all of Ramanujan’s congruences.

Let M(rQn) be the number of partitions of n with crank r modulo Q. Ramanujan’s congruences follow from the “exact” equidistribution of M(rQn) on the residue classes \(r\pmod Q\) for certain Q and n. Here, we show that M(rQn) becomes equidistributed on the residue classes \(r \pmod Q\) for odd Q as \(n\rightarrow \infty \). More precisely, Zapata Rolón [16] gave an asymptotic formula for M(rQn) with an error term which is \(O(n^\epsilon )\). Here we refine his analysis to give an effective bound on the error term with explicit constants. We then use this bound to prove the following effective equidistribution theorem.

Let \(\mu (n):=\sqrt{24n-1}\).

Theorem 1.2

Let \(0 \le r < Q\) with Q an odd integer. Then we have

$$\begin{aligned} \frac{M(r,Q;n)}{p(n)} = \frac{1}{Q} + R(r,Q;n), \end{aligned}$$

where when \(Q<11\) we have

$$\begin{aligned} \left| R(r,Q;n)\right| \le 10^5(40.93 Q + 6.292) e^{-\left( 1-\frac{1}{Q}\right) \frac{\pi \mu (n)}{6}}n^\frac{11}{8} \end{aligned}$$

and when \(Q\ge 11\) we have

$$\begin{aligned} \left| R(r,Q;n)\right| \le 10^5(40.93 Q + 6.292) e^{-\left( 1-\sqrt{1 +12(\frac{1}{Q^2}-\frac{1}{Q})}\right) \frac{\pi \mu (n)}{6}}n^\frac{11}{8}. \end{aligned}$$

It follows immediately that the cranks are asymptotically equidistributed modulo Q.

Corollary 1.3

Let \(0 \le r < Q\) with Q an odd integer. Then we have

$$\begin{aligned} \frac{M(r,Q;n)}{p(n)} ~\longrightarrow ~\frac{1}{Q} \end{aligned}$$

as \(n \rightarrow \infty \).

In the recent work [10], Masri proved a quantitative equidistribution theorem for partition ranks (mod 2) with a power-saving error term using spectral methods and subconvexity bounds.

Corollary 1.3 can be seen as analogous to Dirichlet’s theorem on the equidistribution of primes among the residue classes \(r \pmod Q\) with \((r,Q)=1\). Motivated by this, we will use Theorem 1.2 to prove an analog of Linnik’s theorem which gives an upper bound for the smallest prime in each residue class \(r \pmod Q\).

Theorem 1.4

Let Q be an odd integer and for \(Q\ge 11\) we define the constant

$$\begin{aligned} C_Q:=\frac{(1.93\times 10^{59})(40.93Q^2+6.292Q)^8}{\left( \pi -\pi \sqrt{1+12(\frac{1}{Q^2}-\frac{1}{Q})}\right) ^{24}}+1. \end{aligned}$$
(1)

Then, we have

$$\begin{aligned} M(r,Q;n) > 0 \end{aligned}$$

if \(Q<11\) and \(n\ge 263\), or if \(Q\ge 11\) and \(n\ge C_Q\).

We will also prove the following result (which includes the case that Q is even) using a different, combinatorial argument.

Theorem 1.5

For odd \(Q \ge 11\) we have

$$\begin{aligned} M(r,Q;n)>0 \end{aligned}$$

if and only if \(n\ge \frac{Q+1}{2}\). For even \(Q\ge 8\) we have

$$\begin{aligned} M(r,Q;n)>0 \end{aligned}$$

if and only if \(n\ge \frac{Q}{2}+2\).

In a related direction, Bessenrodt and Ono [4] proved strict log-subadditivity of the partition function. Dawsey and Masri [5] later proved strict log-subadditivity for the Andrews spt-function. We will use Theorem 1.2 to prove strict log-subadditivity of the crank counting function.

Theorem 1.6

Given any residue \(r\pmod Q\) where Q is odd, we have

$$\begin{aligned} M(r,Q;a+b) < M(r,Q;a)M(r,Q;b), \end{aligned}$$

if \(Q<11\) and \(a,b \ge 396\) or if \(Q\ge 11\) and \(a,b\ge C_Q\), where \(C_Q\) is defined in (1).

2 Effective Asymptotic Formula for M(rQn)

In [16, 17], Zapata Rolón gives an asymptotic formula for M(rQn). Here, we refine his analysis and give an asymptotic formula with an effective bound on the error term. We begin by stating a few necessary definitions.

Let

$$\begin{aligned} \omega _{h,k} := \exp (\pi is(h,k)), \end{aligned}$$

where the Dedekind sum s(hk) is defined by

$$\begin{aligned} s(h,k) := \sum _{u \pmod k} \left( \left( \frac{u}{k} \right) \right) \left( \left( \frac{hu}{k} \right) \right) . \end{aligned}$$

Here \(((\cdot ))\) is the sawtooth function defined by

$$\begin{aligned}((x)) := {\left\{ \begin{array}{ll} x - \lfloor x \rfloor - \frac{1}{2} &{} { if} x\in \mathbb {R}\backslash \mathbb {Z}, \\ 0 &{} { if} x\in \mathbb {Z}. \end{array}\right. } \end{aligned}$$

Let \(0\le h<k\) be relatively prime integers. Let \(0<r<Q\) be relatively prime integers where Q is odd. Let \(h'\) be a solution to the congruence \(hh'\equiv -1 \pmod {k}\) if k is odd and \(hh'\equiv -1\pmod {2k}\) if k is even. Let \(c_1:=\frac{c}{(c,k)}\) and \(k_1:=\frac{k}{(c,k)}\). Let l be the minimal positive solution to \(l\equiv ak_1\pmod {c_1}\). For \(m,n\in \mathbb {Z}\) we define:

$$\begin{aligned} {\widetilde{B}}_{a,c,k}(n,m) := (-1)^{ak+1}\sin \left( \frac{\pi a}{c}\right) \sum _{\begin{array}{c} h \pmod k \\ (h,k)=1 \end{array}} \frac{\omega _{h,k}}{\sin \left( \frac{\pi ah'}{c}\right) }e^{\frac{-\pi ia^2k_1h'}{c}}e^{\frac{2\pi i}{k}(nh + mh')}, \end{aligned}$$

where the sum runs over all primitive residue classes modulo k.

For the case \(c \not \mid k\) we define

$$\begin{aligned} D_{a,c,k}(m,n) := (-1)^{ak+l}\sin \left( \frac{\pi a}{c}\right) \sum _{\begin{array}{c} h \pmod k \\ (h,k)=1 \end{array}}\omega _{h,k}e^{\frac{2\pi i}{k}(nh + mh')}, \end{aligned}$$

where l is the solution to \(l \equiv ak_1\) (mod \(c_1\)).

To provide certain bounds, we define the following:

$$\begin{aligned}&\delta _{a,c,k,r}^i := {\left\{ \begin{array}{ll} -(\frac{1}{2} + r)\frac{l}{c_1} + \frac{1}{2}(\frac{l}{c_1})^2 + \frac{1}{24} &{} \text {if }i = +,\\ \frac{l}{2c_1} + \frac{1}{2}(\frac{l}{c_1})^2 - \frac{23}{24} - r(1 - \frac{l}{c_1}) &{} \text {if }i = -, \end{array}\right. }\\&\delta _0:=\frac{1}{2Q^2}-\frac{1}{2Q}+\frac{1}{24}<\frac{1}{24}, \end{aligned}$$

and

$$\begin{aligned} m_{a,c,k,r}^+&:= \frac{1}{2c_1^2}(-a^2k_1^2 + 2lak_1 - ak_1c_1 - l^2 + lc_1 - 2ark_1c_1 + 2lc_1r),\\ m_{a,c,k,r}^-&:= \frac{1}{2c_1^2}(-a^2k_1^2 + 2lak_1 - ak_1c_1 - l^2 + 2c_1^2r\\&\quad -2lrc_1 + 2ark_1c_1 + 2lc_1 + 2c_1^2 - ak_1c_1). \end{aligned}$$

Note that \(\delta ^\pm _{a,Q,k,r}\le \delta _0<\frac{1}{24}\).

Zapata Rolón obtains an asymptotic formula for M(rQn) by using the circle method. First, he defines the generating function

$$\begin{aligned} C(w,q):=\sum _{n=0}^\infty \sum _{m=-\infty }^\infty M(m,n)w^mq^n, \end{aligned}$$

where M(mn) is the number of partitions of n with crank m. In order to use the modular properties of this function, he plugs in a root of unity for w and studies the coefficients of q. Additionally, he defines

$$\begin{aligned} C(e^{2\pi i\frac{j}{k}},q):=\sum _{n=0}^\infty {\tilde{A}}\left( \frac{j}{k},n\right) q^n, \end{aligned}$$

and uses the circle method to find an asymptotic formula for \({\tilde{A}}\left( \frac{j}{k},n\right) \), and uses the identity

$$\begin{aligned} M(r,Q;n)=\frac{1}{Q}\sum _{j=0}^{Q-1}\zeta ^{-jr}{\tilde{A}}\left( \frac{j}{Q},n\right) \end{aligned}$$
(2)

to get an asymptotic formula for M(rQn). Note that \({\tilde{A}}(\frac{0}{Q},n)=p(n)\).

Moreover, Zapata Rolón gives the following asymptotic formula for \({\tilde{A}}\left( \frac{j}{Q},n\right) \):

$$\begin{aligned} {\tilde{A}}\left( \frac{j}{Q},n\right)&= \frac{4\sqrt{3i}}{\mu (n)}\sum _{\begin{array}{c} Q|k\\ k\le \sqrt{n} \end{array}}\frac{\tilde{B}_{j,Q,k}(-n,0)}{\sqrt{k}}\sinh \left( \frac{\pi \mu (n)}{6k}\right) \\&\quad +\frac{8\sqrt{3}\sin (\frac{\pi j}{Q})}{\mu (n)} \sum _{\begin{array}{c} k,s \\ Q\not \mid k \\ \delta ^i_{j,Q,k,s}>0 \\ i \in \{+,-\} \end{array}} \frac{D_{j,Q,k}(-n,m^{i}_{j,Q,k,s})}{\sqrt{k}}\\&\quad \times \sinh \left( \sqrt{24\delta ^i_{j,Q,k,s}}\frac{\pi \mu (n)}{6k}\right) +O(n^\epsilon ), \end{aligned}$$

which when plugged into equation (2) gives

$$\begin{aligned} M(r,Q;n)&= \frac{1}{Q}p(n)+\frac{1}{Q}\sum _{j=1}^{Q-1}\zeta ^{-rj}_{Q} \frac{4\sqrt{3i}}{\mu (n)} \sum _{\begin{array}{c} Q|k\\ k\le \sqrt{n} \end{array}}\frac{\tilde{B}_{j,Q,k}(-n,0)}{\sqrt{k}}\sinh \left( \frac{\pi \mu (n)}{6k}\right) \\&\quad +\frac{1}{Q}\sum _{j=1}^{Q-1}\zeta ^{-rj}_{Q}\frac{8\sqrt{3}\sin (\frac{\pi j}{Q})}{\mu (n)} \sum _{\begin{array}{c} k,s \\ Q\not \mid k \\ \delta ^i_{j,Q,k,s}>0 \\ i \in \{+,-\} \end{array}}\frac{D_{j,Q,k}(-n,m^{i}_{j,Q,k,s})}{\sqrt{k}}\\&\quad \times \sinh \left( \sqrt{24\delta ^i_{j,Q,k,s}}\frac{\pi \mu (n)}{6k}\right) +O(n^\epsilon ). \end{aligned}$$

Proof of Theorem 1.2

We first break the \(O(n^\epsilon )\) error term from the calculation of \({\tilde{A}}(\frac{j}{Q},n)\) into six pieces: \(S_{err},S_{1err},S_{2err},T_{err},\) and the contributions of error from certain integrals which we will call \(\Sigma _1I_{err}\) and \(\Sigma _2I_{err}\). Zapata Rolón provides bounds on each of those pieces, which we can then refine and sum up to get bounds on the error in the formula for \({\tilde{A}}(\frac{j}{Q},n)\). Then using equation (2) and the triangle inequality, we can get our desired bound on |R(rQn)|.

Fix odd integers j and Q. We will bound the error coming from \({\tilde{A}}(\frac{j}{Q},n)\). Zapata Rolón provides the following bounds:

$$\begin{aligned}&|S_{err}| \le \frac{2e^{2\pi + \frac{\pi }{24}}|\sin (\frac{\pi j}{Q})|(c_2 + 2(1 + |\cos (\frac{\pi }{Q})|)c_1(1 + c_2))n^{\frac{1}{4}}\left( 1 + \log \left( \frac{Q-1}{2}\right) \right) }{\pi (1 - \frac{\pi ^2}{24})Q},\\&|T_{err}| \le 16e^{2\pi }f(Q)n^{\frac{1}{4}}\left| \sin \left( \frac{\pi j}{Q}\right) \right| , \end{aligned}$$

where

$$\begin{aligned} f(Q) := \frac{1+c_2e^{\pi \delta _0}}{1-e^{\frac{-\pi }{Q}}} + e^{\pi \delta _0}c_1(1+c_2) + \frac{e^{\pi \delta _0}(c_2+1)c_3}{2}, \end{aligned}$$

and where the \(c_i\) are constants defined in [16]. We have the approximations \(c_1 \le 0.046\), \(c_2 \le 1.048\), and \(c_3 \le 0.001\). Also,

$$\begin{aligned}&|S_{1err}| \le \frac{8e^{2\pi + \frac{\pi }{12}}(1 + \log (\frac{Q-1}{2}))n^{\frac{1}{4}}}{\pi (1 - \frac{\pi ^2}{24})Q},\\&|S_{2err}| \le 32e^{2\pi }n^{\frac{1}{4}}\left| \sin \left( \frac{\pi j}{Q}\right) \right| \frac{e^{2\pi \delta _0}}{1 - e^{\frac{-2\pi }{Q}}},\\&|\Sigma _1I_{err}| \le \frac{4\left( \frac{4}{3}+2^\frac{5}{4}\right) \left| \sin \left( \frac{\pi j}{Q}\right) \right| \left( 1+\log \left( \frac{Q-1}{2}\right) \right) e^{2\pi +\frac{\pi }{12}}n^\frac{3}{8}}{\pi \left( 1-\frac{\pi ^2}{24}\right) Q},\\&|\Sigma _2I_{err}| \le 8\left( \frac{4}{3}+2^\frac{5}{4}\right) \left| \sin \left( \frac{\pi j}{Q}\right) \right| \frac{e^{2\pi \delta _0+2\pi }}{1-e^{-\frac{2\pi }{Q}}}. \end{aligned}$$

Now, we estimate some of the expressions in those bounds to simplify them:

  • \(\left| \sin \left( \frac{\pi j}{Q}\right) \right| \le 1,\)

  • \(\frac{(1 + \log (\frac{Q-1}{2}))}{\pi (1 - \frac{\pi ^2}{24})Q}\le 0.1902,\)

  • \(\left( \frac{4}{3}+2^\frac{5}{4}\right) \le 3.712,\)

  • \(\frac{1}{1-e^{-\frac{\pi }{Q}}}\le \pi Q,\)

  • \(\frac{1}{1-e^{-\frac{2\pi }{Q}}}\le 2\pi Q.\)

To prove these last two bounds, let \(g(x):=\frac{1}{1-e^{-\frac{b}{x}}},\) where \(b,x>0\). Then we have \(g'(x)=b\frac{g(x)^2}{x^2}e^{-\frac{b}{x}}\). Moreover, the function \(h(x):=bx\) satisfies \(h'(x)=b\), and in the case of \(b=\pi \) and \(b=2\pi \) we have \(h(1)>g(1)\) and \(h'(1)>g'(1)\) by a short calculation. This implies that \(h(Q)>g(Q)\) for all \(Q\ge 1\), as desired.

In addition, we simplify the bounds given in [16]:

  • \(|S_{err}| \le 330.9n^{\frac{1}{4}}\),

  • \(|T_{err}| \le (59071 Q +930.05)n^{\frac{1}{4}}\),

  • \(|S_{1err}| \le 1059n^{\frac{1}{4}}\),

  • \(|S_{2err}| \le 22306n^{\frac{1}{4}}\),

  • \(|\Sigma _1I_{err}| \le 1965n^\frac{3}{8}\),

  • \(|\Sigma _2I_{err}| \le 113883 Q\).

Summing these all up gives the total contribution of the \(O(n^\epsilon )\) error term to \({\tilde{A}}(\frac{j}{Q},n)\). We then use equation (2) to get the contribution of the error term to M(rQn). However, after applying the triangle inequality these two bounds will be the same except for a factor of \({(Q-1)}/{Q}\), which we will round up to 1 for simplicity. So, the bound for the \(O(n^\epsilon )\) error term of M(rQn) is

$$\begin{aligned} (172954 Q + 26591) n^\frac{3}{8}. \end{aligned}$$

Now, we will bound the main terms from the formula for M(rQn) by using the following bounds from [16]:

  • \({\widetilde{B}}_{j,Q,k}(-n,0) \le \frac{2k\left( 1 +\log \frac{Q-1}{2} \right) }{\pi \left( 1 -\frac{\pi ^2}{24}\right) }\le 0.3804kQ,\)

  • \(D_{j,Q,k}(-n,m^{i}_{j,Q,k,s})\le k,\)

  • \(\sum \limits _{\begin{array}{c} Q|k\\ k\le \sqrt{n} \end{array}}k^{\frac{1}{2}} \le \frac{2}{3Q}n^{\frac{3}{4}},\)

  • \(\sinh \left( \sqrt{24\delta _{j,Q,k,s}^j}\frac{\pi \mu (n)}{6k}\right) \le \frac{1}{2}e^{\sqrt{24\delta _0}\frac{\pi \mu (n)}{6k}}.\)

First, we have the following estimate.

$$\begin{aligned} \sum \limits _{\begin{array}{c} Q\mid k\\ k\le \sqrt{n} \end{array}}k^{\frac{1}{2}}\le \int _{0}^{\sqrt{n}}x^{\frac{1}{2}}dx =\frac{2}{3}n^{\frac{3}{4}}. \end{aligned}$$

Hence, we obtain

$$\begin{aligned}&\left| \frac{1}{Q}\sum _{j=1}^{Q-1}\zeta ^{-rj}_{Q} \frac{4\sqrt{3i}}{\mu (n)}\sum _{\begin{array}{c} Q|k\\ k\le \sqrt{n} \end{array}}\frac{\tilde{B}_{j,Q,k}(-n,0)}{\sqrt{k}}\sinh \left( \frac{\pi \mu (n)}{6k}\right) \right| \\&\quad \le \frac{4\sqrt{3}}{\mu (n)}\sinh \left( \frac{\pi \mu (n)}{6Q}\right) \\&\quad \sum _{\begin{array}{c} Q|k\\ k\le \sqrt{n} \end{array}}0.3804k^{\frac{1}{2}} Q\\&\quad \le 1.757\frac{1}{\mu (n)}\frac{1}{2}e^{\frac{\pi \mu (n)}{6Q}}n^\frac{3}{4}\\&\quad \le 0.8785e^{\frac{\pi \mu (n)}{6Q}}n^\frac{1}{4}. \end{aligned}$$

Next, by the same argument in [16, p. 35], it follows that for fixed k we have

$$\begin{aligned} \sum _{\begin{array}{c} k,s \\ Q\not \mid k \\ \delta ^i_{j,Q,k,s}>0 \\ i \in \{+,-\} \end{array}}1\le \frac{Q+18}{24}. \end{aligned}$$

Similarly, we bound the other main term:

$$\begin{aligned}&\left| \frac{1}{Q}\sum _{j=1}^{Q-1}\zeta ^{-rj}_{Q}\frac{8\sqrt{3}\sin (\frac{\pi j}{Q})}{\mu (n)} \sum _{\begin{array}{c} k,s \\ Q\not \mid k \\ \delta ^i_{j,Q,k,s}>0 \\ i \in \{+,-\} \end{array}}\frac{D_{j,Q,k}(-n,m^{i}_{j,Q,k,s})}{\sqrt{k}}\sinh \left( \sqrt{24\delta ^i_{j,Q,k,s}}\frac{\pi \mu (n)}{6k}\right) \right| \\&\quad \le \frac{8\sqrt{3}}{\mu (n)} \sinh \left( \sqrt{24\delta _0}\frac{\pi \mu (n)}{6}\right) \sum _{\begin{array}{c} k,s \\ Q\not \mid k \\ \delta ^i_{j,Q,k,s}>0 \\ i \in \{+,-\} \end{array}}{k}^{\frac{1}{2}}\\&\quad \le \frac{8\sqrt{3}}{\mu (n)} \frac{1}{2}e^{\sqrt{24\delta _0}\frac{\pi \mu (n)}{6}}\frac{Q+18}{24}\cdot \frac{2}{3}n^\frac{3}{4}\\&\quad \le (0.1924Q+3.464)e^{\sqrt{24\delta _0}\frac{\pi \mu (n)}{6}}n^\frac{1}{4}. \end{aligned}$$

From [9] we get the following lower bound for p(n):

$$\begin{aligned} p(n) > \frac{\sqrt{3}}{12n}\left( 1-\frac{1}{\sqrt{n}}\right) e^{\frac{\pi \mu (n)}{6}}. \end{aligned}$$

We also note that for \(n\ge 2\),

$$\begin{aligned} \frac{1}{1 - \frac{1}{\sqrt{n}}} \le \frac{1}{1 - \frac{1}{\sqrt{2}}} \le 3.415. \end{aligned}$$

Finally, combining all the estimates, we get

$$\begin{aligned}&|R(r,Q;n)| =\left| \frac{M(r,Q;n)}{p(n)} -\frac{1}{Q}\right| \\&\le \left| \frac{1}{p(n)} 0.8785e^{\frac{\pi \mu (n)}{6Q}}n^\frac{1}{4} + \frac{1}{p(n)} (0.1924Q+3.464)e^{\sqrt{24\delta _0}\frac{\pi \mu (n)}{6}}n^\frac{1}{4} \right. \\&\left. \quad + \frac{1}{p(n)} (172954 Q + 26591) n^\frac{3}{8}\right| \\&\le 20.79e^{\left( \frac{1}{Q}-1\right) \frac{\pi \mu (n)}{6}}n^\frac{5}{4} + (4.553Q+81.96)e^{\left( \sqrt{24\delta _0}-1\right) \frac{\pi \mu (n)}{6}}n^\frac{5}{4}\\&\quad + 10^5(40.93 Q + 6.292) e^{-\frac{\pi \mu (n)}{6}}n^\frac{11}{8}. \end{aligned}$$

This is a sum of three terms each with similar factors. To combine this into an upper bound which can be worked with we take the sum of all three coefficients, the highest order exponential, and the highest power of n from the three terms and put them together in one term. This gives the bounds in the statement of the theorem. We have to break up the \(Q<11\) and \(Q\ge 11\) cases because that is the point at which \({1}/{Q}-1\) is overtaken by \(\sqrt{24\delta _0}-1\). Note that the third term has far larger coefficients but also a much faster decaying exponential term, so a lot of accuracy is lost when combining this term with the others. \(\square \)

3 Surjectivity

The crank is a function that maps the set of partitions \(S_n\) of n to the integers \(\mathbb {Z}\). We can take the reduction of this map modulo Q to get a function from \(S_n\) to \(\mathbb {Z}/Q\mathbb {Z}\). It is natural to ask for which n this map is surjective. This is an analogue of Linnik’s theorem on the smallest prime in an arithmetic progression. We study this question in Theorems 1.4 and 1.5, which we now prove in turn.

Proof of Theorem 1.4

To prove that the reduction of the crank modulo Q is surjective, it is sufficient to prove that

$$\begin{aligned} |R(r,Q;n)| < \frac{1}{Q}, \end{aligned}$$

because this implies \(M(r,Q;n)>0\).

By our bounds on |R(rQn)|, when \(Q<11\) we need

$$\begin{aligned} 10^5(40.93 Q + 6.292) e^{-\left( 1-\frac{1}{Q}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8} < \frac{1}{Q}, \end{aligned}$$

and when \(Q\ge 11\) we need

$$\begin{aligned} 10^5(40.93 Q + 6.292) e^{-\left( 1-\sqrt{1+12(\frac{1}{Q^2}-\frac{1}{Q})}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8} < \frac{1}{Q}. \end{aligned}$$

First assume that \(Q < 11\). Then, to show the inequality

$$\begin{aligned}&10^5(40.93 Q + 6.292) e^{-\left( 1-\frac{1}{Q}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8} < \frac{1}{Q}, \end{aligned}$$

it suffices to show that

$$\begin{aligned} 10^5(40.93\times 11 + 6.292) e^{-\left( 1-\frac{1}{3}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8} <\frac{1}{11}. \end{aligned}$$
(3)

By a short computation, we find that (3) holds when \(n\ge 263\).

Hence, it follows that if \(Q<11\) and \(n\ge 263\), then

$$\begin{aligned} |R(r,Q;n)| < \frac{1}{Q}. \end{aligned}$$

Next, we deal with the case \(Q\ge 11\). It suffices to show that

$$\begin{aligned} |R(r,Q;n)|\le 10^5(40.93 Q + 6.292) e^{-\left( 1-\sqrt{1+12(\frac{1}{Q^2}-\frac{1}{Q})}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8} < \frac{1}{2Q}, \end{aligned}$$

where we replaced 1/Q with 1/2Q since we will need this inequality in Sect. 4. To verify the inequality, it is equivalent to show that

$$\begin{aligned} \frac{e^{\left( 1-\sqrt{1+12(\frac{1}{Q^2}-\frac{1}{Q})}\right) \frac{\pi }{6}\mu (n)}}{n^{\frac{11}{8}}}>2\times 10^5Q(40.93 Q + 6.292). \end{aligned}$$
(4)

Moreover, we recall the following inequality [11, Eq. 4.5.13]

$$\begin{aligned} e^x>\left( 1+\frac{x}{y}\right) ^y,\qquad x,y>0. \end{aligned}$$
(5)

Hence, by taking \(y=3\) in (5), we get

$$\begin{aligned} \frac{e^{\left( 1-\sqrt{1+12(\frac{1}{Q^2}-\frac{1}{Q})}\right) \frac{\pi }{6}\mu (n)}}{n^{\frac{11}{8}}}>&\frac{1}{n^{\frac{11}{8}}}\left( 1+\left( 1-\sqrt{1+12(\frac{1}{Q^2}-\frac{1}{Q})}\right) \frac{\pi }{18}\mu (n)\right) ^3\\ >&\frac{\pi ^3(24n-1)^{\frac{3}{2}}}{18^3n^{\frac{11}{8}}}\left( 1-\sqrt{1+12(\frac{1}{Q^2}-\frac{1}{Q})}\right) ^3. \end{aligned}$$

By combining (4), it suffices to show that

$$\begin{aligned} \frac{(24n-1)^{\frac{3}{2}}}{n^{\frac{11}{8}}}>\frac{2\times 10^5\times 18^3Q(40.93 Q + 6.292)}{\left( \pi -\pi \sqrt{1+12(\frac{1}{Q^2}-\frac{1}{Q})}\right) ^3}. \end{aligned}$$
(6)

In addition, if \(n\ge 2\), then we have

$$\begin{aligned} \frac{(24n-1)^{\frac{3}{2}}}{n^{\frac{11}{8}}}>\frac{24^{\frac{3}{2}}(n-1)^{\frac{3}{2}}}{n^{\frac{11}{8}}}=24^{\frac{3}{2}}\left( 1-\frac{1}{n}\right) ^{\frac{11}{8}}(n-1)^{\frac{1}{8}}\ge \frac{24^{\frac{3}{2}}}{2^{\frac{11}{8}}}(n-1)^{\frac{1}{8}}. \end{aligned}$$

Hence, by a simple calculation, if we choose the constant

$$\begin{aligned} C_Q:=\frac{(1.93\times 10^{59})(40.93Q^2+6.292Q)^8}{\left( \pi -\pi \sqrt{1+12(\frac{1}{Q^2}-\frac{1}{Q})}\right) ^{24}}+1, \end{aligned}$$

then (6) holds when \(n\ge C_Q>2\). This completes the proof. \(\square \)

Remark 3.1

From our estimation, the exponent y in (5) controls the magnitude of \(C_Q\). Hence, it is not hard to see that we can choose the constant \(C_Q\) so that \(C_Q\asymp Q\) for y sufficiently large.

There is a different, combinatorial method which allows us to include the case that Q is even.

We will need the following lemma.

Lemma 3.2

For \(n\ge 6\), the cranks of the partitions of n take on exactly the values \(-n\) through n except for \(-n+1\) and \(n-1\).

Proof

It is clear from the definition of crank that a partition \(\uplambda \) of n cannot have crank larger than n, since \(\uplambda _1 \le n\) and \(\nu (\uplambda )\) is much less than n. The crank cannot be less than \(-n\) since \(o(\uplambda )\le n\). Say there was a partition \(\uplambda \) with crank \(n-1\). Since \(\nu (\uplambda )\) is much less than n, it must be that \(o(\uplambda )=0\) and therefore \(\uplambda _1 = n-1\), but this implies \(\uplambda _2=1\), which is a contradiction. Now say we have a partition \(\uplambda \) with crank \(-n+1\). If every part of \(\uplambda \) is 1, then the crank would be \(-n\), so we must have \(\uplambda _1\ge 2\). This implies \(o(\uplambda )\le n-2\), so the crank can not be \(-n+1\).

We have shown that the crank can only take on the claimed values. We now show that it takes on each of those values. Let \(3\le k\le n\) and we will construct a partition \(\uplambda \) of crank k. Let \(\uplambda _1\) be k. If \(n-k\) is even, then let all the remaining parts be 2. If \(n-k\) is odd, then let \(\uplambda _2\) be 3 and let all the remaining parts be 2. Notice that this does not work when \(k=n-1\) because 1 cannot be written as a sum of 2s and 3s. We can also create a partition of crank \(-k\) by letting there be k 1’s, and letting the remaining parts be 2 or 3 as before. Since \(k\ge 3\), we have \(\nu (\uplambda )=0\), and so the partition has the desired crank. Note that once again this does not work when \(k=n-1\) for the same reason as before. Now it only remains to find partitions with cranks equal to 2, 1, 0, \(-1\), and \(-2\). For \(n\ge 7\), the following partitions work:

  • \(n = (n-5) + 2 + 2 + 1\),

  • \(n = (n-3) + 2 + 1\),

  • \(n = (n-1) + 1\),

  • \(n = (n-2) + 1 + 1\),

  • \(n = (n-3) + 1 + 1 + 1\).

For \(n=6\), we also must consider the partitions \(2+2+2\) and \(2+2+1+1\) with cranks 2 and \(-2\), respectively, and for the 1, 0, and \(-1\) cases the above partitions still work. \(\square \)

Proof of Theorem 1.5

For even Q and \(n\ge {Q}/{2}+2\), Lemma 3.2 implies that the crank takes on at least Q consecutive values, so the crank maps onto each residue class. For \(n={Q}/{2}+1\), no partition has crank congruent to Q/2. For \(n={Q}/{2}\), no partition has crank congruent to \({Q}/{2}-1\). For lower n, no partition has crank congruent to Q/2.

For odd Q and \(n={(Q+1)}/{2}\), the residues \({(Q\pm 1)}/{2}\) are mapped onto by \(-n\) and n, and all the other residues are mapped onto by \(-n+2\) through \(n-2\). For \(n>{(Q+1)}/2\), the crank takes on at least Q consecutive values. When \(n = {(Q-1)}/{2}\), no partition has crank congruent to \({(Q-3)}/{2}\). For lower n, no partition has crank congruent to \({(Q-1)}/{2}\). Thus we have shown that for odd \(Q\ge 11\) and even \(Q\ge 8\), the cranks of the partitions of n take on every value modulo Q exactly when \(n\ge {(Q+1)}/{2}\) or \(n\ge {Q}/{2}+2\) respectively, as desired. \(\square \)

4 Strict log-Subadditivity for Crank Functions

Bessenrodt and Ono [4] showed that if \(a,b\ge 1\) and \(a+b\ge 9\), then

$$\begin{aligned} p(a+b)<p(a)p(b). \end{aligned}$$

Also, Dawsey and Masri [5] showed the following similar result for the spt-function,

$$\begin{aligned} \text {spt}(a+b)<\text {spt}(a)\text {spt}(b), \end{aligned}$$

for \((a,b)\ne (2,2)\) or (3, 3).

We now prove Theorem 1.6, which is an analogous result for the crank counting function.

Proof of Theorem 1.6

We first deal with the case \(Q<11\). By our bounds on |R(rQn)|, when \(Q<11\) we have

$$\begin{aligned} L(Q,n)<M(r,Q;n)<U(Q,n), \end{aligned}$$

where

$$\begin{aligned} L(Q,n)&:=p(n)\left( \frac{1}{Q}-10^5(40.93 Q + 6.292) e^{-\left( 1-\frac{1}{Q}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8}\right) ,\\ U(Q,n)&:=p(n)\left( \frac{1}{Q}+10^5(40.93 Q + 6.292) e^{-\left( 1-\frac{1}{Q}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8}\right) . \end{aligned}$$

Moreover, by \(3\le Q<11\) and \(n\ge 263\), we have

$$\begin{aligned} L(Q,n)>p(n)\left( \frac{1}{11}-10^5(40.93\times 11 + 6.292) e^{-\frac{\pi }{9}\mu (n)}n^\frac{11}{8}\right) >(0.00306)p(n). \end{aligned}$$

Similarly, we get

$$\begin{aligned} U(Q,n)&<p(n)\left( \frac{1}{3}+10^5(40.93\times 11 + 6.292) e^{-\frac{\pi }{9}\mu (n)}n^\frac{11}{8}\right) \\&<(1.10213\times 10^7)p(n). \end{aligned}$$

Hence, if \(n\ge 263\), then we have

$$\begin{aligned} (0.00306)p(n)<M(r,Q;n)<(1.10213\times 10^7)p(n). \end{aligned}$$

On the other hand, Lehmer [9] gives the following bounds for p(n):

$$\begin{aligned} \frac{\sqrt{3}}{12n}\left( 1-\frac{1}{\sqrt{n}}\right) e^{\frac{\pi }{6}\mu (n)}<p(n)< \frac{\sqrt{3}}{12n}\left( 1+\frac{1}{\sqrt{n}}\right) e^{\frac{\pi }{6}\mu (n)}. \end{aligned}$$

Together these give the bounds

$$\begin{aligned}&(0.00306) \frac{\sqrt{3}}{12n}\left( 1-\frac{1}{\sqrt{n}}\right) e^{\frac{\pi }{6}\mu (n)} \nonumber \\&\quad<M(r,Q;n) <(1.10213\times 10^7)\frac{\sqrt{3}}{12n}\left( 1+\frac{1}{\sqrt{n}}\right) e^{\frac{\pi }{6}\mu (n)}. \end{aligned}$$
(7)

Now, we follow the argument in [5, Sect. 6] and let \(b=Ca\) for some \(C\ge 1\). Then by (7), it follows that

$$\begin{aligned}&M(r,Q,a)M(r,Q,b)\\&\quad >(0.00306)^2\frac{1}{48Ca^2}\left( 1-\frac{1}{\sqrt{a}}\right) \left( 1-\frac{1}{\sqrt{Ca}}\right) e^{\frac{\pi }{6}(\mu (a)+\mu (Ca))}, \end{aligned}$$

and

$$\begin{aligned} M(r,Q,a+b)<(1.10213\times 10^7)\frac{\sqrt{3}}{12(a+Ca)}\left( 1+\frac{1}{\sqrt{a+Ca}}\right) e^{\frac{\pi }{6}\mu (a+Ca)}. \end{aligned}$$

It suffices to show that

$$\begin{aligned} T_a(C)>\log \left( V_a(C)\right) +\log \left( S_a(C)\right) , \end{aligned}$$

where

$$\begin{aligned} T_a(C)&:=\frac{\pi }{6}(\mu (a)+\mu (Ca)-\mu (a+Ca)),\\ S_a(C)&:=\frac{1+\frac{1}{\sqrt{a+Ca}}}{\left( 1-\frac{1}{\sqrt{a}}\right) \left( 1-\frac{1}{\sqrt{Ca}}\right) },\\ V_a(C)&:=\frac{(1.10213\times 10^7)}{(0.00306)^2}\frac{4\sqrt{3}Ca}{C+1}. \end{aligned}$$

As functions of C, it can be shown that \(T_a(C)\) is increasing and \(S_a(C)\) is decreasing for \(C \ge 1\), and by combining

$$\begin{aligned} V_a(C)<\frac{(1.10213\times 10^7)}{(0.00306)^2}4\sqrt{3}a, \end{aligned}$$

it suffices to show that

$$\begin{aligned} T_a(1)&=\frac{\pi }{6}(2\mu (a)-\mu (2a))\nonumber \\&>\log \left( \frac{(1.10213\times 10^7)}{(0.00306)^2}4\sqrt{3}a\right) +\log \left( \frac{1+\frac{1}{\sqrt{2a}}}{\left( 1-\frac{1}{\sqrt{a}}\right) ^2}\right) \nonumber \\&=\log \left( \frac{(1.10213\times 10^7)}{(0.00306)^2}4\sqrt{3}a\right) +\log \left( S_a(1)\right) . \end{aligned}$$
(8)

By computing the values \(T_a(1)\) and \(S_a(1)\), we find that (8) holds for all \(a \ge 396\).

Hence, if \(Q<11\) and \(a,b\ge 396\), then we have

$$\begin{aligned} M(r,Q;a+b) < M(r,Q;a)M(r,Q;b). \end{aligned}$$

Next, we deal with the case \(Q\ge 11\). By our bounds on |R(rQn)|, when \(Q\ge 11\) we have

$$\begin{aligned} L_2(Q,n)<M(r,Q;n)<U_2(Q,n), \end{aligned}$$

where

$$\begin{aligned} L_2(Q,n)&:=p(n)\left( \frac{1}{Q}-10^5(40.93 Q + 6.292) e^{-\left( 1-\sqrt{1 +12(\frac{1}{Q^2}-\frac{1}{Q})}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8}\right) ,\\ U_2(Q,n)&:=p(n)\left( \frac{1}{Q}+10^5(40.93 Q + 6.292) e^{-\left( 1-\sqrt{1 +12(\frac{1}{Q^2}-\frac{1}{Q})}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8}\right) . \end{aligned}$$

By the proof of Theorem 1.4, we know that if \(n\ge C_Q\), then we have

$$\begin{aligned} |R(r,Q;n)|\le 10^5(40.93 Q + 6.292) e^{-\left( 1-\sqrt{1 +12(\frac{1}{Q^2}-\frac{1}{Q})}\right) \frac{\pi }{6}\mu (n)}n^\frac{11}{8}<\frac{1}{2Q}. \end{aligned}$$

It follows that

$$\begin{aligned} \left( \frac{1}{2Q}\right) p(n)<M(r,Q;n)<\left( \frac{3}{2Q}\right) p(n). \end{aligned}$$

By the same argument of the case \(Q<11\), we need to show that for any \(b=Ca\) for some \(C\ge 1\),

$$\begin{aligned} T_a(C)>\log \left( W_a(C)\right) +\log \left( S_a(C)\right) , \end{aligned}$$

where

$$\begin{aligned} W_a(C):=(6Q)\frac{4\sqrt{3}Ca}{C+1}. \end{aligned}$$

Moreover, by the trivial bound

$$\begin{aligned} W_a(C)<24\sqrt{3}Qa, \end{aligned}$$

and the same argument, it suffices to show that

$$\begin{aligned} T_a(1)=\frac{\pi }{6}(2\mu (a)-\mu (2a))&>\log (24\sqrt{3}Qa)+\log \left( \frac{1+\frac{1}{\sqrt{2a}}}{\left( 1-\frac{1}{\sqrt{a}}\right) ^2}\right) \nonumber \\&=\log (24\sqrt{3}Qa)+\log \left( S_a(1)\right) . \end{aligned}$$
(9)

On the other hand, if \(a\ge 2\), then we get

$$\begin{aligned} \log (24\sqrt{3}Qa)+\log \left( S_a(1)\right)<\log (24\sqrt{3}Qa)+\log \left( \frac{1+\frac{1}{\sqrt{4}}}{\left( 1-\frac{1}{\sqrt{2}}\right) ^2}\right) <\log (432Qa). \end{aligned}$$
(10)

Also, if \(a\ge (432Q)^2\ge (432\times 11)^2\), then we have

$$\begin{aligned} T_a(1)=\frac{\pi }{6}\frac{16a-1}{\sqrt{48a-1}}>2\log a\ge \log a + 2\log 432Q>\log (432Qa). \end{aligned}$$
(11)

Hence, by combining (9), (10) and (11), we can choose \(a,b\ge (432Q)^2\) to get the desired result. \(\square \)