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.

A110743 Smallest prime beginning with n reversed.

Original entry on oeis.org

11, 2, 3, 41, 5, 61, 7, 83, 97, 11, 11, 211, 31, 41, 5101, 61, 71, 811, 911, 2, 127, 223, 3203, 421, 521, 6203, 727, 821, 929, 3, 13, 23, 331, 43, 53, 631, 73, 83, 937, 41, 149, 241, 347, 443, 541, 641, 743, 8419, 941, 5, 151, 251, 353, 457, 557, 653, 751, 853, 953, 61, 163, 263, 367, 461, 563, 661, 761, 863, 967
Offset: 1

Views

Author

Amarnath Murthy, Aug 10 2005

Keywords

Examples

			a(10) = least prime beginning with 01, i.e. with 1, which is 11.
		

Crossrefs

Programs

  • PARI
    okdigs(np, dfp) = {dnp = digits(np); xdnp = vector(#dfp, id, dnp[id]); return (xdnp == dfp);}
    a(n) = {revn = subst(Polrev(digits(n), x), x, 10); dn = digits(revn); if (revn == 1, p = 2, p = precprime(revn)); while(! okdigs(p, dn), p = nextprime(p+1);); p;} \\ Michel Marcus, Sep 16 2013

Extensions

More terms from Peter Soung (soung3(AT)hotmail.com), Mar 06 2006