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.

User: Alonso del Arte

Alonso del Arte's wiki page.

Alonso del Arte has authored 198 sequences. Here are the ten most recent ones:

A379556 Decimal expansion of the square root of 5312.

Original entry on oeis.org

7, 2, 8, 8, 3, 4, 6, 8, 6, 3, 3, 1, 5, 4, 3, 9, 1, 0, 5, 5, 5, 6, 5, 0, 0, 8, 8, 3, 7, 5, 0, 9, 3, 5, 3, 5, 2, 0, 7, 9, 3, 1, 1, 3, 3, 4, 6, 1, 1, 9, 6, 4, 6, 8, 1, 9, 9, 7, 5, 5, 0, 7, 7, 2, 0, 5, 2, 8, 1, 6, 9, 5, 5, 4, 2, 6, 7, 2, 4, 5, 3, 2, 4, 6, 8, 2, 7, 3, 1, 6, 8, 7, 4, 3, 3, 4, 1, 7, 9, 7, 3, 9, 1, 3, 9, 7, 5, 4, 1, 0, 7, 0, 0, 6, 4, 5, 5, 9, 7, 0, 2, 1, 7, 5, 1, 0, 6, 6
Offset: 2

Author

Alonso del Arte, Dec 25 2024

Keywords

Comments

Continued fraction begins 72 then 1, 7, 1, 1, 2, 1, 1, 2, 1, 35, 1, 2, 1, 1, 2, 1, 1, 7, 1, 144, repeated.
The number sqrt(5312) is an algebraic integer in Z[sqrt(83)] as sqrt(5312) = 8 sqrt(83). Z[sqrt(83)] is a unique factorization domain, and 5312 factorizes as (9 - sqrt(83))^6 (9 + sqrt(83))^6 sqrt(83)^2.

Examples

			72.883468633154391...
		

Crossrefs

Cf. A010534, the square root of 83.

Programs

  • Magma
    SetDefaultRealField(RealField(100)); Sqrt(5312); // Vincenzo Librandi, Jan 02 2025
  • Mathematica
    RealDigits[Sqrt[5312], 10, 100][[1]]
  • Scala
    import java.math.{BigDecimal, MathContext, RoundingMode}
    val num = BigDecimal.valueOf(5312)
    val mc = new MathContext(128, RoundingMode.HALF_EVEN)
    val root = num.sqrt(mc)
    root.toString.replace(".", "").toCharArray.toList
    

A371477 Positive integers that can be represented in an 8-bit floating point format.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 20, 22, 24, 26, 28, 30, 32, 36, 40, 44, 48, 52, 56, 60, 64, 72, 80, 88, 96, 104, 112, 120, 128, 144, 160, 176, 192, 208, 224, 240
Offset: 1

Author

Alonso del Arte, Mar 25 2024

Keywords

Comments

A floating point number representation as a bit string consists of a sign bit, some bits for an exponent for a power of two and the remaining bits are for a mantissa for a fixed point number.
In this 8-bit format, there is one sign bit (S), four exponent bits (E) and three mantissa bits (M). These 8-bit strings correspond to rational numbers (-1)^S * 1.M * 2^(E-7), where 1.M and E are interpreted as numbers written in binary (note the exponent bias of 7), except when the exponent bit string is 0000 or 1111. See Burch or Wikipedia for more details on this format.
This is not the only possible apportionment of the bits. E.g. Verts (2005) proposes an 8-bit format with three exponent bits and four mantissa bits. In the Verts system, the only positive integers that can be represented are the integers from 1 to 15.

Examples

			18 is in the sequence because it can be represented as 0 1011 001, meaning sign bit 0, exponent 11-7 = 4, and tacit leading 1 plus explicit 1/8 for the mantissa. The corresponding number in binary is then 1.001 * 10^(1011-111), or in decimal 1.125 * 2^(11-7) = 9/8 * 16 = 18.
19 is not in the sequence because it would require at least four mantissa bits.
20 is in the sequence because it can be represented as 0 1011 010.
256 is not in this sequence because it would require exponent 8, so the exponent bits would be 1111 (15 in binary, with 15-7 = 8), but that exponent bit string is reserved for a special, non-numerical interpretation. 512 or 1024 are also not in this sequence because their exponents do not fit into four bits (taking into account the bias of 7).
		

Crossrefs

Cf. A000265 (odd part of n).

Programs

  • Scala
    def oddPart(n: Int): Int = {
      if (n == 0) {
        0
      } else {
        var num = n
        while (num % 2 == 0) {
          num >>= 1
        }
        num
      }
    }
    (1 to 255).filter(oddPart(_) < 16)

A334722 Numerators of fractions in Kilminster's FracTran program for prime numbers, 10-fraction version.

Original entry on oeis.org

7, 99, 13, 39, 36, 10, 49, 7, 1, 91
Offset: 1

Author

Alonso del Arte, May 09 2020

Keywords

Comments

Like Conway's PRIMEGAME (A202138/A203363), Kilminster's program delivers the prime numbers as exponents of powers of a base, but the base is 10 rather than 2.

References

  • John H. Conway and Tim Hsu, Some Very Interesting Sequences, in T. Shubin, D. F. Hayes, and G. Alexanderson (eds.), Expeditions in Mathematics, MAA Spectrum series, Washington, DC, 2011, chapter 6, pp. 75-86. See page 78.

Crossrefs

Kilminster also came up with a 9-fraction program. See A183132, A183133.

A335365 Numbers that are unreachable by the process of starting from 1 and adding 5 and/or multiplying by 3.

Original entry on oeis.org

2, 4, 5, 7, 10, 12, 15, 17, 20, 22, 25, 30, 35, 40, 45, 50, 55, 60, 65, 70, 75, 80, 85, 90, 95, 100, 105, 110, 115, 120, 125, 130, 135, 140, 145, 150, 155, 160, 165, 170, 175, 180, 185, 190, 195, 200, 205, 210, 215, 220, 225, 230, 235, 240, 245, 250, 255, 260, 265, 270, 275, 280, 285
Offset: 1

Author

Alonso del Arte, Jun 03 2020

Keywords

Comments

Start with 1. Add 5 or multiply by 3. Then either add 5 or multiply by 3, and so on and so forth. Following both branches at each step, we can create a tree like this:
1
................../ \..................
6 3
11......../ \........18 8......../ \........9
/ \ / \ / \ / \
/ \ / \ / \ / \
/ \ / \ / \ / \
16 33 23 54 13 24 14 27
21 48 38 99 28 69 59 162 18 39 29 72 19 42 32 81
According to Haverbeke (2019), some numbers, like 13, are reachable by this process in at least one way. Other numbers, like 15, are completely unreachable.
In fact, almost all positive integers that are not multiples of 5 are reachable, and all multiples of 5 (A008587) are unreachable.
The latter assertion is proven easily enough by taking note of the powers of 3 modulo 5: 1, 3, 4, 2, 1, 3, 4, 2, 1, 3, 4, 2, ... (A070352).
As for the former assertion, it is enough to note that 26, 27, 28 and 29 are reachable. Given 5k + r, with k > 4 and r one of 1, 2, 3, 4, start with the solution for 25 + r and then, k - 5 times, add 5.
More precisely the sequence consists of all multiples of 5, numbers less than 25 congruent to 2 (mod 5), and 4. - M. F. Hasler, Jun 05 2020

Examples

			Starting with 1, either adding 5 or multiplying by 3 results in a number greater than 2, so 2 is unreachable and therefore in the sequence.
Starting with 1, multiplying by 3 gives 3, proving 3 is reachable and therefore not in the sequence.
		

References

  • Marijn Haverbeke, Eloquent JavaScript, 3rd Ed. San Francisco (2019): No Starch, p. 51.

Crossrefs

Cf. A008587 (subset), A070352, A335392.
Subsets of the complement: A000244, A016861, A016873 (except for first five terms), A016885, A016897 (except for 4).

Programs

  • JavaScript
    // See Haverbeke (2019).
    
  • Mathematica
    LinearRecurrence[{2,-1},{2,4,5,7,10,12,15,17,20,22,25,30},70] (* Harvey P. Dale, Apr 01 2023 *)
  • PARI
    {is(n)=!(n%5&& !while(n>4, n%3|| is(n/3)|| break (n=1); n-=5)&& n%2==1)} \\ Using exhaustive search, for illustration. - M. F. Hasler, Jun 05 2020
    
  • PARI
    select( {is(n)=n%5==0|| (n<23&&(n%5==2||n==4))}, [1..199]) \\ Much more efficient. - M. F. Hasler, Jun 05 2020
    
  • PARI
    Vec(x*(2 - x^2 + x^3 + x^4 - x^5 + x^6 - x^7 + x^8 - x^9 + x^10 + 2*x^11) / (1 - x)^2 + O(x^50)) \\ Colin Barker, Jun 07 2020
  • Scala
    // Based on Haverbeke (2019)
    def find153Sol(n: Int): List[Int] = {
      def recur153(curr: Int, history: List[Int]): List[Int] = {
        if (curr == n) history.drop(1) :+ n else if (curr > n) List() else {
          val add5Branch = recur153(curr + 5, history :+ curr)
          if (add5Branch.nonEmpty) add5Branch
              else recur153(curr * 3, history :+ curr)
        }
      }
      recur153(1, List(1))
    }
    (1 to 200).filter(find153Sol(_).isEmpty)
    

Formula

G.f.: (2*x^11 + x^10 - x^9 + x^8 - x^7 + x^6 - x^5 + x^4 + x^3 - x^2 + 2)*x/(x - 1)^2. - Alois P. Heinz, Jun 05 2020
From Colin Barker, Jun 07 2020: (Start)
a(n) = 2*a(n-1) - a(n-2) for n>12.
a(n) = 5*(n-6) for n>10.
(End)

A334723 Denominators of fractions in Kilminster's FracTran program for prime numbers, 10-fraction version.

Original entry on oeis.org

3, 98, 49, 35, 91, 143, 13, 11, 2, 1
Offset: 1

Author

Alonso del Arte, May 09 2020

Keywords

Comments

Numerators are in A334722.
Just like the denominators for Conway's PRIMEGAME (A203363), the last denominator in Kilminster's program is 1, meaning the last fraction is an integer. Then, like Conway's PRIMEGAME and unlike Conway's FIBONACCIGAME, Kilminster's program has no halting numbers.

Crossrefs

A327894 Unicode codes for digit characters in the Basic Multilingual Plane (BMP).

Original entry on oeis.org

48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 1632, 1633, 1634, 1635, 1636, 1637, 1638, 1639, 1640, 1641, 1776, 1777, 1778, 1779, 1780, 1781, 1782, 1783, 1784, 1785, 1984, 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 2406, 2407, 2408, 2409, 2410, 2411, 2412, 2413, 2414, 2415, 2534
Offset: 1

Author

Alonso del Arte, Sep 29 2019

Keywords

Comments

A digit is a character in a given Unicode block that can be combined with other digits in that same Unicode block to form zero-padded nonnegative integers in a positional number base, which can then be sorted arithmetically according to their Unicode values.
That's not the case for numerals, such as for example Roman Numeral Ten (U+2169), nor ASCII letters used as Roman numerals. For example, XIV, XVI, XIX would be sorted as XIV, XIX, XVI (14, 19, 16, rather than 14, 16, 19).
This listing does not include digit characters in the BMP Private Use Area, such as, for example, Klingon Digit Zero (U+F8F0, corresponding to 63728) as assigned by ConScript.
Unicode consistently assigns digit characters so that the code point modulo 16 corresponds to the numerical value of the digit, so that digit zero is U+xxx0 and digit nine is U+xxx9.
Except for the digits for Indian languages and the Limbu language, which are assigned so that the code point modulo 16 corresponds to the numerical value of the digit plus 6 (thus digit zero is U+xxx6 and digit nine is U+xxxF).
This is a principle that ConScript for the most part follows, such as for example with Klingon and Ferengi. Perhaps the only exception is U+E033, Tengwar Letter Stemless Vilya which also serves as Tengwar Digit One. Interestingly, however, take note of Tengwar Duodecimal Digit Ten (U+E06A) and Tengwar Duodecimal Digit Eleven (U+E06B).
The largest number that could theoretically be in this sequence is 65535. There are digits in the supplementary planes, e.g. Osmanya Digit Zero, U+104A0, giving a theoretical maximum of 1114111.
However, since the assignment of the supplementary planes is ongoing for many years to come, to include those in this entry might require occasional insertions. Computation of that sequence would pose only one minor and easily solved problem for Java's isDigit() function, though.
On the other hand, the assignment of Arabic Extended-B (U+0870 through U+089F) has not been finalized yet, though that proposal contains neither digits nor numerals.
Also, no proposal nor suggestion has been made for U+2FE0 through U+2FEF, so there is a small chance those could be assigned digits.

Examples

			The following digits zero are encoded in the BMP (excluding Private Use Area).
U+0030 (48) [ISO-LATIN-1] Digit Zero
U+0660 (1632) Arabic-Indic Digit Zero
U+06F0 (1776) Extended Arabic-Indic Digit Zero
U+07C0 (1984) Nko Digit Zero
U+0966 (2406) Devanagari Digit Zero
U+09E6 (2534) Bengali Digit Zero
U+0A66 (2662) Gurmukhi Digit Zero
U+0AE6 (2790) Gujarati Digit Zero
U+0B66 (2918) Oriya Digit Zero
U+0BE6 (3046) Tamil Digit Zero
U+0C66 (3174) Telugu Digit Zero
U+0CE6 (3302) Kannada Digit Zero
U+0D66 (3430) Malayalam Digit Zero
U+0E50 (3664) Thai Digit Zero
U+0ED0 (3792) Lao Digit Zero
U+0F20 (3872) Tibetan Digit Zero
U+1040 (4160) Myanmar Digit Zero
U+1090 (4240) Myanmar Shan Digit Zero
U+17E0 (6112) Khmer Digit Zero
U+1810 (6160) Mongolian Digit Zero
U+1946 (6470) Limbu Digit Zero
U+19D0 (6608) New Tai Lue Digit Zero
U+1A80 (6784) Tai Tham Hora Digit Zero
U+1A90 (6800) Tai Tham Tham Digit Zero
U+1B50 (6992) Balinese Digit Zero
U+1BB0 (7088) Sundanese Digit Zero
U+1C40 (7232) Lepcha Digit Zero
U+1C50 (7248) Ol Chiki Digit Zero
U+A620 (42528) Vai Digit Zero
U+A8D0 (43216) Saurashtra Digit Zero
U+A900 (43264) Kayah Li Digit Zero
U+A9D0 (43472) Javanese Digit Zero
U+AA50 (43600) Cham Digit Zero
U+ABF0 (44016) Meetei Mayek Digit Zero
U+FF10 (65296) Fullwidth Digit Zero
Although U+3007, Ideographic Number Zero, from the CJK Symbols & Punctuation block, does have an associated numeric value of 0, it returns false for isDigit(). Thus 12295 is not included in this sequence.
		

Crossrefs

Programs

  • Scala
    (0 to 65535).filter(_.toChar.isDigit)

A309948 Decimal expansion of the real part of the square root of 1 + i.

Original entry on oeis.org

1, 0, 9, 8, 6, 8, 4, 1, 1, 3, 4, 6, 7, 8, 0, 9, 9, 6, 6, 0, 3, 9, 8, 0, 1, 1, 9, 5, 2, 4, 0, 6, 7, 8, 3, 7, 8, 5, 4, 4, 3, 9, 3, 1, 2, 0, 9, 2, 7, 1, 5, 7, 7, 4, 3, 7, 4, 4, 4, 1, 1, 5, 7, 8, 8, 4, 2, 8, 7, 5, 0, 5, 3, 5, 5, 5, 2, 8, 4, 8, 1, 1, 1, 3, 6, 5, 3, 6, 0, 6, 6, 3, 5, 6, 4, 1
Offset: 1

Author

Alonso del Arte, Aug 24 2019

Keywords

Comments

i is the imaginary unit such that i^2 = -1.
Also imaginary part of sqrt(-1 + i).

Examples

			Re(sqrt(1 + i)) = 1.09868411346780996603980119524...
		

Crossrefs

Cf. A010060, A309949 (imaginary part).

Programs

  • Maple
    Digits := 120: Im(-sqrt(-1 - I))*10^95:
    ListTools:-Reverse(convert(floor(%), base, 10)); # Peter Luschny, Sep 20 2019
  • Mathematica
    RealDigits[Sqrt[1/2 + 1/Sqrt[2]], 10, 100][[1]]
  • PARI
    real(sqrt(1+I)) \\ Michel Marcus, Sep 16 2019

Formula

Re(sqrt(1 + i)) = sqrt(1/2 + 1/sqrt(2)) = 2^(1/4) * cos(Pi/8).
Equals Im(-sqrt(-1 - i)). - Peter Luschny, Sep 20 2019
Equals Product_{k>=0} ((8*k+3)*(8*k+5)/((8*k+1)*(8*k+7)))^A010060(k) (Allouche et al., 2019). - Amiram Eldar, Feb 04 2024

A309949 Decimal expansion of the imaginary part of the square root of 1 + i.

Original entry on oeis.org

4, 5, 5, 0, 8, 9, 8, 6, 0, 5, 6, 2, 2, 2, 7, 3, 4, 1, 3, 0, 4, 3, 5, 7, 7, 5, 7, 8, 2, 2, 4, 6, 8, 5, 6, 9, 6, 2, 0, 1, 9, 0, 3, 7, 8, 4, 8, 3, 1, 5, 0, 0, 9, 2, 5, 8, 8, 2, 5, 9, 5, 6, 9, 4, 9, 0, 8, 0, 0, 2, 0, 3, 2, 3, 3, 4, 4, 8, 2, 9, 1, 5, 9, 1, 4, 0, 1, 8, 1, 9, 7, 6, 1, 0, 2
Offset: 0

Author

Alonso del Arte, Aug 24 2019

Keywords

Comments

i is the imaginary unit such that i^2 = -1.
Multiplied by -1, this is the imaginary part of the square root of 1 - i. And also the real part of -sqrt(1 + i) - i + sqrt(1 + i)^3, which is a unit in Q(sqrt(1 + i)).

Examples

			Im(sqrt(1 + i)) = 0.45508986056222734130435775782247...
		

Crossrefs

Cf. A000108, A010767, A182168, A309948 (real part).

Programs

  • Maple
    Digits := 120: Re(sqrt(-1 - I))*10^95:
    ListTools:-Reverse(convert(floor(%), base, 10)); # Peter Luschny, Sep 20 2019
  • Mathematica
    RealDigits[Sqrt[1/Sqrt[2] - 1/2], 10, 100][[1]]
  • PARI
    imag(sqrt(1+I)) \\ Michel Marcus, Sep 16 2019

Formula

Equals sqrt(1/sqrt(2) - 1/2) = 2^(1/4) * sin(Pi/8).
Equals sqrt((sqrt(2) - 1)/2) = A010767 * A182168. - Bernard Schott, Sep 16 2019
Equals Re(sqrt(-1 - i)). - Peter Luschny, Sep 20 2019
Equals Product_{k>=0} ((8*k - 1)*(8*k + 4))/((8*k - 2)*(8*k + 5)). - Antonio GraciĆ” Llorente, Feb 24 2024

A307836 Number of Heegner rings in which prime(n) splits minus the number of Heegner rings in which it stays inert.

Original entry on oeis.org

-4, -4, -3, -4, 0, -3, 1, -2, 1, -3, -3, 1, -1, 2, 1, 1, -1, -1, 2, -1, 1, -3, 1, -1, 3, -3, -1, -1, -1, 1, -1, -1, 1, -1, -1, -1, 1, 4, -3, -1, -1, 1, -3, 3, 1, 1, -1, -1, -3, 1, -1, -3, -1, 1, -1, -1, -1, -3, 1, 1, 1, -3, 1, -3, 3, 1, -1, 1, -1, -1, 1, 1, 1, -1, 3, -5, 1, 5, 1, -1, 1
Offset: 1

Author

Alonso del Arte, Jul 07 2019

Keywords

Comments

Given the nine quadratic integer rings with complex numbers which are also unique factorization domains, it stands to reason that most primes in Z remain inert in some of these quadratic rings and split in others.
So if we add up Legendre(H_i, p), where H_i iterates over the Heegner numbers (A003173 multiplied by -1) and p is an odd prime, we will generally find this sum to be odd and greater than -9 but less than 9.
Indeed the first occurrence of a(n) = -9 corresponds to the prime 3167, and the first occurrence of a(n) = 9 corresponds to the prime 15073. The first occurrence of a(n) = -7 or 7 corresponds to the prime 709.
The only even values in this sequence correspond the primes of A003173 (all nine except for 1). The only 0 corresponds to the prime 11; the three instances of -4 correspond to the primes 2, 3, 7; one instance of -2 for 19; two instances of 2 for 43 and 67; and one instance of 4 for 163.
Although (1 + i) is a ramifying ideal in Z[i], Kronecker(-1, 2) = 1, so here 2 is counted as splitting (+1) rather than ramifying (0) in Z[i].

Examples

			We see that 3 = (1 - sqrt(-2))(1 + sqrt(-2)) = (1/2 - sqrt(-11)/2)(1/2 + sqrt(-11)/2) but is prime in Z[i], O_(Q(sqrt(-7))), O_(Q(sqrt(-19))), O_(Q(sqrt(-43))), O_(Q(sqrt(-67))) and O_(Q(sqrt(-163))).
The fact that 3 = -sqrt(-3)^2 does not matter for our purpose here. So 3 splits in two of these domains but is prime in six of them.
As 3 is the second prime, a(2) is therefore -6 + 2 = -4.
		

Crossrefs

Cf. A003173.

Programs

  • Mathematica
    Table[Plus@@KroneckerSymbol[{-1, -2, -3, -7, -11, -19, -43, -67, -163}, Prime[n]], {n, 100}]

Formula

a(n) = Sum_{i = 1..9} Kronecker(H_i, prime(n)), where Kronecker(a, p) is the Kronecker symbol (the Legendre symbol for all odd primes) and H_i is the i-th Heegner number (A003173 multiplied by -1).

A308420 Squarefree numbers d of the form s^2 + r, where r divides 4s, such that Q(sqrt(d)) has class number 1.

Original entry on oeis.org

2, 3, 5, 6, 7, 11, 13, 14, 17, 21, 23, 29, 33, 37, 38, 47, 53, 62, 69, 77, 83, 93, 101, 141, 167, 173, 197, 213, 227, 237, 293, 398, 413, 437, 453, 573, 677, 717, 1077, 1133, 1253, 1293, 1757
Offset: 1

Author

Alonso del Arte, May 26 2019

Keywords

Comments

This sequence is finite, but might not be given in full if the generalized Riemann hypothesis is false.

Examples

			Since 7 = 3^2 - 2 (note that 2 is a divisor of 4 * 9) and h(Z[sqrt(7)]) = 1, 7 is in the sequence.
Although 10 = 3^2 + 1, we see that h(Z[sqrt(10)]) > 1 since Z[sqrt(10)] is not a unique factorization domain (e.g., 10 = 2 * 5 = sqrt(10)^2). So 10 is not in the sequence.
Although h(Z[sqrt(19)]) = 1, there is no way to express 19 as s^2 + r, e.g., 19 = 3^2 + 10 but 10 is not a divisor of 12, 19 = 4^2 + 3 but 3 is not a divisor of 16, 19 = 5^2 - 6 but 6 is not a divisor of 20, 19 = 6^2 - 17 but -17 does not divide 24. So 19 is not in the sequence either.
		

References

  • Richard A. Mollin, Quadratics. p. 176, Theorem 5.4.3. Given "a fundamental discriminant of ERD-type with radicand D," the ring of Q(sqrt(D)) has class number 1 "if and only if D" is one of the values listed above, "with one possible exceptional value whose existence would be a counterexample to the GRH" (generalized Riemann hypothesis).

Crossrefs

Cf. A053329 (first differs at the 16th term), A003172.

Formula

Given d = s^2 + r where r | 4s (this is called "extended Richaud-Degert type" or "ERD-type" by Mollin), d is in this sequence if h(O_Q(sqrt(d))) = 1, where h(O_K) is the class number of the ring of algebraic integers O_K.