%I #4 Dec 15 2014 08:42:26
%S 1,4,1,2,3,2,10,2,6,4,13,8,3,2,25,5,9,28,1,6,5,17,34,15,9,23,8,49,55,
%T 12,4,33,14,2,24,36,25,2,26,4,2,42,29,11,8,2,10,4,88,6,47,32,48,20,94,
%U 37,23,57,24,3,5,115,6,118,9,44,3,46,68,5,30,139,50,10,51,14,77,20,54,2
%N First member of a pair (A,B) to define the n-th Zeisel number, cf. A051015.
%C Let p(0) = 1 and p(i+1) = A*p(i) + B, if p(i) is prime for i = 1..k, then z = p(1) * ... * p(k) is called a Zeisel number.
%H OEIS Wiki, <a href="https://oeis.org/wiki/Zeisel_numbers">Zeisel numbers</a>
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/ZeiselNumber.html">Zeisel Number.</a>
%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Zeisel_number">Zeisel number</a>
%e . n | A=a(n) B=A252095(n) | p(1) p(2) p(3) | A051015(n)
%e . ---+------------------------+------------------------------
%e . 1 | 1 2 | 3 5 7 | 105
%e . 2 | 4 -1 | 3 11 43 | 1419
%e . 3 | 1 6 | 7 13 19 | 1729
%e . 4 | 2 3 | 5 13 29 | 1885
%e . 5 | 3 2 | 5 17 53 | 4505
%e . 6 | 2 5 | 7 19 43 | 5719
%e . 7 | 10 -7 | 3 23 223 | 15387
%e . 8 | 2 9 | 11 31 71 | 24211
%e . 9 | 6 -1 | 5 29 177 | 25085
%e . 10 | 4 3 | 7 31 141 | 27449
%e . 11 | 13 -10 | 3 29 367 | 31929
%e . 12 | 8 -3 | 5 37 295 | 54205 .
%o (Haskell)
%o a252094 n = a252094_list !! (n-1)
%o (a252094_list, a252095_list) = unzip $ f 3 where
%o f x = if z then (q, p - q) : f (x + 2) else f (x + 2) where
%o z = 0 `notElem` ds && length ds > 2 &&
%o all (== 0) (zipWith mod (tail ds) ds) && all (== q) qs
%o q:qs = (zipWith div (tail ds) ds)
%o ds = zipWith (-) (tail ps) ps
%o ps = 1 : ps'; ps'@(p:_) = a027746_row x
%Y Cf. A051015, A027746, A252095 (B values).
%K nonn
%O 1,2
%A _Reinhard Zumkeller_, Dec 15 2014
|