Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #25 Dec 28 2022 01:57:38
%S 0,0,1,0,2,1,2,0,3,2,6,1,6,2,3,0,4,3,10,2,15,6,12,1,12,6,15,2,10,3,4,
%T 0,5,4,14,3,24,10,21,2,28,15,40,6,35,12,20,1,20,12,35,6,40,15,28,2,21,
%U 10,24,3,14,4,5,0,6,5,18,4,33,14,30,3,44,24,65,10
%N A variation on Stern's diatomic sequence.
%C This sequence has an analogous relationship to A001654 as A002487 has to A000045; maxima between a(2^n) and a(2^n+1) = A001654(n).
%C For 2^k<=n<=2^k+1: a(n) = A002487(2^(k+1)-n)*A002487(n-2^k).
%H Seiichi Manyama, <a href="/A272569/b272569.txt">Table of n, a(n) for n = 1..10000</a>
%H Sam Northshield, <a href="http://arxiv.org/abs/1503.03433">Three analogues of Stern's diatomic sequence</a>, arXiv preprint arXiv:1503.03433 [math.CO], 2015; <a href="https://www.fq.math.ca/Papers1/52-5/Northshield.pdf">also</a>, Proceedings of the 16th International Conference on Fibonacci Numbers and Their Applications, Rochester Institute of Technology, Rochester, New York, July 20-27, 2014.
%H Sam Northshield, <a href="https://www.researchgate.net/profile/Sam-Northshield/publication/366321658_SOME_GENERALIZATIONS_OF_A_FORMULA_OF_REZNICK/">Some generalizations of a formula of Reznick</a>, SUNY Plattsburgh (2022).
%F a(2n) = a(n), a(2n+1) = a(n) + a(n+1) + (4a(n)*a(n+1)+1)^(1/2).
%t nn = 100;
%t a[_] = 0; a[1] = 0; Do[a[n] = If[EvenQ[n], a[n/2], m = (n-1)/2; a[m] + a[m + 1] + Sqrt[1 + 4 a[m] a[m+1]] // Floor], {n, 2, nn}];
%t Array[a, nn] (* _Jean-François Alcover_, Sep 25 2018, from PARI *)
%o (PARI) lista(nn) = {va = vector(nn); va[1] = 0; for (n=2, nn, if (n % 2 == 0, va[n] = va[n/2], m = (n-1)/2; va[n] = va[m] + va[m+1] + sqrtint(1 + 4*va[m]*va[m+1])););va;} \\ _Michel Marcus_, May 03 2016
%Y Cf. A002487, A001654.
%K nonn
%O 1,5
%A _Max Barrentine_, May 02 2016