Is there a reason why the function PartitionsP[] does not return anything for non-integer arguments, although there is a way to calculate using Rademacher’s ‘exact’ formula? I would expect a result - as is the case with the Factorial[] or Binomial[] function.
$\begingroup$
$\endgroup$
3
-
1$\begingroup$ The documentation explicitly states that it's an Integer mathematical function of an integer parameter. If there is an extension, it has simply not been implemented. We can't really say why though. $\endgroup$MarcoB– MarcoB2023-12-17 12:35:26 +00:00Commented Dec 17, 2023 at 12:35
-
1$\begingroup$ You can implement your own function, and ask us for help if you have some implementation difficulties. But we are not associated with Wolfram, we are simply users, not developers. Therefore, I vote to close this question. $\endgroup$yarchik– yarchik2023-12-17 13:13:25 +00:00Commented Dec 17, 2023 at 13:13
-
$\begingroup$ As shown by @azerbajdzan, the continuous extension has an oscillatory behavior and thus Rademacher’s formula is not considered convex. This might be the reason why it was not implemented, which is a satisfactory answer for me. $\endgroup$ftel– ftel2023-12-18 09:03:14 +00:00Commented Dec 18, 2023 at 9:03
Add a comment
|
1 Answer
$\begingroup$
$\endgroup$
1
The upper limit upperlimit suppose to be infinity for exact result. For the plot upperlimit=10 was used.
upperlimit = 10;
ReImPlot[1/(π Sqrt[2]) Sum[(Sum[
KroneckerDelta[GCD[h, k],
1] Exp[π I Sum[
j/k ((h j)/k - Floor[(h j)/k] - 1/2), {j, 1,
k - 1}] - (2 \[Pi] I h n)/k], {h, 1, k}]) Sqrt[
k] ((π Cosh[(Sqrt[2/3] Sqrt[-(1/24) + n] π)/k])/(Sqrt[
6] k (-(1/24) + n)) -
Sinh[(Sqrt[2/3] Sqrt[-(1/24) + n] π)/
k]/(2 (-(1/24) + n)^(3/2))), {k, 1, upperlimit}], {n, 0, 10},
Epilog -> Point[Table[{i, PartitionsP[i]}, {i, 0, 10}]],
PlotRange -> 43]
-
$\begingroup$ @ftel: Yes, you are right, I wrongly assumed that the function is real for all real arguments, but it is real only for integer argument. I corrected my answer. $\endgroup$azerbajdzan– azerbajdzan2023-12-18 09:12:06 +00:00Commented Dec 18, 2023 at 9:12
