Description Usage Arguments Details Note Author(s) Examples
Given an integer, P()
returns the number of additive
partitions, Q()
returns the number of unequal
partitions, and R()
returns the number of
restricted partitions. Function S()
returns the number of
block partitions.
1 2 3 4 
n 
Integer whose partition number is desired. In function

m 
In function 
give 
Boolean, with default 
include.zero 
In 
include.fewer 
In function 
f 
In function 
Functions P()
and Q()
use Euler's
recursion formula. Function R()
enumerates the partitions
using Hindenburg's method (see Andrews) and counts them until the
recursion bottoms out.
Function S()
finds the coefficient of x^n in the
generating function prod_{i=1}^{L}(1+x+x^2+...+x^(f[i])), where L is the
length of f
, using the polynom package.
All these functions return a double.
Functions P()
and Q()
use unsigned long long
integers, a type which is systemdependent. For me, P()
works
for n equal to or less than 416, and Q()
works for
n less than or equal to 792. YMMV; none of the
methods test for overflow, so use with care!
Robin K. S. Hankin; S()
is due to an anonymous JSS referee
1 2 3 4 5 6 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.