login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A168542 Number of trees that have a maximum 'n'. 4

%I

%S 1,1,1,2,2,4,5,10,10,20,25,50,52,104,130,260,260,520,650,1300,1352,

%T 2704,3380,6760,6770,13540,16925,33850,35204,70408,88010,176020,

%U 176020,352040,440050,880100,915304,1830608,2288260,4576520,4583290,9166580,11458225

%N Number of trees that have a maximum 'n'.

%C a(2^n) = Product_{k=1..n} A003095(k). - _Michael Somos_, Dec 20 2018

%H Alois P. Heinz, <a href="/A168542/b168542.txt">Table of n, a(n) for n = 0..5654</a>

%F a(1) = a(2) = 1, a(3*2^m + k) = A003095(m+2) * a(n - 2*2^m) where 0 <= k < 3*2^m. - _Michael Somos_, Dec 20 2018

%F a(n) = Sum_{k=0..n} (A309049(n,k)-A309049(n-1,k)) for n > 0, a(0) = 1. - _Alois P. Heinz_, Jul 12 2019

%p b:= proc(n) option remember; `if`(n=0, 1, (g-> (f->

%p 1+b(f)*b(n-1-f))(min(g-1, n-g/2)))(2^ilog2(n)))

%p end:

%p a:= n-> b(n)-`if`(n=0, 0, b(n-1)):

%p seq(a(n), n=0..45); # _Alois P. Heinz_, Jul 12 2019

%t a[ n_] := If[ n < 3, Boole[n > 0], With[{m = BitLength[Quotient[n, 3]] - 1}, Nest[#^2 + 1 &, 2, m] a[n - 2 2^m]]]; (* _Michael Somos_, Dec 20 2018 *)

%o (PARI) {a(n) = if( n<3, n>0, my(m = #binary(n\3)-1, t = 2); for(i=1, m, t = t^2+1); t*a(n - 2*2^m))}; /* _Michael Somos_, Dec 20 2018 */

%Y Cf. A003095, A070939, A309049.

%Y Partial differences of A091980. - _Alois P. Heinz_, Jul 12 2019

%K nonn

%O 0,4

%A Endi Begeja (andy.bege(AT)libero.it), Nov 29 2009

%E a(0)=1 prepended by _Alois P. Heinz_, Jul 12 2019

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 November 14 20:11 EST 2019. Contains 329129 sequences. (Running on oeis4.)