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-6 of 6 results.

A038500 Highest power of 3 dividing n.

Original entry on oeis.org

1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 27, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 27, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 81
Offset: 1

Views

Author

Keywords

Comments

To construct the sequence: start with 1 and concatenate twice: 1,1,1 then tripling the last term gives: 1,1,3. Concatenating those 3 terms twice gives: 1,1,3,1,1,3,1,1,3, triple the last term -> 1,1,3,1,1,3,1,1,9. Concatenating those 9 terms twice gives: 1,1,3,1,1,3,1,1,9,1,1,3,1,1,3,1,1,9,1,1,3,1,1,3,1,1,9, triple the last term -> 1,1,3,1,1,3,1,1,9,1,1,3,1,1,3,1,1,9,1,1,3,1,1,3,1,1,27 etc. - Benoit Cloitre, Dec 17 2002
Also 3-adic value of 1/n, n >= 1. See the Mahler reference, definition on p. 7. This is a non-archimedean valuation. See Mahler, p. 10. Sometimes also called 3-adic absolute value. - Wolfdieter Lang, Jun 28 2014

References

  • Kurt Mahler, p-adic numbers and their functions, second ed., Cambridge University Press, 1981.

Crossrefs

Programs

  • Haskell
    a038500 = f 1 where
       f y x = if m == 0 then f (y * 3) x' else y  where (x', m) = divMod x 3
    -- Reinhard Zumkeller, Jul 06 2014
    
  • Magma
    [3^Valuation(n,3): n in [1..100]]; // Vincenzo Librandi, Dec 29 2015
  • Maple
    A038500 := n -> 3^padic[ordp](n,3): # Peter Luschny, Nov 26 2010
  • Mathematica
    Flatten[{1,1,#}&/@(3^IntegerExponent[#,3]&/@(3*Range[40]))] (* or *) hp3[n_]:=If[Divisible[n,3],3^IntegerExponent[n,3],1]; Array[hp3,90] (* Harvey P. Dale, Mar 24 2012 *)
    Table[3^IntegerExponent[n, 3], {n, 100}] (* Vincenzo Librandi, Dec 29 2015 *)
  • PARI
    {a(n) = if( n<1, 0, 3^valuation(n, 3))};
    

Formula

Multiplicative with a(p^e) = p^e if p = 3, 1 otherwise. - Mitch Harris, Apr 19 2005
a(n) = n / A038502(n). Dirichlet g.f. zeta(s)*(3^s-1)/(3^s-3). - R. J. Mathar, Jul 12 2012
From Peter Bala, Feb 21 2019: (Start)
a(n) = gcd(n,3^n).
O.g.f.: x/(1 - x) + 2*Sum_{n >= 1} 3^(n-1)*x^(3^n)/ (1 - x^(3^n)). (End)
Sum_{k=1..n} a(k) ~ (2/(3*log(3)))*n*log(n) + (2/3 + 2*(gamma-1)/(3*log(3)))*n, where gamma is Euler's constant (A001620). - Amiram Eldar, Nov 15 2022

A060904 Largest power of 5 that divides n.

Original entry on oeis.org

1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 25, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 25, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 25, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1, 5, 1, 1, 1, 1
Offset: 1

Views

Author

Ahmed Fares (ahmedfares(AT)my-deja.com), May 06 2001

Keywords

Comments

Also the largest power of 5 that divides the n-th Fibonacci number A000045(n).
Multiplicative with a(p^e) = 5^e if p = 5, else a(p^e) = 1. - Mitch Harris, Apr 19 2005
Also 5-adic value of 1/n, n >= 1. See the Mahler reference, definition on p. 7. This is a non-archimedean valuation. See Mahler, p. 10. Sometimes also called 5-adic absolute value. - Wolfdieter Lang, Jun 30 2014

Examples

			a(10) = 5 because 10 = 5 * 2.
		

References

  • Kurt Mahler, p-adic numbers and their functions, second ed., Cambridge University Press, 1981.

Crossrefs

Programs

Formula

If n is not divisible by 5, then a(n) = 1. If n = 5^k * m where m is not divisible by 5, then a(n) = 5^k.
Dirichlet g.f.: zeta(s)*(5^s-1)/(5^s-5). - R. J. Mathar, Jul 12 2012
a(n) = 5^A112765(n). - Tom Edgar, Mar 22 2014
From Peter Bala, Feb 21 2019: (Start)
a(n) = gcd(n,5^n).
a(n) = n/A132739(n).
O.g.f.: x/(1 - x) + 4*Sum_{n >= 1} 5^(n-1)*x^(5^n)/ (1 - x^(5^n)). (End).
a(n) = (1/5)*(sigma(5*n) - sigma(n))/(sigma(5*n) - 5*sigma(n)), where sigma(n) = A000203(n). - Peter Bala, Jun 10 2022
Sum_{k=1..n} a(k) ~ (4/(5*log(5)))*n*log(n) + (3/5 + 4*(gamma-1)/(5*log(5)))*n, where gamma is Euler's constant (A001620). - Amiram Eldar, Nov 15 2022

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), May 07 2001
Edited by Joerg Arndt and M. F. Hasler, Dec 29 2015

A242603 Largest divisor of n not divisible by 7. Remove factors 7 from n.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 1, 8, 9, 10, 11, 12, 13, 2, 15, 16, 17, 18, 19, 20, 3, 22, 23, 24, 25, 26, 27, 4, 29, 30, 31, 32, 33, 34, 5, 36, 37, 38, 39, 40, 41, 6, 43, 44, 45, 46, 47, 48, 1, 50, 51, 52, 53, 54, 55, 8, 57, 58, 59, 60, 61, 62, 9, 64, 65, 66, 67, 68, 69, 10, 71, 72, 73, 74, 75, 76, 11
Offset: 1

Views

Author

Wolfdieter Lang, Jun 18 2014

Keywords

Comments

This is member p = 7 in the p-family of sequences (p a prime).
See A000265, A038502 and A132739 for primes 2, 3 and 5, also for formulas, programs and references.
As well as being multiplicative, a(n) is a strong divisibility sequence, that is, gcd(a(n),a(m)) = a(gcd(n,m)) for n, m >= 1. In particular, a(n) is a divisibility sequence: if n divides m then a(n) divides a(m). - Peter Bala, Feb 21 2019

Examples

			From _Indranil Ghosh_, Jan 31 2017: (Start)
For n = 12, the divisors of 12 are 1,2,3,4,6 and 12. The largest divisor not divisible by 7 is 12. So, a(12) = 12.
For n = 14, the divisors of 14 are 1,2,7 and 14. The largest divisor not divisible by 7 is 2. So, a(14) = 2. (End)
From _Peter Bala_, Feb 21 2019: (Start)
Sum_{n >= 1} n*a(n)*x^n = G(x) - (6*7)*G(x^7) - (6*49)*G(x^49) - (6*343)*G(x^343) - ..., where G(x) = x*(1 + x)/(1 - x)^3.
Sum_{n >= 1} (1/n)*a(n)*x^n = H(x) - (6/7)*H(x^7) - (6/49)*H(x^49) - (6/343)*H(x^343) - ..., where H(x) = x/(1 - x).
Sum_{n >= 1} (1/n^2)*a(n)*x^n = L(x) - (6/7^2)*L(x^7) - (6/49^2)*L(x^49) - (6/343^2)*L(x^343) - ..., where L(x) = Log(1/(1 - x)).
Also, Sum_{n >= 1} (1/a(n))*x^n = L(x) + (6/7)*L(x^7) + (6/7)*L(x^49) + (6/7)*L(x^343) ... . (End)
		

Crossrefs

Programs

  • Mathematica
    Table[n/7^IntegerExponent[n, 7], {n, 80}] (* Alonso del Arte, Jun 18 2014 *)
  • PARI
    a(n) = f = factor(n);  for (i=1, #f~, if (f[i,1]==7, f[i, 1]=1)); factorback(f); \\ Michel Marcus, Jun 18 2014
    
  • PARI
    a(n) = n \ 7^valuation(n, 7) \\ David A. Corneth, Feb 21 2019
    
  • Python
    def A242603(n):
        for i in range(n,0,-1):
            if n%i==0 and i%7!=0:
                return i # Indranil Ghosh, Jan 31 2017

Formula

Multiplicative with a(p^e) = 1 if p = 7, else p^e.
Dirichlet g.f.: zeta(s-1)*7*(7^(s-1) - 1)/(7^s - 1).
a(n) = n/A268354(n).
From Peter Bala, Feb 21 2019: (Start)
a(n) = n/gcd(n,7^n).
O.g.f.: F(x) - 6*F(x^7) - 6*F(x^49) - 6*F(x^243) - ..., where F(x) = x/(1 - x)^2 is the generating function for the positive integers. More generally, for m >= 1,
Sum_{n >= 0} (a(n)^m)*x^n = F(m,x) - (7^m - 1)( F(m,x^7) + F(m,x^49) + F(m,x^243) + ...), where F(m,x) = A(m,x)/(1 - x)^(m+1) with A(m,x) the m_th Eulerian polynomial: A(1,x) = x, A(2,x) = x*(1 + x), A(3,x) = x*(1 + 4*x + x^2) - see A008292.
Repeatedly applying the Euler operator x*d/dx or its inverse operator to the o.g.f. for the sequence a(n) produces generating functions for the sequences (n^m*a(n))n>=1, m in Z. Some examples are given below. (End)
Sum_{k=1..n} a(k) ~ (7/16) * n^2. - Amiram Eldar, Nov 28 2022

A268357 Highest power of 11 dividing n.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 121, 1
Offset: 1

Views

Author

Tom Edgar, Feb 02 2016

Keywords

Comments

The generalized binomial coefficients produced by this sequence provide an analog to Kummer's Theorem using arithmetic in base 11.
This first index where this differs from A109014 is 121; a(121) = 121 and A109014(121) = 11.

Examples

			Since 22 = 11 * 2, a(22) = 11. Likewise, since 11 does not divide 21, a(21) = 1.
		

Crossrefs

Programs

  • Magma
    [11^Valuation(n,11): n in [1..130]]; // Vincenzo Librandi, Feb 03 2016
  • Mathematica
    Table[11^IntegerExponent[n, 11], {n, 130}] (* Bruno Berselli, Feb 03 2016 *)
  • Sage
    [11^valuation(i, 11) for i in [1..130]]
    

Formula

a(n) = 11^valuation(n,11).
Completely multiplicative with a(11) = 11, a(p) = 1 for prime p and p<>11. - Andrew Howroyd, Jul 20 2018
From Peter Bala, Feb 21 2019: (Start)
a(n) = gcd(n,11^n).
O.g.f.: x/(1 - x) + 10*Sum_{n >= 1} 11^(n-1)*x^(11^n)/ (1 - x^(11^n)). (End)
Sum_{k=1..n} a(k) ~ (10/(11*log(11)))*n*log(n) + (6/11 + 10*(gamma-1)/(11*log(11)))*n, where gamma is Euler's constant (A001620). - Amiram Eldar, Nov 15 2022
Dirichlet g.f.: zeta(s)*(11^s-1)/(11^s-11). - Amiram Eldar, Jan 03 2023

A088841 Numerator of the quotient sigma(7*n)/sigma(n).

Original entry on oeis.org

8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 400, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8, 57, 8, 8, 8, 8, 8, 8
Offset: 1

Views

Author

Labos Elemer, Nov 04 2003

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Numerator[DivisorSigma[1, 7*n]/DivisorSigma[1, n]], {n, 1, 128}]
  • PARI
    a(n) = numerator(sigma(7*n)/sigma(n)); \\ Amiram Eldar, Mar 22 2024

Formula

From Amiram Eldar, Mar 22 2024: (Start)
a(n) = numerator(A283078(n)/A000203(n)).
a(n) = (7^(A214411(n)+2)-1)/6 = (49*A268354(n)-1)/6.
Sum_{k=1..n} a(k) ~ (7/log(7))*n*log(n) + (9/2 + 7*(gamma-1)/log(7))*n, where gamma is Euler's constant (A001620).
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k)/A088842(k) = 1 + 36 * Sum_{k>=1} 1/(7^k-1) = 7.87276224676... . (End)

A305720 Square array T(n, k) read by antidiagonals, n > 0 and k > 0; for any prime number p, the p-adic valuation of T(n, k) is the product of the p-adic valuations of n and of k.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 4, 3, 4, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 16, 1, 2, 1, 1, 1, 3, 1, 1, 3, 1, 1, 1, 8, 1, 4, 5, 4, 1, 8, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 9, 64, 1, 6, 1, 64, 9, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 4, 1, 8, 7, 8
Offset: 1

Views

Author

Rémy Sigrist, Jun 09 2018

Keywords

Comments

The array T is completely multiplicative in both parameters.
For any n > 0 and prime number p, T(n, p) is the highest power of p dividing n.
For any function f associating a nonnegative value to any pair of nonnegative values and such that f(0, 0) = 0, we can build an analog of this sequence, say P_f, such that for any prime number p and any n and k > 0 with p-adic valuations i and j, the p-adic valuation of P_f(n, k) equals f(i, j):
f(i, j) P_f
------- ---
i * j T (this sequence)
i + j A003991 (product)
abs(i-j) A089913
min(i, j) A003989 (GCD)
max(i, j) A003990 (LCM)
i AND j A059895
i OR j A059896
i XOR j A059897
If log(N) denotes the set {log(n) : n is in N, the set of the positive integers}, one can define a binary operation on log(N): with prime factorizations n = Product p_i^e_i and k = Product p_i^f_i, set log(n) o log(k) = Sum_{i} (e_i*f_i) * log(p_i). o has the premises of a scalar product even if log(N) isn't a vector space. T(n, k) can be viewed as exp(log(n) o log(k)). - Luc Rousseau, Oct 11 2020

Examples

			Array T(n, k) begins:
  n\k|    1    2    3    4    5    6    7    8    9   10
  ---+--------------------------------------------------
    1|    1    1    1    1    1    1    1    1    1    1
    2|    1    2    1    4    1    2    1    8    1    2  -> A006519
    3|    1    1    3    1    1    3    1    1    9    1  -> A038500
    4|    1    4    1   16    1    4    1   64    1    4
    5|    1    1    1    1    5    1    1    1    1    5  -> A060904
    6|    1    2    3    4    1    6    1    8    9    2  -> A065331
    7|    1    1    1    1    1    1    7    1    1    1  -> A268354
    8|    1    8    1   64    1    8    1  512    1    8
    9|    1    1    9    1    1    9    1    1   81    1
   10|    1    2    1    4    5    2    1    8    1   10  -> A132741
		

Crossrefs

Programs

  • Mathematica
    T[n_, k_] := With[{p = FactorInteger[GCD[n, k]][[All, 1]]}, If[p == {1}, 1, Times @@ (p^(IntegerExponent[n, p] * IntegerExponent[k, p]))]];
    Table[T[n-k+1, k], {n, 1, 15}, {k, 1, n}] // Flatten (* Jean-François Alcover, Jun 11 2018 *)
  • PARI
    T(n, k) = my (p=factor(gcd(n, k))[,1]); prod(i=1, #p, p[i]^(valuation(n, p[i]) * valuation(k, p[i])))

Formula

T(n, k) = T(k, n) (T is commutative).
T(m, T(n, k)) = T(T(m, n), k) (T is associative).
T(n, k) = 1 iff gcd(n, k) = 1.
T(n, n) = A054496(n).
T(n, A007947(n)) = n.
T(n, 1) = 1.
T(n, 2) = A006519(n).
T(n, 3) = A038500(n).
T(n, 4) = A006519(n)^2.
T(n, 5) = A060904(n).
T(n, 6) = A065331(n).
T(n, 7) = A268354(n).
T(n, 8) = A006519(n)^3.
T(n, 9) = A038500(n)^2.
T(n, 10) = A132741(n).
T(n, 11) = A268357(n).
Showing 1-6 of 6 results.