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

A059865 Product_{i=4..n} (prime(i) - 6).

Original entry on oeis.org

1, 1, 1, 1, 5, 35, 385, 5005, 85085, 1956955, 48923875, 1516640125, 53082404375, 1964048961875, 80526007436875, 3784722349533125, 200590284525255625, 11032465648889059375, 672980404582232621875, 43743726297845120421875
Offset: 1

Views

Author

Labos Elemer, Feb 28 2001

Keywords

Comments

Arises in Hardy-Littlewood prime k-tuplet conjectural formulas. Also the sequence gives the exact numbers of X42424Y difference-pattern in dRRS[m], where m=modulus=A002110(n). See A049296 (=dRRS[210]=list of first differences of reduced residue system modulo 210=4th primorial). A pattern X42424Y corresponds to a residue-sextuple or it is their difference-quintuple, X,Y > 4. Analogous pattern for primes is in A022008.
a(352) has 1001 decimal digits. - Michael De Vlieger, Mar 06 2017

Examples

			a(7) = (prime(4)-6) * (prime(5)-6) * (prime(6)-6) * (prime(7)-6) = 1 * 5* 7 *11 = 385
 Also in one period of dRRS with 2,6,30,210,2310,... modulus [A002110(n)] 1,2,8,48,480,... differences occur [A005867(n)]. The number of X42424Y residue-difference-patterns are 0,1,1,1,5,... respectively starting at suitable residues coprime to A002110(n).
		

References

  • See A059862 for references.
  • Steven R. Finch, Mathematical Constants, Cambridge, 2003, pp. 84-94.

Crossrefs

Programs

  • Mathematica
    Table[Product[Prime@ i - 6, {i, 4, n}], {n, 19}] (* Michael De Vlieger, Mar 06 2017 *)
  • PARI
    a(n) = prod(k=4, n, prime(k) - 6); \\ Michel Marcus, Mar 06 2017

A059862 a(n) = Product_{i=3..n} (prime(i) - 3).

Original entry on oeis.org

1, 1, 2, 8, 64, 640, 8960, 143360, 2867200, 74547200, 2087321600, 70968934400, 2696819507200, 107872780288000, 4746402332672000, 237320116633600000, 13289926531481600000, 770815738825932800000, 49332207284859699200000, 3354590095370459545600000, 234821306675932168192000000
Offset: 1

Views

Author

Labos Elemer, Feb 28 2001

Keywords

Examples

			For n = 6, a(6) = 640 because:
prime(1..6)-3 = (-1,0,2,4,8,10) -> (1,1,2,4,8,10)
and
1*1*2*4*8*10 = 640. [Example generalized and reformatted per observation of _Jon E. Schoenfield_ by _Harlan J. Brothers_, Jul 15 2018]
		

References

  • Steven R. Finch, Mathematical Constants, Cambridge, 2003, pp. 84-94.
  • R. K. Guy, Unsolved Problems in Number Theory, A8, A1
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers, 5th ed., Oxford Univ. Press, 1979.
  • G. Polya, Mathematics and Plausible Reasoning, Vol. II, Appendix Princeton UP, 1954.

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember;
          `if`(n<3, 1, a(n-1)*(ithprime(n)-3))
        end:
    seq(a(n), n=1..21);  # Alois P. Heinz, Nov 19 2021
  • Mathematica
    Join[{1, 1}, Table[Product[Prime[i] - 3, {i, 3, n}], {n, 3, 19}]] (* Harlan J. Brothers, Jul 02 2018 *)
    a[1] = 1; a[2] = 1; a[n_] := a[n] = a[n - 1] (Prime[n] - 3);
    Table[a[n], {n, 19}] (* Harlan J. Brothers, Jul 02 2018 *)
  • PARI
    a(n) = prod(i=3, n, prime(i) - 3); \\ Michel Marcus, Jul 15 2018

Formula

a(1) = a(2) = 1; a(n) = a(n-1) * (prime(n) - 3) for n >= 3. - David A. Corneth, Jul 15 2018

Extensions

Name clarified, offset corrected by David A. Corneth, Jul 15 2018

A271564 Number of 6's found in the first differences of a reduced residue system modulo a primorial p#.

Original entry on oeis.org

0, 0, 2, 14, 142, 1690, 26630, 470630, 10169950, 280323050, 8278462850, 293920842950, 11604850743850, 481192519512250, 21869408938627250, 1124832660535333750, 64590101883781223750, 3837395864206055401250, 250972362651045466681250, 17415757437491856599406250, 1243227958252662737649043750
Offset: 1

Views

Author

Logan W. Wilbur, Apr 09 2016

Keywords

Comments

Technically, the formula is undefined modulo 2# or 3#, but their values are listed as "0", since there are no 6's in the first differences of their reduced residue systems. For our purposes, by "6's", we mean n such that n,n+6 are relatively prime to the primorial modulus, while n+1,n+2,n+3,n+4,n+5 all share a factor (or factors) with p#. The values of this sequence are tied to actual distribution of sexy primes over N (conjecture).

Examples

			Modulo 5# (=30), there are (2*(5-2)-2*(5-3))=2 occurrences where n,n+6 are relatively prime, but n+1,n+2,n+3,n+4,n+5 share a factor with 30; they are n=1,n=23(mod30). Modulo 7# (=210), there are (2*(7-2)*(5-2)-2*(7-3)*(5-3))=30-16=14 such occurrences.
		

Crossrefs

Cf. A059861 (d=2,4 values), A049296, A271565.

Programs

  • Mathematica
    Table[2 Product[Prime@ k - 2, {k, 3, n}] - 2 Product[Prime@ k - 3, {k, 3, n}], {n, 21}] (* Michael De Vlieger, Apr 11 2016 *)
  • PARI
    a(n) = 2*prod(k=3, n, prime(k)-2) - 2*prod(k=3, n, prime(k)-3); \\ Michel Marcus, Apr 10 2016

Formula

a(n) = 2*product(p-2)-2*product(p-3), where p runs over the primes greater than 3.

Extensions

Corrected and extended by Michel Marcus, Apr 10 2016

A271565 Number of 8's found in the first differences of a reduced residue system modulo a primorial p#.

Original entry on oeis.org

0, 0, 0, 2, 28, 394, 6812, 128810, 2918020, 83120450, 2524575200, 91589444450, 3682730287600, 155231331960250, 7156139793803000, 372520258834974250, 21613446896458917500, 1296556574981939521250, 85520460088068245240000, 5980843188551617897761250, 430093937447553491544932500
Offset: 1

Views

Author

Logan W. Wilbur, Apr 10 2016

Keywords

Comments

Technically, the formula is undefined modulo 2# or 3#, but I have listed their values as "0", since there are no 8's in the first differences of their reduced residue systems. For our purposes, by "8's", we mean n such that n,n+8 are relatively prime to the primorial modulus, while n+1,n+2,n+3,n+4,n+5,n+6,n+7 all share a factor (or factors) with p#.

Examples

			Modulo 5# (=30), there are (5-2)-2*(5-3)+(5-4)=0 occurrences where n, n+8 are relatively prime but n+1, n+2, n+3, n+4, n+5, n+6, n+7 share a factor with 30.
Modulo 7# (=210), there are (7-2)(5-2)-2*(7-3)(5-3)+(7-4)(5-4)=15-16+3=2 such occurrences; i.e when n=89,113 (mod210).
		

Crossrefs

Programs

  • Mathematica
    Table[Product[Prime@ k - 2, {k, 3, n}] - 2 Product[Prime@ k - 3, {k, 3, n}] + Product[Prime@ k - 4, {k, 3, n}], {n, 21}] (* Michael De Vlieger, Apr 11 2016 *)
  • PARI
    a(n) = prod(k=3, n, prime(k)-2) - 2*prod(k=3, n, prime(k)-3) + prod(k=3, n, prime(k)-4); \\ Michel Marcus, Apr 11 2016

Formula

a(n) = product(p-2) - 2*product(p-3) + product(p-4), where p runs through the primes > 3 and <= prime(n).

Extensions

More terms from Michel Marcus, Apr 11 2016

A059863 a(n) = Product_{i=3..n} (prime(i)-4).

Original entry on oeis.org

1, 1, 1, 3, 21, 189, 2457, 36855, 700245, 17506125, 472665375, 15597957375, 577124422875, 22507852492125, 967837657161375, 47424045200907375, 2608322486049905625, 148674381704844620625, 9366486047405211099375, 627554565176149143658125, 43301264997154290912410625
Offset: 1

Views

Author

Labos Elemer, Feb 28 2001

Keywords

References

  • See A059862 for references.
  • Steven R. Finch, Mathematical Constants, Cambridge, 2003, pp. 84-94.

Crossrefs

Programs

  • PARI
    a(n) = prod(i=3, n, prime(i)-4); \\ Michel Marcus, Aug 25 2019

Extensions

More terms from Michel Marcus, Aug 25 2019

A059864 a(n) = Product_{i=4..n} (prime(i)-5), where prime(i) is i-th prime.

Original entry on oeis.org

1, 1, 1, 2, 12, 96, 1152, 16128, 290304, 6967296, 181149696, 5796790272, 208684449792, 7930009092096, 333060381868032, 15986898329665536, 863292509801938944, 48344380548908580864, 2997351594032332013568
Offset: 1

Views

Author

Labos Elemer, Feb 28 2001

Keywords

Comments

Such products arise in Hardy-Littlewood prime k-tuplet conjectural formulas.

References

  • Steven R. Finch, Mathematical Constants, Cambridge, 2003, pp. 84-94.
  • R. K. Guy, Unsolved Problems in Number Theory, A8, A1
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers, 5th ed., Oxford Univ. Press, 1979.
  • G. Polya, Mathematics and Plausible Reasoning, Vol. II, Appendix Princeton UP, 1954

Crossrefs

Programs

  • Magma
    [n le 3 select 1 else (&*[NthPrime(j) -5: j in [4..n]]): n in [1..30]]; // G. C. Greubel, Feb 02 2023
    
  • Mathematica
    Join[{1,1,1},FoldList[Times,Prime[Range[4,20]]-5]] (* Harvey P. Dale, Dec 29 2018 *)
  • PARI
    a(n) = prod(k=4, n, prime(k)-5); \\ Michel Marcus, Dec 12 2017
    
  • SageMath
    def A059864(n): return product(nth_prime(j) -5 for j in range(4,n+1))
    [A059864(n) for n in range(1,31)] # G. C. Greubel, Feb 02 2023

A319148 Irregular triangle T(n,m) where row n lists differences m = j*p - r - 1, with iterator 1 <= j <= A002110(n), p = prime(n+1), and r is the smallest number that exceeds j*p that is coprime to A002110(n+1).

Original entry on oeis.org

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

Views

Author

Jamie Morken, Sep 11 2018

Keywords

Comments

Let p(i) be primes with p(1)=2, p(n)# the n-th primorial number, and h(n) the Jacobsthal function for primorial p(n)#. Conjecture: gcd(h(n), p(n+1)) = 1.
For a multiple m of a prime n, terms in this sequence give the number of contiguous numbers starting at m+1 which have at least one prime factor < n.
Consider a range s of the first n + 1 primes. Let p be the largest of these primes, i.e., A000040(n+1). Let P be the product of the first n primes, i.e., the primorial A002110(n), and let Q be the product of all the primes in s, i.e., the primorial A002110(n+1). Consider the reduced residue system R of primorial P, that is, those numbers 1 <= r < P such that gcd(r, P) = 1; therefore R = row n of A286941. For each n, we generate the multiples k = j*p, with 1 <= j <= P. For each k, we find the smallest residue r in R that exceeds k and take the difference m = r - k - 1. If no value in R exceeds k, then we use Q + 1 (which is also coprime to Q). Row n is thus a list of these m.
Alternatively, consider a multiple k = j*p, with 1 <= j <= P. We can compute m by iterating i such that the sum (i + k) is coprime to Q and subtracting 1. This technique is more efficient in terms of memory, as it does not require storing the reduced residue system of Q.
For n > 1: The penultimate value m on row n = A040976(n). The number of values m on row n is given by the sequence: 1,1,2,2,10,22,500,...
For n > 3: For any even x = m in row n, the number of x in row n is equal to the count of y in row n where y = x + 1. If x = 0, the count of x and y in row n = A000010(A002110(n-1)). For example, on row 4, A000010(A002110(4-1)) = 8, as 0 and 1 each occur 8 times on row 4. The sequence of counts of x and x+1 pairs on consecutive rows is given by the sequence A059861. For example, for x=0 and y=1 occurring 8 times on row 4, x=2 and y=3 occur 8-3=5 times on row 4 given by the value 3 in A059861. For example, for row 8, x=0 and y=1 occur A000010(A002110(8-1)) = 92160 times on row 8, and x=2 and y=3 occur 92160-22275=69885 times on row 8 given by the value 22275 in A059861.
For 3 < n < 9: The largest value on row n occurs twice, the pattern of occurrence is shown in table 1 of Ziller & Morack in the Links section.

Examples

			Triangle begins:
  0;
  1,0;
  1,0,1,2,3,0;
  3,2,1,0,1,0,3,2,3,0,1,4,5,2,1,0,1,0,3,2,1,2,1,0,3,4,1,0,5,0;
  ...
For n = 2, we have s = {2,3,5}, with p = prime(n+1) = 5, P = A002110(2) = 6, and Q = A002110(3) = 30. Then R = row n of A286941 = {1, 7, 11, 13, 17, 19, 23, 29} (we add 31 to this list since we are concerned with the residue that is larger than the largest k and since 31 is the ensuing number coprime to Q). The series of multiples k = j*p are the multiples 5j with 1 <= j <= P, thus {5, 10, 15, 20, 25, 30}. In R, the smallest residues that exceed the multiples k in the immediately aforementioned list are {7, 11, 17, 23, 29, 31}. The differences are {7 - 5, 11 - 10, 17 - 15, 23 - 20, 29 - 25, 31 - 30} or {2, 1, 2, 3, 4, 1}; subtracting one from each we have row 2 = {1, 0, 1, 2, 3, 0}.
For example, the third value on row n=20000 is 15, so all values in the range (3 * prime(20000) + i) to (3 * prime(20000) + i) for 1 <= i <= 15 have at least one prime factor <= prime(n).
		

Crossrefs

Programs

  • Mathematica
    rowToCreate = 3; (* create row n *)
    redundantDistanceToCheck = 1; (* set to 2 or higher to see n repeating
    patterns of length primorial[rowToCreate] *)
    Primorial[n_] := Times @@ Prime[Range[n]]
    rowValue = 0;
    primeToUse = Prime[rowToCreate];
    distanceToCheck1 = redundantDistanceToCheck*Primorial[rowToCreate];
    (* distanceToCheck1=rowToCreate*10000; *)(* uncomment this second option to create the first few values in very large rows up to rowToCreate=7000000000000 *)
    For[i = primeToUse, i < distanceToCheck1 + 1, i = i + primeToUse,
    For[x = i + 1, x < distanceToCheck1 + 2, x++,
    If[FactorInteger[x][[1, 1]] < primeToUse, rowValue++; , x =
    distanceToCheck1 + 2;
    Print[rowValue];
    rowValue = 0;
    ]]] (* Jamie Morken, Sep 11 2018 *)
    (* Program to check the number of composites referenced to row
    values: *)
    Row = 100;
    ColumnOnTheRow = 12;
    Print["composites>", ColumnOnTheRow*Prime[Row], "=",
    (NextPrime[ColumnOnTheRow*Prime[Row]]) -
    (ColumnOnTheRow*Prime[Row]) - 1];
    (* Second program: *)
    Table[Block[{s = Prime@ Range[n + 1], p, P, Q}, p = Last@ s; P = Times @@
    Most@ s; Q = Times @@ s; Array[Block[{k = 1}, While[! CoprimeQ[k + p #,
    Q], k++]; k - 1] &, P]], {n, 4}] // Flatten (* Michael De Vlieger, Sep 11 2018 *)

Formula

Length of row n = A002110(n - 1).
T(n,1) = A046933(n).
Number of unique or primitive values m in row n = A048670(n-1).

A285298 Number of 10's found in the first differences of a reduced residue system modulo a primorial p#.

Original entry on oeis.org

0, 0, 0, 2, 30, 438, 7734, 148530, 3401790, 97648950, 2985436650, 108861586050, 4396116829650, 186022750845750, 8604610718954250, 449203003036037250, 26126835342151293750, 1570919774837171508750, 103827535054074567986250, 7274630596396103444253750
Offset: 1

Views

Author

Andrew Fuchs, Apr 16 2017

Keywords

Comments

Technically, the formula is undefined modulo 2# or 3#, but I have listed their values as "0", since there are no 10's in the first differences of their reduced residue systems. For our purposes, by "10's", we mean n such that n,n+10 are relatively prime to the primorial modulus, while n+1,n+2,n+3,n+4,n+5,n+6,n+7,n+8,n+9 all share a factor (or factors) with p#.

Crossrefs

Programs

  • Mathematica
    Table[4*Product[-2 + Prime[z], {z, 4, i}] -
       6*Product[-3 + Prime[z], {z, 4, i}] +
       2*Product[-4 + Prime[z], {z, 4, i}], {i, 20}]

Formula

a(n) = 4*product(p-2) - 6*product(p-3) + 2*product(p-4), where p runs through the primes > 5 and <= prime(n).
Showing 1-8 of 8 results.