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.

A341419 a(0) = 1, a(1) = 1, a(2^(n-1)..2^n-1) = fwht(0..2^(n-2)). Here "fwht" is the fast Walsh-Hadamard transform with natural ordering and without multiplication of any factors.

This page as a plain text file.
%I A341419 #37 Mar 29 2021 12:56:15
%S A341419 1,1,2,0,4,2,0,-2,8,6,8,-2,0,-2,-8,-2,16,14,24,-2,32,14,-8,-18,0,-2,
%T A341419 -8,-2,-32,-18,-8,14,32,30,56,-2,96,46,-8,-50,128,94,120,-34,-32,-50,
%U A341419 -136,-18,0,-2,-8,-2,-32,-18,-8,14,-128,-98,-136,30,-32,14,120,46,64,62
%N A341419 a(0) = 1, a(1) = 1, a(2^(n-1)..2^n-1) = fwht(0..2^(n-2)). Here "fwht" is the fast Walsh-Hadamard transform with natural ordering and without multiplication of any factors.
%C A341419 This sequence is a rough integer-valued approximation to one of the nontrivial solutions to f(n) = a*fwht(f(n)).
%H A341419 Thomas Scheuerle, <a href="/A341419/b341419.txt">Table of n, a(n) for n = 0..16383</a>
%F A341419 a(2^n) = 2^n.
%F A341419 a(2^n + 1) = 2^n-2 for n > 0.
%F A341419 a(2^n + 2) = 8*(2^(n-2) - 1) = A159741(n-2) for n > 1.
%F A341419 a(2^n + 3) = -2 for n > 1.
%F A341419 a(2^n + 4) = 32*(2^(n-3) - 1) = A175165(n-3) for n > 2.
%F A341419 a(2^n + 5) = 2*(2^n - 9) for n > 2.
%F A341419 a(2^n + 6) = -8 for n > 2.
%F A341419 a(2^n + 7) = -2*(8 * 2^(n-3) - 7) for n > 2.
%F A341419 a(2^n + 8) = 64*(2^(n-3) - 2) for n > 3.
%o A341419 (MATLAB)
%o A341419 function a = A341419(max_n)
%o A341419 a(1) = 1;
%o A341419 a(2) = 1;
%o A341419     while length(a) < max_n
%o A341419         w = fwht(a,[],'hadamard')*length(a);
%o A341419         %w = myfwht(a); % own implementation for documentation purpose
%o A341419         a = [a w];
%o A341419     end
%o A341419 end
%o A341419 function w = myfwht(in)
%o A341419     h = 1;
%o A341419     while h < length(in)
%o A341419         for i = 1:h*2:length(in)
%o A341419             for j = i:i+h-1
%o A341419                 x = in(j);
%o A341419                 y = in(j+h);
%o A341419                 in(j) = x+y;
%o A341419                 in(j+h) = x-y;
%o A341419             end
%o A341419         end
%o A341419         h = h*2;
%o A341419     end
%o A341419     w = in;
%o A341419 end
%Y A341419 Cf. A159741, A175165.
%K A341419 sign,look
%O A341419 0,3
%A A341419 _Thomas Scheuerle_, Mar 24 2021