

A124666


Numbers ending in 1, 3, 7 or 9 such that either prepending or following them by one digit doesn't produce a prime.


1



891, 921, 1029, 1037, 1653, 1763, 1857, 2427, 2513, 2519, 2607, 3111, 3193, 3213, 3501, 3519, 3707, 3953, 4227, 4459, 4599, 4689, 4803, 4863, 5019, 5043, 5047, 5397, 5459, 5489, 5499, 6019, 6023, 6429, 6483, 6609, 6621, 7113
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,1


COMMENTS

If the number doesn't end in 1, 3, 7 or 9, then the prepending requirement is automatically satisfied. Hence it becomes nonrestrictive and not very interesting.


LINKS

Harvey P. Dale, Table of n, a(n) for n = 1..4000


EXAMPLE

The definition means that 891, 1891, 2891, 3891, 4891, 5891, 6891, 7891, 8891, 9891, 8911, 8913, 8917 and 8919 are all composite numbers.


MATHEMATICA

dppQ[n_]:=AllTrue[Join[{n}, Table[m*10^IntegerLength[n]+n, {m, 9}], Table[ n*10+k, {k, {1, 3, 7, 9}}]], CompositeQ]; Select[Range[8000], MemberQ[ {1, 3, 7, 9}, Mod[ #, 10]]&&dppQ[#]&] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, May 19 2018 *)


CROSSREFS

Sequence in context: A110726 A204366 A266915 * A125303 A087672 A284842
Adjacent sequences: A124663 A124664 A124665 * A124667 A124668 A124669


KEYWORD

base,nonn


AUTHOR

Tanya Khovanova, Dec 23 2006


STATUS

approved



