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 21-30 of 48 results. Next

A109810 Number of permutations of the positive divisors of n, where every element is coprime to its adjacent elements.

Original entry on oeis.org

1, 2, 2, 2, 2, 4, 2, 0, 2, 4, 2, 0, 2, 4, 4, 0, 2, 0, 2, 0, 4, 4, 2, 0, 2, 4, 0, 0, 2, 0, 2, 0, 4, 4, 4, 0, 2, 4, 4, 0, 2, 0, 2, 0, 0, 4, 2, 0, 2, 0, 4, 0, 2, 0, 4, 0, 4, 4, 2, 0, 2, 4, 0, 0, 4, 0, 2, 0, 4, 0, 2, 0, 2, 4, 0, 0, 4, 0, 2, 0, 0, 4, 2, 0, 4, 4, 4, 0, 2, 0, 4, 0, 4, 4, 4, 0, 2, 0, 0, 0, 2, 0, 2, 0, 0
Offset: 1

Views

Author

Leroy Quet, Aug 16 2005

Keywords

Comments

Depends only on prime signature. - Reinhard Zumkeller, May 24 2010

Examples

			The divisors of 6 are 1, 2, 3 and 6. Of the permutations of these integers, only (6,1,2,3), (6,1,3,2), (2,3,1,6) and (3,2,1,6) are such that every pair of adjacent elements is coprime.
		

Crossrefs

Cf. A178254. - Reinhard Zumkeller, May 24 2010

Formula

a(1)=1, a(p) = 2, a(p^2) = 2, a(p*q) = 4 (where p and q are distinct primes), all other terms are 0.
a(A033942(n))=0; a(A037143(n))>0; a(A000430(n))=2; a(A006881(n))=4. - Reinhard Zumkeller, May 24 2010

Extensions

Terms 17 to 59 from Diana L. Mecum, Jul 18 2008
More terms from David Wasserman, Oct 01 2008

A284288 Numbers n such that the average of the strong divisors of n is an integer.

Original entry on oeis.org

2, 3, 4, 5, 7, 9, 11, 13, 17, 19, 23, 25, 27, 28, 29, 31, 37, 41, 43, 47, 49, 53, 54, 56, 59, 61, 64, 67, 68, 71, 73, 79, 81, 83, 89, 91, 97, 98, 99, 100, 101, 103, 107, 109, 113, 121, 127, 131, 133, 137, 138, 139, 148, 149, 151, 154, 157, 163, 165, 167, 169, 173, 179, 181, 188, 191, 192, 193, 197, 199
Offset: 1

Views

Author

Ilya Gutkovskiy, Mar 24 2017

Keywords

Comments

We say d is a strong divisor of n iff d is a divisor of n and d > 1.
Numbers n such that A032741(n) divides A039653(n).
All primes and squares of primes are in this sequence.
Positions of ones in A296082 and A296084. - Antti Karttunen, Dec 05 2017

Examples

			28 is in the sequence because 28 has 6 divisors {1, 2, 4, 7, 14, 28} therefore 5 strong divisors {2, 4, 7, 14, 28}, 2 + 4 + 7 + 14 + 28 = 55 and 5 divides 55.
		

Crossrefs

Cf. A000203, A000430, A003601, A023884, A023886, A032741, A039653, A296082, A296084 (characteristic function).

Programs

  • Maple
    filter:= proc(n) local d,t;
      d:= numtheory:-divisors(n) minus {1};
      convert(d,`+`) mod nops(d) = 0
    end proc:
    select(filter, [$2..1000]); # Robert Israel, Mar 27 2017
  • Mathematica
    Select[Range[2, 200], Mod[DivisorSigma[1, #1] - 1, DivisorSigma[0, #1] - 1] == 0 &]
  • PARI
    for(n=2, 200, if((sigma(n) - 1)%(numdiv(n) - 1)==0, print1(n,", "))) \\ Indranil Ghosh, Mar 24 2017
    
  • Python
    from sympy.ntheory import divisor_sigma, divisor_count
    print([n for n in range(2, 201) if (divisor_sigma(n) - 1)%(divisor_count(n) - 1) == 0]) # Indranil Ghosh, Mar 24 2017

A087797 Primes, squares of primes and cubes of primes.

Original entry on oeis.org

2, 3, 4, 5, 7, 8, 9, 11, 13, 17, 19, 23, 25, 27, 29, 31, 37, 41, 43, 47, 49, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 121, 125, 127, 131, 137, 139, 149, 151, 157, 163, 167, 169, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241
Offset: 1

Views

Author

Benoit Cloitre, Oct 10 2003

Keywords

Comments

Union of A000040 and A168363. - Chai Wah Wu, Aug 09 2024

Crossrefs

Programs

  • Mathematica
    m=400;Union[Prime[Range[PrimePi[m]]],Prime[Range[PrimePi[m^(1/2)]]]^2,Prime[Range[PrimePi[m^(1/3)]]]^3] (* Vladimir Joseph Stephan Orlovsky, Apr 11 2011 *)
    With[{nn=70},Take[Union[Flatten[{#,#^2,#^3}&/@Prime[Range[nn]]]],nn]] (* Harvey P. Dale, Oct 16 2012 *)
  • PARI
    is(n)=my(t=isprimepower(n)); t && t<4 \\ Charles R Greathouse IV, Oct 19 2015
    
  • Python
    from math import isqrt
    from sympy import primepi, integer_nthroot
    def A087797(n):
        def f(x): return n+x-primepi(x)-primepi(isqrt(x))-primepi(integer_nthroot(x,3)[0])
        m, k = n, f(n)
        while m != k:
            m, k = k, f(k)
        return int(m) # Chai Wah Wu, Aug 09 2024

Formula

a(n) ~ n log n. - Charles R Greathouse IV, Oct 19 2015

A088382 Numbers not exceeding the 4th power of their smallest prime factor.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, 61, 63, 65, 67, 69, 71, 73, 75, 77, 79, 81, 83, 85, 89, 91, 95, 97, 101, 103, 107, 109, 113, 115, 119, 121, 125, 127, 131, 133
Offset: 1

Views

Author

Reinhard Zumkeller, Sep 28 2003

Keywords

Comments

a(n) <= A020639(a(n))^4 = A088379(a(n)); complement of A088383;
a(n) < A088383(k) for n <= 67, a(n) > A088383(k) for n > 67.

Crossrefs

Positions of numbers less than 5 in A307908.

Programs

  • Haskell
    a088382 n = a088382_list !! (n-1)
    a088382_list = [x | x <- [1..], x <= a020639 x ^ 4]
    -- Reinhard Zumkeller, Feb 06 2015
  • Mathematica
    Select[Range[200],#<=FactorInteger[#][[1,1]]^4&] (* Harvey P. Dale, Jan 25 2015 *)

A088380 Numbers not exceeding the cube of their smallest prime factor.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 35, 37, 41, 43, 47, 49, 53, 55, 59, 61, 65, 67, 71, 73, 77, 79, 83, 85, 89, 91, 95, 97, 101, 103, 107, 109, 113, 115, 119, 121, 125, 127, 131, 133, 137, 139, 143, 149, 151, 157, 161, 163, 167, 169
Offset: 1

Views

Author

Reinhard Zumkeller, Sep 28 2003

Keywords

Comments

a(n) <= A020639(a(n))^3 = A088378(a(n)); complement of A088381;
a(n) < A088381(k) for n <= 28, a(n) > A088381(k) for n > 28.

Crossrefs

Positions of numbers less than 4 in A307908.

Programs

  • Haskell
    a088380 n = a088382_list !! (n-1)
    a088380_list = [x | x <- [1..], x <= a020639 x ^ 3]
    -- Reinhard Zumkeller, Feb 06 2015
  • Mathematica
    Select[Range[200],#<=FactorInteger[#][[1,1]]^3&] (* Harvey P. Dale, Apr 28 2022 *)

A371734 Maximal length of a factorization of n into factors > 1 all having different sums of prime indices.

Original entry on oeis.org

0, 1, 1, 1, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 2, 2, 1, 2, 1, 2, 2, 2, 1, 2, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 2, 3, 1, 2, 2, 3, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 2, 3, 2, 2, 1, 3, 1, 2, 2, 3, 2, 3, 1, 2, 2, 3, 1, 3, 1, 2, 2, 2, 2, 3, 1, 3, 2, 2, 1, 3, 2, 2, 2, 3, 1, 3, 2, 2, 2, 2, 2, 3, 1, 2, 2, 3, 1, 3, 1, 3, 3
Offset: 1

Views

Author

Gus Wiseman, Apr 13 2024

Keywords

Comments

A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798. Sum of prime indices is given by A056239.
Factorizations into factors > 1 all having different sums of prime indices are counted by A321469.

Examples

			The factorizations of 90 of this type are (2*3*15), (2*5*9), (2*45), (3*30), (5*18), (6*15), (90), so a(90) = 3.
		

Crossrefs

For set partitions of binary indices we have A000120, same sums A371735.
Positions of 1's are A000430.
Positions of terms > 1 are A080257.
Factorizations of this type are counted by A321469, same sums A321455.
For same instead of different sums we have A371733.
A001055 counts factorizations.
A002219 (aerated) counts biquanimous partitions, ranks A357976.
A112798 lists prime indices, reverse A296150, length A001222, sum A056239.
A321451 counts non-quanimous partitions, ranks A321453.
A321452 counts quanimous partitions, ranks A321454.

Programs

  • Mathematica
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&, Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    hwt[n_]:=Total[Cases[FactorInteger[n],{p_,k_}:>PrimePi[p]*k]];
    Table[Max[Length/@Select[facs[n],UnsameQ@@hwt/@#&]],{n,100}]
  • PARI
    A056239(n) = if(1==n, 0, my(f=factor(n)); sum(i=1, #f~, f[i, 2] * primepi(f[i, 1])));
    all_have_different_sum_of_pis(facs) = if(!#facs, 1, (#Set(apply(A056239,facs)) == #facs));
    A371734(n, m=n, facs=List([])) = if(1==n, if(all_have_different_sum_of_pis(facs),#facs,0), my(s=0, newfacs); fordiv(n, d, if((d>1)&&(d<=m), newfacs = List(facs); listput(newfacs,d); s = max(s,A371734(n/d, d, newfacs)))); (s)); \\ Antti Karttunen, Jan 20 2025

Extensions

Data section extended to a(105) by Antti Karttunen, Jan 20 2025

A232175 Least positive k such that n^3 + k^2 is a square, or 0 if there is no such k.

Original entry on oeis.org

0, 1, 3, 6, 10, 3, 21, 8, 36, 15, 55, 6, 78, 35, 15, 48, 136, 27, 171, 10, 42, 99, 253, 10, 300, 143, 81, 42, 406, 15, 465, 64, 88, 255, 35, 63, 666, 323, 91, 3, 820, 21, 903, 55, 66, 483, 1081, 48, 1176, 125, 85, 39, 1378, 81, 165, 28, 76, 783, 1711, 15, 1830, 899, 63
Offset: 1

Views

Author

Alex Ratushnyak, Nov 19 2013

Keywords

Comments

Numbers n such that a(n) = n*(n-1)/2 appear to be A000430.
n = 1 is the only number for which a(n) = 0. - T. D. Noe, Nov 21 2013

Crossrefs

Programs

  • Mathematica
    Join[{0}, Table[k = 1; While[! IntegerQ[Sqrt[n^3 + k^2]], k++]; k, {n, 2, 100}]] (* T. D. Noe, Nov 21 2013 *)
  • PARI
    a(n) = {k = 1; while (!issquare(n^3+k^2), k++); k;} \\ Michel Marcus, Nov 20 2013
  • Python
    import math
    for n in range(77):
       n3 = n*n*n
       y=1
       for k in range(1, 10000001):
         s = n3 + k*k
         r = int(math.sqrt(s))
         if r*r == s:
           print(k, end=', ')
           y=0
           break
       if y: print(end='-, ')
    
  • Python
    from _future_ import division
    from sympy import divisors
    def A232175(n):
        n3 = n**3
        ds = divisors(n3)
        for i in range(len(ds)//2-1,-1,-1):
            x = ds[i]
            y = n3//x
            a, b = divmod(y-x,2)
            if not b:
                return a
        return 0 # Chai Wah Wu, Sep 12 2017
    

A342657 The difference between floor(log_2(.)) of and the number of prime factors in A156552(n) (when counted with multiplicity).

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 2, 0, 3, 1, 1, 0, 2, 0, 3, 1, 3, 0, 3, 0, 4, 1, 3, 0, 2, 0, 3, 3, 5, 1, 1, 0, 7, 3, 3, 0, 4, 0, 5, 2, 5, 0, 4, 0, 2, 4, 6, 0, 3, 1, 5, 5, 7, 0, 4, 0, 9, 3, 2, 3, 4, 0, 6, 7, 4, 0, 3, 0, 10, 2, 7, 1, 5, 0, 5, 1, 11, 0, 3, 3, 11, 5, 3, 0, 2, 1, 8, 7, 11, 4, 4, 0, 3, 3, 3, 0, 5, 0, 7, 2
Offset: 2

Views

Author

Antti Karttunen, Mar 18 2021

Keywords

Crossrefs

Programs

  • PARI
    A156552(n) = {my(f = factor(n), p, p2 = 1, res = 0); for(i = 1, #f~, p = 1 << (primepi(f[i, 1]) - 1); res += (p * p2 * (2^(f[i, 2]) - 1)); p2 <<= f[i, 2]); res};
    A342657(n) = { my(u=A156552(n)); (#binary(u)-bigomega(u))-1; };

Formula

a(n) = (A252464(n)-A342655(n))-1 = (A325134(n)-A342655(n)) - 2.
a(p) = a(p^2) = 0 for all primes p. (Second part added Jul 27 2023)
a(A003961(n)) = a(2*A246277(n)) = a(n).

A381747 a(n) is the number of solutions to tau(x) + tau(n-x) = tau(n) where 1 <= x <= floor(n/2).

Original entry on oeis.org

0, 1, 0, 1, 0, 1, 0, 1, 0, 3, 0, 1, 0, 2, 1, 2, 0, 2, 0, 1, 1, 3, 0, 1, 0, 4, 0, 3, 0, 3, 0, 3, 1, 4, 0, 1, 0, 2, 1, 2, 0, 3, 0, 5, 6, 4, 0, 0, 0, 5, 0, 5, 0, 5, 1, 4, 0, 4, 0, 2, 0, 3, 6, 4, 0, 5, 0, 8, 1, 5, 0, 3, 0, 5, 8, 8, 0, 5, 0, 3, 0, 5, 0, 3, 1, 5, 0, 6
Offset: 1

Views

Author

Felix Huber, Mar 30 2025

Keywords

Comments

Observation: For even positive multiples of 48, k <= 17000, a(k) = 0 only for k = 1*48, 2304 = 48*48 and 3600 = 75*48. The next numbers k which are multiples of 48 and for which a(k) = 0 are 46656, 63504, 233280, 513216, 793152, 2286144, 3111696.

Examples

			a(10) = 3 because tau(x) + tau(10-x) = tau(10) has 3 solutions for 0 <= x <= 5:
  x = 1: tau(1) + tau(9) = 1 + 3 = 4 = tau(10);
  x = 3: tau(3) + tau(7) = 2 + 2 = 4 = tau(10);
  x = 5: tau(5) + tau(5) = 2 + 2 = 4 = tau(10).
		

Crossrefs

Programs

  • Maple
    with(NumberTheory):
    A381747:=proc(n)
        local a,x;
        a:=0;
        for x to n/2 do
            if tau(x)+tau(n-x)=tau(n) then
                a:=a+1
            fi
        od;
        return a
    end proc;
    seq(A381747(n),n=1..88);
  • PARI
    a(n) = my(nd=numdiv(n)); sum(x=1, n\2, numdiv(x)+numdiv(n-x) == nd); \\ Michel Marcus, Apr 26 2025

Formula

a(A000430(n)) = 0 for n > 3.

A385378 The maximum possible number of distinct factors in the factorization of n into prime powers (A246655).

Original entry on oeis.org

0, 1, 1, 1, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 2, 2, 1, 2, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 2, 2, 1, 2, 2, 3, 1, 3, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 3, 2, 3, 2, 2, 1, 3, 1, 2, 2, 3, 2, 3, 1, 2, 2, 3, 1, 3, 1, 2, 2, 2, 2, 3, 1, 3, 2, 2, 1, 3, 2, 2, 2
Offset: 1

Views

Author

Amiram Eldar, Jun 27 2025

Keywords

Comments

Differs from A376885 and A384422 at n = 32, 64, 96, 128, 160, 192, ... .
Differs from A086435 at n = 36, 100, 144, 180, 196, 225, ... .
Differs from A375272 at n = 128, 384, 640, 896, 1024, 1152, ... .
a(n) depends only on the prime signature of n (A118914).
The indices of records in this sequence are the partial products of the sequence of powers of primes (A000961), i.e., the terms in A024923.
The least index n such that a(n) = k, for k = 0, 1, 2, ..., is A024923(k+1).

Examples

			      n | a(n) | factorization
  ------+------+--------------------------------
      2 |  1   | 2
      6 |  2   | 2 * 3
     24 |  3   | 2 * 3 * 2^2
    120 |  4   | 2 * 3 * 2^2 * 5
    840 |  5   | 2 * 3 * 2^2 * 5 * 7
   6720 |  6   | 2 * 3 * 2^2 * 5 * 7 * 2^3
  60480 |  7   | 2 * 3 * 2^2 * 5 * 7 * 2^3 * 3^2
		

Crossrefs

Programs

  • Mathematica
    f[p_, e_] := Floor[(Sqrt[8*e + 1] - 1)/2]; a[1] = 0; a[n_] := Plus @@ f @@@ FactorInteger[n]; Array[a, 100]
  • PARI
    a(n) = vecsum(apply(x -> (sqrtint(8*x+1)-1)\2 , factor(n)[, 2]));

Formula

Additive with a(p^e) = A003056(e).
a(n) >= A001221(n), with equality if and only if n is cubefree (A004709).
a(n) >= 1 for n >= 2, with equality if and only if n is a prime or a square of a prime (A000430).
Sum_{k=1..n} a(k) ~ n * (log(log(n)) + B + C), where B is Mertens's constant (A077761), C = Sum_{k>=2} P(k*(k+1)/2) = 0.19285739770001405035..., and P is the prime zeta function.
Previous Showing 21-30 of 48 results. Next