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.
%I A383401 #31 May 15 2025 08:17:16 %S A383401 1,1,2,1,2,3,2,1,3,3,2,3,2,3,4,1,2,5,2,4,4,3,2,3,3,3,4,4,2,7,2,1,4,3, %T A383401 4,6,2,3,4,4,2,7,2,4,6,3,2,3,3,5,4,4,2,7,4,4,4,3,2,9,2,3,6,1,4,7,2,4, %U A383401 4,7,2,7,2,3,6,4,4,7,2,4,5,3,2,9,4,3,4,5,2,11,4,4,4,3,4,3,2,5,6,7 %N A383401 Index of the largest odd divisor in the list of divisors of n. %C A383401 a(n) = 1 if and only if n is a power of 2. %C A383401 a(n) = 2 if and only if n is an odd prime. %H A383401 Amiram Eldar, <a href="/A383401/b383401.txt">Table of n, a(n) for n = 1..10000</a> %F A383401 a(2n-1) = A000005(2n-1). %e A383401 For n = 10 the divisors of 10 are [1, 2, 5, 10] and the largest odd divisor is 5 and 5 is the third divisor, so a(10) = 3. %t A383401 a[n_] := If[OddQ[n], DivisorSigma[0, n], FirstPosition[Divisors[n], n/2^IntegerExponent[n, 2]][[1]]]; Array[a, 100] (* _Amiram Eldar_, May 14 2025 *) %o A383401 (PARI) a(n) = select(x->x==n/2^valuation(n,2), divisors(n), 1)[1]; \\ _Michel Marcus_, May 14 2025 %Y A383401 Cf. A000005, A000079, A000265, A001227, A027750, A065091, A174090. %K A383401 nonn,easy %O A383401 1,3 %A A383401 _Omar E. Pol_, May 14 2025