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.

A055634 2-adic factorial function.

This page as a plain text file.
%I A055634 #35 Jul 29 2023 03:00:11
%S A055634 1,-1,1,-3,3,-15,15,-105,105,-945,945,-10395,10395,-135135,135135,
%T A055634 -2027025,2027025,-34459425,34459425,-654729075,654729075,
%U A055634 -13749310575,13749310575,-316234143225,316234143225,-7905853580625,7905853580625,-213458046676875,213458046676875
%N A055634 2-adic factorial function.
%C A055634 Also known as Morita's 2-adic gamma function. - _Harry Richman_, Jul 26 2023
%D A055634 Serge Lang, Cyclotomic Fields I and II, Springer-Verlag, 1990, p. 315.
%H A055634 Kenny Lau, <a href="/A055634/b055634.txt">Table of n, a(n) for n = 0..806</a>
%H A055634 Daniel Barsky, <a href="http://www.numdam.org/item/GAU_1977-1978__5__A1_0/">On Morita's p-adic Gamma function</a>, Groupe de travail d'analyse ultramétrique, 5 (1977-1978), Talk no. 3, 6 p.
%H A055634 Wikipedia, <a href="https://en.wikipedia.org/wiki/P-adic_gamma_function">P-adic gamma function</a>.
%F A055634 a(2*n) = -a(2*n - 1) = (2*n - 1)!!
%F A055634 a(n) = (-1)^n*n!/A037223(n), A037223(n) = 2^floor(n/2)*floor(n/2)!. Exponential generating function: (1-x)*exp(x^2/2). - Antonio G. Astudillo (afg_astudillo(AT)hotmail.com), Nov 01 2002
%t A055634 a[ n_] := If[ n < 0, 0, n! (-1)^n / (n - Mod[n, 2])!!]; (* _Michael Somos_, Jun 30 2018 *)
%t A055634 4[ n_] := If[ n < 0, 0, n! SeriesCoefficient[ (1 - x) Exp[x^2/2], {x, 0, n}]]; (* _Michael Somos_, Jun 30 2018 *)
%o A055634 (PARI) {a(n) = if( n<1, 1, -if( n%2, n * a(n-1), a(n-1)))};
%o A055634 (PARI) a(n)=(-1)^n*(n=bitor(n-1,1))!/(n\2)!>>(n\2) \\ _Charles R Greathouse IV_, Oct 01 2012
%o A055634 (Sage)
%o A055634 def Gauss_factorial(N, n): return mul(j for j in (1..N) if gcd(j, n) == 1)
%o A055634 def A055634(n): return (-1)^n*Gauss_factorial(n, 2)
%o A055634 [A055634(n) for n in (0..28)]  # _Peter Luschny_, Oct 01 2012
%o A055634 (Magma) /* Based on Gauss factorial n_2!: */ k:=2; [IsZero(n) select 1 else (-1)^n*&*[j: j in [1..n] | IsOne(GCD(j,k))]: n in [0..30]]; // _Bruno Berselli_, Dec 10 2013
%Y A055634 Cf. A000142, A006882, A001147, A133221.
%K A055634 sign
%O A055634 0,4
%A A055634 _Michael Somos_, Jun 06 2000