Changed the way B times A is handled. (Has some issues with dimension checking).