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.

A349031 The "Fouriest" numbers: numbers that can be expressed as a string of 4's longer than the original number in some base.

This page as a plain text file.
%I A349031 #37 Nov 19 2021 16:51:50
%S A349031 624,3124,6220,15624,37324,78124,78432,223948,390624,549028,1343692,
%T A349031 1953124,3843200,8062156,9586980,9765624,26902404,48372940,48828124,
%U A349031 76695844,188316832,244140624,290237644,613566756,1220703124,1318217828,1741425868,4908534052
%N A349031 The "Fouriest" numbers: numbers that can be expressed as a string of 4's longer than the original number in some base.
%C A349031 Inspired by Saturday Morning Breakfast Cereal comics.
%C A349031 The "Fouriest" numbers. The number shown in the comment, 624, is correctly identified as a term of the sequence.
%H A349031 David Consiglio, Jr., <a href="/A349031/b349031.txt">Table of n, a(n) for n = 1..461</a>
%H A349031 Saturday Morning Breakfast Cereal comics, <a href="https://www.smbc-comics.com/comic/2013-02-01">Teaching math was way more fun after tenure</a>, Feb 01 2013.
%e A349031 624 is a member of this sequence because 624 expressed in base 5 is 4444. 4444 has 4 digits and 624 has only 3.
%o A349031 (Python)
%o A349031 from math import log
%o A349031 def A349031(limit):
%o A349031     super_fours = []
%o A349031     for length in range(4,int(log(limit,5))+1):
%o A349031         fours = "4"*length
%o A349031         for base in range(5, 10):
%o A349031             keep = 4*(1-base**length)//(1-base)
%o A349031             if len(str(keep)) < len(fours) and keep < limit:
%o A349031                 super_fours.append(keep)
%o A349031     return sorted(super_fours)
%o A349031 result = A349031(10**20)
%Y A349031 For the Fouriest transform see A268236-A268238, A268300. - _N. J. A. Sloane_, Nov 19 2021
%K A349031 nonn,base
%O A349031 1,1
%A A349031 _David Consiglio, Jr._, Nov 06 2021