a(n) = floor(a(n-1)/3) if this is positive and not yet in the sequence, otherwise a(n) = 8*a(n-1).

A050096

a(n) = floor(a(n-1)/3) if this is positive and not yet in the sequence, otherwise a(n) = 8*a(n-1).

Terms

    a(0) =1a(1) =8a(2) =2a(3) =16a(4) =5a(5) =40a(6) =13a(7) =4a(8) =32a(9) =10a(10) =3a(11) =24a(12) =192a(13) =64a(14) =21a(15) =7a(16) =56a(17) =18a(18) =6a(19) =48a(20) =384a(21) =128a(22) =42a(23) =14a(24) =112a(25) =37a(26) =12a(27) =96a(28) =768a(29) =256

External references