I would like to vectorize the calculation of the sum
A{1} + A{2} + ... + A{end}
where A is a vector cell array and each A{i} is a nxn numeric matrix.
There are many ways to code my way through this but I was wondering if there was a clever one fitting in just one or two lines of code.
You can catenate first, then sum up along the 3rd dimension: