This is probably a stupid question but when I type ?\
in the REPL (Julia 0.6), I get the following docstrings for \(x, y)
and \(A, B)
:
\(x, y)
Left division operator: multiplication of y by the inverse of x on the left.
Gives floating-point results for integer arguments.
julia> 3 \ 6
2.0
julia> inv(3) * 6
2.0
julia> A = [1 2; 3 4]; x = [5, 6];
julia> A \ x
2-element Array{Float64,1}:
-4.0
4.5
julia> inv(A) * x
2-element Array{Float64,1}:
-4.0
4.5
\(A, B)
Matrix division using a polyalgorithm. For input matrices A and B, the
result X is such that A*X == B when A is square. The solver that is used
depends upon the structure of A. If A is upper or lower triangular (or
diagonal), no factorization of A is required and the system is solved with
either forward or backward substitution. For non-triangular square matrices,
an LU factorization is used.
For rectangular A the result is the minimum-norm least squares solution
computed by a pivoted QR factorization of A and a rank estimate of A based
on the R factor.
When A is sparse, a similar polyalgorithm is used. For indefinite matrices,
the LDLt factorization does not use pivoting during the numerical
factorization and therefore the procedure can fail even for invertible
matrices.
Example
≡≡≡≡≡≡≡≡≡
julia> A = [1 0; 1 -2]; B = [32; -4];
julia> X = A \ B
2-element Array{Float64,1}:
32.0
18.0
julia> A * X == B
true
In the Julia documentation, however, I could only find the first method: https://docs.julialang.org/en/release-0.6/stdlib/linalg/#Standard-Functions-1
Is that on purpose to not clutter the documentation? Or is \(A,B)
documented somewhere else?