A095362 Ratio A095110(n)/A000079(n-2) rounded to nearest integer.
2, 6, 12, 20, 38, 53, 106, 200, 369, 657, 1227, 2191, 4268, 8076, 15291, 28932, 55125, 105983, 202482, 391506
Offset: 1
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.
from functools import lru_cache @lru_cache(maxsize=None) def A162459(n): if n == 0: return 0 c, j = n, 2 k1 = n//j while k1 > 1: j2 = n//k1 + 1 c += (j2-j)*A162459(k1)//2**(k1-1) j, k1 = j2, n//j2 return 2**(n-1)*(j-c) # Chai Wah Wu, Mar 30 2021
First few rows of the triangle = 1; 2, 5; 4, 10, 22; 8, 20, 44, 99; 16, 40, 88, 198, 471; 32, 80, 176, 396, 942, 2386; 64, 160, 352, 792, 1884, 4772, 12867; 128, 324, 704, 1584, 3768, 9544, 25734, 73681; ...
nmax:=13: a(0):=1: a(1):=2: for n from 0 to nmax/2 do a(2*n+1):= 2^(2*n+1)*a(2*n): a(2*n+2):=2^(2*n+2)*((4^(n+2) - 1)/(4^(n+1) - 1))*a(2*n+1): od: seq(a(n),n=0..nmax);
The three-column array pPT(n,k) begins: n\k 0 1 2 ------------------------------- 0: 3 4 5 1: 21 20 29 2: 105 88 137 3: 465 368 593 4: 1953 1504 2465 5: 8001 6080 10049 6: 32385 24448 40577 7: 130305 98048 163073 8: 522753 392704 653825 9: 2094081 1571840 2618369 10: 8382465 6289408 10479617 ... - _Wolfdieter Lang_, Jun 13 2020
h21={{1, 3}, {0, 2}}; l = {}; Do[v = MatrixPower[h21, n, {2, 1}]; p = v[[1]]; q = v[[2]]; a = p^2 - q^2; b = 2 p q; c = p^2 + q^2; l = AppendTo[l, {a, b, c}], {n, 0, 14}]; l // Flatten
Vec((3 + 4*x + 5*x^2 - 8*x^4 - 6*x^5 + 4*x^7 + 4*x^8) / ((1 - x)*(1 + x + x^2)*(1 - 2*x^3)*(1 - 4*x^3)) + O(x^35)) \\ Colin Barker, Jun 12 2020
Square array: 1, 2, 4, 8, 16, 32, 64, 128, ... = A000079(n) 1, 1, 3, 5, 11, 21, 43, 85, ... = A001045(n+1) 1, 0, 2, 2, 6, 10, 22, 42, ... = A078008(n) 1, -1, 1, -1, 1, -1, 1, -1, ... = A033999(n) 1, -2, 0, -4, -4, -12, -20, -44, ... = -A084247(n) 1, -3, -1, -7, -9, -23, -41, -87, ... = (-1)^n*A140966(n+1) 1, -4, -2, -10, -14, -34, -62, -130, ... = -A135440(n) 1, -5, -3, -13, -19, -45, -83, -173, ... = -A155980(n+3) or -A171382(n+1) ...
A:= (n, k)-> (<<0|1>, <2|1>>^k. <<1, 2-n>>)[1$2]: seq(seq(A(d-k, k), k=0..d), d=0..12); # Alois P. Heinz, Jan 21 2021
A340660[m_, n_] := LinearRecurrence[{1, 2}, {1, m}, {n}]; Table[Reverse[Table[A340660[m, n + m - 2] // First, {m, 2, -n + 3, -1}]], {n, 1, 11}] // Flatten (* Robert P. P. McKone, Jan 28 2021 *)
T(n, k) = 2^k - n*(2^k - (-1)^k)/3; matrix(10,10,n,k,T(n-1,k-1)) \\ Michel Marcus, Jan 19 2021
f[p_, e_] := If[p == 2, e + 1, 2]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
a(n) = {my(f = factor(n)); prod(i = 1, #f~, if(f[i,1] == 2, f[i,2]+1, 2));}
4 is not in the sequence because it is in A000079. 14 is not in the sequence because 14 = 3+5+6.
Comments