cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A140644 a(0)=1. a(n) = a(n-1)/d(n) if d(n) divides a(n-1). Otherwise, a(n) = a(n-1)*d(n). (d(n) is the number of positive divisors of n.).

Original entry on oeis.org

1, 1, 2, 1, 3, 6, 24, 12, 3, 1, 4, 2, 12, 6, 24, 6, 30, 15, 90, 45, 270, 1080, 270, 135, 1080, 360, 90, 360, 60, 30, 240, 120, 20, 5, 20, 5, 45, 90, 360, 90, 720, 360, 45, 90, 15, 90, 360, 180, 18, 6, 1, 4, 24, 12, 96, 24, 3, 12, 3, 6, 72, 36, 9, 54, 378, 1512, 189, 378, 63
Offset: 0

Views

Author

Leroy Quet, Jul 08 2008

Keywords

Crossrefs

Cf. A008336.

Programs

  • Maple
    A140644 := proc(n) option remember ; local d ; if n = 0 then 1; else d := numtheory[tau](n) ; if A140644(n-1) mod d = 0 then RETURN( A140644(n-1)/d ) ; else RETURN( d*A140644(n-1) ) ; fi; fi; end: for n from 0 to 80 do printf("%d,",A140644(n)) ; od: # R. J. Mathar, Aug 08 2008
  • Mathematica
    nxt[{n_,a_}]:=Module[{d=DivisorSigma[0,n+1]},{n+1,If[Divisible[a,d], a/d, a*d]}]; Transpose[NestList[nxt,{0,1},70]][[2]] (* Harvey P. Dale, Jul 25 2015 *)

Extensions

Extended beyond a(20) by R. J. Mathar, Aug 08 2008