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.

A181898 Smallest positive integer which cannot be calculated by an expression containing n binary operators (any of add, subtract, multiply and divide) whose operands are any integer between 1 and 9; parentheses allowed.

Original entry on oeis.org

10, 19, 92, 417, 851, 4237, 14771, 73237, 298609
Offset: 0

Views

Author

Derek M. Jones, Apr 03 2012

Keywords

Examples

			a(2)=92 because at least 3 operators are required, e.g., (2*7 + 9)*4.
		

Crossrefs

Cf. A181957, A181958, A181959, A181960, A005520, A048183 (see text of comment).

Programs

  • PARI
    first(n)=my(op=[(x,y)->x+y, (x,y)->x-y, (x,y)->y-x, (x,y)->x*y, (x,y)->x/y, (x,y)->y/x], v=vector(n+1), t); v[1]=[1..9]; for(k=2,#v, my(u=[]); for(i=1,(k+1)\2, my(a=v[i],b=v[k-i]); t=Set(concat(apply(f->setbinop(f,a,b), op))); u=concat(u,t)); v[k]=setminus(Set(u), [0])); t=10; for(i=1,#v, while(setsearch(v[i],t), t++); v[i]=t); v \\ Charles R Greathouse IV, Jan 09 2017
  • R
    See Jones link.