|
|
A309320
|
|
a(n) is the smallest positive integer m such that the digits of n in base 10 are also the first digits of sin(m) in base 10 after the decimal point.
|
|
1
|
|
|
0, 3, 6, 53, 9, 10, 7, 4, 1, 2, 91, 69, 47, 25, 3, 41, 63, 85, 107, 129, 151, 160, 138, 116, 94, 72, 50, 6, 16, 38, 60, 82, 104, 148, 170, 163, 141, 97, 75, 53, 31, 9, 13, 57, 79, 101, 145, 167, 166, 122, 100, 78, 34, 12, 10, 32, 76, 98, 120, 164, 147, 125, 81
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,2
|
|
LINKS
|
|
|
EXAMPLE
|
a(1) = 3 because we have sin(1.) = 0.8414709848..., sin(2.) = 0.9092974268..., sin(3.) = 0.1411200081.. - N. J. A. Sloane, Sep 28 2019
|
|
MATHEMATICA
|
a[0] =0; a[n_] := Module[{m = 1}, While[(d = IntegerDigits[n]) != RealDigits[ Sin[m], 10, Length[d], -1][[1]], m++]; m]; Array[a, 100, 0] (* Amiram Eldar, Sep 28 2019 *)
|
|
PROG
|
(Python) import numpy as np
import math as m
n = 1
i = 0
inp = np.zeros(1)
out = inp
while n < 10001:
k=m.fabs( m.trunc( m.sin(i) * m.pow( 10, m.floor( m.log10(n)+1 ) ) ) )
if k==n:
inp = np.append(inp, int(n))
out = np.append(out, int(i))
print(n, i)
n += 1
i = 0
continue
else:
i+=1
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|