login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A170826 a(n) = gcd(n^2, n!). 5
1, 2, 3, 8, 5, 36, 7, 64, 81, 100, 11, 144, 13, 196, 225, 256, 17, 324, 19, 400, 441, 484, 23, 576, 625, 676, 729, 784, 29, 900, 31, 1024, 1089, 1156, 1225, 1296, 37, 1444, 1521, 1600, 41, 1764, 43, 1936, 2025, 2116, 47, 2304, 2401, 2500, 2601, 2704, 53, 2916 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
FORMULA
If n is prime then a(n) = n; otherwise, if n <> 4 then a(n) = n^2. - Zak Seidov, Dec 28 2009
a(n) = n!/A092043(n). - Johannes W. Meijer, Jun 04 2016
a(n) = n^2 / n^c(n), where c = A010051 for n >= 5. - Wesley Ivan Hurt, Nov 10 2023
MAPLE
GCDWITHFACTORIAL:=proc(a) local b, i, k:
if whattype(a) <> list then RETURN([]); fi:
b:=[]:
for i to nops(a) do b:=[op(b), gcd(a[i], i!)]: od;
RETURN(b);
end:
A170826 := proc(n): gcd(n^2, n!) end: seq(A170826(n), n=1..54); # Johannes W. Meijer, Jun 04 2016
MATHEMATICA
Table[GCD[n^2, n!], {n, 54}] (* Michael De Vlieger, Jun 05 2016 *)
PROG
(PARI) a(n)=if(isprime(n), n, if(n==4, 8, n^2)) \\ Charles R Greathouse IV, Feb 01 2013
CROSSREFS
Sequence in context: A184392 A007955 A324502 * A162537 A369740 A109844
KEYWORD
nonn,easy
AUTHOR
N. J. A. Sloane, Dec 27 2009
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 16 04:38 EDT 2024. Contains 371696 sequences. (Running on oeis4.)