From 65a7f3bf32d05aaf8eedd3b07438344a348bd10c Mon Sep 17 00:00:00 2001 From: Martin Holters Date: Tue, 1 Aug 2017 09:31:56 +0200 Subject: [PATCH] Add \(::RowVector, ::Number) and /(::Number, ::AbstractVector) --- base/linalg/generic.jl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/base/linalg/generic.jl b/base/linalg/generic.jl index c5864120b6875..f3a424038e49b 100644 --- a/base/linalg/generic.jl +++ b/base/linalg/generic.jl @@ -859,6 +859,8 @@ end (/)(A::AbstractVecOrMat, B::AbstractVecOrMat) = (B' \ A')' # \(A::StridedMatrix,x::Number) = inv(A)*x Should be added at some point when the old elementwise version has been deprecated long enough # /(x::Number,A::StridedMatrix) = x*inv(A) +\(v::RowVector, x::Number) = pinv(v)*x +/(x::Number, v::AbstractVector) = x*pinv(v) cond(x::Number) = x == 0 ? Inf : 1.0 cond(x::Number, p) = cond(x)