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!)
A122414 Triangle T(n,k) for 1 <= k <= n read by rows, where T(n,k) = 1 if gcd(n,k) is prime, 0 otherwise. 3

%I #6 Apr 21 2021 10:45:06

%S 0,0,1,0,0,1,0,1,0,0,0,0,0,0,1,0,1,1,1,0,0,0,0,0,0,0,0,1,0,1,0,0,0,1,

%T 0,0,0,0,1,0,0,1,0,0,0,0,1,0,1,1,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,

%U 1,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,1,0,1,1,1,0,1,0,1,0,0

%N Triangle T(n,k) for 1 <= k <= n read by rows, where T(n,k) = 1 if gcd(n,k) is prime, 0 otherwise.

%F T(n,n) = A010051(n).

%F T(n,1) = 0.

%e The triangle starts

%e 0

%e 0 1

%e 0 0 1

%e 0 1 0 0

%e 0 0 0 0 1

%e 0 1 1 1 0 0

%e 0 0 0 0 0 0 1

%e 0 1 0 0 0 1 0 0

%e 0 0 1 0 0 1 0 0 0

%e 0 1 0 1 1 1 0 1 0 0

%e 0 0 0 0 0 0 0 0 0 0 1

%e 0 1 1 0 0 0 0 0 1 1 0 0

%e 0 0 0 0 0 0 0 0 0 0 0 0 1

%e 0 1 0 1 0 1 1 1 0 1 0 1 0 0

%e 0 0 1 0 1 1 0 0 1 1 0 1 0 0 0

%p A122414 := proc(n,k)

%p if isprime(igcd(n,k)) then

%p 1;

%p else

%p 0;

%p end if;

%p end proc: # _R. J. Mathar_, Apr 21 2021

%o (PARI) {m=14; v=vector(m,x,vector(x)); for(n=1,m,for(k=1,n,if(isprime(gcd(n,k)),v[n][k]=1))); for(n=1,m,for(k=1,n,print1(v[n][k],",")))}

%Y Cf. A010051 (diagonal), A122415 (sub-triangle).

%Y Row sums are in A117494. [From _Klaus Brockhaus_, May 29 2009]

%K nonn,tabl,easy

%O 1,1

%A _Klaus Brockhaus_, Sep 03 2006

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 March 29 05:16 EDT 2024. Contains 371264 sequences. (Running on oeis4.)