OFFSET
1,3
EXAMPLE
a(9) +a(10) = 42. The smallest integer greater than a(10)=23 which is coprime to 42 is 25. So a(11) = 25.
MAPLE
A122089 := proc(maxn) local a, nexta, n ; a := [1, 1] ; for n from 3 to maxn do nexta := op(n-1, a)+1 ; while gcd(nexta, op(n-2, a)+op(n-1, a)) >1 do nexta := nexta+1 ; od ; a := [op(a), nexta] ; od ; RETURN(a) ; end: maxn := 100 : alist := A122089(maxn) : for i from 1 to maxn do printf("%d, ", op(i, alist)) ; end : # R. J. Mathar, Oct 21 2006
MATHEMATICA
f[l_List] := Block[{k = l[[ -1]] + 1}, While[GCD[k, l[[ -1]] + l[[ -2]]] > 1, k++ ]; Append[l, k]]; Nest[f, {1, 1}, 61] (* Ray Chandler, Oct 19 2006 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Leroy Quet, Oct 17 2006
EXTENSIONS
Extended by Ray Chandler, Oct 19 2006
More terms from R. J. Mathar, Oct 21 2006
STATUS
approved