login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A226378 Number of distinct sums i+j+k with i,j,k >= 0, i*j*k = n. 4
1, 1, 1, 1, 2, 1, 2, 1, 3, 2, 2, 1, 4, 1, 2, 2, 4, 1, 4, 1, 4, 2, 2, 1, 6, 2, 2, 3, 4, 1, 5, 1, 5, 2, 2, 2, 7, 1, 2, 2, 5, 1, 5, 1, 4, 4, 2, 1, 9, 2, 4, 2, 4, 1, 6, 2, 6, 2, 2, 1, 10, 1, 2, 4, 7, 2, 5, 1, 4, 2, 5, 1, 11, 1, 2, 4, 4, 2, 5, 1, 9, 4, 2, 1, 10 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,5

LINKS

Robert Price and Michael De Vlieger, Table of n, a(n) for n = 0..10000 (first 100 terms from Robert Price).

Michael De Vlieger, Records and first positions of records in A226378(n), with 0 <= n <= 10^6.

FORMULA

For n >= 1, a(n) <= A034836(n). - Antti Karttunen, Aug 30 2017

EXAMPLE

From Antti Karttunen, Aug 30 2017: (Start)

For n = 4 = 1*1*4 = 1*2*2, 1+1+4 = 6 and 1+2+2 = 5, so there are two distinct sums, and a(4) = 2.

For n = 6 = 1*1*6 = 1*2*3, 1+1+6 = 8 and 1+2+3 = 6, so there are two distinct sums, and a(6) = 2.

For n = 36, of its A034836(36) = 8 factorizations as x*y*z with 1 <= x <= y <= z: 1*1*36 = 1*2*18 = 1*3*12 = 1*4*9 = 1*6*6 = 2*2*9 = 2*3*6 = 3*3*4, sums 1+6+6 and 2+2+9 are both 13, while other triples yield unique sums, thus a(36) = 8-1 = 7. (End)

MATHEMATICA

f[n_] := Length[Complement[Union[Flatten[Table[If[i*j*k == n, {i + j + k}], {i, 0, n}, {j, 0, n}, {k, 0, n}], 2]], {Null}]]; Table[f[n], {n, 0, 100}]

(* Second program, more efficient: *)

{1}~Join~Table[With[{D = Divisors@ n}, Length@ Union@ Reap[Map[Function[a, Map[Function[b, Map[Function[c, If[a b c == n, Sow[a + b + c]]], Select[D, # <= n/a b &]]], Select[D, # <= n/a &]]], D]][[-1, 1]] ], {n, 100}] (* Michael De Vlieger, Aug 24 2017 *)

PROG

(PARI) A226378(n) = { my(sums=Set()); if(!n, 1, fordiv(n, i, for(j=i, (n/i), if(!(n%j), for(k=j, n/(i*j), if(i*j*k==n, sums = Set(concat(sums, (i+j+k)))))))); length(sums)); }; \\ Antti Karttunen, Aug 30 2017

CROSSREFS

Cf. A226357, A226359, A222945, A222947, A223133, A223134, A223135.

Cf. A008578 (gives the positions of 1's after a(0)=1).

Differs from A034836 for the first time at n=36.

Sequence in context: A069157 A294894 A076526 * A033273 A319685 A034836

Adjacent sequences:  A226375 A226376 A226377 * A226379 A226380 A226381

KEYWORD

nonn

AUTHOR

Robert Price, Jun 12 2013

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified February 23 07:11 EST 2020. Contains 332159 sequences. (Running on oeis4.)