login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A117532 a(n) = smallest positive integer not occurring earlier in the sequence such that Sum_{k=1..n} a(k) is coprime to n. 3
1, 2, 4, 6, 3, 7, 8, 10, 5, 11, 12, 14, 9, 15, 17, 13, 18, 20, 16, 22, 19, 23, 24, 26, 21, 27, 29, 25, 30, 32, 28, 34, 31, 35, 36, 38, 33, 39, 41, 37, 42, 44, 40, 46, 43, 47, 48, 50, 45, 51, 53, 49, 54, 56, 52, 58, 55, 59, 60, 64, 57, 61, 62, 66, 63, 67, 68, 70, 65, 71, 72, 74 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

Sequence is likely to be a permutation of the positive integers, but I am uncertain. A117533(n) = Sum_{k=1..n} a(k). Sequence A117534 is the inverse permutation if this sequence is a permutation of the positive integers.

LINKS

Michael De Vlieger, Table of n, a(n) for n = 1..3000

EXAMPLE

a(4) = 6 because 6 is the smallest positive integer m not among the first 3 terms of the sequence such that 1+2+4+m is coprime to 4. 1+2+4+3 = 10 and gcd(4,10)=2; 1+2+4+5 = 12 and gcd(4,12)=4; but 1+2+4+6 = 13 and gcd(4,13)=1.

MAPLE

A117532 := proc(nmax) local a, n, nxt, asu ; a := [1] ; asu := 1 ; while nops(a) < nmax do n := nops(a)+1 ; nxt := 1 ; while nxt in a or gcd(n, asu+nxt) <> 1 do nxt := nxt+1 ; od ; a := [op(a), nxt] ; asu := asu+nxt ; od ; a ; end: A117532(80) ; # R. J. Mathar, May 10 2007

MATHEMATICA

Fold[Append[#1, Block[{k = 2}, While[Nand[FreeQ[#1, k], CoprimeQ[Total@ #1 + k, #2]], k++]; k]] &, {1}, Range[2, 72]] (* Michael De Vlieger, Sep 30 2017 *)

CROSSREFS

Cf. A117534, A117533.

Sequence in context: A161184 A140645 A327724 * A287662 A278376 A057336

Adjacent sequences:  A117529 A117530 A117531 * A117533 A117534 A117535

KEYWORD

nonn

AUTHOR

Leroy Quet, Mar 26 2006

EXTENSIONS

More terms from R. J. Mathar, May 10 2007

STATUS

approved

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 28 19:48 EST 2021. Contains 349415 sequences. (Running on oeis4.)