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 101-110 of 243 results. Next

A168110 Palindromic primes in base 8 which are also emirps (A006567) in base 10.

Original entry on oeis.org

73, 97, 113, 12547, 12611, 13259, 13523, 14107, 14563, 14891, 15667, 15731, 30367, 31799, 31991, 312073, 318281, 350033, 359377, 366169, 371353, 372377, 383833, 392153, 393761, 397921, 792131, 796291, 936227, 936739, 948707, 966379, 992947, 1005427, 1008563, 1029883, 1043899, 1048571, 1311749, 1313797, 1340357, 1358029
Offset: 1

Views

Author

Jonathan Vos Post, Nov 18 2009

Keywords

Comments

What is a good way in the OEIS to show other such pairs of bases analogous to this?

Examples

			a(1) = 73 because 73 (base 8) = 111 (which is a palindrome), and R(73) = 37 which is a different prime (base 10). a(2) = 97 because 97 (base 8) = 141 (which is a palindrome), and R(97) = 79 which is a different prime (base 10). a(3) = 113 because 113 (base 8) = 161 (which is a palindrome), and R(113) = 311 which is a different prime (base 10). a(4) = 12547 because 12547 (base 8) = 30403 (which is a palindrome), and R(12547) = 74521 which is a different prime (base 10).
		

Crossrefs

Programs

  • Maple
    isA006567 := proc(p) local r; if isprime(p) then r := digrev(p) ; r <> p and isprime(r) ; else false; end if; end proc: isA029803 := proc(n) local dgs,d; dgs := convert(n,base,8) ; for d from 1 to nops(dgs)/2 do if op(d,dgs) <> op(-d,dgs) then return false; end if; end do ; return true; end proc: isA029976 := proc(n) isprime(n) and isA029803(n) ; end proc: isA168110 := proc(p) isA029976(p) and isA006567(p) ; end proc: A168110 := proc(n) option remember ; local a; if n = 1 then 73 ; else a := nextprime(procname(n-1)) ; while not isA168110(a) do a := nextprime(a) ; end do ; return a; end if; end proc: seq(A168110(n),n=1..30) ; # R. J. Mathar, Dec 06 2009
  • Mathematica
    okQ[n_]:=Module[{fridn=FromDigits[Reverse[IntegerDigits[n]]], idn8= IntegerDigits[n,8]}, fridn!=n&&PrimeQ[fridn]&&idn8==Reverse[idn8]]; Select[Prime[Range[75000]],okQ] (* Harvey P. Dale, Aug 10 2011 *)

Formula

A029976 INTERSECTION A006567.

Extensions

Terms beyond a(10) by R. J. Mathar, Dec 06 2009

A190597 Maximal digit in base-8 expansion of n.

Original entry on oeis.org

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

Views

Author

N. J. A. Sloane, May 13 2011

Keywords

Crossrefs

Programs

  • Mathematica
    Max[IntegerDigits[#,8]]&/@Range[0,110] (* Harvey P. Dale, Sep 05 2019 *)
  • PARI
    a(n) = if (n, vecmax(digits(n, 8)), 0); \\ Michel Marcus, Jul 19 2020

A272576 a(n) = f(10, f(9, n)), where f(k,m) = floor(m*k/(k-1)).

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 10, 11, 12, 13, 14, 15, 16, 17, 20, 21, 22, 23, 24, 25, 26, 27, 30, 31, 32, 33, 34, 35, 36, 37, 40, 41, 42, 43, 44, 45, 46, 47, 50, 51, 52, 53, 54, 55, 56, 57, 60, 61, 62, 63, 64, 65, 66, 67, 70, 71, 72, 73, 74, 75, 76, 77, 80, 81, 82, 83, 84, 85, 86, 87, 90
Offset: 0

Views

Author

Bruno Berselli, May 03 2016

Keywords

Comments

Also, numbers not ending with the digit 8 or 9.
The initial terms coincide with those of A007094 and A039155. First disagreement is after 77 (index 63): a(64) = 80, A007094(64) = 100 and A039155(65) = 89.

Crossrefs

Cf. similar sequences listed in A272574.

Programs

  • Magma
    k:=10; f:=func; [f(k,f(k-1,n)): n in [0..70]];
    
  • Maple
    f := (k, m) -> floor(m*k/(k-1)):
    a := n -> f(10, f(9,n)):
    seq(a(n), n = 0..72); # Peter Luschny, May 03 2016
  • Mathematica
    f[k_, m_] := Floor[m*k/(k-1)];
    a[n_] := f[10, f[9, n]];
    Table[a[n], {n, 0, 72}] (* Jean-François Alcover, May 09 2016 *)
    LinearRecurrence[{1,0,0,0,0,0,0,1,-1},{0,1,2,3,4,5,6,7,10},90] (* Harvey P. Dale, Jun 22 2017 *)
  • PARI
    is(n)=n%10<8 \\ Charles R Greathouse IV, Feb 13 2017
  • Sage
    f = lambda k, m: floor(m*k/(k-1))
    a = lambda n: f(10, f(9, n))
    [a(n) for n in range(73)] # Peter Luschny, May 03 2016
    

Formula

G.f.: x*(1 + x + x^2 + x^3 + x^4 + x^5 + x^6 + 3*x^7)/((1 + x)*(1 - x)^2*(1 + x^2) *(1 + x^4)).
a(n) = a(n-1) + a(n-8) - a(n-9).
a(n) = 1.25n + O(1). - Charles R Greathouse IV, Nov 07 2022

A306110 Numbers with digits in {0,...,7} such that every other digit is strictly less than its neighbors.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 10, 20, 21, 30, 31, 32, 40, 41, 42, 43, 50, 51, 52, 53, 54, 60, 61, 62, 63, 64, 65, 70, 71, 72, 73, 74, 75, 76, 101, 102, 103, 104, 105, 106, 107, 201, 202, 203, 204, 205, 206, 207, 212, 213, 214, 215, 216, 217, 301, 302, 303, 304, 305, 306, 307, 312, 313, 314, 315, 316, 317, 323, 324, 325
Offset: 1

Views

Author

M. F. Hasler, Oct 05 2018

Keywords

Comments

Terms of A032863 written in base 8.

Crossrefs

Cf. A306105 .. A306111 and A297147: analog for bases 3..9 and 10.
Cf. A032863 and A032858 .. A032865 for other bases 3..10.

Programs

  • PARI
    A(Nmax=100,K=7,A=[0..K],i=vector(2*K,i,max(1,i-K+1)),c(T,v)=apply(t->t+T,v))={for(n=0,oo, for(k=10,K*11,if(k%10
    				

Formula

a(n) = A007094(A032863(n)).

A308496 Numbers with digits 1,2,4,7 when written in base 8.

Original entry on oeis.org

1, 2, 4, 7, 9, 10, 12, 15, 17, 18, 20, 23, 33, 34, 36, 39, 57, 58, 60, 63, 73, 74, 76, 79, 81, 82, 84, 87, 97, 98, 100, 103, 121, 122, 124, 127, 137, 138, 140, 143, 145, 146, 148, 151, 161, 162, 164, 167, 185, 186, 188, 191, 265, 266, 268, 271, 273
Offset: 1

Views

Author

Creighton Dement, Jun 01 2019

Keywords

Comments

Floretions of all orders. - Creighton Dement, Oct 28 2022
For any natural number n, the set of terms of this sequence between indices (4^n-1)/3 and (4^(n+1)-4)/3 is "isomorphic" to the group of n-th order floretions. In this case, group multiplication is given by bitwise logical operations (see EXAMPLE). Note that the case of n = 1 is simply the quaternions.
In the table below, the left column is the binary representation, the middle column the terms of ((a(n)) and the right column the conventional notation. Multiply x*y (disregarding signs) using the bitwise XNOR operation, where x and y are any floretions of the same order. The XNOR operation returns a 1 if the number of 1's in its inputs is even, and a 0 if the number of 1's is odd. This operation is used to calculate the base vector of the result.
**** 1st-order floretions (= quaternions) ****
| binary | decimal | floretion
1 | 001 | 1 | i
2 | 010 | 2 | j
4 | 100 | 4 | k
7 | 111 | 7 | e (unit)
**** 2nd-order floretions ****
1_1 | 001_001 | 9 | ii
1_2 | 001_010 | 10 | ij
1_4 | 001_100 | 12 | ik
1_7 | 001_111 | 15 | ie
2_1 | 010_001 | 17 | ji
2_2 | 010_010 | 18 | jj
2_4 | 010_100 | 20 | jk
2_7 | 010_111 | 23 | je
4_1 | 100_001 | 33 | ki
4_2 | 100_010 | 34 | kj
4_4 | 100_100 | 36 | kk
4_7 | 100_111 | 39 | ke
7_1 | 111_001 | 57 | ei
7_2 | 111_010 | 58 | ej
7_4 | 111_100 | 60 | ek
7_7 | 111_111 | 63 | ee
**** 3rd-order floretions ****
1_1_1
1_1_2
...
Note that for a floretion of order n, two digits from any one of its "binary triplets" abc determine the other since XOR(a,b,c) = 1.
When working with a floretion algebra over the reals, i.e., elements of the form x = q_1*f_1 + ... q_m*f_m where q_1,...,q_m are real numbers and f_1,...,f_m are any floretions of the same order, then x may also be referred to as a "floretion". In this case f_1,...,f_m (i.e., terms of this sequence) may be referred to as "floretion base vectors" to avoid confusion.
Taking signs into account:
Given two binary representations (ab) and (cd) for quaternion elements, define multiplication as:
Compute (XNOR(a,c))(XNOR(b,d)) to get the base vector of the result.
Compute AND(b,c), AND(XNOR(a,b),d), and AND(a,XNOR(c,d)). These are all bitwise AND operations.
The sign is negative if and only if the total number of 1's in the results is even.
For example, with k*j = (10)*(01) = -i, compute:
The base vector as (XNOR(1,0) XNOR(0,1)) = (0)(0) = i.
The signs as AND(0,1), AND(XNOR(1,0),1), AND(1, XNOR(0,1)) = 0, 0, 0. There are zero 1's in total, which is an even number, so the result is negative.
An example of image processing: take for example a quaternion x = .2i + .5j + .3k + e. Assume we have a square monitor (aspect ratio). Furthermore, assume the screen is divided into 4 squares- one for i (bottom left), one for j (top left), one for k (top right) one for e (bottom right) and that the coefficient is the amount the pixels are lit up on the screen (1 being full brightness, 0 being off- this could be modified later to accomodate negative numbers). Now imagine we have square monitor of resolution 2^n x 2^n. Then we can represent any black and white image with that resolution with an n-th order floretion. This means we can multiply images together, with some parallels to Fourier analysis.
Multiplying an image by an idempotent floretion would allow one to repeatedly apply a specific transformation (e.g., a rotation, scaling, or some other operation) to an image, and then undo all of those transformations by continuing to apply the same operation a certain number of times. It could be used in applications such as data encryption, where an image could be "scrambled" using a specific floretion and then "unscrambled" by continuing to apply the same floretion.
A compact definition of multiplication is x*y = (ab)(cd) = (-1)^{m+1} (aqc)(bqd) where m = b&c + (aqb)&d + a&(cqd) and "q", "&" are the bitwise XNOR and AND operators respectively. - Creighton Dement, Jul 09 2023

Crossrefs

Programs

  • Mathematica
    A308496Q[n_]:=ContainsOnly[IntegerDigits[n,8],{1,2,4,7}];
    Select[Range[1000],A308496Q] (* Paolo Xausa, Dec 31 2023 *)
  • PARI
    is(n)=!#setminus(Set(digits(n,8)),[1,2,4,7]);
    a(n) =
    {
      local(total_count, index);
      until(total_count == n+1, if(is(index)==1, total_count++); index++);
      index-1;
    }
    
  • PARI
    a(n,b=8,d=[1,2,4,7]) = { for (w=1, oo, if (n>#d^w, n-=#d^w, return (fromdigits(apply(x -> d[1+x], digits(#d^w+n-1, #d))[2..-1],b)))) } \\ Rémy Sigrist, Jun 01 2019

A338881 Product of the nonzero digits of (n written in base 8).

Original entry on oeis.org

1, 1, 2, 3, 4, 5, 6, 7, 1, 1, 2, 3, 4, 5, 6, 7, 2, 2, 4, 6, 8, 10, 12, 14, 3, 3, 6, 9, 12, 15, 18, 21, 4, 4, 8, 12, 16, 20, 24, 28, 5, 5, 10, 15, 20, 25, 30, 35, 6, 6, 12, 18, 24, 30, 36, 42, 7, 7, 14, 21, 28, 35, 42, 49, 1, 1, 2, 3, 4, 5, 6, 7, 1, 1, 2, 3, 4, 5, 6, 7, 2
Offset: 0

Views

Author

Ilya Gutkovskiy, Nov 13 2020

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Times @@ DeleteCases[IntegerDigits[n, 8], 0], {n, 0, 80}]
    nmax = 80; A[] = 1; Do[A[x] = (1 + x + 2 x^2 + 3 x^3 + 4 x^4 + 5 x^5 + 6 x^6 + 7 x^7) A[x^8] + O[x]^(nmax + 1) // Normal, nmax + 1]; CoefficientList[A[x], x]
  • PARI
    a(n) = vecprod(select(x->x, digits(n, 8))); \\ Michel Marcus, Nov 14 2020

Formula

G.f. A(x) satisfies: A(x) = (1 + x + 2*x^2 + 3*x^3 + 4*x^4 + 5*x^5 + 6*x^6 + 7*x^7) * A(x^8).

A376898 Positive numbers k such that all the digits in the octal expansion of k^3 are distinct.

Original entry on oeis.org

1, 2, 5, 7, 10, 11, 14, 15, 22, 30, 37, 41, 49, 61, 74, 98, 122
Offset: 1

Views

Author

Kalle Siukola, Oct 08 2024

Keywords

Comments

There are no terms >= 2^8 because 2^24-1 is the largest eight-digit octal number.

Examples

			11 is a term because 11^3 = 1331 = 2463_8 in octal and no octal digit occurs more than once.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[2^8],Length[IntegerDigits[#^3,8]]==Length[Union[IntegerDigits[#^3,8]]]&] (* James C. McMahon, Oct 16 2024 *)
  • Python
    for k in range(1, 2**8):
        octal = format(k**3, "o")
        if len(octal) == len(set(octal)): print(k, end=",")

A029477 Numbers k that divide the (left) concatenation of all numbers <= k written in base 8 (most significant digit on left).

Original entry on oeis.org

1, 7, 13, 17, 35, 49, 65, 245, 305, 679, 889, 1421, 2231, 2891, 3623, 31943, 59365, 113141, 143755, 193595, 367673, 414545, 1133461, 4916897, 201152387, 1347933505, 1409041697, 1462237105
Offset: 1

Views

Author

Keywords

Comments

No other terms below 3*10^10.

Examples

			For k=7, we have 7654321_8 which is 2054353_10, and 2054353 = 7*293479.
		

Crossrefs

Programs

  • Mathematica
    b = 8; c = {}; Select[Range[10^4], Divisible[FromDigits[c = Join[IntegerDigits[#, b], c], b], #] &] (* Robert Price, Mar 12 2020 *)
  • PARI
    isok(k) = my(list=List()); forstep(i=k, 1, -1, my(d=digits(i, 8)); for (j=1, #d, listput(list, d[j]));); (fromdigits(Vec(list), 8) % k) == 0; \\ Michel Marcus, May 20 2024

Extensions

More terms from Andrew Gacek (andrew(AT)dgi.net), Feb 20 2000
More terms from Larry Reeves (larryr(AT)acm.org), Jun 01 2001
Edited and updated by Larry Reeves (larryr(AT)acm.org), Apr 12 2002
a(23)-a(24) from Max Alekseyev, May 14 2011
a(25)-a(28) from Jason Yuen, May 19 2024

A031487 Numbers whose base-8 representation has the same number of 0's as 7's.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 9, 10, 11, 12, 13, 14, 17, 18, 19, 20, 21, 22, 25, 26, 27, 28, 29, 30, 33, 34, 35, 36, 37, 38, 41, 42, 43, 44, 45, 46, 49, 50, 51, 52, 53, 54, 56, 71, 73, 74, 75, 76, 77, 78, 81, 82, 83, 84, 85, 86, 89, 90, 91, 92, 93, 94, 97
Offset: 1

Views

Author

Keywords

Crossrefs

Cf. A007094.

Programs

  • Mathematica
    Select[Range[100],DigitCount[#,8,0]==DigitCount[#,8,7]&] (* Harvey P. Dale, Dec 12 2017 *)

A031488 Numbers whose base-8 representation has one more 0 than 7's.

Original entry on oeis.org

8, 16, 24, 32, 40, 48, 65, 66, 67, 68, 69, 70, 72, 80, 88, 96, 104, 112, 129, 130, 131, 132, 133, 134, 136, 144, 152, 160, 168, 176, 193, 194, 195, 196, 197, 198, 200, 208, 216, 224, 232, 240, 257, 258, 259, 260, 261, 262, 264, 272
Offset: 1

Views

Author

Keywords

Crossrefs

Cf. A007094.
Previous Showing 101-110 of 243 results. Next