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.

A065422 If n | a(n) then a(n+1) = a(n)/(highest power of n that divides a(n)), otherwise a(n+1) = n*a(n); a(0) = 1.

This page as a plain text file.
%I A065422 #35 May 08 2022 23:18:08
%S A065422 1,1,2,6,24,120,20,140,1120,10080,1008,11088,77,1001,14014,210210,
%T A065422 3363360,57177120,1029188160,19554575040,977728752,2217072,100776,
%U A065422 2317848,96577,2414425,62775050,1694926350,47457937800,1376280196200
%N A065422 If n | a(n) then a(n+1) = a(n)/(highest power of n that divides a(n)), otherwise a(n+1) = n*a(n); a(0) = 1.
%H A065422 Reinhard Zumkeller, <a href="/A065422/b065422.txt">Table of n, a(n) for n = 0..1000</a>
%H A065422 <a href="/index/Rea#Recaman">Index entries for sequences related to Recamán's sequence</a>
%t A065422 nxt[{n_,a_}]:={n+1,If[Divisible[a,n],a/n^IntegerExponent[a,n],a*n]}; Join[ {1,1},Transpose[NestList[nxt,{3,2},30]][[2]]] (* _Harvey P. Dale_, Jan 08 2013 *)
%o A065422 (Haskell)
%o A065422 a065422 n = a065422_list !! n
%o A065422 a065422_list = 1 : 1 : f 2 1 where
%o A065422    f n x = x' : f (n+1) x' where
%o A065422        x' | x `mod` n == 0 = until ((> 0) . (`mod` n)) (`div` n) x
%o A065422           | otherwise      = x * n
%o A065422 -- _Reinhard Zumkeller_, Oct 10 2011
%Y A065422 See A008336 for another version. Cf. A005132.
%K A065422 easy,nonn,nice,look
%O A065422 0,3
%A A065422 _Naohiro Nomoto_, Nov 23 2001
%E A065422 Definition and offset corrected by _Reinhard Zumkeller_, Oct 10 2011
%E A065422 Typo in Crossrefs fixed by _Paul Tek_, Aug 01 2015