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.

A278996 Numbers of the form (3h+1)*3^(2k)-1 or (3h+2)*3^(2k+1)-1 for h,k in N.

Original entry on oeis.org

0, 3, 5, 6, 8, 9, 12, 14, 15, 18, 21, 23, 24, 27, 30, 32, 33, 35, 36, 39, 41, 42, 45, 48, 50, 51, 53, 54, 57, 59, 60, 62, 63, 66, 68, 69, 72, 75, 77, 78, 80, 81, 84, 86, 87, 89, 90, 93, 95, 96, 99, 102, 104, 105, 108, 111, 113, 114, 116, 117, 120, 122, 123, 126, 129, 131
Offset: 1

Views

Author

N. J. A. Sloane, Dec 07 2016

Keywords

Comments

n is in the sequence if and only if either n == 0, 3, 5, or 6 (mod 9) or n == 8 (mod 9) and (n-8)/9 is in the sequence. - Robert Israel, Dec 15 2016

Crossrefs

Complement of A278997.

Programs

  • Maple
    filter:= proc(n) local m;
      m:= padic:-ordp(n+1,3);
      (n+1)/3^m mod 3 = 1 + (m mod 2)
    end proc:
    select(filter, [$0..100]); # Robert Israel, Dec 15 2016
  • Mathematica
    isok[n_]:=Module[{ord=IntegerExponent[n+1,3]},Mod[(n+1)/3^ord,3]==Mod[ord,2]+1];Select[Range[0,131],isok](* Ray Chandler, Dec 17 2016 *)

Extensions

More terms from Robert Israel, Dec 15 2016