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.

A345055 Dirichlet inverse of A011772.

Original entry on oeis.org

1, -3, -2, 2, -4, 9, -6, 0, -4, 20, -10, -16, -12, 29, 11, 0, -16, 16, -18, -43, 18, 49, -22, 18, -8, 60, -2, -43, -28, -89, -30, 0, 29, 80, 34, 1, -36, 89, 36, 71, -40, -136, -42, -96, 27, 109, -46, -18, -12, 8, 47, -123, -52, -19, 70, -25, 54, 140, -58, 326, -60, 149, 21, 0, 71, -201, -66, -128, 65, -264, -70, -140, -72, 180, 16
Offset: 1

Views

Author

Antti Karttunen, Jun 20 2021

Keywords

Crossrefs

Cf. A011772, A345053 (positions of zeros), A345065.
Cf. also A344767.

Programs

  • PARI
    up_to = 16384;
    DirInverseCorrect(v) = { my(u=vector(#v)); u[1] = (1/v[1]); for(n=2, #v, u[n] = (-u[1])*sumdiv(n, d, if(dA011772(n) = { if(n==1, return(1)); my(f=factor(if(n%2, n, 2*n)), step=vecmax(vector(#f~, i, f[i, 1]^f[i, 2]))); forstep(m=step, 2*n, step, if(m*(m-1)/2%n==0, return(m-1)); if(m*(m+1)/2%n==0, return(m))); }; \\ From A011772
    v345055 = DirInverseCorrect(vector(up_to,n,A011772(n)));
    A345055(n) = v345055[n];
    (Python 3.8+)
    from itertools import combinations
    from math import prod
    from sympy import factorint, divisors
    from sympy.ntheory.modular import crt
    def A011772(n):
        plist = [p**q for p, q in factorint(2*n).items()]
        return 2*n-1 if len(plist) == 1 else min(min(crt([m,2*n//m],[0,-1])[0],crt([2*n//m,m],[0,-1])[0]) for m in (prod(d) for l in range(1,len(plist)//2+1) for d in combinations(plist,l)))
    def A345055(n): return 1 if n == 1 else -sum(A011772(n//d)*A345055(d) for d in divisors(n, generator=True) if d < n) # Chai Wah Wu, Jun 20 2021

Formula

a(2^i) = 0 for i >= 3. See A345053. - Chai Wah Wu, Jul 05 2021