cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-3 of 3 results.

A121153 Numbers k with the property that 1/k can be written in base 3 in such a way that the fractional part contains no 1's.

Original entry on oeis.org

1, 3, 4, 9, 10, 12, 13, 27, 28, 30, 36, 39, 40, 81, 82, 84, 90, 91, 108, 117, 120, 121, 243, 244, 246, 252, 270, 273, 324, 328, 351, 360, 363, 364, 729, 730, 732, 738, 756, 757, 810, 819, 820, 949, 972, 984, 1036, 1053, 1080, 1089, 1092, 1093, 2187
Offset: 1

Views

Author

Jack W Grahl, Aug 12 2006

Keywords

Comments

Numbers k such that 1/k is in the Cantor set.
A subsequence of A054591. The first member of A054591 which does not belong to this sequence is 146. See A135666.
This is not a subsequence of A005836 (949 belongs to the present sequence but not to A005836). See A170830, A170853.

Examples

			1/3 in base 3 can be written as either .1 or .0222222... The latter version contains no 1's, so 3 is in the sequence.
1/4 in base 3 is .02020202020..., so 4 is in the sequence.
		

Crossrefs

Programs

  • Mathematica
    (* Mma code from T. D. Noe, Feb 20 2010. This produces the sequence except for the powers of 3. *)
    (* Find the length of the periodic part of the fraction: *)
    FracLen[n_] := Module[{r = n/3^IntegerExponent[n, 3]}, MultiplicativeOrder[3, r]]
    (* Generate the fractions and select those that have no 1's: *)
    Select[Range[100000], ! MemberQ[Union[RealDigits[1/#, 3, FracLen[ # ]][[1]]], 1] &]
  • PARI
    is(n,R=divrem(3^logint(n,3),n),S=0)={while(R[1]!=1&&!bittest(S,R[2]), S+=1<M. F. Hasler, Feb 27 2018

Extensions

Extended to 10^5 by T. D. Noe and N. J. A. Sloane, Feb 20 2010
Entry revised by N. J. A. Sloane, Feb 22 2010

A170951 Numbers n with the property that some of the fractions i/n (with gcd(i,n)=1, 0 < i/n < 1) are in the Cantor set and some are not.

Original entry on oeis.org

9, 12, 13, 27, 28, 30, 36, 39, 40, 81, 82, 84, 90, 91, 108, 117, 120, 121, 243, 244, 246, 252, 270, 273, 324, 328, 351, 360, 363, 364, 729, 730, 732, 738, 756, 757, 810, 819, 820, 949, 972, 984, 1036, 1053, 1080, 1089, 1092, 1093, 2187
Offset: 1

Views

Author

J. H. Conway and N. J. A. Sloane, Feb 20 2010

Keywords

Comments

Equals A054591 \ {1,3,4,10}.
The natural numbers may be divided into three sets: denominators which force membership in the Cantor set, denominators which deny membership in the Cantor set and denominators which neither force nor deny membership. The first set contains just the numbers 1, 3, 4, 10. The second set is A170944. The third set is the present sequence.

Examples

			1/9 is in the Cantor set, but 4/9 is not.
		

Crossrefs

A170952 Take the Cantor set sequence A121153 and if the entry m = A121153(n) is in the range 3^k <= m < 3^(k+1), subtract 3^k from it.

Original entry on oeis.org

0, 0, 1, 0, 1, 3, 4, 0, 1, 3, 9, 12, 13, 0, 1, 3, 9, 10, 27, 36, 39, 40, 0, 1, 3, 9, 27, 30, 81, 85, 108, 117, 120, 121, 0, 1, 3, 9, 27, 28, 81, 90, 91, 220, 243, 255, 307, 324, 351, 360, 363, 364, 0, 1, 3, 9, 27, 81, 84, 175, 243, 270, 273, 625, 660, 729, 733, 765, 921, 972, 1053
Offset: 1

Views

Author

J. H. Conway, T. D. Noe and N. J. A. Sloane, Feb 22 2010

Keywords

Examples

			If written as a triangle:
0,
0, 1,
0, 1, 3, 4,
0, 1, 3, 9, 12, 13,
0, 1, 3, 9, 10, 27, 36, 39, 40,
0, 1, 3, 9, 27, 30, 81, 85, 108, 117, 120, 121,
0, 1, 3, 9, 27, 28, 81, 90, 91, 220, 243, 255, 307, 324, 351, 360, 363, 364,
0, 1, 3, 9, 27, 81, 84, 175, 243, 270, 273, 625, 660, 729, 733, 765, 921, 972, 1053, 1080, 1089, 1092, 1093,
...
		

Crossrefs

Showing 1-3 of 3 results.