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!)
A330715 a(1), a(2), a(3) = 1; a(n) = (a(n-1) mod a(n-3)) + a(n-2) + 1. 1

%I #18 May 03 2023 14:32:08

%S 1,1,1,2,2,3,4,4,6,7,10,12,16,19,24,28,34,39,46,52,60,67,76,84,94,103,

%T 114,124,136,147,160,172,186,199,214,228,244,259,276,292,310,327,346,

%U 364,384,403,424,444,466,487,510,532,556,579,604,628,654,679,706,732

%N a(1), a(2), a(3) = 1; a(n) = (a(n-1) mod a(n-3)) + a(n-2) + 1.

%H Matthew Niemiro, <a href="/A330715/b330715.txt">Table of n, a(n) for n = 1..1000</a>

%F a(1), a(2), a(3) = 1; a(n) = (a(n-1) mod a(n-3)) + a(n-2) + 1.

%F Conjectures from _Colin Barker_, Dec 28 2019: (Start)

%F G.f.: x*(1 - x - x^2 + 2*x^3 - x^4 + x^6 - 2*x^7 + 2*x^8) / ((1 - x)^3*(1 + x)).

%F a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4) for n>9.

%F a(n) = (99 - 3*(-1)^n - 24*n + 2*n^2) / 8 for n>5.

%F (End)

%t Nest[Append[#, Mod[#[[-1]], #[[-3]] ] + #[[-2]] + 1] &, {1, 1, 1}, 57] (* _Michael De Vlieger_, Dec 27 2019 *)

%o (Python)

%o x = 1

%o y = 1

%o z = 1

%o for i in range(4, 1001):

%o new = z % x + y + 1

%o print(str(i) +" " + str(new))

%o x = y

%o y = z

%o z = new

%K nonn,hear

%O 1,4

%A _Matthew Niemiro_, Dec 27 2019

%E More terms from _Michael De Vlieger_, Dec 27 2019

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 23 23:26 EDT 2024. Contains 371917 sequences. (Running on oeis4.)