Module for computing solutions to linear systems of the form:
Computes the solution of an upper triangular system:
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(in) | :: | U(:,:) |
Upper triangular matrix |
||
| real, | intent(in) | :: | b(:) |
Right hand side vector |
Solution vector x
Computes the solution of a lower triangular system:
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(in) | :: | L(:,:) |
Lower triangular matrix |
||
| real, | intent(in) | :: | b(:) |
Right hand side vector |
Solution vector x
Computes the solution of the system: where A is a non-singular matrix.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(in) | :: | A(:,:) |
Non-singular matrix |
||
| real, | intent(in) | :: | b(:) |
Right hand side vector |
Solution vector x
Computes the solution to the system: where L and U are the matrices obtained from a LU factorization.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(in) | :: | L(:,:) |
Lower triangular matrix |
||
| real, | intent(in) | :: | U(:,:) |
Upper triangular matrix |
||
| real, | intent(in) | :: | b(:) |
Right hand side vector |
Solution vector x
Computes the solution to the system: using LU factorization.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(in) | :: | A(:,:) |
Non-singular matrix |
||
| real, | intent(in) | :: | b(:) |
Right hand side vector |
Solution vector x
Computes the solution to the system using the Jacobi iterative method.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(in) | :: | A(:,:) |
Non-singular matrix |
||
| real, | intent(in) | :: | b(:) |
Right hand side vector |
||
| real, | intent(in) | :: | x_0(:) |
Initial approximation for the iteration |
||
| integer, | intent(in) | :: | maxIter |
Maximum number of iterations |
||
| real, | intent(in) | :: | err_x |
Precision for the stop criterion |
Solution vector x
Computes the solution to the system using the Gauss-Seidel iterative method.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(in) | :: | A(:,:) |
Non-singular matrix |
||
| real, | intent(in) | :: | b(:) |
Right hand side vector |
||
| real, | intent(in) | :: | x_0(:) |
Initial approximation for the iteration |
||
| integer, | intent(in) | :: | maxIter |
Maximum number of iterations |
||
| real, | intent(in) | :: | err_x |
Precision for the stop criterion |
Solution vector x
Makes the matrix M upper triangular
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(inout) | :: | M(:,:) |
Matrix M with maximum range |
Computes de LU factorization of a non-singular matrix A
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real, | intent(in) | :: | A(:,:) |
Non-singular matrix |
||
| real, | intent(out) | :: | L(size(A,1),size(A,2)) |
Lower triangular matrix |
||
| real, | intent(out) | :: | U(size(A,1),size(A,2)) |
Upper triangular matrix |