MATLAB: Summing all the Matrices in a Cell Array

cell arraysumming

Lets say i have a cell array with 3 7×2 matrices in it:
.
.
How do i sum them up so to get a single 7×2 matrix?
In this exmaple, i only have 3 matrices.
But i may have a cell array with maybe 100+ matrices.
How should i do it?

Best Answer

a={rand(7,2) rand(7,2) rand(7,2)} % This is an example
b=sum(cat(3,a{:}),3)