[−][src]Trait opencv::core::SVDTrait
Singular Value Decomposition
Class for computing Singular Value Decomposition of a floating-point matrix. The Singular Value Decomposition is used to solve least-square problems, under-determined linear systems, invert matrices, compute condition numbers, and so on.
If you want to compute a condition number of a matrix or an absolute value of
its determinant, you do not need u
and vt
. You can pass
flags=SVD::NO_UV|... . Another flag SVD::FULL_UV indicates that full-size u
and vt must be computed, which is not necessary most of the time.
See also
invert, solve, eigen, determinant
Required methods
pub fn as_raw_SVD(&self) -> *const c_void
[src]
pub fn as_raw_mut_SVD(&mut self) -> *mut c_void
[src]
Provided methods
pub fn u(&mut self) -> Mat
[src]
pub fn set_u(&mut self, val: Mat)
[src]
pub fn w(&mut self) -> Mat
[src]
pub fn set_w(&mut self, val: Mat)
[src]
pub fn vt(&mut self) -> Mat
[src]
pub fn set_vt(&mut self, val: Mat)
[src]
pub fn back_subst(
&self,
rhs: &dyn ToInputArray,
dst: &mut dyn ToOutputArray
) -> Result<()>
[src]
&self,
rhs: &dyn ToInputArray,
dst: &mut dyn ToOutputArray
) -> Result<()>
performs a singular value back substitution.
The method calculates a back substitution for the specified right-hand side:
Using this technique you can either get a very accurate solution of the convenient linear system, or the best (in the least-squares terms) pseudo-solution of an overdetermined linear system.
Parameters
-
rhs: right-hand side of a linear system (u*w*v')*dst = rhs to be solved, where A has been previously decomposed.
-
dst: found solution of the system.
Note: Explicit SVD with the further back substitution only makes sense if you need to solve many linear systems with the same left-hand side (for example, src ). If all you need is to solve a single system (possibly with multiple rhs immediately available), simply call solve add pass #DECOMP_SVD there. It does absolutely the same thing.