%I #12 Mar 14 2015 18:22:32
%S 1,1,2,2,4,4,6,4,4,8,9,2,2,10,11,2,2,12,8,13,2,2,14,16,12,15,3,13,17,
%T 14,2,18,16,12,17,2,2,17,2,2,19,3,16,3,3,20,2,17,3,22,2,32,21,2,2,23,
%U 2,2,25,8,8,32,31,9,31,31,24,3,10,4,23,10,9,3,37,34,2,42,29,2,5,2,2,30,39
%N a(1) = a(2) = 1. a(n) = number of terms among (a(1),a(2),...a(n-1)) that divide (a(n-1) + a(n-2)).
%C From _Robert G. Wilson v_, Apr 29 2007: (Start)
%C a(n} = 2 for n's: 3, 4, 12, 13, 16, 17, 21, 22, 31, 36, 37, 39, 40, 47, 51, 54, 55, 57, 58, ..., .
%C First occurrence of k: 1, 3, 27, 5, 81, 7, 118, 10, 11, 14, 15, 18, 20, 23, 26, 24, 29, 32, 41, 46, ..., .
%C (End)
%e a(6) + a(7) = 10. 10 is divisible by a(1)=1, a(2)=1, a(3)=2, a(4)=2 and is not divisible by any other of the first 7 terms. So a(8) = 4.
%p a[1]:=1: a[2]:=1: for n from 3 to 110 do ct:=0: for j from 1 to n-1 do if type((a[n-1]+a[n-2])/a[j], integer)=true then ct:=ct+1 else ct:=ct: fi od: a[n]:=ct: od: seq(a[n],n=1..110); # _Emeric Deutsch_, Apr 26 2007
%t f[s_List] := Block[{}, Append[s, Count[ Mod[ s[[ -1]] + s[[ -2]], s], 0]]]; Nest[f, {1, 1}, 85] (* _Robert G. Wilson v_ *)
%K nonn
%O 1,3
%A _Leroy Quet_, Apr 25 2007
%E More terms from _Emeric Deutsch_ and _Robert G. Wilson v_, Apr 26 2007
|