Expand a size-1 dimension to the given size (broadcast).
Tensor expand(List<int> newShape) { assert(newShape.length == ndim); final result = Tensor.zeros(newShape); _broadcastCopy(this, result); return result; }