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.

A070861 Triangle of all possible distinct numbers obtained as a product of distinct numbers from 1..n.

This page as a plain text file.
%I A070861 #32 Apr 16 2025 05:25:44
%S A070861 1,1,1,2,1,2,3,6,1,2,3,4,6,8,12,24,1,2,3,4,5,6,8,10,12,15,20,24,30,40,
%T A070861 60,120,1,2,3,4,5,6,8,10,12,15,18,20,24,30,36,40,48,60,72,90,120,144,
%U A070861 180,240,360,720,1,2,3,4,5,6,7,8,10,12,14,15,18,20,21,24,28,30,35,36,40,42
%N A070861 Triangle of all possible distinct numbers obtained as a product of distinct numbers from 1..n.
%C A070861 Factorials are a subsequence (A000142). - _Reinhard Zumkeller_, Jul 02 2011
%C A070861 More generally, all sequences of positive integers are subsequences. - _Charles R Greathouse IV_, Mar 06 2017
%H A070861 Reinhard Zumkeller, <a href="/A070861/b070861.txt">Rows n = 0..20 of triangle, flattened</a>
%F A070861 T(n,A060957(n)) = A000142(n) = n!. - _Alois P. Heinz_, Aug 01 2022
%e A070861 Triangle begins:
%e A070861   1;
%e A070861   1;
%e A070861   1, 2;
%e A070861   1, 2, 3, 6;
%e A070861   1, 2, 3, 4, 6, 8, 12, 24;
%e A070861   ...
%p A070861 T:= proc(n) option remember; `if`(n=0, 1,
%p A070861       sort([map(x-> [x, x*n][], {T(n-1)})[]])[])
%p A070861     end:
%p A070861 seq(T(n), n=0..7);  # _Alois P. Heinz_, Aug 01 2022
%t A070861 row[n_] := Times @@@ Subsets[Range[n]] // Flatten // Union; Table[row[n], {n, 1, 20}] // Flatten (* _Jean-François Alcover_, Feb 02 2015 *)
%o A070861 (Haskell)
%o A070861 a070861 n = a070861_list !! (n-1)
%o A070861 a070861_list = concat a070861_tabf
%o A070861 a070861_tabf = [1] : f 2 [1] where
%o A070861    f n ps = ps' : f (n+1) ps' where ps' = m ps $ map (n*) ps
%o A070861    m []         ys = ys
%o A070861    m xs'@(x:xs) ys'@(y:ys)
%o A070861        | x < y     = x : m xs ys'
%o A070861        | x == y    = x : m xs ys
%o A070861        | otherwise = y : m xs' ys
%o A070861 b070861 = bFile' "A070861" (concat $ take 20 a070861_tabf) 1
%o A070861 -- _Reinhard Zumkeller_, Jul 02 2011
%o A070861 (PARI) row(n)=my(v=[2..n]); Set(vector(2^(n-1),i, factorback(vecextract(v,i-1)))) \\ _Charles R Greathouse IV_, Mar 06 2017
%Y A070861 Cf. A000142, A060957.
%Y A070861 Row sums give A070863.
%Y A070861 Row products give A283261.
%K A070861 nonn,tabf
%O A070861 0,4
%A A070861 _Amarnath Murthy_, May 16 2002
%E A070861 Corrected and extended by _Lior Manor_, May 23 2002
%E A070861 Row n=0 prepended by _Alois P. Heinz_, Aug 01 2022