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-10 of 23 results. Next

A292579 Inverse to A055643: Consider n as a number written in base 60, using 2 decimal digits for each base-60 digit (which we allow to be in the range 0 .. 99), and write n in base 10.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69
Offset: 0

Views

Author

M. F. Hasler, Jan 09 2018

Keywords

Comments

For the first 240000 terms, also the conversion of a digital clock display H:MM:SS to seconds, i.e., a(HMMSS) yields the number of seconds after midnight corresponding to that time, with leading zeros allowed: 0 <= H <= 24, 0 <= MM, SS <= 59.
Numbers where SS or MM etc. are > 59 are strictly spoken invalid in base 60. However, in order to "fill in the gaps" in a meaningful way, we simply do allow SS, MM, etc. to take values up to 99. (The ISO specification for writing time and date does actually allow SS to take values including 60 in order to account for leap seconds, as it allows H to be equal to 24 to denote midnight at the end of a day.) Therefore a(60+k) = 60+k for k < 40, but a(100+k) = 60+k, a(200+k) = 120+k etc, for 0 <= k <= 99.

Examples

			Interpreted in base-60, HMMSS[60] = H*60^2 + MM*60 + SS. Thus, e.g., a(100) = 60, a(123456) = 12*3600 + 34*60 + 56 = 45296.
In contrast to (most) digital clocks, MM and SS may take values up to 99. For example, a(199) = 1*60 + 99 = 159.
		

Crossrefs

Cf. A055643.

Programs

  • PARI
    A292579(n)=fromdigits(digits(n,100),60)

Formula

a(n) = n - [n/100]*40 - [n/10^4]*40*60 - [n\10^6]*40*60^2 - ..., where [.] denotes the floor function.
A292579 o A055643 = A001477 (the identity map on the set of nonnegative integers), i.e., for all n >= 0, A292579(A055643(n)) = n.
Also, A055643(A292579(n)) = n for all n in the range of A055643, which are the "valid base-60 numbers", i.e., excluding 60, ..., 99, 160, ..., 199 etc. The latter (60, ...) are "converted" by A055643 o A292579 to correct base-60 numbers, i.e., 60 -> 100, 99 = 60 + 39 -> 139, 9999 -> 14039 since 99*60 + 99 = 6039 = 1*60^2 + 40*60 + 39 = 14039[60].

A295000 Prime time primes (of the form HMMSS with primes H < 24 and MM, SS < 60) such that the corresponding number of seconds after midnight is also prime.

Original entry on oeis.org

20231, 20297, 20353, 20507, 20719, 20753, 20771, 21107, 21313, 21379, 21713, 21767, 21773, 21929, 21937, 22343, 22367, 22397, 22961, 22973, 23131, 23143, 23167, 23173, 23197, 23719, 23741, 23743, 23747, 23753, 24137, 24179, 24337, 24359, 24371, 24379
Offset: 1

Views

Author

M. F. Hasler, Jan 15 2018

Keywords

Comments

Could be called "super prime time primes": all of H, MM, SS, HMMSS (6-digit clock display) and H*3600 + MM*60 + SS (seconds after midnight) are prime.
This sequence lists the prime time primes A295013 for which the number of seconds A295003 is prime. These are also the times HMMSS (obtained through A055643) which correspond to the subset A295002 of primes in A295003.
Sequence A295002 lists the number of seconds after midnight corresponding to the "prime times" = 6-digit clock displays listed here.
Sequences A295003 and A295004 list the number of seconds after midnight corresponding to the prime time primes A295013 and prime time numbers A295014, i.e., primes and all numbers of the form HMMSS where H < 24 and MM, SS < 60 are prime.

Examples

			The smallest prime of the form HMMSS, with H, MM, SS and H*3600 + MM*60 + SS also prime, is a(1) = 20231, corresponding to a prime number A295002(1) = H*3600 + MM*60 + SS = 7351 (the first prime in A295003) of seconds after midnight.
		

Crossrefs

Programs

Formula

a(n) = A055643(A295002(n)) ; A295000 = { A295013(k) | A295003(k) is prime }.

A295002 Primes in A295003, the number of seconds after midnight corresponding to prime time primes A295013 (primes of the form HMMSS with primes H < 24 and MM, SS < 60).

Original entry on oeis.org

7351, 7417, 7433, 7507, 7639, 7673, 7691, 7867, 7993, 8059, 8233, 8287, 8293, 8369, 8377, 8623, 8647, 8677, 9001, 9013, 9091, 9103, 9127, 9133, 9157, 9439, 9461, 9463, 9467, 9473, 9697, 9739, 9817, 9839, 9851, 9859, 10453, 10753, 10771, 10837, 10867, 10949
Offset: 1

Views

Author

M. F. Hasler, Jan 15 2018

Keywords

Comments

See A295000(n) = A055643(a(n)) for the corresponding "prime time primes", i.e., 6-digit clock displays. Reciprocally, the number of seconds given here is obtained through A292579 from the "super prime time primes" A295000.

Crossrefs

Programs

Formula

a(n) = A292579(A295000(n))

A357970 a(n) is the number of segments used to represent the time of n minutes past midnight in the format hh:mm on a 7-segment calculator display; version where the digits '6', '7' and '9' use 6, 3 and 6 segments, respectively.

Original entry on oeis.org

24, 20, 23, 23, 22, 23, 24, 21, 25, 24, 20, 16, 19, 19, 18, 19, 20, 17, 21, 20, 23, 19, 22, 22, 21, 22, 23, 20, 24, 23, 23, 19, 22, 22, 21, 22, 23, 20, 24, 23, 22, 18, 21, 21, 20, 21, 22, 19, 23, 22, 23, 19, 22, 22, 21, 22, 23, 20, 24, 23, 20, 16, 19, 19, 18, 19, 20
Offset: 0

Views

Author

Stefano Spezia, Oct 22 2022

Keywords

Comments

The sequence is periodic of period 1440 since the term a(1440) = a(0) = 24 corresponds to the time 00:00.

Crossrefs

Programs

  • Mathematica
    a055643[n_]:=FromDigits@ Apply[Join, PadLeft[#, 2] & /@ IntegerDigits@ IntegerDigits[n, 60]]; a006942[n_] := Plus @@ (IntegerDigits@ n /. {0 -> 6, 1 -> 2, 2 -> 5, 3 -> 5, 7 -> 3, 8 -> 7, 9 -> 6}); a[n_]:=a006942[a055643[n]]+6(4-Ceiling[Log10[a055643[n]+1]]); Join[{24}, Array[a, 66]]

Formula

a(n) = A006942(A055643(n)) + 6*(4 - ceiling(log10(A055643(n) + 1))) for n > 0.
a(n) <= 26.

A357971 a(n) is the number of segments used to represent the time of n minutes past midnight in the format hh:mm on a 7-segment calculator display; version where the digits '6', '7' and '9' use 6, 4 and 6 segments, respectively.

Original entry on oeis.org

24, 20, 23, 23, 22, 23, 24, 22, 25, 24, 20, 16, 19, 19, 18, 19, 20, 18, 21, 20, 23, 19, 22, 22, 21, 22, 23, 21, 24, 23, 23, 19, 22, 22, 21, 22, 23, 21, 24, 23, 22, 18, 21, 21, 20, 21, 22, 20, 23, 22, 23, 19, 22, 22, 21, 22, 23, 21, 24, 23, 20, 16, 19, 19, 18, 19, 20
Offset: 0

Views

Author

Stefano Spezia, Oct 22 2022

Keywords

Comments

The sequence is periodic of period 1440 since the term a(1440) = a(0) = 24 corresponds to the time 00:00.

Crossrefs

Programs

  • Mathematica
    a055643[n_]:=FromDigits@ Apply[Join, PadLeft[#, 2] & /@ IntegerDigits@ IntegerDigits[n, 60]]; a010371[n_] := Plus @@ (IntegerDigits@ n /. {0 -> 6, 1 -> 2, 2 -> 5, 3 -> 5, 7 -> 4, 8 -> 7, 9 -> 6}); a[n_]:=a010371[a055643[n]]+6(4-Ceiling[Log10[a055643[n]+1]]); Join[{24},Array[a,66]]

Formula

a(n) = A010371(A055643(n)) + 6*(4 - ceiling(log10(A055643(n) + 1))) for n > 0.
a(n) <= 26.

A357972 a(n) is the number of segments used to represent the time of n minutes past midnight in the format hh:mm on a 7-segment calculator display; version where the digits '6', '7' and '9' use 5, 3 and 5 segments, respectively.

Original entry on oeis.org

24, 20, 23, 23, 22, 23, 23, 21, 25, 23, 20, 16, 19, 19, 18, 19, 19, 17, 21, 19, 23, 19, 22, 22, 21, 22, 22, 20, 24, 22, 23, 19, 22, 22, 21, 22, 22, 20, 24, 22, 22, 18, 21, 21, 20, 21, 21, 19, 23, 21, 23, 19, 22, 22, 21, 22, 22, 20, 24, 22, 20, 16, 19, 19, 18, 19, 19
Offset: 0

Views

Author

Stefano Spezia, Oct 22 2022

Keywords

Comments

The sequence is periodic of period 1440 since the term a(1440) = a(0) = 24 corresponds to the time 00:00.

Crossrefs

Programs

  • Mathematica
    a055643[n_]:=FromDigits@ Apply[Join, PadLeft[#, 2] & /@ IntegerDigits@ IntegerDigits[n, 60]]; a063720[n_] := Plus @@ (IntegerDigits@ n /. {0 -> 6, 1 -> 2, 2 -> 5, 3 -> 5, 6 -> 5, 7 -> 3, 8 -> 7, 9 -> 5}); a[n_]:=a063720[a055643[n]]+6(4-Ceiling[Log10[a055643[n]+1]]); Join[{24},Array[a,66]]

Formula

a(n) = A063720(A055643(n)) + 6*(4 - ceiling(log10(A055643(n) + 1))) for n > 0.
a(n) <= 26.

A357973 a(n) is the number of segments used to represent the time of n minutes past midnight in the format hh:mm on a 7-segment calculator display; version where the digits '6', '7' and '9' use 6, 4 and 5 segments, respectively.

Original entry on oeis.org

24, 20, 23, 23, 22, 23, 24, 22, 25, 23, 20, 16, 19, 19, 18, 19, 20, 18, 21, 19, 23, 19, 22, 22, 21, 22, 23, 21, 24, 22, 23, 19, 22, 22, 21, 22, 23, 21, 24, 22, 22, 18, 21, 21, 20, 21, 22, 20, 23, 21, 23, 19, 22, 22, 21, 22, 23, 21, 24, 22, 20, 16, 19, 19, 18, 19, 20
Offset: 0

Views

Author

Stefano Spezia, Oct 22 2022

Keywords

Comments

The sequence is periodic of period 1440 since the term a(1440) = a(0) = 24 corresponds to the time 00:00.

Crossrefs

Programs

  • Mathematica
    a055643[n_]:=FromDigits@ Apply[Join, PadLeft[#, 2] & /@ IntegerDigits@ IntegerDigits[n, 60]]; a074458[n_] := Plus @@ (IntegerDigits@ n /. {0 -> 6, 1 -> 2, 2 -> 5, 3 -> 5, 7 -> 4, 8 -> 7, 9 -> 5}); a[n_]:=a074458[a055643[n]]+6(4-Ceiling[Log10[a055643[n]+1]]); Join[{24},Array[a,66]]

Formula

a(n) = A074458(A055643(n)) + 6*(4 - ceiling(log10(A055643(n) + 1))) for n > 0.
a(n) <= 26.

A357974 a(n) is the number of segments used to represent the time of n minutes past midnight in the format hh:mm on a 7-segment calculator display; version where the digits '6', '7' and '9' use 6, 3 and 5 segments, respectively.

Original entry on oeis.org

24, 20, 23, 23, 22, 23, 24, 21, 25, 23, 20, 16, 19, 19, 18, 19, 20, 17, 21, 19, 23, 19, 22, 22, 21, 22, 23, 20, 24, 22, 23, 19, 22, 22, 21, 22, 23, 20, 24, 22, 22, 18, 21, 21, 20, 21, 22, 19, 23, 21, 23, 19, 22, 22, 21, 22, 23, 20, 24, 22, 20, 16, 19, 19, 18, 19, 20
Offset: 0

Views

Author

Stefano Spezia, Oct 22 2022

Keywords

Comments

The sequence is periodic of period 1440 since the term a(1440) = a(0) = 24 corresponds to the time 00:00.

Crossrefs

Programs

  • Mathematica
    a055643[n_]:=FromDigits@ Apply[Join, PadLeft[#, 2] & /@ IntegerDigits@ IntegerDigits[n, 60]]; a277116[n_] := Plus @@ (IntegerDigits@ n /. {0 -> 6, 1 -> 2, 2 -> 5, 3 -> 5, 7 -> 3, 8 -> 7, 9 -> 5}); a[n_]:=a277116[a055643[n]]+6(4-Ceiling[Log10[a055643[n]+1]]); Join[{24},Array[a,66]]

Formula

a(n) = A277116(A055643(n)) + 6*(4 - ceiling(log10(A055643(n) + 1))) for n > 0.
a(n) <= 26.

A109827 Numbers written in an alternating binary-then-ternary base.

Original entry on oeis.org

0, 1, 10, 11, 20, 21, 100, 101, 110, 111, 120, 121, 1000, 1001, 1010, 1011, 1020, 1021, 1100, 1101, 1110, 1111, 1120, 1121, 2000, 2001, 2010, 2011, 2020, 2021, 2100, 2101, 2110, 2111, 2120, 2121, 10000, 10001, 10010, 10011, 10020, 10021, 10100, 10101
Offset: 0

Views

Author

Rick L. Shepherd, Jul 03 2005

Keywords

Comments

Exercise 14 on page 30 of the Long textbook is "Let m_1, m_2, m_3 ... be an infinite sequence of integers such that m_i >= 2 for all i. Let M_0 = 1 and M_i = Product_{j=1..i} m_j for all i >= 1. Show that every nonnegative integer r can be written uniquely in the form r = c_n M_n + c_(n-1) M_(n-1) + ... + c_1 M_1 + c_0 where c_n <> 0 for r <> 0 and 0 <= c_i < m_(i+1) for all i." The current sequence of terms a(r) = (c_n c_(n-1) ... c_1 c_0 concatenated) is one example of an infinite family of hybrid representations (just using only 2 and 3). For the m_i, this sequence uses A010693. Then the corresponding M_i are A026549. Thus the places reading from right have values (1,2,2*3,2*3*2,2*3*2*3,...) = A026549. The (ternary) digit 2 may only appear in the even positions counting from the rightmost as position 1. Appending "00" to any term multiplies the number by 6.
However, appending a single "0" to a term multiplies the number by 2 or by 3 or produces an invalid string of digits -- or even none of the above (110 => 1100, 8 becomes 18) -- depending upon the original number and its length.

Examples

			a(29) = 2021 as 29 = 2*12 + 0*6 + 2*2 + 1*1.
		

References

  • Calvin T. Long, Elementary Introduction to Number Theory, 2nd ed., D.C. Heath and Company, 1972, p. 30.

Crossrefs

Cf. A010693 (2, 3, 2, 3, ...), A026549 (place values), A089293 (sum of digits).
Cf. A055643 (Babylonian numbers), A007623 (numbers in factorial base), A049345 (numbers in primorial base), A007088 (numbers in base 2: binary), A007089 (numbers in base 3: ternary).

Programs

  • PARI
    my(table=[0,1,10,11,20,21]); a(n) = fromdigits(apply(d->table[d+1], digits(n,6)), 100); \\ Kevin Ryde, Aug 03 2021
    
  • PARI
    A010693(n) = if(n%2, 2, 3) \\ Function m is A010693 with index 1 here.
    {\\ The function b(n, m) works for all nonnegative n and every sequence m of (mixed or constant) radices as described above.
    my(c, d, k, ntmp, p, v, x); b(n, m) = if(n < 0, , v = [1]; k = 0;
    while(1, k++; p = v[#v]*m(k); if(p <= n, v = concat(v, p), break));
    ntmp = n; c = [];
    forstep(i = #v, 1, -1, d = ntmp\v[i]; c = concat(c, d); ntmp = ntmp - d*v[i]);
    x = 10; if(vecmax(c) < x, eval(Pol(c, 'x)), c))
    \\ returned value is a vector of decimal coefficients if any calculated
    \\ digit is larger than 9 (i.e., not suitable as an OEIS term)
    }
    a(n) = b(n, A010693) \\ Rick L. Shepherd, Aug 04 2021
  • Python
    a109827 = lambda n: 100 * a109827(n // 6) + 10 * ((n % 6) // 2) + n % 2 if n else 0 # David Radcliffe, Aug 03 2021
    

A254334 Powers of 3 in base 60, concatenating the decimal values of the sexagesimal digits.

Original entry on oeis.org

1, 3, 9, 27, 121, 403, 1209, 3627, 14921, 52803, 162409, 491227, 2273721, 7225203, 22083609, 106254827, 319172521, 957521603, 2953364809, 12940502427, 42902311321, 132707334003, 402122410009, 2010408030027, 6031224090121, 18093712270403, 54285137211209
Offset: 0

Views

Author

Michael De Vlieger, Jan 28 2015

Keywords

Comments

Each sexagesimal digit appears as a pair of decimal digits as on a digital clock. Any leading zeros are truncated. Thus decimal 81 appears as "121" and not "0121".

Examples

			a(6) = 1209, since 3^6 = 729 = 12 * 60^1 + 9, thus 12:09 in clock-like notation, which becomes 1209 when restricted to numeric characters.
		

Crossrefs

Cf. A000244 (Powers of 3), A055643 (Babylonian numbers).
Cf. Sexagesimal representations: A250073 (Powers of 2), A254335 (Powers of 5), A254336 (Powers of 10).

Programs

  • Mathematica
    f[n_] := FromDigits@ StringJoin[If[# < 10, StringJoin["0", ToString[#]], ToString[#]] & /@ IntegerDigits[3^n, 60]]; Table[f@ i, {i, 0, 26}] (* Michael De Vlieger, Jan 28 2015 *)
  • PARI
    a(n) = subst(Pol(digits(3^n, 60)), x, 100); \\ Michel Marcus, Feb 22 2015
    
  • Python
    def digits(n,b=10): # list of digits of n in base b
        x, y = n, []
        while x >= b:
            x, r = divmod(x,b)
            y.append(r)
        y.append(x)
        return list(reversed(y))
    A254334_list = [int(''.join([format(x,'02d') for x in digits(3**i, 60)])) for i in range(10**2)]
    # Chai Wah Wu, Mar 14 2015

Formula

a(n) = A055643(A000244(n)). - Michel Marcus, Mar 02 2015
Showing 1-10 of 23 results. Next