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

A186193 Numbers k such that k!! is divisible by (k+1).

Original entry on oeis.org

14, 20, 24, 26, 32, 34, 38, 44, 48, 50, 54, 56, 62, 64, 68, 74, 76, 80, 84, 86, 90, 92, 94, 98, 104, 110, 114, 116, 118, 120, 122, 124, 128, 132, 134, 140, 142, 144, 146, 152, 154, 158, 160, 164, 168, 170, 174, 176, 182, 184, 186, 188, 194, 200, 202, 204, 206
Offset: 1

Views

Author

Zak Seidov, Feb 14 2011

Keywords

Comments

Positions of zeros in A119688 (k!! mod (k+1)).
All terms are even (for k odd, k!! is odd and not divisible by even (k+1)).
Apparently all integers of form 8+6*j, j >= 1, are in the sequence.
Exactly all even numbers k >= 14 with composite k+1 are in this sequence. - Alois P. Heinz, Feb 15 2011

Examples

			14!! = 14*12*10*8*6*4*2 = 645120 = 43008*15, so 14 is in the sequence.
16!! = 16*14*12*10*8*6*4*2 = 10321920 is not divisible by 17, so 16 is not in the sequence.
20!! = 20*18*16*14*12*10*8*6*4*2 = 3715891200 = 176947200*21, so 20 is in the sequence.
		

Crossrefs

Programs

  • Magma
    DoubleFactorial:=func< n | &*[n..2 by -2] >; [ n: n in [1..250] | DoubleFactorial(n) mod (n+1) eq 0 ]; // Klaus Brockhaus, Feb 15 2011
  • Maple
    a:= proc(n) option remember; local k;
          if n=1 then 14
        else for k from 2+a(n-1) by 2
                while isprime(k+1)
             do od; k
          fi
        end:
    seq(a(n), n=1..100);  # Alois P. Heinz, Feb 15 2011
  • Mathematica
    Select[Range[300], Divisible[#!!, #+1]&] (* Jean-François Alcover, Nov 11 2020 *)

A126868 a(n) = (n+1)!! mod n.

Original entry on oeis.org

0, 1, 2, 3, 3, 3, 6, 1, 6, 5, 1, 3, 8, 7, 0, 1, 13, 9, 1, 15, 0, 11, 1, 9, 0, 13, 0, 7, 17, 15, 1, 1, 0, 17, 0, 27, 6, 19, 0, 25, 9, 21, 1, 11, 0, 23, 46, 33, 0, 25, 0, 39, 30, 27, 0, 49, 0, 29, 58, 15, 50, 31, 0, 1, 0, 33, 1, 51, 0, 35, 1, 9, 27, 37, 0, 19, 0, 39, 78, 65, 0, 41, 82, 63, 0, 43
Offset: 1

Views

Author

Keywords

Examples

			n=3 (n+1)!! = 4!! = 8; (8 mod 3) = 2.
n=4 (n+1)!! = 5!! = 15; (15 mod 4) = 3.
		

Crossrefs

Programs

  • Maple
    P:=proc(n) local i,j,k,w; for i from 1 by 1 to n do k:=i+1; w:=i-1; while w>0 do k:=k*w; w:=w-2; od; j:=(k mod i); print(j); od; end: P(100);
  • Mathematica
    Table[Mod[(n+1)!!,n],{n,86}] (* James C. McMahon, Dec 27 2024 *)
  • PARI
    df(n) = prod(i=0, (n-1)\2, n - 2*i );
    a(n) = df(n+1) % n; \\ Michel Marcus, Aug 22 2016
Showing 1-2 of 2 results.