The Cholesky algorithm is a recursive method for calculating the decomposition matrix L using Gaussian elimination. It works by starting with the first row/column of the matrix A and subtracting outer products of rows from the remaining rows, resulting in an upper triangular matrix. This process is repeated for each subsequent row/column until the entire matrix A is decomposed into the lower triangular matrix L.