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.

Showing 1-10 of 136 results. Next

A137322 a(n) = k! - A051674(n), where k is the smallest number for which A051674(n) <= k! where A051674(n) = prime(n)^prime(n).

Original entry on oeis.org

2, 93, 1915, 2805257, 1022362697389, 52812321503747, 296760465891270915823, 13532790387670672394876021, 244372391812343146601953447089433, 11196066938065133911754151366849886273516531, 3328707950474207400029638710843582600755265569
Offset: 1

Views

Author

Ctibor O. Zizka, Apr 06 2008

Keywords

Examples

			a(4) = 10! - prime(4)^prime(4) = 3628800 - 823543 = 2805257.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := Module[{p = Prime[n]^Prime[n], k = 1}, While[k! < p, k++]; k! - p]; Array[a, 11] (* Amiram Eldar, Mar 12 2022 *)
  • PARI
    f(n) = my(p = prime(n)); p^p;
    a(n) = my(k=1, P=f(n)); until(k! >= P, k++); k!-P; \\ Michel Marcus, Mar 12 2022

Extensions

Corrected and extended by Michel Marcus, Mar 12 2022

A003415 a(n) = n' = arithmetic derivative of n: a(0) = a(1) = 0, a(prime) = 1, a(m*n) = m*a(n) + n*a(m).

Original entry on oeis.org

0, 0, 1, 1, 4, 1, 5, 1, 12, 6, 7, 1, 16, 1, 9, 8, 32, 1, 21, 1, 24, 10, 13, 1, 44, 10, 15, 27, 32, 1, 31, 1, 80, 14, 19, 12, 60, 1, 21, 16, 68, 1, 41, 1, 48, 39, 25, 1, 112, 14, 45, 20, 56, 1, 81, 16, 92, 22, 31, 1, 92, 1, 33, 51, 192, 18, 61, 1, 72, 26, 59, 1, 156, 1, 39, 55, 80, 18, 71
Offset: 0

Views

Author

Keywords

Comments

Can be extended to negative numbers by defining a(-n) = -a(n).
Based on the product rule for differentiation of functions: for functions f(x) and g(x), (fg)' = f'g + fg'. So with numbers, (ab)' = a'b + ab'. This implies 1' = 0. - Kerry Mitchell, Mar 18 2004
The derivative of a number x with respect to a prime number p as being the number "dx/dp" = (x-x^p)/p, which is an integer due to Fermat's little theorem. - Alexandru Buium, Mar 18 2004
The relation (ab)' = a'b + ab' implies 1' = 0, but it does not imply p' = 1 for p a prime. In fact, any function f defined on the primes can be extended uniquely to a function on the integers satisfying this relation: f(Product_i p_i^e_i) = (Product_i p_i^e_i) * (Sum_i e_i*f(p_i)/p_i). - Franklin T. Adams-Watters, Nov 07 2006
See A131116 and A131117 for record values and where they occur. - Reinhard Zumkeller, Jun 17 2007
Let n be the product of a multiset P of k primes. Consider the k-dimensional box whose edges are the elements of P. Then the (k-1)-dimensional surface of this box is 2*a(n). For example, 2*a(25) = 20, the perimeter of a 5 X 5 square. Similarly, 2*a(18) = 42, the surface area of a 2 X 3 X 3 box. - David W. Wilson, Mar 11 2011
The arithmetic derivative n' was introduced, probably for the first time, by the Spanish mathematician José Mingot Shelly in June 1911 with "Una cuestión de la teoría de los números", work presented at the "Tercer Congreso Nacional para el Progreso de las Ciencias, Granada", cf. link to the abstract on Zentralblatt MATH, and L. E. Dickson, History of the Theory of Numbers. - Giorgio Balzarotti, Oct 19 2013
a(A235991(n)) odd; a(A235992(n)) even. - Reinhard Zumkeller, Mar 11 2014
Sequence A157037 lists numbers with prime arithmetic derivative, i.e., indices of primes in this sequence. - M. F. Hasler, Apr 07 2015
Maybe the simplest "natural extension" of the arithmetic derivative, in the spirit of the above remark by Franklin T. Adams-Watters (2006), is the "pi based" version where f(p) = primepi(p), see sequence A258851. When f is chosen to be the identity map (on primes), one gets A066959. - M. F. Hasler, Jul 13 2015
When n is composite, it appears that a(n) has lower bound 2*sqrt(n), with equality when n is the square of a prime, and a(n) has upper bound (n/2)*log_2(n), with equality when n is a power of 2. - Daniel Forgues, Jun 22 2016
If n = p1*p2*p3*... where p1, p2, p3, ... are all the prime factors of n (not necessarily distinct), and h is a real number (we assume h nonnegative and < 1), the arithmetic derivative of n is equivalent to n' = lim_{h->0} ((p1+h)*(p2+h)*(p3+h)*... - (p1*p2*p3*...))/h. It also follows that the arithmetic derivative of a prime is 1. We could assume h = 1/N, where N is an integer; then the limit becomes {N -> oo}. Note that n = 1 is not a prime and plays the role of constant. - Giorgio Balzarotti, May 01 2023

Examples

			6' = (2*3)' = 2'*3 + 2*3' = 1*3 + 2*1 = 5.
Note that, for example, 2' + 3' = 1 + 1 = 2, (2+3)' = 5' = 1. So ' is not linear.
G.f. = x^2 + x^3 + 4*x^4 + x^5 + 5*x^6 + x^7 + 12*x^8 + 6*x^9 + 7*x^10 + ...
		

References

  • G. Balzarotti, P. P. Lava, La derivata aritmetica, Editore U. Hoepli, Milano, 2013.
  • E. J. Barbeau, Problem, Canad. Math. Congress Notes, 5 (No. 8, April 1973), 6-7.
  • L. E. Dickson, History of the Theory of Numbers, Vol. 1, Chapter XIX, p. 451, Dover Edition, 2005. (Work originally published in 1919.)
  • A. M. Gleason et al., The William Lowell Putnam Mathematical Competition: Problems and Solutions 1938-1964, Math. Assoc. America, 1980, p. 295.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A086134 (least prime factor of n').
Cf. A086131 (greatest prime factor of n').
Cf. A068719 (derivative of 2n).
Cf. A068720 (derivative of n^2).
Cf. A068721 (derivative of n^3).
Cf. A001787 (derivative of 2^n).
Cf. A027471 (derivative of 3^(n-1)).
Cf. A085708 (derivative of 10^n).
Cf. A068327 (derivative of n^n).
Cf. A024451 (derivative of p#).
Cf. A068237 (numerator of derivative of 1/n).
Cf. A068238 (denominator of derivative of 1/n).
Cf. A068328 (derivative of squarefree numbers).
Cf. A068311 (derivative of n!).
Cf. A168386 (derivative of n!!).
Cf. A260619 (derivative of hyperfactorial(n)).
Cf. A260620 (derivative of superfactorial(n)).
Cf. A068312 (derivative of triangular numbers).
Cf. A068329 (derivative of Fibonacci(n)).
Cf. A096371 (derivative of partition number).
Cf. A099301 (derivative of d(n)).
Cf. A099310 (derivative of phi(n)).
Cf. A342925 (derivative of sigma(n)).
Cf. A349905 (derivative of prime shift).
Cf. A327860 (derivative of primorial base exp-function).
Cf. A369252 (derivative of products of three odd primes), A369251 (same sorted).
Cf. A068346 (second derivative of n).
Cf. A099306 (third derivative of n).
Cf. A258644 (fourth derivative of n).
Cf. A258645 (fifth derivative of n).
Cf. A258646 (sixth derivative of n).
Cf. A258647 (seventh derivative of n).
Cf. A258648 (eighth derivative of n).
Cf. A258649 (ninth derivative of n).
Cf. A258650 (tenth derivative of n).
Cf. A185232 (n-th derivative of n).
Cf. A258651 (A(n,k) = k-th arithmetic derivative of n).
Cf. A085731 (gcd(n,n')), A083345 (n'/gcd(n,n')), A057521 (gcd(n, (n')^k) for k>1).
Cf. A342014 (n' mod n), A369049 (n mod n').
Cf. A341998 (A003557(n')), A342001 (n'/A003557(n)).
Cf. A098699 (least x such that x' = n, antiderivative of n).
Cf. A098700 (n such that x' = n has no integer solution).
Cf. A099302 (number of solutions to x' = n).
Cf. A099303 (greatest x such that x' = n).
Cf. A051674 (n such that n' = n).
Cf. A083347 (n such that n' < n).
Cf. A083348 (n such that n' > n).
Cf. A099304 (least k such that (n+k)' = n' + k').
Cf. A099305 (number of solutions to (n+k)' = n' + k').
Cf. A328235 (least k > 0 such that (n+k)' = u * n' for some natural number u).
Cf. A328236 (least m > 1 such that (m*n)' = u * n' for some natural number u).
Cf. A099307 (least k such that the k-th arithmetic derivative of n is zero).
Cf. A099308 (k-th arithmetic derivative of n is zero for some k).
Cf. A099309 (k-th arithmetic derivative of n is nonzero for all k).
Cf. A129150 (n-th derivative of 2^3).
Cf. A129151 (n-th derivative of 3^4).
Cf. A129152 (n-th derivative of 5^6).
Cf. A189481 (x' = n has a unique solution).
Cf. A190121 (partial sums).
Cf. A258057 (first differences).
Cf. A229501 (n divides the n-th partial sum).
Cf. A165560 (parity).
Cf. A235991 (n' is odd), A235992 (n' is even).
Cf. A327863, A327864, A327865 (n' is a multiple of 3, 4, 5).
Cf. A157037 (n' is prime), A192192 (n'' is prime), A328239 (n''' is prime).
Cf. A328393 (n' is squarefree), A328234 (squarefree and > 1).
Cf. A328244 (n'' is squarefree), A328246 (n''' is squarefree).
Cf. A328303 (n' is not squarefree), A328252 (n' is squarefree, but n is not).
Cf. A328248 (least k such that the (k-1)-th derivative of n is squarefree).
Cf. A328251 (k-th arithmetic derivative is never squarefree for any k >= 0).
Cf. A256750 (least k such that the k-th derivative is either 0 or has a factor p^p).
Cf. A327928 (number of distinct primes p such that p^p divides n').
Cf. A342003 (max. exponent k for any prime power p^k that divides n').
Cf. A327929 (n' has at least one divisor of the form p^p).
Cf. A327978 (n' is primorial number > 1).
Cf. A328243 (n' is a partial sum of primorial numbers and larger than one).
Cf. A328310 (maximal prime exponent of n' minus maximal prime exponent of n).
Cf. A328320 (max. prime exponent of n' is less than that of n).
Cf. A328321 (max. prime exponent of n' is >= that of n).
Cf. A328383 (least k such that the k-th derivative of n is either a multiple or a divisor of n, but not both).
Cf. A263111 (the ordinal transform of a).
Cf. A300251, A319684 (Möbius and inverse Möbius transform).
Cf. A305809 (Dirichlet convolution square).
Cf. A349133, A349173, A349394, A349380, A349618, A349619, A349620, A349621 (for miscellaneous Dirichlet convolutions).
Cf. A069359 (similar formula which agrees on squarefree numbers).
Cf. A258851 (the pi-based arithmetic derivative of n).
Cf. A328768, A328769 (primorial-based arithmetic derivatives of n).
Cf. A328845, A328846 (Fibonacci-based arithmetic derivatives of n).
Cf. A302055, A327963, A327965, A328099 (for other variants and modifications).
Cf. A038554 (another sequence using "derivative" in its name, but involving binary expansion of n).
Cf. A322582, A348507 (lower and upper bounds), also A002620.

Programs

  • GAP
    A003415:= Concatenation([0,0],List(List([2..10^3],Factors),
    i->Product(i)*Sum(i,j->1/j))); # Muniru A Asiru, Aug 31 2017
    (APL, Dyalog dialect) A003415 ← { ⍺←(0 1 2) ⋄ ⍵≤1:⊃⍺ ⋄ 0=(3⊃⍺)|⍵:((⊃⍺+(2⊃⍺)×(⍵÷3⊃⍺)) ((2⊃⍺)×(3⊃⍺)) (3⊃⍺)) ∇ ⍵÷3⊃⍺ ⋄ ((⊃⍺) (2⊃⍺) (1+(3⊃⍺))) ∇ ⍵} ⍝ Antti Karttunen, Feb 18 2024
  • Haskell
    a003415 0 = 0
    a003415 n = ad n a000040_list where
      ad 1 _             = 0
      ad n ps'@(p:ps)
         | n < p * p     = 1
         | r > 0         = ad n ps
         | otherwise     = n' + p * ad n' ps' where
           (n',r) = divMod n p
    -- Reinhard Zumkeller, May 09 2011
    
  • Magma
    Ad:=func; [n le 1 select 0 else Ad(n): n in [0..80]]; // Bruno Berselli, Oct 22 2013
    
  • Maple
    A003415 := proc(n) local B,m,i,t1,t2,t3; B := 1000000000039; if n<=1 then RETURN(0); fi; if isprime(n) then RETURN(1); fi; t1 := ifactor(B*n); m := nops(t1); t2 := 0; for i from 1 to m do t3 := op(i,t1); if nops(t3) = 1 then t2 := t2+1/op(t3); else t2 := t2+op(2,t3)/op(op(1,t3)); fi od: t2 := t2-1/B; n*t2; end;
    A003415 := proc(n)
            local a,f;
            a := 0 ;
            for f in ifactors(n)[2] do
                    a := a+ op(2,f)/op(1,f);
            end do;
            n*a ;
    end proc: # R. J. Mathar, Apr 05 2012
  • Mathematica
    a[ n_] := If[ Abs @ n < 2, 0, n Total[ #2 / #1 & @@@ FactorInteger[ Abs @ n]]]; (* Michael Somos, Apr 12 2011 *)
    dn[0] = 0; dn[1] = 0; dn[n_?Negative] := -dn[-n]; dn[n_] := Module[{f = Transpose[FactorInteger[n]]}, If[PrimeQ[n], 1, Total[n*f[[2]]/f[[1]]]]]; Table[dn[n], {n, 0, 100}] (* T. D. Noe, Sep 28 2012 *)
  • PARI
    A003415(n) = {local(fac);if(n<1,0,fac=factor(n);sum(i=1,matsize(fac)[1],n*fac[i,2]/fac[i,1]))} /* Michael B. Porter, Nov 25 2009 */
    
  • PARI
    apply( A003415(n)=vecsum([n/f[1]*f[2]|f<-factor(n+!n)~]), [0..99]) \\ M. F. Hasler, Sep 25 2013, updated Nov 27 2019
    
  • PARI
    A003415(n) = { my(s=0, m=1, spf); while(n>1, spf = A020639(n); n /= spf; s += m*n; m *= spf); (s); }; \\ Antti Karttunen, Mar 10 2021
    
  • PARI
    a(n) = my(f=factor(n), r=[1/(e+!e)|e<-f[,1]], c=f[,2]); n*r*c; \\ Ruud H.G. van Tol, Sep 03 2023
    
  • Python
    from sympy import factorint
    def A003415(n):
        return sum([int(n*e/p) for p,e in factorint(n).items()]) if n > 1 else 0
    # Chai Wah Wu, Aug 21 2014
    
  • Sage
    def A003415(n):
        F = [] if n == 0 else factor(n)
        return n * sum(g / f for f, g in F)
    [A003415(n) for n in range(79)] # Peter Luschny, Aug 23 2014
    

Formula

If n = Product p_i^e_i, a(n) = n * Sum (e_i/p_i).
a(m*p^p) = (m + a(m))*p^p, p prime: a(m*A051674(k))=A129283(m)*A051674(k). - Reinhard Zumkeller, Apr 07 2007
For n > 1: a(n) = a(A032742(n)) * A020639(n) + A032742(n). - Reinhard Zumkeller, May 09 2011
a(n) = n * Sum_{p|n} v_p(n)/p, where v_p(n) is the largest power of the prime p dividing n. - Wesley Ivan Hurt, Jul 12 2015
For n >= 2, Sum_{k=2..n} floor(1/a(k)) = pi(n) = A000720(n) (see K. T. Atanassov article). - Ivan N. Ianakiev, Mar 22 2019
From A.H.M. Smeets, Jan 17 2020: (Start)
Limit_{n -> oo} (1/n^2)*Sum_{i=1..n} a(i) = A136141/2.
Limit_{n -> oo} (1/n)*Sum_{i=1..n} a(i)/i = A136141.
a(n) = n if and only if n = p^p, where p is a prime number. (End)
Dirichlet g.f.: zeta(s-1)*Sum_{p prime} 1/(p^s-p), see A136141 (s=2), A369632 (s=3) [Haukkanen, Merikoski and Tossavainen]. - Sebastian Karlsson, Nov 25 2021
From Antti Karttunen, Nov 25 2021: (Start)
a(n) = Sum_{d|n} d * A349394(n/d).
For all n >= 1, A322582(n) <= a(n) <= A348507(n).
If n is not a prime, then a(n) >= 2*sqrt(n), or in other words, for all k >= 1 for which A002620(n)+k is not a prime, we have a(A002620(n)+k) > n. [See Ufnarovski and Åhlander, Theorem 9, point (3).]
(End)

Extensions

More terms from Michel ten Voorde, Apr 11 2001

A048103 Numbers not divisible by p^p for any prime p.

Original entry on oeis.org

1, 2, 3, 5, 6, 7, 9, 10, 11, 13, 14, 15, 17, 18, 19, 21, 22, 23, 25, 26, 29, 30, 31, 33, 34, 35, 37, 38, 39, 41, 42, 43, 45, 46, 47, 49, 50, 51, 53, 55, 57, 58, 59, 61, 62, 63, 65, 66, 67, 69, 70, 71, 73, 74, 75, 77, 78, 79, 82, 83, 85, 86, 87, 89, 90, 91, 93, 94, 95, 97, 98
Offset: 1

Views

Author

Keywords

Comments

If a(n) = Product p_i^e_i then p_i > e_i for all i.
Complement of A100716; A129251(a(n)) = 0. - Reinhard Zumkeller, Apr 07 2007
Density is 0.72199023441955... = Product_{p>=2} (1 - p^-p) where p runs over the primes. - Charles R Greathouse IV, Jan 25 2012
A027748(a(n),k) <= A124010(a(n),k), 1<=k<=A001221(a(n)). - Reinhard Zumkeller, Apr 28 2012
Range of A276086. Also numbers not divisible by m^m for any natural number m > 1. - Antti Karttunen, Nov 18 2024

Examples

			6 = 2^1 * 3^1 is OK but 12 = 2^2 * 3^1 is not.
625 = 5^4 is present because it is not divisible by 5^5.
		

Crossrefs

Complement: A100716.
Positions of 0's in A129251, A342023, A376418, positions of 1's in A327936, A342007, A359550 (characteristic function).
Cf. A048102, A048104, A051674 (p^p), A054743, A054744, A377982 (a left inverse, partial sums of char. fun, see also A328402).
Cf. A276086 (permutation of this sequence, see also A376411, A376413).
Subsequences: A002110, A005117, A006862, A024451 (after its initial 0), A057588, A099308 (after its initial 0), A276092, A328387, A328832, A359547, A370114, A371083, A373848, A377871, A377992.
Disjoint union of {1}, A327934 and A358215.
Also A276078 is a subsequence, from which this differs for the first time at n=451 where a(451)=625, while that value is missing from A276078.

Programs

  • Haskell
    a048103 n = a048103_list !! (n-1)
    a048103_list = filter (\x -> and $
       zipWith (>) (a027748_row x) (map toInteger $ a124010_row x)) [1..]
    -- Reinhard Zumkeller, Apr 28 2012
    
  • Mathematica
    {1}~Join~Select[Range@ 120, Times @@ Boole@ Map[First@ # > Last@ # &, FactorInteger@ #] > 0 &] (* Michael De Vlieger, Aug 19 2016 *)
  • PARI
    isok(n) = my(f=factor(n)); for (i=1, #f~, if (f[i,1] <= f[i,2], return(0))); return(1); \\ Michel Marcus, Nov 13 2020
    
  • PARI
    A359550(n) = { my(pp); forprime(p=2, , pp = p^p; if(!(n%pp), return(0)); if(pp > n, return(1))); }; \\ (A359550 is the characteristic function for A048103) - Antti Karttunen, Nov 18 2024
    
  • Python
    from itertools import count, islice
    from sympy import factorint
    def A048103_gen(startvalue=1): # generator of terms >= startvalue
        return filter(lambda n:all(map(lambda d:d[1]A048103_list = list(islice(A048103_gen(),30)) # Chai Wah Wu, Jan 05 2023
  • Scheme
    ;; With Antti Karttunen's IntSeq-library.
    (define A048103 (ZERO-POS 1 1 A129251))
    ;; Antti Karttunen, Aug 18 2016
    

Formula

a(n) ~ kn with k = 1/Product_{p>=2}(1 - p^-p) = Product_{p>=2}(1 + 1/(p^p - 1)) = 1.3850602852..., where the product is over all primes p. - Charles R Greathouse IV, Jan 25 2012
For n >= 1, A377982(a(n)) = n. - Antti Karttunen, Nov 18 2024

Extensions

More terms from James Sellers, Apr 22 2000

A062457 a(n) = prime(n)^n.

Original entry on oeis.org

2, 9, 125, 2401, 161051, 4826809, 410338673, 16983563041, 1801152661463, 420707233300201, 25408476896404831, 6582952005840035281, 925103102315013629321, 73885357344138503765449, 12063348350820368238715343, 3876269050118516845397872321
Offset: 1

Views

Author

Labos Elemer, Jul 09 2001

Keywords

Comments

Heinz numbers of square integer partitions, where the Heinz number of an integer partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k). - Gus Wiseman, Apr 14 2018
Main diagonal of A182944. - Omar E. Pol, Sep 12 2018
Second diagonal of A319075. - Omar E. Pol, Sep 13 2018

Crossrefs

Programs

Formula

a(n) = A062006(n) - 1. - Wesley Ivan Hurt, Jan 18 2016
From Amiram Eldar, Nov 16 2020: (Start)
Sum_{n>=1} 1/a(n) = A093358.
Sum_{n>=1} (-1)^(n+1)/a(n) = A201614. (End)

A129251 Number of distinct prime factors p of n such that p^p is a divisor of n.

Original entry on oeis.org

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

Views

Author

Reinhard Zumkeller, Apr 07 2007

Keywords

Comments

Average value is A094289 = 0.28735...; attains record values on A076265, in particular a(A076265(n)) = n.

Examples

			Since 15 = 3^1 * 5^1, a(15) = 0. But 16 = 2^4 is divisible by 2^2, so a(16) = 1. - _Michael B. Porter_, Aug 18 2016
		

Crossrefs

Cf. A048103 (indices of zeros), A100716 (nonzeros).
Differs from A276077 for the first time at n=625, where a(625) = 0, while A276077(625) = 1.

Programs

Formula

a(A048103(n)) = 0, a(A100716(n)) > 0.
a(n) << sqrt(log n)/log log n. - Charles R Greathouse IV, Sep 14 2015
From Antti Karttunen, Aug 18 2016: (Start)
These formulas use Iverson bracket, which gives 1 as its value if the condition given inside [ ] is true and 0 otherwise:
a(1) = 0, for n > 1, a(n) = a(A028234(n)) + [A067029(n) >= A020639(n)].
Or, for n > 1, a(n) = a(A028234(n)) + [0 = n mod (A020639(n)^A020639(n))]. (End)
a(n) = Sum_{d|n} [rad(d) = Omega(d)*[omega(d) = 1]], where [ ] is the Iverson bracket. - Wesley Ivan Hurt, Feb 09 2022
Additive with a(p^e) = 1 if e >= p, and 0 otherwise. - Amiram Eldar, Nov 07 2022

Extensions

Data section filled up to 120 terms by Antti Karttunen, Aug 18 2016

A100716 Numbers k such that p^p divides k for some prime p.

Original entry on oeis.org

4, 8, 12, 16, 20, 24, 27, 28, 32, 36, 40, 44, 48, 52, 54, 56, 60, 64, 68, 72, 76, 80, 81, 84, 88, 92, 96, 100, 104, 108, 112, 116, 120, 124, 128, 132, 135, 136, 140, 144, 148, 152, 156, 160, 162, 164, 168, 172, 176, 180, 184, 188, 189, 192, 196, 200, 204, 208, 212
Offset: 1

Views

Author

Leroy Quet, Dec 10 2004

Keywords

Comments

Complement of A048103; A129251(a(n)) > 0; A051674 is a subsequence; A129254 = (terms a(k) such that a(k+1)=a(k)+1). - Reinhard Zumkeller, Apr 07 2007
A027748(a(n),k) <= A124010(a(n),k) for some k<=A001221(a(n)). - Reinhard Zumkeller, Apr 28 2012

Examples

			54 is included because 3^3 divides 54.
		

Crossrefs

Complement: A048103.
Positions of nonzeros in A129251.
Cf. A054744.
Cf. A051674 (a subsequence).
Subsequence of A276079 from which it differs for the first time at n=175, where a(175) = 628, while A276079(175) = 625, a value missing from here.

Programs

  • Haskell
    a100716 n = a100716_list !! (n-1)
    a100716_list = filter (\x -> or $
       zipWith (<=) (a027748_row x) (map toInteger $ a124010_row x)) [1..]
    -- Reinhard Zumkeller, Apr 28 2012
    (Scheme, with Antti Karttunen's IntSeq-library)
    (define A100716 (NONZERO-POS 1 1 A129251))
    ;; Antti Karttunen, Aug 18 2016
    
  • Mathematica
    fQ[n_] := Union[ Table[ #[[1]] <= #[[2]]] & /@ FactorInteger[n]][[ -1]] == True; Select[ Range[2, 215], fQ[ # ] &] (* Robert G. Wilson v, Dec 14 2004 *)
    f[n_] := Module[{aux=FactorInteger[n]}, Last@Union@Table[aux[[i,1]] <=  aux[[i,2]], {i,Length[aux]}] == True]; Select[Range[2,215], f] (* José María Grau Ribas, Jan 25 2012 *)
    Rest@ Select[Range@ 216, Times @@ Boole@ Map[First@ # > Last@ # &, FactorInteger@ #] == 0 &] (* Michael De Vlieger, Aug 19 2016 *)
  • PARI
    is(n)=forprime(p=2,default(primelimit),if(n%p^p==0,return(1));if(p^p>n,return(0))) \\ Charles R Greathouse IV, Jan 24 2012
    
  • Python
    from itertools import count, islice
    from sympy import factorint
    def A100716_gen(startvalue=1): # generator of terms >= startvalue
        return filter(lambda n:any(map(lambda d:d[1]>=d[0],factorint(n).items())),count(max(startvalue,1)))
    A100716_list = list(islice(A100716_gen(),30)) # Chai Wah Wu, Jan 05 2023

Formula

a(n) ~ k*n with k = 1/(1 - Product(1 - p^-p)) = 3.5969959469... where the product is over all primes p. - Charles R Greathouse IV, Jan 24 2012

Extensions

More terms from Robert G. Wilson v, Dec 14 2004

A054640 a(n) is the sum of the divisors of the n-th primorial: a(n) = A000203(A002110(n)).

Original entry on oeis.org

1, 3, 12, 72, 576, 6912, 96768, 1741824, 34836480, 836075520, 25082265600, 802632499200, 30500034969600, 1281001468723200, 56364064623820800, 2705475101943398400, 146095655504943513600, 8765739330296610816000, 543475838478389870592000, 36956357016530511200256000
Offset: 0

Views

Author

Labos Elemer, May 15 2000

Keywords

Crossrefs

Programs

  • Magma
    [1/2*&*[(1+NthPrime(k)): k in [0..n-1]]: n in [1..19]]; // Vincenzo Librandi, May 08 2017
    
  • Maple
    a:= n-> mul(1+ithprime(j), j=1..n): seq(a(n), n=0..20); # Zerinvary Lajos, Aug 24 2008
  • Mathematica
    Table[Product[1 + Prime[i], {i,n-1}], {n,100}] (* Geoffrey Critzer, Dec 01 2014 *)
  • PARI
    a(n)=prod(i=1,n,prime(i)+1) \\ Charles R Greathouse IV, Feb 13 2013
    
  • SageMath
    def A054640(n): return product(nth_prime(j)+1 for j in range(1,n+1))
    [A054640(n) for n in range(41)] # G. C. Greubel, Aug 05 2024

Formula

a(n+1) = a(n)*(prime(n) + 1) = a(n)*A028815(n) (quotient=n-th prime+1 starting with 2).
a(n) ~ (6/Pi^2) * exp(gamma) * A002110(n) * log(prime(n)) + O(A002110(n)) (Jakimczuk, 2017). - Amiram Eldar, Feb 17 2021
a(n) = a(n-1) * A008864(n). - Flávio V. Fernandes, Mar 20 2021
a(n) = A002110(n) + A074107(n), a(n) <= A070826(1+n) [= A002110(1+n)/2] < A051674(n). - Antti Karttunen, Nov 19 2024

Extensions

a(0)=1 prepended by Alois P. Heinz, Apr 01 2021

A072873 Numbers k such that Sum_i ( e(i)/p(i) ) is an integer, where the prime factorization of k is Product_i ( p(i)^e(i) ).

Original entry on oeis.org

1, 4, 16, 27, 64, 108, 256, 432, 729, 1024, 1728, 2916, 3125, 4096, 6912, 11664, 12500, 16384, 19683, 27648, 46656, 50000, 65536, 78732, 84375, 110592, 186624, 200000, 262144, 314928, 337500, 442368, 531441, 746496, 800000, 823543
Offset: 1

Views

Author

Benoit Cloitre, Jul 28 2002

Keywords

Comments

Also, numbers k such that k divides k', the arithmetic derivative of k. As shown by Ufnarovski and Ahlander, all terms in this sequence have the form Product_{j=1..r} (pj^pj)^ej, where the pj are primes. The quotient k'/k equals Sum_{j=1..r} ej. - T. D. Noe, Jan 04 2006
Multiplicative closure of A051674. - Reinhard Zumkeller, Jan 21 2012
The number of terms < 10^k: 2, 5, 9, 15, 25, 36, 52, 73, 98, 128, 167, 213, 270, 338, 421, 517, 632, 768, 920, 1101, ..., . - Robert G. Wilson v, Jan 19 2016

Examples

			108 is in the sequence because 108 = 2^2*3^3 and 2/2 + 3/3 = 2 is an integer.
		

References

Crossrefs

Programs

  • Haskell
    import Data.Set (empty, fromList, deleteFindMin, union)
    import qualified Data.Set as Set (null)
    a072873 n = a072873_list !! (n-1)
    a072873_list = 1 : h empty [1] a051674_list where
       h s mcs xs'@(x:xs)
        | Set.null s || x < m = h (s `union` fromList (map (* x) mcs)) mcs xs
        | otherwise = m : h (s' `union` fromList (map (* m) $ init (m:mcs)))
                            (m:mcs) xs'
        where (m, s') = deleteFindMin s
    -- Reinhard Zumkeller, Jan 21 2012
    
  • Mathematica
    Select[Range[1000000],IntegerQ[Total[#[[2]]/#[[1]]&/@FactorInteger[#]]]&] (* Harvey P. Dale, Jul 04 2014 *)
    lst = {}; Do[n = 2^e2*3^e3*5^e5*7^e7; If[n < 10^11, AppendTo[lst, n]], {e2, 0, 36, 2}, {e3, 0, 23, 3}, {e5, 0, 15, 5}, {e7, 0, 13, 7}]; Take[ Sort@ lst, 40] (* Robert G. Wilson v, Jan 19 2016 *)
  • PARI
    is(n)=my(f=factor(n)); for(i=1,#f~,if(f[i,2]%f[i,1], return(0))); 1 \\ Charles R Greathouse IV, Oct 28 2014
    
  • Python
    from itertools import count, islice
    from sympy import factorint
    def A072873_gen(startvalue=1): # generator of terms >= startvalue
        return (k for k in count(max(startvalue,1)) if not any(e%p for p, e in factorint(k).items()))
    A072873_list = list(islice(A072873_gen(),20)) # Chai Wah Wu, Sep 15 2023

Formula

A124010(a(n),k) mod A027748(a(n),k) = 0 for k = 1 .. A001221(a(n)). - Reinhard Zumkeller, Jan 21 2012
Sum_{n>=1} 1/a(n) = Product_{p prime} p^p/(p^p-1) = 1.38506028520448917638... - Amiram Eldar, Sep 27 2020

Extensions

More terms from T. D. Noe, Jan 04 2006

A129283 a(n) = (arithmetic derivative of n) + n.

Original entry on oeis.org

0, 1, 3, 4, 8, 6, 11, 8, 20, 15, 17, 12, 28, 14, 23, 23, 48, 18, 39, 20, 44, 31, 35, 24, 68, 35, 41, 54, 60, 30, 61, 32, 112, 47, 53, 47, 96, 38, 59, 55, 108, 42, 83, 44, 92, 84, 71, 48, 160, 63, 95, 71, 108, 54, 135, 71, 148, 79, 89, 60, 152, 62, 95, 114, 256, 83, 127, 68
Offset: 0

Views

Author

Reinhard Zumkeller, Apr 07 2007

Keywords

Crossrefs

Programs

Formula

a(n) = A003415(n) + n.
a(n) = A003415(n*A051674(k)) / A051674(k).
a(A129284(n)) > 1, a(A129285(n)) > 1, a(A129286(n)) > 1.
Sum_{k=1..n} a(k) ~ c * n^2 / 2, where c = 1 + Sum_{p prime} 1/(p*(p-1)) = 1 + A136141 = 1.773156... . - Amiram Eldar, May 14 2025

A327969 The length of a shortest path from n to zero when using the transitions x -> A003415(x) and x -> A276086(x), or -1 if no zero can ever be reached from n.

Original entry on oeis.org

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

Views

Author

Antti Karttunen, Oct 07 2019

Keywords

Comments

The terms of this sequence are currently known only up to n=23, with the value of a(24) still being uncertain. For the tentative values of the later terms, see sequence A328324 which gives upper bounds for these terms, many of which are very likely also exact values for them.
As A051903(A003415(n)) >= A051903(n)-1, it means that it takes always at least A051903(n) steps to a prime if iterating solely with A003415.
Some known values and upper bounds from n=24 onward:
a(24) <= 11.
a(25) = 4.
a(26) = 7.
a(27) <= 22.
a(33) = 4.
a(39) = 4.
a(40) = 5.
a(42) = 3.
a(44) <= 10.
a(45) = 5.
a(46) = 5.
a(48) = 9.
a(49) = 6.
a(50) = 6.
a(55) = 7.
a(74) = 5.
a(77) = 6.
a(80) <= 18.
a(111) = 6.
a(112) = 8.
a(125) <= 9.
a(240) = 7.
a(625) <= 10.
a(875) = 8.
From Antti Karttunen, Feb 20 2022: (Start)
a(2556) <= 20.
a(5005) <= 19.
What is the value of a(128), and is A328324(128) well-defined?
When I created this sequence, I conjectured that by applying two simple arithmetic operations "arithmetic derivative" (A003415) and "primorial base exp-function" (A276086) in some combination, and starting from any positive integer, we could always reach zero (via a prime and 1).
At the first sight it seems almost certain that the conjecture holds, as it is always possible at every step to choose from two options (which very rarely meet, see A351088), leading to an exponentially growing search tree, and also because A276086 always jumps out of any dead-end path with p^p-factors (dead-end from the arithmetic derivative's point of view). However, it should be realized that one can reach the terms of either A157037 or A327978 with a single step of A003415 only from squarefree numbers (or respectively, cubefree numbers that are not multiples of 4, see A328234), and in general, because A003415 decreases the maximal exponent of the prime factorization (A051903) at most by one, if the maximal exponent in the prime factorization of n is large, there is a correspondingly long path to traverse if we take only A003415-steps in the iteration, and any step could always lead with certain probability to a p^p-number. Note that the antiderivatives of primorials with a square factor seem quite rare, see A351029.
And although taking a A276086-step will always land us to a p^p-free number (which a priori is not in the obvious dead-end path of A003415, although of course it might eventually lead to one), it (in most cases) also increases the magnitude of number considerably, that tends to make the escape even harder. Particularly, in the majority of cases A276086 increases the maximal exponent (which in the preimage is A328114, "maximal digit value used when n is written in primorial base"), so there will be even a longer journey down to squarefree numbers when using A003415. See the sequences A351067 and A351071 for the diminishing ratios suggesting rapidly diminishing chances of successfully reaching zero from larger terms of A276086. Also, the asymptotic density of A276156 is zero, even though A351073 may contain a few larger values.
On the other hand, if we could prove that by (for example) continuing upwards with any p^p-path of A003415 we could eventually reach with a near certainty a region of numbers with low values of A328114 (i.e., numbers with smallish digits in primorial base, like A276156), then the situation might change (see also A351089). However, a few empirical runs seemed to indicate otherwise.
For all of the above reasons, I now conjecture that there are natural numbers from which it is not possible to reach zero with any combination of steps. For example 128 or 5^5 = 3125.
(End)

Examples

			Let -A> stand for an application of A003415 and -B> for an application of A276086, then, we have for example:
a(8) = 6 as we have 8 -A>  12 -B>  25 -A> 10 -A>  7 -A> 1 -A> 0, six transitions in total (and there are no shorter paths).
a(15) = 6 as we have 15 -B> 150 -A> 185 -A> 42 -A> 41 -A> 1 -A> 0, six transitions in total (and there are no shorter paths).
a(20) = 7, as 20 -B> 375 -A> 350 -A> 365 -A> 78 -A> 71 -A> 1 -A> 0, and there are no shorter paths.
For n=112, we know that a(112) cannot be larger than eight, as A328099^(8)(112) = 0, so we have a path of length 8 as 112 -A> 240 -B> 77 -A> 18 -A> 21 -A> 10 -A> 7 -A> 1 -A> 0. Checking all 32 combinations of the paths of lengths of 5 starting from 112 shows that none of them or their prefixes ends with a prime, thus there cannot be any shorter path, and indeed a(112) = 8.
a(24) <= 11 as A328099^(11)(24) = 0, i.e., we have 24 -A> 44 -A> 48 -A> 112 -A> 240 -B> 77 -A> 18 -A> 21 -A> 10 -A> 7 -A> 1 -A> 0. On the other hand, 24 -B> 625 -B> 17794411250 -A> 41620434625 -A> 58507928150 -A> 86090357185 -A> 54113940517 -A> 19982203325 -A> 12038411230 -A> 8426887871 -A> 1 -A> 0, thus offering another path of length 11.
		

Crossrefs

Cf. A328324 (a sequence giving upper bounds, computed with restricted search space).
Sequences for whose terms k, value a(k) has a guaranteed constant upper bound: A000040, A002110, A143293, A157037, A192192, A327978, A328232, A328233, A328239, A328240, A328243, A328249, A328313.
Sequences for whose terms k, it is guaranteed that a(k) has finite value > 0, even if not bound by a constant: A099308, A328116.

Programs

  • PARI
    A003415(n) = if(n<=1, 0, my(f=factor(n)); n*sum(i=1, #f~, f[i, 2]/f[i, 1]));
    A276086(n) = { my(m=1, p=2); while(n, m *= (p^(n%p)); n = n\p; p = nextprime(1+p)); (m); };
    A327969(n,searchlim=0) = if(!n,n,my(xs=Set([n]),newxs,a,b,u); for(k=1,oo, print("n=", n, " k=", k, " xs=", xs); newxs=Set([]); for(i=1,#xs,u = xs[i]; a = A003415(u); if(0==a, return(k)); if(isprime(a), return(k+2)); b = A276086(u); if(isprime(b), return(k+1+(u>2))); newxs = setunion([a],newxs); if(!searchlim || (b<=searchlim),newxs = setunion([b],newxs))); xs = newxs));

Formula

a(0) = 0, a(p^p) = 1 + a(A276086(p^p)) for primes p, and for other numbers, a(n) = 1+min(a(A003415(n)), a(A276086(n))).
a(p) = 2 for all primes p.
For all n, a(n) <= A328324(n).
Let A stand the transition x -> A003415(x), and B stand for x -> A276086(x). The following sequences give some constant upper limits, because it is guaranteed that the combination given in brackets (the leftmost A or B is applied first) will always lead to a prime:
For all n, a(A157037(n)) = 3. [A]
For n > 1, a(A002110(n)) = 3. [B]
For all n, a(A192192(n)) <= 4. [AA]
For all n, a(A327978(n)) = 4. [AB]
For all n, a(A328233(n)) <= 4. [BA]
For all n, a(A143293(n)) <= 4. [BB]
For all n, a(A328239(n)) <= 5. [AAA]
For all n, a(A328240(n)) <= 5. [BAA]
For all n, a(A328243(n)) <= 5. [ABB]
For all n, a(A328313(n)) <= 5. [BBB]
For all n, a(A328249(n)) <= 6. [BAAA]
For all k in A046099, a(k) >= 4, and if A328114(k) > 1, then certainly a(k) > 4.
Showing 1-10 of 136 results. Next