﻿ConstrainedLeastSquares Class

# ConstrainedLeastSquares Class

Class for solver constrained least squares problems.
Inheritance Hierarchy
SystemObject
CenterSpace.NMath.CoreConstrainedLeastSquares

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

The ConstrainedLeastSquares type exposes the following members.

Constructors
NameDescription
ConstrainedLeastSquares Constructs an instance of ConstrainedLeastSquares.
Top
Properties
NameDescription
Iterations Gets the number of iterations performed by the most recent solve.
ResidualNorm Gets the Euclidean norm of the Residual vector. You must call one of the Solve methods before accessing.
Residuals Gets the vector of residuals for the computed solution Residuals = Ax - b, where x is the computed solution. You must call one of the Solve methods before accessing.
X Gets the calcluated solution of the most recently solved constrained least squares problem. You must call one of the Solve methods before accessing.
Top
Methods
NameDescription
Clone Returns a deep copy of self.
GetQuadraticProblem Reformulates the given constrained least squares problem as a Quadratic Programming problem.
Solve(ConstrainedLeastSquaresProblem) Solves the given least squares problem using the default quadratic programming solver.
Solve(ConstrainedLeastSquaresProblem, ActiveSetQPSolver, DoubleVector) Solves the given least squares problem using an active set quadratic programming solver.
Solve(ConstrainedLeastSquaresProblem, InteriorPointQPSolver, InteriorPointQPSolverParams) Solves the given least squares problem using an interior point quadratic programming solver.
Top
Remarks
Minimize ||Ax - b||^2 /// Subject to
ai'x = bi, for i in E,
ai'x >= bi, for i in I

where A is an mxn matrix, b is an m-vector, each ai is an n-vector and each bi is a scalar. ||.||^2 denotes the Euclidean norm squared.