|
The Open FUSION Toolkit 1.0.0-beta5
Modeling tools for plasma and fusion research and engineering
|
Wrapper matrix for matrix-free Jacobians.
Computes a Finite Difference approximation to the Jacobian of a function \( F'(v) = [F(u0 + h * v) - F(u0)]/h \)

Public Member Functions | |
| procedure | add_values (self, i_inds, j_inds, b, n, m, iblock, jblock, loc_cache) |
| Add values to a matrix. | |
| procedure(mat_add_values), deferred | add_values (self, i_inds, j_inds, b, n, m, iblock, jblock, loc_cache) |
| Add values to the matrix. | |
| generic | apply (self, a, b) |
| Apply the matrix. | |
| generic | apply (self, a, b) |
| Apply the matrix. | |
| procedure | apply_complex (self, a, b) |
| Apply the matrix to a field and optionally add it to an existing field. | |
| procedure | apply_real (self, a, b) |
| Apply the matrix to a field. | |
| procedure | apply_real (self, a, b) |
| Compute Jacobian approximation. | |
| procedure(mat_apply_vec), deferred | apply_real (self, a, b) |
| generic | applyt (self, a, b) |
| Apply the matrix transpose. | |
| generic | applyt (self, a, b) |
| Apply the matrix transpose. | |
| procedure | applyt_complex (self, a, b) |
| Apply the matrix to a field. | |
| procedure | applyt_complex (self, a, b) |
| Apply the matrix to a field and optionally add it to an existing field. | |
| procedure | applyt_real (self, a, b) |
| Apply the matrix to a field. | |
| procedure(mat_apply_vec), deferred | applyt_real (self, a, b) |
| procedure | assemble (self, diag) |
| Finish assembly of matrix and optionally extract diagonals. | |
| procedure(mat_assemble), deferred | assemble (self, diag) |
| Complete matrix assembly. | |
| procedure | atomic_add_values (self, i_inds, j_inds, b, n, m, iblock, jblock, loc_cache) |
| Add values to a matrix. | |
| procedure(mat_add_values), deferred | atomic_add_values (self, i_inds, j_inds, b, n, m, iblock, jblock, loc_cache) |
| Add values atomically to the matrix. | |
| procedure | delete (self) |
| Delete matrix. | |
| procedure | delete (self) |
| Cleanup internal storage. | |
| procedure | delete (self) |
| Delete matrix. | |
| procedure | set_values (self, i_inds, j_inds, b, n, m, iblock, jblock) |
| Set values of a matrix. | |
| procedure(mat_set_values), deferred | set_values (self, i_inds, j_inds, b, n, m, iblock, jblock) |
| Set values of the matrix. | |
| procedure | setup (self, a, f, utyp) |
| Setup MF jacobian operator. | |
| procedure | update (self, a) |
| Update linearization point. | |
| procedure | zero (self) |
| Zero all entries in matrix. | |
| procedure(mat_zero), deferred | zero (self) |
| Zero all elements. | |
| procedure | zero_rows (self, nrows, irows, iblock, keep_diag) |
| Zero all entries in the specified rows. | |
| procedure(mat_zero_rows), deferred | zero_rows (self, nrows, irows, iblock, keep_diag) |
| Zero all elements in a given row. | |
Public Attributes | |
| real(r8) | b0 = 1.d-6 |
| Approximate relative error in function eval. | |
| class(oft_vector), pointer | d => NULL() |
| Diagonal entries for scaling. | |
| class(oft_matrix), pointer | f => NULL() |
| Non-linear function. | |
| class(oft_vector), pointer | f0 => NULL() |
| Linearization value "F(u0)". | |
| logical | force_local = .FALSE. |
| Do not stitch resulting vector (Native ONLY) | |
| type(oft_map), dimension(:), pointer | i_map => NULL() |
| Row block mapping. | |
| type(oft_map), dimension(:), pointer | j_map => NULL() |
| Column block mapping. | |
| integer(i4) | nc |
| Local number of columns. | |
| integer(i8) | ncg |
| Gobal number of columns. | |
| integer(i4) | ncslice = 0 |
| Number of owned columns. | |
| integer(i4) | ni = 0 |
| Number of row blocks. | |
| integer(i4) | nj = 0 |
| Number of column blocks. | |
| integer(i4) | nr |
| Local number of rows. | |
| integer(i8) | nrg |
| Gobal number of rows. | |
| integer(i4) | nrslice = 0 |
| Number of owned rows. | |
| class(oft_vector), pointer | tmp => NULL() |
| Internal work vector. | |
| class(oft_vector), pointer | u0 => NULL() |
| Linearization point. | |
| class(oft_vector), pointer | utyp => NULL() |
| Typical values vector. | |
|
inherited |
Add values to a matrix.
| [in] | i_inds | Row indices of entries to set [n] |
| [in] | j_inds | Column indices of entries to set [m] |
| [in] | b | Values to add [n,m] |
| [in] | n | Number of rows in local matrix |
| [in] | m | Number of columns in local matrix |
| [in] | iblock | Row block (optional) |
| [in] | jblock | Column block (optional) |
|
pure virtualinherited |
Add values to the matrix.
|
inherited |
Apply the matrix.
b = self^T * a
| [in] | a | Source field |
| [in,out] | b | Result of matrix product |
| [in] | beta | Factor for matrix addition |
|
inherited |
Apply the matrix.
|
inherited |
Apply the matrix to a field and optionally add it to an existing field.
b = self^T * a
| [in] | a | Source field |
| [in,out] | b | Result of matrix product |
| [in] | beta | Factor for matrix addition |
|
inherited |
Apply the matrix to a field.
b = self * a
| [in] | a | Source field |
| [out] | b | Result of matrix product |
| procedure apply_real | ( | class(oft_mf_matrix), intent(inout) | self, |
| class(oft_vector), intent(inout), target | a, | ||
| class(oft_vector), intent(inout) | b | ||
| ) |
Compute Jacobian approximation.
| [in] | a | Source field |
| [in,out] | b | F(a) |
|
pure virtualinherited |
|
inherited |
Apply the matrix transpose.
b = self^T * a
| [in] | a | Source field |
| [in,out] | b | Result of matrix product |
| [in] | beta | Factor for matrix addition |
|
inherited |
Apply the matrix transpose.
|
inherited |
Apply the matrix to a field.
b = self * a
| [in] | a | Source field |
| [out] | b | Result of matrix product |
|
inherited |
Apply the matrix to a field and optionally add it to an existing field.
b = self^T * a
| [in] | a | Source field |
| [in,out] | b | Result of matrix product |
| [in] | beta | Factor for matrix addition |
|
inherited |
Apply the matrix to a field.
b = self * a
| [in] | a | Source field |
| [out] | b | Result of matrix product |
|
pure virtualinherited |
|
inherited |
Finish assembly of matrix and optionally extract diagonals.
| [in,out] | diag | Diagonal entries of matrix [nr] (optional) |
|
pure virtualinherited |
Complete matrix assembly.
|
inherited |
Add values to a matrix.
| [in] | i_inds | Row indices of entries to set [n] |
| [in] | j_inds | Column indices of entries to set [m] |
| [in] | b | Values to add [n,m] |
| [in] | n | Number of rows in local matrix |
| [in] | m | Number of columns in local matrix |
| [in] | iblock | Row block (optional) |
| [in] | jblock | Column block (optional) |
|
pure virtualinherited |
Add values atomically to the matrix.
|
inherited |
Delete matrix.
| procedure delete | ( | class(oft_mf_matrix), intent(inout) | self | ) |
Cleanup internal storage.
|
inherited |
Delete matrix.
|
inherited |
Set values of a matrix.
| [in] | i_inds | Row indices of entries to set [n] |
| [in] | j_inds | Column indices of entries to set [m] |
| [in] | b | Values to set [n,m] |
| [in] | n | Number of rows in local matrix |
| [in] | m | Number of columns in local matrix |
| [in] | iblock | Row block (optional) |
| [in] | jblock | Column block (optional) |
|
pure virtualinherited |
Set values of the matrix.
| procedure setup | ( | class(oft_mf_matrix), intent(inout) | self, |
| class(oft_vector), intent(inout) | a, | ||
| class(oft_matrix), intent(in), target | f, | ||
| class(oft_vector), intent(inout), optional | utyp | ||
| ) |
Setup MF jacobian operator.
| [in] | a | Field defining domain and range spaces |
| [in] | f | Non-linear function defining the Jacobian |
| procedure update | ( | class(oft_mf_matrix), intent(inout) | self, |
| class(oft_vector), intent(inout) | a | ||
| ) |
Update linearization point.
| [in] | a | New linearization point |
|
inherited |
Zero all entries in matrix.
|
pure virtualinherited |
Zero all elements.
|
inherited |
Zero all entries in the specified rows.
| [in] | nrows | Number of rows to zero |
| [in] | irows | Indices of rows to zero [nrows] |
| [in] | iblock | Row block (optional) |
| [in] | keep_diag | Keep diagonal entries |
|
pure virtualinherited |
Zero all elements in a given row.
|
inherited |
Diagonal entries for scaling.
| class(oft_matrix), pointer f => NULL() |
Non-linear function.
| class(oft_vector), pointer f0 => NULL() |
Linearization value "F(u0)".
|
inherited |
Do not stitch resulting vector (Native ONLY)
|
inherited |
Row block mapping.
|
inherited |
Column block mapping.
|
inherited |
Local number of columns.
|
inherited |
Gobal number of columns.
|
inherited |
Number of owned columns.
|
inherited |
Number of row blocks.
|
inherited |
Number of column blocks.
|
inherited |
Local number of rows.
|
inherited |
Gobal number of rows.
|
inherited |
Number of owned rows.
| class(oft_vector), pointer tmp => NULL() |
Internal work vector.
| class(oft_vector), pointer u0 => NULL() |
Linearization point.
| class(oft_vector), pointer utyp => NULL() |
Typical values vector.