login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A193804 Square array read by antidiagonals: S(n,k) = n - A193805(n,k). 5

%I #12 Jul 30 2013 04:06:39

%S 0,1,0,1,1,0,2,2,1,0,1,2,1,1,0,4,2,3,2,1,0,1,4,2,2,1,1,0,4,2,4,3,2,2,

%T 1,0,3,4,2,4,1,3,1,1,0,6,4,5,3,5,3,2,2,1,0,1,6,3,4,2,4,1,2,1,1,0,8,2,

%U 7,5,5,4,4,3,3,2,1,0,1,8,2,6,4,5,1,4,2,2,1,1,0

%N Square array read by antidiagonals: S(n,k) = n - A193805(n,k).

%C Let cophi(n) be the cototient function A051953(n). Then cophi(n) = S(n,1) = S(n,n).

%H Peter Luschny, <a href="http://oeis.org/wiki/User:Peter_Luschny/EulerTotient">Euler's totient function</a>

%e [x][1][2][3][4][5][6][7][8]

%e [1] 0, 0, 0, 0, 0, 0, 0, 0

%e [2] 1, 1, 1, 1, 1, 1, 1, 1

%e [3] 1, 2, 1, 2, 1, 2, 1, 2

%e [4] 2, 2, 3, 2, 2, 3, 2, 2

%e [5] 1, 2, 2, 3, 1, 3, 1, 3

%e [6] 4, 4, 4, 4, 5, 4, 4, 4

%e [7] 1, 2, 2, 3, 2, 4, 1, 3

%e [8] 4, 4, 5, 4, 5, 5, 5, 4

%e Triangle k=1..n, n>=1:

%e [1] 0

%e [2] 1, 1

%e [3] 1, 2, 1

%e [4] 2, 2, 3, 2

%e [5] 1, 2, 2, 3, 1

%e [6] 4, 4, 4, 4, 5, 4

%e [7] 1, 2, 2, 3, 2, 4, 1

%e [8] 4, 4, 5, 4, 5, 5, 5, 4

%e Triangle n=1..k, k>=1:

%e [1] 0

%e [2] 0, 1

%e [3] 0, 1, 1

%e [4] 0, 1, 2, 2

%e [5] 0, 1, 1, 2, 1

%e [6] 0, 1, 2, 3, 3, 4

%e [7] 0, 1, 1, 2, 1, 4, 1

%e [8] 0, 1, 2, 2, 3, 4, 3, 4

%e S(15, 22) = card({2,3,5,6,9,10,11,12,15}) = 9 as

%e the defining set is {1,2,..,15} minus {1,4,7,8,13,14}.

%p strongdivisors := n -> numtheory[divisors](n) minus {1}:

%p coprimes := n -> select(k->igcd(k,n)=1,{$1..n}):

%p S := (n,k) -> nops({seq(i,i={$1..n})}

%p minus((coprimes(n) minus strongdivisors(k)))):

%p seq(seq(S(n-k+1,k), k=1..n), n=1..8); # Square array by antidiagonals.

%p seq(print(seq(S(n, k), k=1..n)), n=1..8); # Lower triangle.

%p seq(print(seq(S(n, k), n=1..k)), k=1..8); # Upper triangle.

%t s[n_, k_] := Complement[ Range[n], Complement[ Select[ Range[n], CoprimeQ[#, n]&], Divisors[k] // Rest]] // Length; Table[ s[n-k+1, k], {n, 1, 13}, {k, 1, n}] // Flatten (* _Jean-François Alcover_, Jul 30 2013 *)

%Y Cf. A000010, A051953, A193805.

%K nonn,tabl

%O 1,7

%A Peter Luschny, Aug 06 2011

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 16:40 EDT 2024. Contains 371916 sequences. (Running on oeis4.)