bsxfun
- :
C =bsxfun(f, A, B)¶ Apply the element-wise binary function f to A and B with singleton expansion.
Along every dimension the sizes of A and B must be equal or one of them must be 1; a singleton dimension is replicated to match the other operand. f is a function handle or the name of a function and must return an array with the size of the expanded operands.
bsxfun (@minus, magic (3), mean (magic (3)))