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.

A257848 a(n) = floor(n/8) * (n mod 8).

This page as a plain text file.
%I A257848 #19 Nov 05 2023 02:33:54
%S A257848 0,0,0,0,0,0,0,0,0,1,2,3,4,5,6,7,0,2,4,6,8,10,12,14,0,3,6,9,12,15,18,
%T A257848 21,0,4,8,12,16,20,24,28,0,5,10,15,20,25,30,35,0,6,12,18,24,30,36,42,
%U A257848 0,7,14,21,28,35,42,49,0,8,16,24,32,40,48,56,0,9
%N A257848 a(n) = floor(n/8) * (n mod 8).
%C A257848 Equivalently, write n in base 8, multiply the last digit by the number with its last digit removed.
%H A257848 Colin Barker, <a href="/A257848/b257848.txt">Table of n, a(n) for n = 0..1000</a>
%H A257848 <a href="/index/Rec#order_16">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,-1).
%F A257848 a(n) = 2*a(n-8)-a(n-16). - _Colin Barker_, May 11 2015
%F A257848 G.f.: x^9*(7*x^6+6*x^5+5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x+1)^2*(x^2+1)^2*(x^4+1)^2). - _Colin Barker_, May 11 2015
%t A257848 Table[Floor[n/8]Mod[n,8],{n,0,90}] (* or *) LinearRecurrence[{0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,-1},{0,0,0,0,0,0,0,0,0,1,2,3,4,5,6,7},90] (* _Harvey P. Dale_, Nov 05 2023 *)
%o A257848 (PARI) a(n,b=8)=(n=divrem(n,b))[1]*n[2]
%o A257848 (PARI) concat([0,0,0,0,0,0,0,0,0], Vec(x^9*(7*x^6+6*x^5+5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x+1)^2*(x^2+1)^2*(x^4+1)^2) + O(x^100))) \\ _Colin Barker_, May 11 2015
%o A257848 (Python)
%o A257848 def A257848(n): return (n>>3)*(n&7) # _Chai Wah Wu_, Jan 19 2023
%Y A257848 Cf. A142150 (the base 2 analog), A115273, A257844 - A257850.
%K A257848 nonn,base,easy
%O A257848 0,11
%A A257848 _M. F. Hasler_, May 10 2015