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

A099796 a(n) = (A094998(n)-1) / A099795(n).

Original entry on oeis.org

1, 1, 2, 5, 10, 3, 10, 4, 3, 28, 17, 18, 30, 20, 41, 42, 14, 19, 30, 37, 63, 50, 7, 12, 83, 30, 91, 19, 69, 91, 97, 56, 22, 80, 39, 137, 44, 9, 154, 19, 37, 141, 141, 168, 126, 183, 200, 205, 136, 55, 95, 204, 126, 213, 230, 68, 63, 158, 202, 162, 102, 182, 104, 38, 165, 119
Offset: 1

Views

Author

Ray Chandler, Oct 29 2004

Keywords

Crossrefs

Cf. A059955. [From R. J. Mathar, Sep 02 2008]

A254924 a(n) = (A060371(n) - A094998(n))/A056604(n) for n > 1, with a(1)=1.

Original entry on oeis.org

1, 0, 0, 1, 130, 1329, 1707670, 27502484, 209927657739, 130904517147542068, 3673771932850374193, 69623451054783204822486486, 3724616892817543661693877073170, 149157913707716515940392007441860, 12429106799179771738076359013310638297
Offset: 1

Views

Author

Bruno Berselli, Feb 12 2015 - proposed by Umberto Cerruti (Department of Mathematics "Giuseppe Peano", University of Turin, Italy)

Keywords

Comments

Let theta(p) be the smallest nonnegative solution z to the system of congruences z == 0 (mod p), z == 1 (mod v(p-1)), where p is a prime and v(p-1) = lcm(1,...,p-1). Theta(p) is unique mod lcm(p, v(p-1)), therefore it is unique mod v(p). Since both (p-1)!+1 and theta(p) are solutions to these congruences, ((p-1)!+1 - theta(p))/v(p) is always an integer. The sequence lists the values of this ratio (assuming theta(2)=0 and p=prime(n)).

Examples

			For n=5, a(5) = (A060371(5) - A094998(5))/A056604(5) = (3628801 - 25201)/27720 = 130.
		

Crossrefs

Programs

  • Magma
    [(Factorial(p-1)+1-Modinv(p,Lcm([1..p-1]))*p)/Lcm([1..p]): p in PrimesUpTo(50)];
  • Maple
    with(numtheory): P:=proc(q)  local a,j,k,ok,n;  print(1); a:=[1];
    for n from 3 to q do k:=0; a:=[op(a),n]; if isprime(n) then ok:=0;  while ok=0 do ok:=1;
    k:=k+1; for j from 2 to n-1 do if not (k*n mod j)=1 then ok:=0; break; fi; od; od;
    print((((n-1)!+1)-k*n)/lcm(op(a))); fi; od; end: P(100); # Paolo P. Lava, Feb 16 2015
  • Mathematica
    r[k_] := LCM @@ Range[k]; s[k_] := PowerMod[k, -1, r[k - 1]] k; w[k_] := ((k - 1)! + 1 - s[k])/r[k]; Table[w[Prime[n]], {n, 1, 20}]

A099795 Least common multiple of 1, 2, 3, ..., prime(n)-1.

Original entry on oeis.org

1, 2, 12, 60, 2520, 27720, 720720, 12252240, 232792560, 80313433200, 2329089562800, 144403552893600, 5342931457063200, 219060189739591200, 9419588158802421600, 3099044504245996706400, 164249358725037825439200, 9690712164777231700912800
Offset: 1

Views

Author

Ray Chandler, Oct 29 2004

Keywords

Comments

Alternative definition: a(n) = Product{i = 1..(n-1)}prime(i)^e_i, where prime(i)^e_i is the greatest power of prime(i) which does not exceed prime(n). Every term is a product of prime powers, and also of primorial powers(the greatest of which is A002110(n-1); see Example and A053589). - David James Sycamore, Oct 24 2024

Examples

			For n = 7, prime(7) = 17, using the alternative definition (see Comment), a(7) = 2^4*3^2*5^1*7^1*11^1*13^1 = 16*9*5*7*11*13 = 720720 = 24*30030 = 2^2*6*30030 = A002110(1)^2*A002110(2)*A002110(6). - _David James Sycamore_, Oct 24 2024
		

Crossrefs

Programs

  • Magma
    [Lcm([2..p-1]): p in PrimesUpTo(70)]; // Bruno Berselli, Feb 06 2015
  • Maple
    Primes:= select(isprime, [2,$3..100]):
    seq(ilcm($2..Primes[i]-1),i=1..nops(Primes)); # Robert Israel, Jul 19 2016
  • Mathematica
    LCM@@Range[#]&/@(Prime[Range[20]]-1) (* Harvey P. Dale, Jan 30 2015 *)

Formula

a(n) = (A094998(n)-1) / A099796(n).
a(n) = A038610(A000040(n)). - Anthony Browne, Jul 19 2016
Rad(a(n)) = A007947(a(n)) = A002110(n-1). - David James Sycamore, Oct 24 2024

Extensions

a(18) from Bruno Berselli, Feb 06 2015

A099794 a(n) = smallest integer k such that k*prime(n) == 1 mod j for each integer j with 1

Original entry on oeis.org

1, 1, 5, 43, 2291, 6397, 423953, 2579419, 30364247, 77544004469, 1277242663471, 70250377083373, 3909462041753561, 101888460343995907, 8217087542785091183, 2455846588270412484317, 38974424104246263663539
Offset: 1

Views

Author

Ray Chandler, Oct 29 2004

Keywords

Crossrefs

Programs

  • Magma
    /* By definition (slow): */
    S:=[]; for n in [1..9] do k:=1; while not forall{j: j in [2..NthPrime(n)-1] | IsOne(k*NthPrime(n) mod j)} do k:=k+1; end while; Append(~S, k); end for; S; /* or */
    [p eq 2 select 1 else Modinv(p, Lcm([1..p-1])): p in PrimesUpTo(60)];// Bruno Berselli, Feb 08 2015
  • Mathematica
    a[1] = a[2] = 1; a[n_] := Module[{p, m, r, r0, r1}, p = Prime[n]; m = LCM @@ Range[2, p-1]; r = Reduce[k>0 && p*k + m*j == 1, {k, j}, Integers]; r0 = r /. C[] -> 0; r1 = r /. C[] -> 1 ; If[r0 === False, r1[[1, 2]], Min[r0[[1, 2]], r1[[1, 2]]]]]; Table[a[n], {n, 1, 20}] (* Jean-François Alcover, Feb 09 2015 *)

Formula

a(n) = A094998(n) / prime(n).

A234423 a(n) = the smallest multiple of prime(n) such that a(n) == j-1 (mod j) for each integer j with 1 <= j < prime(n).

Original entry on oeis.org

2, 3, 35, 119, 2519, 277199, 5045039, 183783599, 4655851199, 80313433199, 32607253879199, 2743667504978399, 58772246027695199, 5038384364010597599
Offset: 1

Views

Author

Jaroslav Krizek, Dec 25 2013

Keywords

Comments

Sequence of numbers k(n): 1, 1, 7, 17, 229, 21323, 296767, 9672821, 202428313, 2769428731, 1051846899329, ...

Examples

			Prime(4) = 7, a(4) = 119 = 7*17 because 119 is smallest multiple of 7 such that 119 mod 1 = 0, 119 mod 2 = 1, 119 mod 3 = 2, 119 mod 4 = 3, 119 mod 5 = 4, 119 mod 6 = 5.
		

Crossrefs

Cf. A000040 (primes), A094998.

Programs

  • PARI
    for(n=1, 10, p=prime(n); forstep(m=p, 10^11, p, forstep(j=p-1, 1, -1, if(m%j<>j-1, next(2))); print(n " " m); next(2))) \\ Donovan Johnson, Dec 30 2013

Extensions

a(12)-a(14) from Donovan Johnson, Dec 30 2013
Showing 1-5 of 5 results.