Write a Python program to calculate the sum of the elements in a given matrix. Assume the matrix is a list of lists.
matrix = [[1,2], [3,4], [5,6]]
def matrix_sum(matrix):
sum = 0
for row in matrix:
 for elem in row:
  sum += elem
return sum