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

A330526 a(n) = (p-1)! mod p^3, where p = prime(n).

Original entry on oeis.org

1, 2, 24, 34, 494, 675, 4419, 4008, 4944, 13136, 21730, 23531, 14103, 41236, 86432, 77644, 64250, 148534, 243209, 141005, 384490, 373985, 29215, 101281, 543102, 109281, 154396, 1122108, 965630, 1006716, 1283207, 152876, 2147337, 1419745, 1545874, 1381045, 1108262, 123879
Offset: 1

Views

Author

Michel Marcus, Dec 17 2019

Keywords

Crossrefs

Programs

  • Magma
    [Factorial(p-1)mod p^3: p in PrimesUpTo(170)]; // Marius A. Burtea, Dec 18 2019
  • Maple
    f:= proc(n) local p,p3,k,r;
        p:= ithprime(n);
        p3:= p^3;
        r:= 1:
        for k from 1 to p-1 do
          r:= r*k mod p3
        od;
        r
    end proc:
    map(f, [$1..100]); # Robert Israel, Dec 18 2019
  • Mathematica
    Mod[(#-1)!,#^3]&/@Prime[Range[40]] (* Harvey P. Dale, Jan 09 2024 *)
  • PARI
    a(n) = my(p=prime(n)); (p-1)! % p^3;
    

Formula

a(n)= A177771(n) mod A030078(n).
Showing 1-1 of 1 results.