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.

Previous Showing 11-19 of 19 results.

A206807 Position of 3^n when {2^j} and {3^k} are jointly ranked; complement of A206805.

Original entry on oeis.org

2, 5, 7, 10, 12, 15, 18, 20, 23, 25, 28, 31, 33, 36, 38, 41, 43, 46, 49, 51, 54, 56, 59, 62, 64, 67, 69, 72, 74, 77, 80, 82, 85, 87, 90, 93, 95, 98, 100, 103, 105, 108, 111, 113, 116, 118, 121, 124, 126, 129, 131, 134, 137, 139, 142, 144, 147, 149, 152, 155
Offset: 1

Views

Author

Clark Kimberling, Feb 16 2012

Keywords

Comments

The joint ranking is for j >= 1 and k >= 1, so that the sets {2^j} and {3^k} are disjoint.

Examples

			The joint ranking begins with 2,3,4,8,9,16,27,32,64,81,128,243,256, so that
A206805 = (1,3,4,6,8,9,11,13,...)
A206807 = (2,5,7,10,12,...)
		

Crossrefs

Programs

  • Mathematica
    f[n_] := 2^n; g[n_] := 3^n; z = 200;
    c = Table[f[n], {n, 1, z}]; s = Table[g[n], {n, 1, z}];
    j = Sort[Union[c, s]];
    p[n_] := Position[j, f[n]]; q[n_] := Position[j, g[n]];
    Flatten[Table[p[n], {n, 1, z}]]           (* A206805 *)
    Table[n + Floor[n*Log[3, 2]], {n, 1, 50}] (* A206805 *)
    Flatten[Table[q[n], {n, 1, z}]]           (* this sequence *)
    Table[n + Floor[n*Log[2, 3]], {n, 1, 50}] (* this sequence as a table *)
  • PARI
    a(n) = logint(3^n, 2) + n; \\ Ruud H.G. van Tol, Dec 10 2023

Formula

a(n) = n + floor(n*log_2(3)).
A206805(n) = n + floor(n*log_3(2)).
a(n) = n + A056576(n). - Michel Marcus, Dec 12 2023
a(n) = A098294(n) + 2*n - 1. - Ruud H.G. van Tol, Jan 22 2024

A258033 Fractal sequence derived from A022328.

Original entry on oeis.org

0, 0, 2, 1, 0, 2, 1, 3, 0, 5, 2, 4, 1, 3, 0, 5, 2, 4, 1, 6, 3, 0, 8, 5, 2, 7, 4, 1, 6, 3, 0, 8, 5, 2, 10, 7, 4, 1, 9, 6, 3, 0, 8, 5, 2, 10, 7, 4, 1, 9, 6, 3, 11, 0, 8, 5, 13, 2, 10, 7, 4, 12, 1, 9, 6, 3, 11, 0, 8, 5, 13, 2, 10, 7, 4, 12, 1, 9, 6, 14, 3
Offset: 1

Views

Author

Keywords

Comments

The sequence is constructed as follows: after partitioning A022328 into segments starting with 0, in each segment the greatest term is to be deleted (see example and comment in A022328); length of k-th mentioned segment = A020914(k); respective greatest term = A056576(k);
this sequence is fractal, i.e. if the first occurrence of each n is removed, the resulting sequence is the original sequence;
A258051 is constructed from this sequence, applying the same transform as described above.

Examples

			Segments of A022328 starting with 0, deleted maxima in brackets:
.   1:  0 [1]
.   2:  0 2 1 [3]
.   3:  0 2 [4] 1 3
.   4:  0 5 2 4 1 [6] 3
.   5:  0 5 2 [7] 4 1 6 3
.   6:  0 8 5 2 7 4 1 [9] 6 3
.   7:  0 8 5 2 10 7 4 1 9 6 3 [11]
.   8:  0 8 5 2 10 7 4 [12] 1 9 6 3 11
.   9:  0 8 5 13 2 10 7 4 12 1 9 6 [14] 3 11
.  10:  0 8 5 13 2 10 7 [15] 4 12 1 9 6 14 3 11
.  11:  0 8 16 5 13 2 10 7 15 4 12 1 9 [17] 6 14 3 11
.  12:  0 8 16 5 13 2 10 18 7 15 4 12 1 9 17 6 14 3 11 [19]
.  13:  0 8 16 5 13 2 10 18 7 15 4 12 [20] 1 9 17 6 14 3 11 19
.  14:  0 8 16 5 13 21 2 10 18 7 15 4 12 20 1 9 17 6 14 [22] 3 11 19
.  15:  0 8 16 5 13 21 2 10 18 7 15 [23] 4 12 20 1 9 17 6 14 22 3 11 19
		

Crossrefs

Programs

  • Haskell
    import Data.List (delete)
    a258033 n = a258033_list !! (n-1)
    a258033_list = 0 : f (tail a022328_list) where
       f xs = (0 : (delete (maximum ys) ys)) ++ f zs
              where (ys, (_ : zs)) = span (> 0) xs

A074720 Least k such that floor(3^n/2^k) is prime.

Original entry on oeis.org

2, 1, 4, 5, 6, 1, 11, 6, 7, 4, 5, 1, 9, 6, 8, 21, 8, 4, 25, 12, 20, 13, 30, 17, 6, 13, 10, 13, 19, 5, 12, 34, 33, 37, 16, 39, 35, 13, 38, 30, 28, 20, 53, 16, 60, 24, 40, 43, 34, 19, 23, 32, 63, 59, 19, 22, 27, 56, 86, 14, 29, 5, 53, 13, 15, 63, 19, 7, 88, 1, 87, 46, 22, 51, 25, 30
Offset: 2

Views

Author

Benoit Cloitre, Sep 04 2002

Keywords

Comments

From Robert Israel, Jan 04 2017: (Start)
a(n) <= A056576(n) - 1.
a(n) = 1 for n in A028491. (End)

Programs

  • Maple
    f:= proc(n) local t, k;
       t:= 3^n;
       for k from 1 do t:= t/2; if isprime(floor(t)) then return k fi od:
    end proc:
    map(f, [$2..100]); # Robert Israel, Jan 04 2017
  • Mathematica
    lk[n_]:=Module[{k=1,n3=3^n},While[!PrimeQ[Floor[n3/2^k]],k++];k]; Array[lk,80,2] (* Harvey P. Dale, Feb 24 2013 *)
  • PARI
    a(n)=if(n<0,0,k=1; while(isprime(floor(3^n/2^k)) == 0,k++); k)

A098295 ((3/2)^n)/2^a(n) lies in the half-open interval [1,2).

Original entry on oeis.org

0, 1, 1, 2, 2, 3, 4, 4, 5, 5, 6, 7, 7, 8, 8, 9, 9, 10, 11, 11, 12, 12, 13, 14, 14, 15, 15, 16, 16, 17, 18, 18, 19, 19, 20, 21, 21, 22, 22, 23, 23, 24, 25, 25, 26, 26, 27, 28, 28, 29, 29, 30, 31, 31, 32, 32, 33, 33, 34, 35, 35, 36, 36, 37, 38, 38, 39, 39, 40, 40, 41, 42, 42, 43, 43
Offset: 1

Views

Author

Wolfdieter Lang, Oct 18 2004

Keywords

Comments

Stacking perfect fifths (the frequency ratio of a fifth is 3/2), a division by 2^a(n) leads the equivalent tone belonging to the first octave interval [1,2). For example, the third fifth, (3/2)^3, falls into the second octave. This means it lies in the interval [2^1,2^2)=[2,4). Hence ((3/2)^3)/2^1 belongs to the first octave, the interval [1,2).
This sequence coincides for the first 93 term with the floor of y(n)= 4*Pi*log(phi)*n/(Pi^2 + (2*log(phi)^2)), with phi:=(1+sqrt(5))/2. a(n) = floor(y(n)), for n=1..93. Note that y(n) is not the imaginary part of the zero of the Fibonacci function because of a different bracket setting. See A214656. - Wolfdieter Lang, Jul 24 2012

Examples

			(3/2)^12 lies in the eighth octave [2^7,2^8) and
((3/2)^12)/2^a(12)= ((3/2)^12)/2^7 = 3^12/2^19 = 531441/524288 = 1.01363... belongs to the first octave [1,2). This ratio is called the Pythagorean comma.
		

Crossrefs

This sequence differs from A074840 for the first time at entry a(41)=23: A074840(41)=24.

Programs

Formula

a(n) = A098294(n)-1, n >= 1.
a(n) = ceiling(tau*n)-1 with tau = log(3)/log(2)-1 = 0.58496250072..., n >= 1.
a(n) = A056576(n) - n. - Ruud H.G. van Tol, Jan 26 2024

A204399 Numbers k such that floor(2^k / 3^n) = 1.

Original entry on oeis.org

0, 2, 4, 5, 7, 8, 10, 12, 13, 15, 16, 18, 20, 21, 23, 24, 26, 27, 29, 31, 32, 34, 35, 37, 39, 40, 42, 43, 45, 46, 48, 50, 51, 53, 54, 56, 58, 59, 61, 62, 64, 65, 67, 69, 70, 72, 73, 75, 77, 78, 80, 81, 83, 85, 86, 88, 89, 91, 92, 94, 96, 97, 99, 100, 102, 104
Offset: 0

Views

Author

Michel Lagneau, Jan 15 2012

Keywords

Comments

Presumably a(n) ~ 3*n - floor(n*sqrt(2)) = A195176(n). In the first hundred, a(n) = A195176(n) except for n = 41, 70, 82, 94 where a(n) = A195176(n) - 1.
The conjecture is false; A195176(n) - a(n) increases without bound (though not monotonically) since log_2(3) < 3 - sqrt(2). - Charles R Greathouse IV, Jan 15 2012
Basically a duplicate of A020914. - R. J. Mathar, Jan 16 2012

Crossrefs

Programs

  • Maple
    for n from 0 to 120 do : for k from 0 to 100 do: x:=floor(2^k /3^n):if x=1 then printf(`%d, `,k):else fi:od:od:
  • PARI
    a(n)=ceil(n*log(3)/log(2)) \\ Charles R Greathouse IV, Jan 15 2012

Formula

a(n) = ceiling( n * log_2(3) ). - Charles R Greathouse IV, Jan 15 2012

A337921 a(n) is the sum of (3^n mod 2^k) for k such that 2^k < 3^n.

Original entry on oeis.org

1, 3, 18, 38, 195, 585, 607, 3948, 11976, 42415, 127921, 56067, 666938, 2082798, 10769251, 22610393, 110616780, 315726436, 408228944, 2384863439, 7159829169, 23350950650, 74348867826, 49863537606, 401947783347, 1296027221145, 6159163094580, 13796041908620, 60717334308629, 181812784262527
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Jan 29 2021

Keywords

Comments

a(n) == A056576(n) (mod 2).

Examples

			a(3) = (3^3 mod 2^1) + (3^3 mod 2^2) + (3^3 mod 2^3) + (3^3 mod 2^4) = 18.
		

Crossrefs

Cf. A056576.

Programs

  • Maple
    f:= proc(n) local k; add(3 &^ n mod 2^k, k = 1 .. ilog2(3^n)) end proc:
    map(f, [$1..100]);
  • Mathematica
    A337921[n_] := Sum[Mod[3^n, 2^k], {k, 1, Floor[n*Log[2, 3]]}]; Table[A337921[n], {n, 1, 30}] (* Robert P. P. McKone, Jan 31 2021 *)
  • PARI
    a(n) = sum(k=1, logint(3^n, 2), lift(Mod(3, 2^k)^n)); \\ Michel Marcus, Jan 30 2021

A372779 Numbers m such that v^n - u^m < u^(m+1) - v^n, where u=2, v=3, and u^m < v^n < u^(m+1).

Original entry on oeis.org

2, 4, 6, 7, 9, 11, 12, 14, 16, 18, 19, 21, 23, 24, 26, 28, 30, 31, 33, 35, 36, 38, 40, 42, 43, 45, 47, 48, 50, 52, 53, 55, 57, 59, 60, 62, 64, 65, 67, 69, 71, 72, 74, 76, 77, 79, 81, 83, 84, 86, 88, 89, 91, 93, 95, 96, 98, 100, 101, 103, 105, 106, 108, 110
Offset: 1

Views

Author

Clark Kimberling, May 18 2024

Keywords

Examples

			The condition u^m < v^n < u^(m + 1) implies m = floor (n*log(v)/log(u)). With u=2 and v=3, for n = 1, we have m = 1 and 3 - 2 >= 4 - 3, so 1 is in A372780. For n = 2, we have m = 3 and 9 - 8 < 16 - 9, so 2 is in this sequence.
		

Crossrefs

Cf. A000079, A000244, A056576, A372780 (complement).

Programs

  • Mathematica
    z = 200; {u, v} = {2, 3};
    m[n_] := Floor[n*Log[v]/Log[u]];
    Table[m[n], {n, 0, z}];
    s = Select[Range[z], v^# - u^m[#] < u^(m[#] + 1) - v^# &]  (* this sequence *)
    Complement[Range[Max[s]], s]   (* A372780 *)

A372780 Numbers m such that v^n - u^m >= u^(m+1) - v^n, where u=2, v=3, and u^m < v^n < u^(m+1).

Original entry on oeis.org

1, 3, 5, 8, 10, 13, 15, 17, 20, 22, 25, 27, 29, 32, 34, 37, 39, 41, 44, 46, 49, 51, 54, 56, 58, 61, 63, 66, 68, 70, 73, 75, 78, 80, 82, 85, 87, 90, 92, 94, 97, 99, 102, 104, 107, 109, 111, 114, 116, 119, 121, 123, 126, 128, 131, 133, 135, 138, 140, 143, 145
Offset: 1

Views

Author

Clark Kimberling, May 18 2024

Keywords

Examples

			The condition u^m < v^n < u^(m + 1) implies m = floor(n*log(v)/log(u)). With u=2 and v=3, for n = 1, we have m = 1 and 3 - 2 >= 4 - 3, so 1 is in this sequence. For n = 2, we have m = 3 and 9 - 8 < 16 - 9, so 2 is in A372779.
		

Crossrefs

Cf. A000079, A000244, A056576, A372779 (complement).

Programs

  • Mathematica
    z = 200; {u, v} = {2, 3};
    m[n_] := Floor[n*Log[v]/Log[u]];
    Table[m[n], {n, 0, z}];
    s = Select[Range[z], v^# - u^m[#] < u^(m[#] + 1) - v^# &]  (* A372779 *)
    Complement[Range[Max[s]], s]   (* this sequence *)

A375619 a(n) is the largest integer such that there exists a simple graph with n vertices, a(n) edges, and no cycles of length 0 mod 4.

Original entry on oeis.org

0, 1, 3, 4, 6, 7, 9, 11, 12, 14, 15, 17, 19, 20, 22, 23, 25, 26, 28, 30, 31, 33, 34, 36, 38, 39, 41, 42, 44, 45, 47, 49, 50, 52, 53, 55, 57, 58, 60, 61, 63, 64, 66, 68, 69, 71, 72, 74, 76, 77, 79, 80, 82, 83, 85, 87, 88, 90, 91, 93, 95, 96, 98, 99, 101, 102
Offset: 1

Views

Author

Luc Ta, Aug 21 2024

Keywords

Comments

In the parlance of extremal graph theory, a(n) is the extremal number ex(n, C_(0 mod 4)).

Examples

			For n = 4, any simple graph with 4 vertices and 5 edges contains a cycle of length 4 == 0 (mod 4), so a(4) < 5. There are exactly two nonisomorphic graphs with 4 vertices and 4 edges. One of them has no cycles of any length other than 3, so a(4) = 4.
		

Crossrefs

Programs

  • Mathematica
    Table[Floor[19/12 * (n - 1)], {n, 100}]

Formula

a(n) = floor(19/12(n-1)). See Győri et al. in Links.
a(n) = A172272(n-1) for all n <= 77; then a(78) = 121 != 122 = A172272(77).
a(n) = A056576(n-1) for all n <= 53; then a(54) = 83 != 84 = A056576(53).
Previous Showing 11-19 of 19 results.