#include <ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp>
Inheritance diagram for ConstrainedOptPack::MatrixSymPosDefLBFGS:
Public types | |
| typedef Teuchos::RefCountPtr< const MultiVector > | multi_vec_ptr_t |
| | |
Constructors and initializers | |
| MatrixSymPosDefLBFGS (size_type m=10, bool maintain_original=true, bool maintain_inverse=true, bool auto_rescaling=false) | |
Calls this->initial_setup(). | |
| void | auto_rescaling (const bool &auto_rescaling) |
| Set whether automatic rescaling is used or not. | |
| void | initial_setup (size_type m=10, bool maintain_original=true, bool maintain_inverse=true, bool auto_rescaling=false) |
| Initial setup for the matrix. | |
| size_type | m () const |
| | |
| size_type | m_bar () const |
| | |
| value_type | gamma_k () const |
| | |
| const multi_vec_ptr_t | S () const |
| | |
| const multi_vec_ptr_t | Y () const |
| | |
| bool | maintain_original () const |
| | |
| bool | maintain_inverse () const |
| | |
| size_type | num_secant_updates () const |
Returns the total number of successful secant updates performed since this->init_identity() was called. | |
Overridden from MatrixOp | |
| const VectorSpace & | space_cols () const |
| | |
| std::ostream & | output (std::ostream &out) const |
| | |
| MatrixOp & | operator= (const MatrixOp &mwo) |
| | |
| void | Vp_StMtV (VectorMutable *v_lhs, value_type alpha, BLAS_Cpp::Transp trans_rhs1, const Vector &v_rhs2, value_type beta) const |
| | |
Overridden from MatrixOpNonsing | |
| void | V_InvMtV (VectorMutable *v_lhs, BLAS_Cpp::Transp trans_rhs1, const Vector &v_rhs2) const |
| | |
Overridden from MatrixSymSecant | |
| void | init_identity (const VectorSpace &space_diag, value_type alpha) |
| | |
| void | init_diagonal (const Vector &diag) |
| Actually this calls init_identity( diag.space(), diag.norm_inf() ). | |
| void | secant_update (VectorMutable *s, VectorMutable *y, VectorMutable *Bs) |
| | |
Overridden from MatrixOp | |
| std::ostream & | output (std::ostream &out) const |
| | |
| MatrixOp & | operator= (const MatrixOp &m) |
| | |
| void | Vp_StMtV (DVectorSlice *vs_lhs, value_type alpha, BLAS_Cpp::Transp trans_rhs1, const DVectorSlice &vs_rhs2, value_type beta) const |
| | |
Overridden from MatrixWithOpFactorized | |
| void | V_InvMtV (DVectorSlice *v_lhs, BLAS_Cpp::Transp trans_rhs1, const DVectorSlice &vs_rhs2) const |
| | |
Overridden from MatrixSymSecant | |
| void | init_identity (size_type n, value_type alpha) |
| | |
| void | init_diagonal (const DVectorSlice &diag) |
| Actually this calls init_identity( (&diag)->size(), norm_inf(diag) ). | |
| void | secant_update (DVectorSlice *s, DVectorSlice *y, DVectorSlice *Bs) |
| | |
Overridden from MatrixSymAddDelUpdateble | |
| void | initialize (value_type alpha, size_type max_size) |
| This is fine as long as alpha > 0.0. | |
| void | initialize (const DMatrixSliceSym &A, size_type max_size, bool force_factorization, Inertia inertia, PivotTolerances pivot_tols) |
| Sorry, this will throw an exception! | |
| size_type | max_size () const |
| | |
| Inertia | inertia () const |
| Returns (0,0,rows()). | |
| void | set_uninitialized () |
| Will set rows() == 0. | |
| void | augment_update (const DVectorSlice *t, value_type alpha, bool force_refactorization, EEigenValType add_eigen_val, PivotTolerances pivot_tols) |
| Augment the matrix to add a row and column. | |
| void | delete_update (size_type jd, bool force_refactorization, EEigenValType drop_eigen_val, PivotTolerances pivot_tols) |
| Should always succeed unless user gives a wrong value for drop_eigen_val. | |
Public Member Functions | |
| MatrixSymPosDefLBFGS (size_type max_size=0, size_type m=10, bool maintain_original=true, bool maintain_inverse=true, bool auto_rescaling=false) | |
| Calls initial_setup(,,,). | |
| void | auto_rescaling (const bool &auto_rescaling) |
| Set whether automatic rescaling is used or not. | |
| void | initial_setup (size_type max_size=0, size_type m=10, bool maintain_original=true, bool maintain_inverse=true, bool auto_rescaling=false) |
| Initial setup for the matrix. | |
| size_type | m () const |
| | |
| size_type | m_bar () const |
| | |
| size_type | k_bar () const |
| | |
| value_type | gamma_k () const |
| | |
| const DMatrixSlice | S () const |
| | |
| const DMatrixSlice | Y () const |
| | |
| bool | maintain_original () const |
| | |
| bool | maintain_inverse () const |
| | |
| size_type | num_secant_updates () const |
| Returns the total number of successful secant updates performed. | |
| size_type | rows () const |
| | |
The function set_num_updates_stored() must be called first to set the maximum number of the most recent updates that can be stored. The storage requirements for this class are O( n*m + m*m ) which is O(n*m) when n >> m which is expected (where n is the dimension of the vector space and m is the maximum number of updates stored).
This implementation is based on:
Byrd, Nocedal, and Schnabel, "Representations of quasi-Newton matrices and their use in limited memory methods", Mathematical Programming, 63 (1994)
Consider BFGS updates of the form:
( B^{k-1}, s^{k-1}, y^{k-1} ) -> B^{k}
where:
B^{k} = B^{k-1} - ( (B*s)*(B*s)' / (s'*B*s) )^{k-1} + ( (y*y') / (s'*y) )^{k-1}
B <: R^(n x n)
s <: R^(n)
y <: R^(n)
Bo = ( 1 / gamma_k ) * I
where:
/ (s^{k-1}'*y^{k-1})/(y^{k-1}'*y^{k-1}) : if auto_rescaling() == true
gamma_k = |
\ 1/alpha from last call to init_identity(n,alpha) : otherwise
S and Y that store the update vectors s^{i} and y^{i} for i = 1 ... m_bar:
S = [ s^{1}, s^{2},...,s^{m_bar} ] <: R^(n x m)
Y = [ y^{1}, y^{2},...,y^{m_bar} ] <: R^(n x m)
m_bar <= m most recent update vectors and their ordering is significant. The columns S(:,m_bar) and Y(:,m_bar) contain the most recent update vectors. This is all client needs to know in order to reconstruct the updates themselves.
This class allows matrix-vector products x = B*y and the inverse matrix-vector products x = inv(B)*y to be performed at a cost of about O(n*m_bar^2).
Definition at line 97 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp.
|
|
Definition at line 107 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
||||||||||||||||||||
|
Calls
Definition at line 148 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
||||||||||||||||||||||||
|
Calls initial_setup(,,,).
Definition at line 140 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
|
Set whether automatic rescaling is used or not. This function must be called before a BFGS update is performed in order for it to take effect for that update. Definition at line 155 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
||||||||||||||||||||
|
Initial setup for the matrix. This function must be called before init_identity(n) is called in order for these setting to have affect. When this function is called all current updates are lost and the matrix becomes uninitialized.
Definition at line 158 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
|
Definition at line 347 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
|
Definition at line 353 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
|
Definition at line 359 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
|
Definition at line 366 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
|
Definition at line 373 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
|
Definition at line 379 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
|
Definition at line 385 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
|
Returns the total number of successful secant updates performed since
Definition at line 391 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.hpp. |
|
|
Implements AbstractLinAlgPack::MatrixBase. Definition at line 184 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
|
Reimplemented from AbstractLinAlgPack::MatrixOp. Definition at line 189 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
|
Reimplemented from AbstractLinAlgPack::MatrixOp. Definition at line 213 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
||||||||||||||||||||||||
|
Implements AbstractLinAlgPack::MatrixOp. Definition at line 249 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
||||||||||||||||
|
Implements AbstractLinAlgPack::MatrixNonsing. Definition at line 339 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
||||||||||||
|
Definition at line 463 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
|
Actually this calls init_identity( diag.space(), diag.norm_inf() ). This initialization is not convienent for this implementation. Besides, when we are using automatric rescaling (auto_rescaling == true) then this will really not matter much anyway. Definition at line 495 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
||||||||||||||||
|
Definition at line 500 of file ConstrainedOptPack_MatrixSymPosDefLBFGS.cpp. |
|
|
Set whether automatic rescaling is used or not. This function must be called before a BFGS update is performed in order for it to take effect for that update. Definition at line 130 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.hpp. |
|
||||||||||||||||||||||||
|
Initial setup for the matrix. This function must be called before init_identity(n) is called. When this function is called all current updates are lost and the matrix becomes uninitialized.
Definition at line 151 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
|
|
|
|
|
|
|
Definition at line 385 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.hpp. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Returns the total number of successful secant updates performed.
|
|
|
Reimplemented from AbstractLinAlgPack::MatrixBase. Definition at line 178 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
|
Reimplemented from AbstractLinAlgPack::MatrixOp. |
|
|
Reimplemented from AbstractLinAlgPack::MatrixOp. |
|
||||||||||||||||||||||||
|
Definition at line 239 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
||||||||||||||||
|
Definition at line 336 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
||||||||||||
|
Definition at line 458 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
|
Actually this calls init_identity( (&diag)->size(), norm_inf(diag) ). This initialization is not convienent for this implementation. Besides, when we are using automatric rescaling (auto_rescaling == true) then this will really not matter much anyway. Definition at line 498 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
||||||||||||||||
|
Definition at line 504 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
||||||||||||
|
This is fine as long as alpha > 0.0.
Definition at line 661 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
||||||||||||||||||||||||
|
Sorry, this will throw an exception!
Definition at line 678 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
|
Definition at line 691 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
|
Returns (0,0,rows()).
Definition at line 696 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
|
Will set rows() == 0.
Definition at line 701 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
||||||||||||||||||||||||
|
Augment the matrix to add a row and column. This function is very limited in what it will do. It will throw exceptions if alpha <= 0.0 or t != NULL or add_eigen_val == EIGEN_VAL_NEG or this->rows() == this->max_size(). The obvious postconditions for this function will only technically be satisfied if alpha == this->gamma_k(). Definition at line 706 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
|
||||||||||||||||||||
|
Should always succeed unless user gives a wrong value for drop_eigen_val.
Definition at line 760 of file ConstrainedOptPack_MatrixSymPosDefLBFGSSerial.cpp. |
1.3.9.1