login
A187338
a(n) = 3*n + floor(sqrt(2)*n), complement of A187328.
5
4, 8, 13, 17, 22, 26, 30, 35, 39, 44, 48, 52, 57, 61, 66, 70, 75, 79, 83, 88, 92, 97, 101, 105, 110, 114, 119, 123, 128, 132, 136, 141, 145, 150, 154, 158, 163, 167, 172, 176, 180, 185, 189, 194, 198, 203, 207, 211, 216, 220, 225, 229, 233, 238, 242, 247, 251, 256, 260, 264, 269, 273, 278, 282, 286, 291, 295, 300
OFFSET
1,1
COMMENTS
A187338 and A187328 are a pair of Beatty sequences. The following three sequences partition the natural numbers:
A190329: a(n)=n+[n*sqrt(2)]+[n/sqrt(2)].
A190330: b(n)=n+[n/sqrt(2)]+[n/2].
A187338: c(n)=3n+[n*sqrt(2)].
LINKS
FORMULA
a(n) = 3*n + floor(sqrt(2)*n) = 3*n+A001951(n).
MATHEMATICA
Table[Floor[(3+2^(1/2))n], {n, 1, 120}]
With[{c=3+Sqrt[2]}, Floor[c*Range[70]]] (* Harvey P. Dale, Aug 15 2013 *)
PROG
(PARI) for(n=1, 70, print1(3*n + floor(sqrt(2)*n), ", ")) \\ G. C. Greubel, Jan 29 2018
(Magma) [3*n + Floor(Sqrt(2)*n): n in [1..70]]; // G. C. Greubel, Jan 29 2018
(Python)
from sympy import integer_nthroot
def A187338(n): return 3*n+integer_nthroot(2*n**2, 2)[0] # Chai Wah Wu, Mar 17 2021
CROSSREFS
Cf. A187328.
Sequence in context: A311922 A311923 A311924 * A311925 A311926 A311927
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Mar 08 2011
STATUS
approved