|
|
A172398
|
|
Number of partitions of n into the sum of two refactorable numbers (A033950).
|
|
5
|
|
|
0, 1, 1, 1, 0, 0, 0, 0, 1, 2, 1, 0, 1, 1, 0, 1, 1, 1, 1, 2, 1, 0, 0, 1, 1, 2, 1, 0, 0, 1, 0, 1, 1, 0, 0, 2, 1, 1, 0, 0, 1, 2, 0, 1, 1, 0, 0, 3, 1, 0, 0, 1, 0, 1, 0, 0, 1, 2, 0, 1, 1, 1, 0, 2, 1, 0, 0
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,10
|
|
LINKS
|
|
|
FORMULA
|
a(n) = Sum_{i=1..floor(n/2)} ((1+floor(i/d(i)) - ceiling(i/d(i))) * (1 + floor((n-i)/d(n-i)) - ceiling((n-i)/d(n-i)))). - Wesley Ivan Hurt, Jan 12 2013
|
|
EXAMPLE
|
a(10)=2 because 10 = 1(refactorable) + 9(refactorable) = 2(refactorable) + 8(refactorable).
|
|
MAPLE
|
with(numtheory);
a:=n-> sum( ((1 + floor(i/tau(i)) - ceil(i/tau(i))) * (1 + floor((n-i)/tau(n-i)) - ceil((n-i)/tau(n-i))) ), i=1..floor(n/2));
# alternative
isA033950 := proc(n)
if modp(n, numtheory[tau](n)) = 0 then
true;
else
false;
end if;
end proc:
local a;
a := 0 ;
for i from 1 to n/2 do
if isA033950(i) and isA033950(n-i) then
a := a+1 ;
end if;
end do:
a ;
|
|
MATHEMATICA
|
a[n_] := IntegerPartitions[n, {2}, Select[Range[n], Divisible[#, DivisorSigma[0, #]]&]] // Length;
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|