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-2 of 2 results.

A055046 Numbers of the form 4^i*(8*j+3).

Original entry on oeis.org

3, 11, 12, 19, 27, 35, 43, 44, 48, 51, 59, 67, 75, 76, 83, 91, 99, 107, 108, 115, 123, 131, 139, 140, 147, 155, 163, 171, 172, 176, 179, 187, 192, 195, 203, 204, 211, 219, 227, 235, 236, 243, 251, 259, 267, 268, 275, 283, 291, 299, 300, 304, 307, 315, 323, 331, 332
Offset: 1

Views

Author

N. J. A. Sloane, Jun 01 2000

Keywords

Comments

Numbers not of the form x^2+y^2+5z^2.
Also values of n such that numbers of the form x^2+n*y^2 for some integers x, y cannot have prime factor of 2 raised to an odd power. - V. Raman, Dec 18 2013

Crossrefs

Programs

  • Mathematica
    A055046Q[k_] := Mod[k/4^IntegerExponent[k, 4], 8] == 3;
    Select[Range[500], A055046Q] (* Paolo Xausa, Mar 20 2025 *)
  • PARI
    is(n)=n/=4^valuation(n,4); n%8==3 \\ Charles R Greathouse IV and V. Raman, Dec 19 2013
    
  • Python
    from itertools import count, islice
    def A055046_gen(startvalue=1): # generator of terms >= startvalue
        return filter(lambda n:not (m:=(~n&n-1).bit_length())&1 and (n>>m)&7==3,count(max(startvalue,1)))
    A055046_list = list(islice(A055046_gen(),30)) # Chai Wah Wu, Jul 09 2022
    
  • Python
    def A055046(n):
        def bisection(f,kmin=0,kmax=1):
            while f(kmax) > kmax: kmax <<= 1
            kmin = kmax >> 1
            while kmax-kmin > 1:
                kmid = kmax+kmin>>1
                if f(kmid) <= kmid:
                    kmax = kmid
                else:
                    kmin = kmid
            return kmax
        def f(x): return n+x-sum(((x>>(i<<1))-3>>3)+1 for i in range(x.bit_length()>>1))
        return bisection(f,n,n) # Chai Wah Wu, Feb 14 2025

Formula

a(n) = 6n + O(log n). - Charles R Greathouse IV, Dec 19 2013
a(n) = A055043(n)/2. - Chai Wah Wu, Mar 19 2025

A370267 Numbers with an even number of prime factors not of the form 8m+-1 (counting repetitions).

Original entry on oeis.org

1, 4, 6, 7, 9, 10, 15, 16, 17, 22, 23, 24, 25, 26, 28, 31, 33, 36, 38, 39, 40, 41, 42, 47, 49, 54, 55, 57, 58, 60, 63, 64, 65, 68, 70, 71, 73, 74, 79, 81, 86, 87, 88, 89, 90, 92, 95, 96, 97, 100, 102, 103, 104, 105, 106, 111, 112, 113, 118, 119, 121, 122, 124, 127, 129
Offset: 1

Views

Author

Peter Munn, Feb 13 2024

Keywords

Comments

Construction by subgroup generation: (Start)
The set of numbers congruent to 1 modulo 8 (A017077) contains all the odd squares and generates a subgroup of the positive rational numbers (under multiplication) that contains no additional integers. The subgroup has an infinite number of cosets. The rest of the construction process extends the subgroup, reducing the number of cosets to 2, by choosing additional generators that are semiprime.
First we extend the subgroup to include all nonzero integer squares. As we already have the odd squares, we need only add 4, the square of the smallest prime, as a generator. The extended subgroup has only 8 cosets and its integer members are listed in A234000. To achieve a subgroup with 2 cosets we now add squarefree semiprime generators. The 2 smallest, 6 and 10, suffice.
The resulting subgroup has this sequence's terms as its integer members.
(End)
The equivalent process starting with numbers congruent to 1 modulo 3 (or 1 modulo 6) produces A189715. If we take its intersection with this sequence we get A370268, which starts with the first 72 nonzero numbers of the form x^2 + 6y^2 (see A002481). Similarly, if we start with numbers congruent to 1 modulo 5 (or 1 modulo 10) and take the resulting set's intersection with this sequence we get a set starting with the first 32 nonzero numbers of the form x^2 - 10y^2 (see A242664).
The construction process leads to a number of properties:
- The sequence is closed under multiplication and all integer ratios between terms are in the sequence.
- The sequence and its complement have the property that the terms of one can be generated by halving the even terms of the other. Each has asymptotic density 1/2.
Numbers whose squarefree part is congruent to {1,7} mod 8 or {6,10} mod 16.

Examples

			7 is prime, so 7 is its only prime factor, which has the form 8m-1. So 7 has an even number (zero) of prime factors not of the form 8m+-1, and therefore is in the sequence. In terms of the subgroup generators described at the start of the comments, (13*8+1) * 4 / (6*10) = 105 * 4/60 = 7.
110 = 2 * 5 * 11, so it has 3 prime factors and all 3 do not have the form 8m+-1. 3 is odd, so 110 is not in the sequence.
		

Crossrefs

Disjoint union of A004215, A055042, A055043 and A234000.
See the comments for the relationships with A002481, A017077, A189715, A242664, A370268.
Cf. A042999 (primes), A059897.

Programs

  • PARI
    isok(k) = {c = core(k); c%8 == 1 || c%8 == 7 || c%16 == 6 || c%16 == 10}
    
  • Python
    def A370267(n):
        def f(x): return n+x-sum(((y:=x>>(i<<1))-7>>3)+(y-1>>3)+2 for i in range((x.bit_length()>>1)+1))-sum(((z:=x>>(i<<1)+1)-5>>3)+(z-3>>3)+2 for i in range(x.bit_length()-1>>1))
        m, k = n, f(n)
        while m != k: m, k = k, f(k)
        return m # Chai Wah Wu, Mar 19 2025

Formula

{a(n) : n >= 1} = {A059897(i,j) : i in A234000, j in {1, 6, 10, 15}}.
Showing 1-2 of 2 results.