mrdivide

Right matrix division, the / operator.

Category: Mathematics > Linear Algebra

Syntax

x = b/A

Solves x*A = b.

x = mrdivide(b, A)

Function form of b/A.

Description

Right division is left division on the transposes: b/A equals (A'\b')'. Use it when the unknown multiplies the matrix from the left, as in a row vector of unknown weights. With scalar operands it is ordinary division.

It is also preferable to b*inv(A), for the same reasons that backslash is preferable to inv(A)*b.

Input arguments

b
Right-hand side with size(A,2) columns.
A
Coefficient matrix, or a scalar divisor.

Output arguments

x
The solution with size(A,1) columns.

Example

A row vector of unknowns

x = [3 5] / [2 1; 1 3]
6/2
Output
x = 1×2

    0.8000    1.4000
ans = 3

See also

mldivide mtimes inv rdivide