Mercurial > octave
changeset 24198:11cdca79d316
maint: Periodic merge of stable to default.
author | Rik <rik@octave.org> |
---|---|
date | Fri, 03 Nov 2017 14:24:39 -0700 |
parents | 2b769c242188 (current diff) 63fc7a75a3d7 (diff) |
children | 2ac103974d00 |
files | libinterp/corefcn/inv.cc libinterp/corefcn/pinv.cc |
diffstat | 2 files changed, 4 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/libinterp/corefcn/inv.cc Fri Nov 03 13:53:45 2017 -0700 +++ b/libinterp/corefcn/inv.cc Fri Nov 03 14:24:39 2017 -0700 @@ -54,7 +54,7 @@ If called with a sparse matrix, then in general @var{x} will be a full matrix requiring significantly more storage. Avoid forming the inverse of a sparse matrix if possible. -@seealso{ldivide, rdivide} +@seealso{ldivide, rdivide, pinv} @end deftypefn */) { if (args.length () != 1)
--- a/libinterp/corefcn/pinv.cc Fri Nov 03 13:53:45 2017 -0700 +++ b/libinterp/corefcn/pinv.cc Fri Nov 03 14:24:39 2017 -0700 @@ -39,18 +39,17 @@ doc: /* -*- texinfo -*- @deftypefn {} {} pinv (@var{x}) @deftypefnx {} {} pinv (@var{x}, @var{tol}) -Return the pseudoinverse of @var{x}. +Return the Moore-Penrose pseudoinverse of @var{x}. Singular values less than @var{tol} are ignored. If the second argument is omitted, it is taken to be @example -tol = max (size (@var{x})) * sigma_max (@var{x}) * eps, +tol = max ([rows(@var{x}), columns(@var{x})]) * norm (@var{x}) * eps @end example -@noindent -where @code{sigma_max (@var{x})} is the maximal singular value of @var{x}. +@seealso(inv, ldivide) @end deftypefn */) { int nargin = args.length ();