Tensara Logo

tensara

Lower Triangular Matrix Multiplication

MEDIUM

Perform matrix multiplication of two lower triangular matrices:

C=ABC = A \cdot B

Where A and B are lower triangular matrices.

The result C will also be a lower triangular matrix.

Input

  • Lower triangular matrix AA of size N×NN \times N
  • Lower triangular matrix BB of size N×NN \times N

Output

  • Lower triangular matrix CC of size N×NN \times N

Notes:

  • All matrices A\text{A}, B\text{B}, and C\text{C} are stored in row-major order.
  • A matrix LL is lower triangular if Lij=0L_{ij} = 0 for all i<ji < j.
  • This problem is adapted from KernelBench

GPU Type

Language

Data Type

Loading...

Loading editor...

CUDA C++ environment

Sample Run Results

Hit "Run" to test your code with sample inputs

Desktop Required for Code Submission

For the best coding experience, please switch to a desktop device to write and submit your solution.