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 41-44 of 44 results.

A140888 Number of nonprimes in [210n - 210, 210n] coprime to 210.

Original entry on oeis.org

6, 13, 15, 16, 18, 19, 21, 17, 21, 21, 22, 23, 18, 22, 26, 21, 22, 21, 24, 24, 22, 25, 22, 22, 26, 24, 22, 21, 28, 23, 25, 23, 25, 24, 26, 25, 22, 27, 27, 24, 27, 22, 24, 25, 23, 26, 23, 28, 23, 26, 27, 26, 27, 26, 27, 30, 22, 26, 27, 22, 25, 24, 26, 29, 27, 24, 27, 31, 25, 26
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jul 06 2008

Keywords

Comments

For almost all n, a(n) = phi(210) = 48. It first attains this value at a(1751794).

Examples

			{1,11,13,...,209,} are coprime to 210 in [0, 210]; the nonprimes are {1,121,143,169,187,209} so a(1) = 1.
		

Crossrefs

Programs

  • PARI
    a(n)=sum(k=210*n-210,210*n,gcd(k,210)==1&!isprime(k))

Extensions

Corrected and rewritten by Charles R Greathouse IV, Mar 26 2010

A246541 Take the squares of all P_(n+2)-rough numbers less than the (n+1)-th primorial and mod each by the (n+1)-th primorial. There will be a(n) different results.

Original entry on oeis.org

1, 2, 6, 30, 180, 1440, 12960, 142560, 1995840, 29937600, 538876800, 10777536000, 226328256000, 5205549888000, 135344297088000, 3924984615552000, 117749538466560000, 3885734769396480000, 136000716928876800000, 4896025809439564800000, 190945006568143027200000
Offset: 1

Views

Author

John B. Yin, Aug 29 2014

Keywords

Comments

The P_(n+2)-rough numbers less than the (n+1)-th primorial also comprise the reduced residue system of the (n+1)-th primorial.
The conjectured formula from Jon E. Schoenfield is true. This can be seen by considering that each odd prime p has exactly (p+1)/2 quadratic residues (mod p), of which (p-1)/2 are nonzero. The P_(n+2)-rough numbers less than the (n+1)-th primorial comprise all combinations of nonzero residues modulo the first n+1 primes. So for each odd prime p, the p-1 nonzero residues map to (p-1)/2 (nonzero) residues after squaring. - Bert Dobbelaere, Aug 09 2023

Examples

			For n=2, P_(n+2) = 7.
The 7-rough numbers less than 2*3*5 are 1,7,11,13,17,19,23,29.
The squares of those numbers mod 2*3*5 are 1,19,1,19,19,1,19,1.
There are 2 different results: 1 and 19; so a(2) = 2.
		

Crossrefs

Cf. A002110 (primorial).
Cf. k-rough numbers A007310 (k=5), A007775 (k=7), A008364 (k=11), A008365 (k=13), A008366 (k=17), A166061 (k=19), A166063 (k=23).
Cf. A323739.

Programs

  • Java
    import java.util.TreeSet;
    for(int z = 1; z < 10 ; z++) {
    int n = z;
    int numNumPerLine = 210;
    int[] primes = {2,3,5,7,11,13,17,19,23,29,31,37,41,43};
    int numRepeats = 1;
    int numSpaces = 1;
    for(int i = 0; i < n + 1; i++) {
    numSpaces *= (primes[i] - 1);
    }
    int counter = 0;
    long integerLength = 1;
    for(int i = 0; i < n + 1; i++) {
    integerLength *= primes[i];
    }
    TreeSet numResults = new TreeSet();
    numSpaces/=2;
    for(int i = 1; i < integerLength / 2; i+=2) {
    boolean isInList = true;
    for(int j = 1; j < n + 1; j++) {
    if(i % primes[j] == 0) {
    isInList = false;
    }
    }
    if(isInList) {
    long k = i % integerLength;
    if(k != 0) {
    long l = (k * k) % integerLength;
    if(!numResults.contains(l)) {
    numResults.add(l);
    }
    }
    }
    }
    System.out.println(numResults.size());
    }
    
  • PARI
    a(n) = {hp = prod(k=1, n+1, prime(k)); rp = prod(k=1, n+2, prime(k)); v = []; for (i=1, hp, if (gcd(i, rp) == 1, nv = i^2 % hp; if (! vecsearch(v, nv), v = vecsort(concat(v, nv))););); #v;} \\ Michel Marcus, Sep 06 2014

Formula

Conjecture: a(n) = (1/2^n)*Product_{j=1..n} (prime(j+1)-1) = A005867(n+1)/2^n. - Jon E. Schoenfield, Feb 20 2019
a(n) = A323739(n+1). - Bert Dobbelaere, Aug 09 2023

A294907 a(n) is the smallest number k such that exactly half of the prime(n+1)-rough numbers in the interval [prime(n)^2 + 1, k] are prime.

Original entry on oeis.org

87, 925, 4757, 17699, 43357, 97703, 187813, 350321, 595871, 920081, 1405609, 2024047, 2827861, 3931217, 5348053, 7053941, 9058607, 11637667, 14631209, 18251339, 22657429, 27786589, 33829567, 40651799, 48209237, 56928409, 67107197, 78713287, 92233283, 107643667
Offset: 1

Views

Author

Jon E. Schoenfield, Nov 10 2017

Keywords

Comments

Students who are first learning about prime and composite numbers and factorization learn that trial division is a simple way to determine whether a given number N is prime, and that only those divisors up through the square root of N need to be tried, since trial division by each prime up through a given prime p is sufficient to completely factor every composite number up through at least p^2.
Given a four-function calculator and a set of randomly-selected integers of manageable size to either factor or identify as prime, one can observe fairly quickly that as trial division is attempted using the primes in increasing order as divisors, many numbers that aren't divisible by any of the first several primes turn out to be prime.
Given some positive integer j > prime(n)^2, if we consider the set of integers that exceed prime(n)^2 but do not exceed j, and we exclude each number that is divisible by any of the first n primes, then the numbers that remain will include exactly as many primes as composites if j = a(n), but if j < a(n), then most of the numbers that remain will be prime.

Examples

			The 1st prime is 2, and exactly half of the 42 3-rough numbers (i.e., odd numbers) in the interval [2^2 + 1, 87] are prime, and more than half of the 3-rough numbers in [5, k] are prime for all k < 87, so a(1)=87.
The 2nd prime is 3, and exactly half of the 306 5-rough numbers (i.e., numbers that are not divisible by 2 or 3) in the interval [3^2 + 1, 925] are prime, and more than half of the 5-rough numbers in [10, k] are prime for all k < 925, so a(2) = 925.
		

Crossrefs

Cf. A005408 (3-rough numbers, i.e., the odd numbers), A007310 (5-rough numbers), A007775 (7-rough numbers), A008364 (11-rough numbers).

A328138 Numbers m that divide 9^m + 8.

Original entry on oeis.org

1, 17, 803, 1241, 20264753, 28214180783393, 228454543831049
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Oct 04 2019

Keywords

Comments

Conjecture: For n > 1, k^n == 1-k (mod n) has an infinite number of positive solutions.
No term can be a multiple of 2, 3, 5, 7, or 13. Also 4879573990210017348077958628152400091281634488825721395187 is a term. - Giovanni Resta, Oct 07 2019
Also 6788776064693081883870036833 is a term. - Max Alekseyev, Dec 27 2024

Crossrefs

Subsequence of A008364.
Solutions to k^m == k-1 (mod m): 1 (k = 1), A006521 (k = 2), A015973 (k = 3), A327840 (k = 4), A123047 (k = 5), A327943 (k = 6), A328033 (k = 7), A327468 (k = 8), this sequence (k = 9).
Cf. A253212 (9^n + 8).

Programs

  • Magma
    [1] cat [n: n in [1..10^8] | Modexp(9, n, n) + 8 eq n];
    
  • PARI
    isok(n) = Mod(9, n)^n==-8; \\ Michel Marcus, Oct 05 2019

Formula

a(n) > 15n for large enough n. (Surely the sequence grows superlinearly, but I can't prove it.) - Charles R Greathouse IV, Dec 27 2024

Extensions

a(7) from Giovanni Resta confirmed and a(6) added by Max Alekseyev, Dec 27 2024
Previous Showing 41-44 of 44 results.