cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A348536 Number of partitions of n into 3 parts that divide n.

Original entry on oeis.org

0, 0, 1, 1, 0, 2, 0, 1, 1, 0, 0, 3, 0, 0, 1, 1, 0, 2, 0, 1, 1, 0, 0, 3, 0, 0, 1, 1, 0, 2, 0, 1, 1, 0, 0, 3, 0, 0, 1, 1, 0, 2, 0, 1, 1, 0, 0, 3, 0, 0, 1, 1, 0, 2, 0, 1, 1, 0, 0, 3, 0, 0, 1, 1, 0, 2, 0, 1, 1, 0, 0, 3, 0, 0, 1, 1, 0, 2, 0, 1, 1, 0, 0, 3, 0, 0, 1, 1, 0, 2, 0, 1, 1, 0, 0
Offset: 1

Views

Author

Wesley Ivan Hurt, Oct 21 2021

Keywords

Comments

From David A. Corneth, Oct 08 2022: (Start)
Proof of formula: suppose we have a partition d_1 + d_2 + d_3 = n where 0 < d_1 <= d_2 <= d_3 and d_1 | n, d_2 | n and d_3 | n.
Then let m_i * d_i = n for i in (1, 2, 3).
Dividing d_1 + d_2 + d_3 = n by n gives d_1/n + d_2/n + d_3/n = n/n, i.e., 1/m_1 + 1/m_2 + 1/m_3 = 1. There are 3 solutions to that equation namely (m_1, m_2, m_3) in {(2, 4, 4), (2, 3, 6), (3, 3, 3)}. The lcm of these numbers is 12 so the sequence is periodic with a period of 12 and then calculating the first 12 terms defines the sequence.
Alternative name: number of divisors of n from {3, 4, 6}. (End)

Examples

			a(12) = 3 via 2 + 4 + 6 = 3 + 3 + 6 = 4 + 4 + 4. - _David A. Corneth_, Oct 08 2022
		

Crossrefs

Programs

  • Mathematica
    Block[{c}, c[n_] := 1 - Ceiling[n] + Floor[n]; Array[Sum[Sum[c[#/j]*c[#/i]*c[#/(# - i - j)], {i, j, Floor[(# - j)/2]} ], {j, Floor[#/3]} ] &, 105]] (* Michael De Vlieger, Oct 21 2021 *)
    Table[Count[IntegerPartitions[n,{3}],?(Mod[n,#]=={0,0,0}&)],{n,100}] (* _Harvey P. Dale, Apr 07 2025 *)
  • PARI
    a(n) = [0, 0, 1, 1, 0, 2, 0, 1, 1, 0, 0, 3][(n-1)%12 + 1] \\ David A. Corneth, Oct 08 2022
    
  • PARI
    a(n) = { my(d = divisors(n), res = 0); d = d[^#d]; forvec(x = vector(2, i, [1, #d]), s = d[x[1]] + d[x[2]]; if(n - s >= d[x[2]], if(n % (n - s) == 0, print([d[x[1]], d[x[2]], n-s]); res++ ) ) , 1 ); res } \\ David A. Corneth, Oct 08 2022

Formula

a(n) = Sum_{j=1..floor(n/3)} Sum_{i=j..floor((n-j)/2)} c(n/j) * c(n/i) * c(n/(n-i-j)), where c(n) = 1 - ceiling(n) + floor(n).
a(n + 12) = a(n) where n >= 1. - David A. Corneth, Oct 08 2022