Derivation of two matrices using lcm and gcd

31 Views Asked by At

I need to form two $6 \times 6$ matrices where (i) each element $b_{i,j}$ is the lcm of $i$ and $j$ (ii) individual element $c_{i,j}$ is the gcd of $i$ and $j$.

1

There are 1 best solutions below

1
On BEST ANSWER

HINT

Note that for

  • row 1: $\gcd(1,j)=1 \quad \text{lcm}(1,j)=j$
  • column 1: $\gcd(i,1)=1 \quad \text{lcm}(i,1)=i$
  • use the definition for others entries
  • you can also use the following gcd-lcm formula