login
A079792
a(1) = 1, a(n) = a(n-1)/gcd(a(n-1),n) if gcd(a(n-1),n) > 1 otherwise a(n) is the concatenation of a(n-1) and n.
0
1, 12, 4, 1, 15, 5, 57, 578, 5789, 578910, 57891011, 5789101112, 578910111213, 82701444459, 27567148153, 2756714815316, 275671481531617, 27567148153161718, 2756714815316171819, 275671481531617181920
OFFSET
1,2
EXAMPLE
a(3) = 12/3 = 4, a(4) = 4/4 = 1, a(5) = 15, a(6) = 15/3 = 5.
MATHEMATICA
a[1] = 1; a[n_] := a[n] = Block[{b = GCD[a[n - 1], n]}, If[b > 1, a[n - 1]/b, FromDigits[ Join[ IntegerDigits[ a[n - 1]], IntegerDigits[ n]]]]]; Table[a[n], {n, 1, 20}]
CROSSREFS
Cf. A079791.
Sequence in context: A098909 A261403 A010202 * A079791 A018812 A306375
KEYWORD
base,nonn
AUTHOR
Amarnath Murthy, Feb 04 2003
EXTENSIONS
Edited and extended by Robert G. Wilson v, Feb 04 2003
STATUS
approved