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.

Previous Showing 11-12 of 12 results.

A371402 a(n) = gcd(2*n, 4^n)^(2*n + 1) mod (2^(2*n + 1) - 1)^2.

Original entry on oeis.org

0, 8, 63, 128, 1534, 2048, 16383, 32768, 524285, 524288, 4194303, 8388608, 100663294, 134217728, 1073741823, 2147483648, 42949672956, 34359738368, 274877906943, 549755813888, 6597069766654, 8796093022208, 70368744177663, 140737488355328, 2251799813685245
Offset: 0

Views

Author

Peter Luschny, Mar 26 2024

Keywords

Crossrefs

Programs

  • Maple
    a := n -> modp(igcd(2*n, 4^n)^(2*n + 1), (2^(2*n + 1) - 1)^2):
    seq(a(n), n = 0..19);
  • PARI
    a(n) = lift(Mod(gcd(2*n, 4^n),(2^(2*n + 1) - 1)^2)^(2*n + 1)); \\ Michel Marcus, Mar 27 2024
    
  • Python
    def A371402(n): return ((~n & n-1).bit_length()+2<<(n<<1) if n&1 else ((m:=(~n & n-1).bit_length())+1<<(n<<1)+1)-m) if n else 0 # Chai Wah Wu, Mar 27 2024
  • SageMath
    def v2(n): return valuation(2*n, 2)
    def a(n):
        if n == 0: return 0
        return 4^n*(v2(n) + 1) if n % 2 else 2*4^n*v2(n) - v2(n//2)
    print([a(n) for n in range(0, 25)])
    

Formula

a(2*n) = 2*4^(2*n)*A001511(2*n) - A001511(n) for n >= 1.
a(2*n+1) = 4^(2*n + 1)*(A001511(2*n + 1) + 1) for n >= 1.

A327727 Expansion of Product_{i>=1, j>=0} (1 + x^(i*2^j)) / (1 - x^(i*2^j)).

Original entry on oeis.org

1, 2, 6, 12, 28, 52, 104, 184, 340, 578, 1004, 1652, 2752, 4404, 7088, 11080, 17362, 26592, 40730, 61284, 92096, 136408, 201608, 294456, 428952, 618658, 889684, 1268624, 1803520, 2545164, 3580784, 5005584, 6976046, 9667164, 13356364, 18360368, 25165732
Offset: 0

Views

Author

Ilya Gutkovskiy, Sep 23 2019

Keywords

Comments

Convolution of the sequences A000041 and A092119.

Crossrefs

Programs

  • Mathematica
    nmax = 36; CoefficientList[Series[Product[1/(1 - x^k)^(IntegerExponent[2 k, 2] + 1), {k, 1, nmax}], {x, 0, nmax}], x]
    a[n_] := a[n] = If[n == 0, 1, Sum[Sum[d (IntegerExponent[2 d, 2] + 1), {d, Divisors[k]}] a[n - k], {k, 1, n}]/n]; Table[a[n], {n, 0, 36}]
  • PARI
    seq(n)={Vec(1/prod(k=1, n, (1 - x^k + O(x*x^n))^(2+valuation(k, 2))))} \\ Andrew Howroyd, Sep 23 2019

Formula

G.f.: Product_{k>=1} ((1 + x^k) / (1 - x^k))^A001511(k).
G.f.: Product_{k>=1} 1 / (1 - x^k)^(A001511(k) + 1).
Previous Showing 11-12 of 12 results.