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.

A247254 a(1)=0; for n>1, a(n+1)= a(n)- A004648(n) if a(n)>= A004648(n) else a(n) + A004648(n).

This page as a plain text file.
%I A247254 #32 Dec 02 2014 16:43:04
%S A247254 0,0,1,3,0,1,0,3,0,5,14,5,4,2,1,3,8,0,7,17,6,16,3,17,0,22,45,23,0,22,
%T A247254 45,42,39,34,31,22,15,6,17,6,19,4,17,36,19,2,17,40,9,40,11,40,9,38,3,
%U A247254 40,1,42,3,44,3,42,87,32,87,34,87,24,89,87,18,87,16,14
%N A247254 a(1)=0; for n>1, a(n+1)= a(n)- A004648(n) if a(n)>= A004648(n) else a(n) + A004648(n).
%H A247254 Michel Lagneau, <a href="/A247254/b247254.txt">Table of n, a(n) for n = 1..10000</a>
%p A247254 A247254 := proc(n)
%p A247254     option remember;
%p A247254     local a48 ;
%p A247254     if n=1 then
%p A247254         0;
%p A247254     else
%p A247254         a48 := A004648(n-1) ;
%p A247254         if procname(n-1) >= a48 then
%p A247254             procname(n-1)-a48 ;
%p A247254         else
%p A247254             procname(n-1)+a48 ;
%p A247254         end if;
%p A247254     end if;
%p A247254 end proc: # _R. J. Mathar_, Dec 02 2014
%Y A247254 Cf. A004648.
%K A247254 nonn
%O A247254 1,4
%A A247254 _Michel Lagneau_, Nov 30 2014