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.

A072512 Product of all n - d, where 1 < d < n and d is a divisor of n.

Original entry on oeis.org

1, 1, 1, 2, 1, 12, 1, 24, 6, 40, 1, 4320, 1, 84, 120, 1344, 1, 25920, 1, 43200, 252, 220, 1, 31933440, 20, 312, 432, 183456, 1, 136080000, 1, 322560, 660, 544, 840, 12563527680, 1, 684, 936, 919296000, 1, 1155772800, 1, 1219680, 1814400, 1012, 1
Offset: 1

Views

Author

Amarnath Murthy, Jul 28 2002

Keywords

Comments

For prime p, a(p) = 1.
If n is not a prime or the square of a prime then n divides a(n).

Examples

			For n = 16 the nontrivial divisors d are 2,4 and 8, so a(16) = (16-2)*(16-4)*(16-8) = 14*12*8 = 1344.
		

Crossrefs

Cf. A072513.

Programs

  • Maple
    f:= proc(n) local d; mul(n-d, d = numtheory:-divisors(n) minus {1,n}) end proc:
    map(f, [$1..50]); # Robert Israel, Dec 30 2024
  • PARI
    a(n) = my(d=divisors(n)); prod(j=2, matsize(d)[2]-1, n-d[j]);

Extensions

Edited and extended by Klaus Brockhaus, Jul 31 2002