public class LinearSystemSolver extends Object
Ax = b,We assume that, after row reduction, A has no more rows than columns. That is, the system must not be over-determined. For example, the following system is not over-determined. One of the rows is linearly dependent. \[ \begin{bmatrix} 1 & -1 & 0\\ 0 & -2 & 0\\ 0 & 0 & -1\\ 0 & 0 & -2 \end{bmatrix} x = \begin{bmatrix} -0.8\\ -1.6\\ 0.8\\ 1.6 \end{bmatrix} \] This linear system of equations is solved in two steps.
x_particular + {x_null_space_of_A}hence, the translation of the null space of A by the vector x_particular.
Modifier and Type | Class and Description |
---|---|
static class |
LinearSystemSolver.NoSolution
This is the runtime exception thrown when it fails to solve a system of
linear
equations.
|
static interface |
LinearSystemSolver.Solution
This is the solution to a linear system of equations.
|
Constructor and Description |
---|
LinearSystemSolver(double epsilon)
Construct a solver for a linear system of equations.
|
Modifier and Type | Method and Description |
---|---|
LinearSystemSolver.Solution |
solve(Matrix A0)
Get a particular solution for the linear system, Ax = b.
|
public LinearSystemSolver(double epsilon)
epsilon
- a precision parameter: when a number |x| ≤ ε,
it is
considered 0public LinearSystemSolver.Solution solve(Matrix A0)
A0
- a matrix representing a linear system of equations (the
homogeneous part)Copyright © 2010-2020 NM FinTech Ltd.. All Rights Reserved.