A173999 Successive positions of odd digits in decimal expansion of Pi (position 0 means 3 before comma or decimal point).
0, 1, 3, 4, 5, 8, 9, 10, 12, 13, 14, 15, 17, 24, 25, 27, 29, 30, 31, 37, 38, 39, 40, 42, 43, 44, 45, 46, 47, 48, 49, 51, 55, 56, 58, 61, 62, 64, 66, 68, 79, 80, 86, 90, 91, 94, 95, 96, 99, 100, 103, 109, 110, 111, 115, 120, 122, 123, 129, 130, 131, 133, 137, 138, 139, 141
Offset: 0
Examples
Pi=3,141592653589793... 0 in this sequence because 3 is odd. 1 in this sequence because 1 is odd. 2 is not in this sequence because second digit after comma 4 is not even.
Programs
-
Mathematica
s = First[RealDigits[N[Pi, 1000]]]; aa = {}; Do[If[OddQ[s[[n]]], AppendTo[aa, n - 1]], {n, 1, Length[s]}]; aa (*Artur Jasinski*) Flatten[Position[RealDigits[\[Pi],10,150][[1]],?OddQ]-1] (* _Harvey P. Dale, Apr 19 2011 *)
Extensions
Edited by Charles R Greathouse IV, Aug 02 2010
Definition clarified by Harvey P. Dale, Apr 01 2019