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

A079602 Greatest of smallest odd prime factors of all composite numbers between n-th prime and next prime.

Original entry on oeis.org

3, 5, 3, 7, 3, 11, 13, 3, 17, 19, 3, 23, 13, 29, 3, 31, 17, 3, 37, 41, 43, 47, 7, 3, 53, 3, 7, 61, 5, 67, 3, 73, 3, 19, 79, 83, 43, 89, 3, 47, 3, 97, 3, 103, 109, 113, 3, 29, 59, 3, 61, 127, 131, 67, 3, 137, 139, 3, 73, 151, 7, 3, 157, 163, 167, 173, 3, 11, 179, 181, 23, 47, 191
Offset: 3

Views

Author

Reinhard Zumkeller, Jan 28 2003

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := Max[FactorInteger[#/2^IntegerExponent[#, 2]][[1, 1]] & /@ Range[Prime[n] + 1, Prime[n + 1] - 1]]; Array[a, 100, 3] (* Amiram Eldar, Mar 28 2025 *)

A338101 Smallest odd prime dividing n is a(n)-th prime, or 0 if no such prime exists.

Original entry on oeis.org

0, 0, 2, 0, 3, 2, 4, 0, 2, 3, 5, 2, 6, 4, 2, 0, 7, 2, 8, 3, 2, 5, 9, 2, 3, 6, 2, 4, 10, 2, 11, 0, 2, 7, 3, 2, 12, 8, 2, 3, 13, 2, 14, 5, 2, 9, 15, 2, 4, 3, 2, 6, 16, 2, 3, 4, 2, 10, 17, 2, 18, 11, 2, 0, 3, 2, 19, 7, 2, 3, 20, 2, 21, 12, 2, 8, 4, 2, 22, 3, 2, 13, 23, 2, 3, 14, 2, 5, 24, 2
Offset: 1

Views

Author

Ilya Gutkovskiy, Nov 10 2020

Keywords

Examples

			70 = 2 * 5 * 7 = prime(1) * prime(3) * prime(4), 3 < 4, so a(70) = 3.
		

Crossrefs

Cf. A000079 (positions of 0's), A000265, A000720, A020639, A055396, A078701.

Programs

  • Maple
    f:= proc(n) local w;
       w:= numtheory:-factorset(n) minus {2};
       if w = {} then 0 else numtheory:-pi(min(w)) fi
    end proc:
    map(f, [$1..100]); # Robert Israel, Nov 13 2020
  • Mathematica
    Array[If[Or[# == 1, ! IntegerQ@ #], 0, PrimePi@ #] &@ SelectFirst[FactorInteger[#][[All, 1]], OddQ] &, 90] (* Michael De Vlieger, Nov 13 2020 *)
  • PARI
    a(n) = my(v = select(x->((x%2)==1), factor(n)[, 1])); if (#v, primepi(vecmin(v)), 0); \\ Michel Marcus, Nov 13 2020

Formula

a(n) = A000720(A020639(A000265(n))).
a(n) = A000720(A078701(n)).

A372263 Least odd prime factor of the n-th sum of two consecutive primes, A001043(n) = prime(n) + prime(n+1), or 2 if there is no odd prime factor.

Original entry on oeis.org

5, 2, 3, 3, 3, 3, 3, 3, 13, 3, 17, 3, 3, 3, 5, 7, 3, 2, 3, 3, 19, 3, 43, 3, 3, 3, 3, 3, 3, 3, 3, 67, 3, 3, 3, 7, 5, 3, 5, 11, 3, 3, 3, 3, 3, 5, 7, 3, 3, 3, 59, 3, 3, 127, 5, 7, 3, 137, 3, 3, 3, 3, 3, 3, 3, 3, 167, 3, 3, 3, 89, 3, 5, 47, 3, 193, 3, 3, 3, 3, 3, 3, 3, 109, 3, 223
Offset: 1

Views

Author

M. F. Hasler, Apr 24 2024

Keywords

Comments

Since the sum of any two primes > 2 is even, we rather consider odd prime factors.
Can it be proved or disproved that there are primes that occur only finitely many times (or never) in this sequence? If so, which is the smallest such prime?
From Robert Israel, Dec 29 2024: (Start)
Dickson's conjecture implies that every odd prime occurs infinitely many times in the sequence.
a(n) = 2 if and only if n = A000720(2^k) where k is in A226178. (End)

Examples

			Sums of two consecutive primes are given as s(n) = A001043(n). The least odd prime factor (or 2 if there's no odd prime factor) of these terms is a(n):
n = 1, 2,  3,  4,  5,  6,  7,  8,  9, 10, 11, 12, 13, 14,  15,  16,  17,  18, ...
s = 5, 8, 12, 18, 24, 30, 36, 42, 52, 60, 68, 78, 84, 90, 100, 112, 120, 128, ...
a = 5, 2,  3,  3,  3,  3,  3,  3, 13,  3, 17,  3,  3,  3,   5,   7,   3,   2, ...
Also, a(21) = spf(152) = 19; a(23) = spf(172) = 43; a(32) = spf(268) = 67, ...
		

Crossrefs

Cf. A001043 (sums of two consecutive primes), A078701 (least odd prime divisor), A020639 (spf: least prime factor), A000265 (odd part of n), A000079 (powers of 2).
Cf. A024677 (spf of A024675(n) = A001043(n)/2).
Cf. A226178.

Programs

  • Maple
    f:= proc(n) subs(infinity=2,min(numtheory:-factorset(ithprime(n)+ithprime(n+1)) minus {2})) end proc:
    map(f, [$1..100]); # Robert Israel, Dec 29 2024
  • PARI
    apply( {a(n) = max(A078701(A001043(n)), 2)}, [1..99])
    /* a "self-contained" but less efficient definition:
    a(n) = factor(max((n=prime(n)+prime(n+1))>>valuation(n,2),2))[1,1] */

Formula

a(n) = max(A078701(A001043(n)), 2) = A020639(max(A000265(A001043(n)), 2)), where A000265(m) > 2 unless m is in A000079.

A023511 Least odd prime divisor of prime(n) + 1, or 1 if prime(n) + 1 is a power of 2.

Original entry on oeis.org

3, 1, 3, 1, 3, 7, 3, 5, 3, 3, 1, 19, 3, 11, 3, 3, 3, 31, 17, 3, 37, 5, 3, 3, 7, 3, 13, 3, 5, 3, 1, 3, 3, 5, 3, 19, 79, 41, 3, 3, 3, 7, 3, 97, 3, 5, 53, 7, 3, 5, 3, 3, 11, 3, 3, 3, 3, 17, 139, 3, 71, 3, 7, 3, 157, 3, 83, 13, 3, 5, 3, 3, 23, 11, 5, 3, 3, 199, 3, 5, 3, 211, 3, 7, 5, 3, 3
Offset: 1

Views

Author

Keywords

Comments

Note that a(n) = 1 for n= 2, 4, 11, 31, 1028, ... (A059305). - Michel Marcus, Oct 01 2013

Crossrefs

Programs

  • PARI
    a(n) = my(p = prime(n) + 1, v = p/(2^valuation(p, 2))) ; if (v == 1, 1, factor(v)[1, 1]); \\ Michel Marcus, Oct 01 2013

Formula

a(n) = A078701(A008864(n)). - Michel Marcus, Jun 06 2019

A023519 Least odd prime divisor of prime(n)*prime(n-1) - 1, or 1 if prime(n)*prime(n-1) - 1 is a power of 2.

Original entry on oeis.org

1, 5, 7, 17, 19, 71, 5, 7, 109, 3, 449, 3, 379, 881, 5, 3, 3, 7, 3, 29, 2591, 3, 11, 3, 13, 31, 7, 5, 7, 3079, 5, 4159, 3, 9521, 5, 7, 3, 3, 5, 3, 3, 97, 5, 7, 5, 17, 3, 3, 5, 7, 13339, 3, 31, 5, 3, 3, 3, 7, 3, 11, 39761, 11, 5, 23869, 7, 5, 23, 3, 59, 151, 19, 3, 43, 3, 3, 11, 3, 19, 39799, 13
Offset: 1

Views

Author

Keywords

Comments

Assumes the not generally accepted convention prime(0) = 1. - Michel Marcus, Jun 06 2019

Crossrefs

Programs

  • PARI
    p(n) = if (n==0, 1, prime(n));
    f(n) = my(v = select(x->((x%2)==1), factor(n)[, 1])); if (#v, vecmin(v), 1);
    a(n) = f(p(n)*p(n-1) - 1); \\ Michel Marcus, Jun 06 2019

Formula

a(n) = A078701(A023515(n)). - Michel Marcus, Jun 06 2019

Extensions

Terms corrected by Sean A. Irvine, Jun 05 2019
Previous Showing 21-25 of 25 results.