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!)
A127076 a(0)=1. a(n) = a(n-1) + (sum of the earlier terms {among terms a(0) through a(n-1)} which are coprime to n). 2

%I #13 Sep 15 2020 21:07:39

%S 1,2,3,6,10,22,23,90,117,175,319,746,1264,3925,8313,10690,23566,64525,

%T 133493,380783,903835,2427039,6349271,16657466,24493816,74970066,

%U 84860988,133884920,144156567,630996725,637860615,2396049996,3819335725

%N a(0)=1. a(n) = a(n-1) + (sum of the earlier terms {among terms a(0) through a(n-1)} which are coprime to n).

%H Robert Israel, <a href="/A127076/b127076.txt">Table of n, a(n) for n = 0..3125</a>

%e The terms of the sequence, among terms a(0) through a(7), which are coprime to 8 are a(0)=1, a(2)=3 and a(6) = 23. So a(8) = a(7) +1 +3 +23 = 117.

%p R:= [1]:

%p for n from 1 to 100 do

%p x:= R[-1] + convert(select(t -> igcd(t,n)=1, R),`+`);

%p R:= [op(R),x];

%p od:

%p R; # _Robert Israel_, Sep 15 2020

%t f[l_List] := Append[l, l[[ -1]] + Plus @@ Select[l, GCD[ #, Length[l]] == 1 &]];Nest[f, {1}, 32] (* _Ray Chandler_, Jan 06 2007 *)

%Y Cf. A127075.

%K nonn

%O 0,2

%A _Leroy Quet_, Jan 04 2007

%E Extended by _Ray Chandler_, Jan 06 2007

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 25 01:35 EDT 2024. Contains 371964 sequences. (Running on oeis4.)