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.

A130836 Square array d(m,n) = multiplicative distance between m>=1 and n>=1, read by antidiagonals.

This page as a plain text file.
%I A130836 #31 Dec 09 2019 16:18:14
%S A130836 0,1,1,1,0,1,2,2,2,2,1,1,0,1,1,2,2,3,3,2,2,1,1,2,0,2,1,1,3,2,1,3,3,1,
%T A130836 2,3,2,2,2,2,0,2,2,2,2,2,3,4,3,3,3,3,4,3,2,1,1,1,1,2,0,2,1,1,1,1,3,2,
%U A130836 3,4,4,3,3,4,4,3,2,3,1,2,2,2,3,3,0,3,3,2,2,2,1,2,2,2,3,1,2,4,4,2,1,3,2,2,2
%N A130836 Square array d(m,n) = multiplicative distance between m>=1 and n>=1, read by antidiagonals.
%C A130836 If m = p_1^e_1 * p_2^e_2 * ... * p_k^e^k and n = p_1^f_1 * p_2^f_2 * ... * p_k^f^k, we define d(m, n) = Sum_{i = 1..k} |e_i - f_i| to be the multiplicative distance between m and n (see A130849).
%C A130836 Equivalently, if m/n = Product p_k^e_k, then d(m,n) = Sum |e_k|. - _M. F. Hasler_, Dec 08 2019
%H A130836 Robert Israel, <a href="/A130836/b130836.txt">Table of n, a(n) for n = 1..10011</a> (first 141 antidiagonals, flattened)
%H A130836 D. Dominici, <a href="http://arxiv.org/abs/0906.0632">An Arithmetic Metric</a>, arXiv:0906.0632 [math.NT], 2009.
%F A130836 a(n,m) = A127185(n,m). - _R. J. Mathar_, Oct 17 2007
%e A130836 Array begins:
%e A130836 0 1 1 2 1 2 1 3 ...
%e A130836 1 0 2 1 2 1 2 2 ...
%e A130836 1 2 0 3 2 1 2 4 ...
%e A130836 2 1 3 0 3 2 3 1 ...
%e A130836 ...
%p A130836 A001222 := proc(n) numtheory[bigomega](n) ; end: A127185 := proc(n,m) local g ; g := gcd(n,m) ; RETURN(A001222(n/g)+A001222(m/g)) ; end: A130836 := proc(n,m) A127185(n,m) ; end: for d from 1 to 17 do for n from 1 to d do printf("%d, ",A130836(n,d-n+1)) ; od: od: # _R. J. Mathar_, Oct 17 2007
%p A130836 g:= proc(s) local t;
%p A130836   if s = 1 then 0
%p A130836   elif type(s,function) then 1
%p A130836   elif type(s,`^`) then abs(op(2,s))
%p A130836   else add(procname(t),t=s)
%p A130836   fi
%p A130836 end proc:
%p A130836 f:= (m,n) -> g(ifactor(m)/ifactor(n)):
%p A130836 seq(seq(f(m,n-m),m=1..n-1), n=1..20); # _Robert Israel_, Sep 17 2018
%t A130836 t[n_, n_] = 0; t[n_, 1] := PrimeOmega[n]; t[n_, m_] := With[{g = GCD[n, m]}, PrimeOmega[n/g] + PrimeOmega[m/g]];  Table[t[n-m+1, m], {n, 1, 14}, {m, 1, n}] // Flatten (* _Jean-François Alcover_, Jan 17 2014, after _R. J. Mathar_ *)
%o A130836 (PARI) T(m, n) = {if (m==n, 0, my(f=vecsort(concat(factor(m)[, 1], factor(n)[, 1]),, 8)); sum(i=1, #f, abs(valuation(m, f[i])-valuation(n, f[i]))))}; \\ _Michel Marcus_, Sep 20 2018
%o A130836 (PARI) A130836(m,n)=vecsum(abs(factor(m/n)[,2])) \\ _M. F. Hasler_, Dec 07 2019
%Y A130836 Half of antidiagonal sums gives A130849. First row is A001222.
%K A130836 nonn,tabl,easy
%O A130836 1,7
%A A130836 _N. J. A. Sloane_, Sep 28 2007
%E A130836 More terms from _R. J. Mathar_, Oct 17 2007