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

A231531 Imaginary part of Product_{k = 1..n} (k + i), i = sqrt(-1).

Original entry on oeis.org

0, 1, 3, 10, 40, 190, 1050, 6620, 46800, 365300, 3103100, 28269800, 271627200, 2691559000, 26495469000, 238131478000, 1394099824000, -15194495654000, -936096296850000, -29697351895900000, -819329864480400000, -21683886333440500000, -570263312237604700000, -15145164178973569000000, -409583160925827252000000
Offset: 0

Views

Author

Stanislav Sykora, Nov 10 2013

Keywords

Comments

Extension of factorial(n) to factim(n,m) defined by the recurrence a(0)=1, a(n)=a(n-1)*(n+m*i). Hence n! = factim(n,0), while the current sequence shows the imaginary parts of factim(n,1). The real parts are in A231530 and squares of magnitudes are in A101686.
From Peter Bala, Jun 01 2023: (Start)
Compare with A105751(n) = the imaginary part of Product_{k = 0..n} (1 + k*sqrt(-1)). Moll (2012) studied the prime divisors of the terms of A105750 - the real part of Product_{k = 0..n} (1 + k*sqrt(-1)) - and divided the primes into three types. Calculation suggests that a similar division holds in this case.
Type 1: the prime p does not divide any element of the sequence. It appears that for this sequence, unlike in A105750, there are no type 1 primes; i.e., every prime p divides some term of the sequence.
Type 2: primes p such that the p-adic valuation v_p(a(n)) has asymptotically linear behavior. An example is given below.
We conjecture that the set of type 2 primes consists of p = 2 and all primes of the form p == 1 (mod 4). See A002144.
Moll's conjecture 5.5 about type 2 primes extends to this sequence and takes the form:
(i) the 2-adic valuation v_2(a(n)) ~ n/4 as n -> oo.
(ii) for a type 2 prime p, the p-adic valuation v_p(a(n)) ~ n/(p - 1) as n -> oo.
Type 3: primes p such that the sequence of p-adic valuations {v_p(a(n)) : n >= 0} exhibits an oscillatory behavior (this phrase is not precisely defined). An example is given below.
We conjecture that the set of type 3 primes is A002145, primes of the form 4*k + 3. (End)

Examples

			factim(5,1) = -90+190*i. Hence a(5) = 190.
From _Peter Bala_, Jun 01 2023: (Start)
Asymptotic linearity for the type 2 prime p = 5: the sequence of 5-adic valuations [ v_5(a(n)) : n = 1..100] = [0, 0, 1, 1, 1, 2, 1, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 5, 5, 5, 6, 5, 6, 6, 7, 6, 6, 7, 7, 7, 8, 7, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 11, 11, 11, 13, 11, 12, 12, 13, 12, 12, 13, 13, 13, 14, 13, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 18, 19, 18, 18, 18, 19, 19, 19, 20, 19, 20, 21, 20, 20, 20, 21, 21, 21, 21, 21, 22, 22, 22, 22, 22, 24, 25, 24, 24, 24, 25, 25, 25].
Note that v_5(a(100)) = 25 = 100/(5 - 1), in line with Moll's conjecture 5.5 above.
Oscillatory behavior for the type 3 prime p = 3: the sequence of 3-adic valuations [ v_3(a(n)) : n = 1..100] = [0, 1, 0, 0, 0, 1, 0, 2, 0, 0, 0, 2, 0, 2, 0, 0, 0, 2, 0, 1, 0, 0, 0, 1, 0, 3, 0, 0, 0, 3, 0, 2, 0, 0, 0, 2, 0, 1, 0, 0, 0, 1, 0, 2, 0, 0, 0, 2, 0, 3, 0, 0, 0, 3, 0, 1, 0, 0, 0, 1, 0, 2, 0, 0, 0, 2, 0, 2, 0, 0, 0, 2, 0, 1, 0, 0, 0, 1, 0, 4, 0, 0, 0, 4, 0, 2, 0, 0, 0, 2, 0, 1, 0, 0, 0, 1, 0, 2, 0, 0]. It appears that v_3(a(n)) = 0 unless n == 0 or 2 (mod 6). (End)
		

Crossrefs

Cf. A231530 (real parts), A101686 (squares of magnitudes), A003703, A105750, A105751.
See A242651, A242652 for a pair of similar sequences.

Programs

  • Maple
    seq(simplify(-sinh(Pi)*Im(I!*(n-I)!)/Pi), n=0..19); # Peter Luschny, Oct 23 2015
  • Mathematica
    Table[Im[Pochhammer[1+I, n]], {n, 0, 20}]
    Table[Sum[(-1)^(n+k) StirlingS1[n+1, 2k], {k, 0, (n+1)/2}], {n, 0, 20}] (* Vladimir Reshetnikov, Oct 22 2015 *)
  • PARI
    Factim(nmax, m)={local(a, k); a=vector(nmax); a[1]=1+0*I;
      for (k=2, nmax, a[k]=a[k-1]*(k-1+m*I); ); return(a); }
    a = Factim(1000,1); imag(a)
    
  • PARI
    t(n) = if( n<0, 0, n! * polcoeff(cos(log(1+x+x*O(x^n))), n));
    vector(50, n, n--; (-1)^n*t(n+1)) \\ Altug Alkan, Oct 22 2015
    
  • Python
    from sympy.functions.combinatorial.numbers import stirling
    def A231531(n): return sum(stirling(n+1,k<<1,kind=1)*(1 if k&1 else -1) for k in range((n+1>>1)+1)) # Chai Wah Wu, Feb 22 2024

Formula

From Vladimir Reshetnikov, Oct 22 2015: (Start)
a(n) = Im((1+i)_n) = -Re(Gamma(i)*Gamma(n+1-i))*sinh(Pi)/Pi, where (a)_n is the Pochhammer symbol, i=sqrt(-1).
a(n) = (-1)^n*A003703(n+1).
E.g.f.: sin(log(1-x))/(x-1). (End)
P-recursive: a(n) = (2*n - 1)*a(n-1) - (n^2 - 2*n + 2)*a(n-2) with a(0) = 0 and a(1) = 1. - Peter Bala, Jun 01 2023

A231530 Real part of Product_{k=1..n} (k+i), where i is the imaginary unit.

Original entry on oeis.org

1, 1, 1, 0, -10, -90, -730, -6160, -55900, -549900, -5864300, -67610400, -839594600, -11186357000, -159300557000, -2416003824000, -38894192662000, -662595375078000, -11911522255750000, -225382826562400000, -4477959179352100000, -93217812901913700000, -2029107997508660900000
Offset: 0

Views

Author

Stanislav Sykora, Nov 10 2013

Keywords

Comments

Extension of factorial(n) to factim(n,m) defined by the recurrence a(0)=1, a(n) = a(n-1)*(n+m*i), where i is the imaginary unit. Hence n! = factim(n,0), while the current sequence lists the real parts of factim(n,1). The imaginary parts are in A231531 and squares of magnitudes are in A101686.

Examples

			factim(5,1) = -90 + 190*i. Hence a(5) = -90.
		

Crossrefs

Cf. A231531 (imaginary parts), A101686 (squares of magnitudes), A009454.
See A242651, A242652 for a pair of similar sequences.

Programs

  • Maple
    seq(simplify(Re(I!*(n-I)!)*sinh(Pi)/Pi),n=0..22); # Peter Luschny, Oct 23 2015
  • Mathematica
    Table[Re[Product[k+I,{k,n}]],{n,0,30}] (* Harvey P. Dale, Aug 04 2016 *)
  • PARI
    Factim(nmax,m)={local(a,k);a=vector(nmax);a[1]=1+0*I;
      for (k=2,nmax,a[k]=a[k-1]*(k-1+m*I););return(a);}
    a = Factim(1000,1); real(a)
    
  • Python
    from sympy.functions.combinatorial.numbers import stirling
    def A231530(n): return sum(stirling(n+1,(k<<1)+1,kind=1)*(-1 if k&1 else 1) for k in range((n>>1)+1)) # Chai Wah Wu, Feb 22 2024
  • Sage
    A231530 = lambda n : rising_factorial(1-I, n).real()
    [A231530(n) for n in range(24)] # Peter Luschny, Oct 23 2015
    

Formula

From Peter Luschny, Oct 23 2015: (Start)
a(n) = Re(i!*(n-i)!)*sinh(Pi)/Pi.
a(n) = n!*[x^n](cos(log(1-x))/(1-x)).
a(n) = Sum_{k=0..floor(n/2)} (-1)^(n+k)*Stirling1(n+1,2*k+1).
a(n) = Re(rf(1+i,n)) where rf(k,n) is the rising factorial and i the imaginary unit.
a(n) = (-1)^n*A009454(n+1). (End)

A242652 Imaginary part of Product_{k=0..n} (i-k), where i=sqrt(-1).

Original entry on oeis.org

1, -1, 1, 0, -10, 90, -730, 6160, -55900, 549900, -5864300, 67610400, -839594600, 11186357000, -159300557000, 2416003824000, -38894192662000, 662595375078000, -11911522255750000, 225382826562400000, -4477959179352100000, 93217812901913700000, -2029107997508660900000, 46099220630461596000000
Offset: 0

Views

Author

N. J. A. Sloane, May 29 2014

Keywords

Comments

Shifted version of A009454. - R. J. Mathar, May 30 2014

Examples

			Table of n, Product_{k=0..n} (i-k):
   0, i
   1, -1 - i
   2, 3 + i
   3, -10
   4, 40 - 10*i
   5, -190 + 90*i
   6, 1050 - 730*i
   7, -6620 + 6160*i
   8, 46800 - 55900*i
   9, -365300 + 549900*i
  10, 3103100 - 5864300*i
  11, -28269800 + 67610400*i
  12, 271627200 - 839594600*i
		

References

  • Edmund Landau, Handbuch der Lehre von der Verteilung der Primzahlen, Chelsea Publishing, NY 1953, pp. 561-562, Section 148.

Crossrefs

Cf. A009454.
A231531 is the same except for signs.

Programs

  • Maple
    a:= n-> Im(mul(I-j, j=0..n)):
    seq(a(n), n=0..25);  # Alois P. Heinz, Jan 03 2021
  • PARI
    a(n) = imag(prod(k=0, n, I-k)); \\ Michel Marcus, Jan 03 2021
Showing 1-3 of 3 results.