Click or drag to resize

DoubleQRLeastSq Class

Class DoubleQRLeastSq solves least squares problems by using a QR decomposition.
Inheritance Hierarchy
SystemObject
  CenterSpace.NMath.CoreDoubleQRLeastSq

Namespace: CenterSpace.NMath.Core
Assembly: NMath (in NMath.dll) Version: 7.4
Syntax
[SerializableAttribute]
public class DoubleQRLeastSq : ICloneable

The DoubleQRLeastSq type exposes the following members.

Constructors
 NameDescription
Public methodDoubleQRLeastSq Constrcts a DoubleQRLeastSq instance with all sizes zero.
Public methodDoubleQRLeastSq(DoubleMatrix) Constructs a DoubleQRLeastSq instance from the given matrix.
Public methodDoubleQRLeastSq(DoubleMatrix, Double) Constructs a DoubleQRLeastSq instance from the given matrix. The specified tolerance is used in computing the numerical rank of the matrix.
Top
Properties
 NameDescription
Public propertyCols Gets the number of columns in the matrix.
Public propertyIsGood Gets a boolean value that is true if the QR decomposition may be used to solve least squares problems; otherwise false.
Public propertyRank Gets the numerical rank of the matrix.
Public propertyRows Gets the number of rows in the matrix.
Top
Methods
 NameDescription
Public methodClone Creates a deep copy of this least squares instance.
Public methodFactor(DoubleMatrix) Factors a given matrix so that it may be used to solve least squares problems.
Public methodFactor(DoubleMatrix, Boolean) Factors a given matrix so that it may be used to solve least squares problems. The specified tolerance is used in computing the numerical rank of the matrix.
Public methodFactor(DoubleMatrix, Double) Factors a given matrix so that it may be used to solve least squares problems. The specified tolerance is used in computing the numerical rank of the matrix.
Public methodFactor(DoubleMatrix, Boolean, Double) Factors a given matrix so that it may be used to solve least squares problems. The specified tolerance is used in computing the numerical rank of the matrix.
Public methodOnSerializing processing following deserialization
Public methodResidualNormSqr Computes the 2-norm squared of the residual vector.
Public methodResidualVector Computes and returns the residual vector.
Public methodSolve Computes the solution to the least squares problem Ax = b.
Top
Remarks
Use class DoubleQRLeastSq to find the minimal norm solution to the overdetermined linear system:
C#
Ax = b
That is, find the vector x that minimizes the 2-norm of the residual vector Ax - b. Prerequisites on the matrix A are that it has more rows than columns, and is of full rank.
See Also