A007627 Primitive modest numbers.
13, 19, 23, 29, 49, 59, 79, 89, 103, 109, 111, 133, 199, 203, 209, 211, 233, 299, 311, 409, 411, 433, 499, 509, 511, 533, 599, 611, 709, 711, 733, 799, 809, 811, 833, 899, 911, 1003, 1009, 1011, 1027, 1033, 1037, 1099, 1111
Offset: 1
References
- Problem 1291, J. Rec. Math., 17 (No.2, 1984), 140-141.
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
Links
- Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
- H. Havermann, Modest numbers, J. Recreational Mathematics, 17.2 (1984), 140-141. (Annotated scanned copy)
Programs
-
Haskell
import Data.List (inits, tails) a007627 n = a007627_list !! (n-1) a007627_list = filter modest' [1..] where modest' x = or $ zipWith m (map read $ (init $ tail $ inits $ show x) :: [Integer]) (map read $ (tail $ init $ tails $ show x) :: [Integer]) where m u v = u < v && (x - u) `mod` v == 0 && gcd u v == 1 -- Reinhard Zumkeller, Mar 27 2011
Formula
n = a*10^k + b such that (a, b)=1, n == a (mod b), a < b < 10^k.
Comments