login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A019569 Number of bar segments in a certain way of representing the integers graphically. 1
0, 1, 2, 2, 3, 2, 3, 3, 3, 3, 4, 3, 3, 4, 3, 3, 4, 3, 4, 4, 4, 4, 4, 4, 4, 5, 4, 5, 4, 3, 5, 4, 5, 4, 4, 4, 4, 5, 5, 5, 4, 4, 5, 5, 4, 5, 4, 4, 4, 4, 6, 6, 4, 4, 5, 6, 5, 5, 5, 4, 4, 5, 5, 3, 6, 5, 5, 5, 6, 4, 5, 5, 5, 6, 4, 6, 4, 5, 5, 5, 4 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
COMMENTS
Let p(i) = i-th prime. Let n = Product_{i=1..s} p(k_i)^e_i with k_1 < k_2 < ... < k_s. The drawing of n=1 is a blank space. The drawing of n > 1 is arranged around a horizontal bar divided by s-1 scores into s segments. The scores and the bar divide the space above and below the bar into 2's compartments. In the i-th compartment above the bar place the drawing of e_i and in the i-th compartment below the bar place the drawing of k_i - k_{i-1}.
LINKS
Sean A. Irvine, Java program (github)
FORMULA
a(1) = 0; a(2) = 1; a(n) = s + Sum_{i=1..s} ( a(e_i) + a(k_i - k_{i-1}) ) with k_0 = 0.
MAPLE
with(numtheory):
a:= proc(n) option remember; `if`(n<3, n-1, (l-> nops(l)+
add(a(l[i, 2])+a(pi(l[i, 1])-`if`(i=1, 0, pi(l[i-1, 1]))),
i=1..nops(l)))(sort(ifactors(n)[2], (x, y)-> x[1]<y[1])))
end:
seq(a(n), n=1..100); # Alois P. Heinz, Mar 26 2019
MATHEMATICA
a[n_] := a[n] = If[n<3, n-1, Function[l, Length[l] + Sum[a[l[[i, 2]]] + a[PrimePi[l[[i, 1]]] - If[i == 1, 0, PrimePi[l[[i-1, 1]]]]], {i, 1, Length[l]}]][SortBy[FactorInteger[n], First]]];
Array[a, 100] (* Jean-François Alcover, Nov 17 2020, after Alois P. Heinz *)
CROSSREFS
Sequence in context: A202472 A235613 A322418 * A003434 A330808 A097849
KEYWORD
nonn
AUTHOR
EXTENSIONS
Formula corrected by Sean A. Irvine, Mar 26 2019
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 10:38 EDT 2024. Contains 371791 sequences. (Running on oeis4.)