For n > 1, if n appears in the sequence then a(n) = lastindex(n), where lastindex(n) is the index of the last appearance of n. Otherwise a(n+1) = a(n)/(n+1) if (n+1)|a(n), otherwise a(n)*(n+1), a(1) = 1 and a(2) = 1*2.

A362332

For n > 1, if n appears in the sequence then a(n) = lastindex(n), where lastindex(n) is the index of the last appearance of n. Otherwise a(n+1) = a(n)/(n+1) if (n+1)|a(n), otherwise a(n)*(n+1), a(1) = 1 and a(2) = 1*2.

Terms

    a(0) =1a(1) =2a(2) =6a(3) =24a(4) =120a(5) =3a(6) =21a(7) =168a(8) =1512a(9) =15120a(10) =166320a(11) =13860a(12) =180180a(13) =12870a(14) =858a(15) =13728a(16) =233376a(17) =4200768a(18) =79814592a(19) =1596291840a(20) =7a(21) =154a(22) =3542a(23) =4a(24) =100a(25) =2600a(26) =70200a(27) =1965600a(28) =57002400a(29) =1900080

External references