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.

A207187 Numbers matching polynomials y(k,x) that have x+1 as a factor; see Comments.

Original entry on oeis.org

3, 5, 9, 13, 19, 22, 25, 27, 30, 33, 39, 43, 49, 52, 55, 59, 65, 68, 71, 83, 89, 92, 95, 101, 104, 107, 110, 113, 116, 119, 121, 124, 127, 133, 136, 139, 142, 145, 148, 151, 157, 169, 172, 175, 181, 185, 191, 194, 197, 209, 215, 218, 221, 224, 227, 230
Offset: 1

Views

Author

Clark Kimberling, Feb 16 2012

Keywords

Comments

The polynomials y(k,x) range through all monic polynomials with coefficients in {-1,0,1}, ordered as at A206821.

Examples

			The first 13 polynomials:
1 .... 1
2 .... x
3 .... x + 1
4 .... x^2
5 .... x^2 - 1
6 .... x^2 - x
7 .... x^2 - x - 1
8 .... x^2 + 1
9 .... x^2 + x
10 ... x^2 + x + 1
11 ... x^3
12 ... x^3 - 1
13 ... x^3 - x
The list exemplifies these sequences:
A207187 (multiples of x + 1): 3,5,9,13,...
A207188 (multiples of x): 2,4,6,9,11,13,...
A207189 (multiples of x - 1): 5,6,12,13,...
A207190 (multiples of x^2 + 1): 8,20,25,27,...
		

Crossrefs

Cf. A206821.

Programs

  • Mathematica
    t = Table[IntegerDigits[n, 2], {n, 1, 2000}];
    b[n_] := Reverse[Table[x^k, {k, 0, n}]]
    p[n_] := p[n] = t[[n]].b[-1 + Length[t[[n]]]]
    TableForm[Table[{n, p[n], Factor[p[n]]}, {n, 1, 6}]]
    f[k_] := 2^k - k; g[k_] := 2^k - 2 + f[k - 1];
    q1[n_] := p[2^(k - 1)] - p[n + 1 - f[k]]
    q2[n_] := p[n - f[k] + 2]
    y1 = Table[p[n], {n, 1, 4}];
    Do[AppendTo[y1,
      Join[Table[q1[n], {n, f[k], g[k] - 1}],
       Table[q2[n], {n, g[k], f[k + 1] - 1}]]], {k, 3, 10}]
    y = Flatten[y1]; (* monic polynomials over {-1,0,1} *)
    TableForm[Table[{n, y[[n]], Factor[y[[n]]]}, {n, 1, 10}]]
    Table[y[[n]] /. x -> -1, {n, 1, 300}];
    Flatten[Position[%, 0]]  (* A207187 *)
    Table[y[[n]] /. x -> 0, {n, 1, 300}] ;
    Flatten[Position[%, 0]]  (* A207188 *)
    Table[y[[n]] /. x -> 1, {n, 1, 1200}] ;
    Flatten[Position[%, 0]]  (* A207189 *)
    Table[y[[n]] /. x -> I, {n, 1, 600}] ;
    Flatten[Position[%, 0]]  (* A207190 *)