ConstrainedOptPack: C++ Tools for Constrained (and Unconstrained) Optimization  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ConstrainedOptPack_DecompositionSystemVarReductPerm.hpp
1 // @HEADER
2 // ***********************************************************************
3 //
4 // Moocho: Multi-functional Object-Oriented arCHitecture for Optimization
5 // Copyright (2003) Sandia Corporation
6 //
7 // Under terms of Contract DE-AC04-94AL85000, there is a non-exclusive
8 // license for use of this work by or on behalf of the U.S. Government.
9 //
10 // Redistribution and use in source and binary forms, with or without
11 // modification, are permitted provided that the following conditions are
12 // met:
13 //
14 // 1. Redistributions of source code must retain the above copyright
15 // notice, this list of conditions and the following disclaimer.
16 //
17 // 2. Redistributions in binary form must reproduce the above copyright
18 // notice, this list of conditions and the following disclaimer in the
19 // documentation and/or other materials provided with the distribution.
20 //
21 // 3. Neither the name of the Corporation nor the names of the
22 // contributors may be used to endorse or promote products derived from
23 // this software without specific prior written permission.
24 //
25 // THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
26 // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
27 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
28 // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
29 // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
30 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
31 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
32 // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
33 // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
34 // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
35 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36 //
37 // Questions? Contact Roscoe A. Bartlett (rabartl@sandia.gov)
38 //
39 // ***********************************************************************
40 // @HEADER
41 
42 #ifndef DECOMPOSITION_SYSTEM_VAR_REDUCT_PERM_H
43 #define DECOMPOSITION_SYSTEM_VAR_REDUCT_PERM_H
44 
45 #include <stdexcept>
46 
47 #include "ConstrainedOptPack_DecompositionSystemVarReduct.hpp"
48 #include "AbstractLinAlgPack_VectorSpace.hpp"
49 
50 namespace ConstrainedOptPack {
51 
57 public:
58 
61 
63  typedef Teuchos::RCP<
65 
67 
70 
73  EExplicitImplicit D_imp = MAT_IMP_AUTO
74  ,EExplicitImplicit Uz_imp = MAT_IMP_AUTO
75  )
76  :DecompositionSystemVarReduct(D_imp,Uz_imp)
77  {}
78 
80 
83 
85  virtual const perm_fcty_ptr_t factory_P_var() const = 0;
87  virtual const perm_fcty_ptr_t factory_P_equ() const = 0;
88 
90 
93 
96  virtual bool has_basis() const = 0;
97 
102  virtual void set_decomp(
103  std::ostream *out
104  ,EOutputLevel olevel
105  ,ERunTests test_what
106  ,const Permutation &P_var
107  ,const Range1D &var_dep
108  ,const Permutation *P_equ
109  ,const Range1D *equ_decomp
110  ,const MatrixOp &Gc
111  ,MatrixOp *Z
112  ,MatrixOp *Y
113  ,MatrixOpNonsing *R
114  ,MatrixOp *Uz
115  ,MatrixOp *Uy
116  ,EMatRelations mat_rel = MATRICES_INDEP_IMPS
117  ) = 0;
118 
123  virtual void select_decomp(
124  std::ostream *out
125  ,EOutputLevel olevel
126  ,ERunTests test_what
127  ,const Vector *nu
128  ,MatrixOp *Gc
129  ,Permutation *P_var
130  ,Range1D *var_dep
131  ,Permutation *P_equ
132  ,Range1D *equ_decomp
133  ,MatrixOp *Z
134  ,MatrixOp *Y
135  ,MatrixOpNonsing *R
136  ,MatrixOp *Uz
137  ,MatrixOp *Uy
138  ,EMatRelations mat_rel = MATRICES_INDEP_IMPS
139  ) = 0;
140 
142 
143 }; // end class DecompositionSystemVarReductPerm
144 
145 } // end namespace ConstrainedOptPack
146 
147 #endif // DECOMPOSITION_SYSTEM_VAR_REDUCT_PERM_H
virtual const perm_fcty_ptr_t factory_P_var() const =0
EOutputLevel
Enumeration for the amount of output to create from update_decomp().
virtual void set_decomp(std::ostream *out, EOutputLevel olevel, ERunTests test_what, const Permutation &P_var, const Range1D &var_dep, const Permutation *P_equ, const Range1D *equ_decomp, const MatrixOp &Gc, MatrixOp *Z, MatrixOp *Y, MatrixOpNonsing *R, MatrixOp *Uz, MatrixOp *Uy, EMatRelations mat_rel=MATRICES_INDEP_IMPS)=0
Client selects the basis for Gc(:,con_decomp)'.
ERunTests
Enumeration for if to run internal tests or not.
DecompositionSystemVarReductPerm(EExplicitImplicit D_imp=MAT_IMP_AUTO, EExplicitImplicit Uz_imp=MAT_IMP_AUTO)
virtual Range1D equ_decomp() const
Returns the range of the decomposed equalities.
virtual const perm_fcty_ptr_t factory_P_equ() const =0
Specialization of DecompositionSystem for variable reduction decompositions.
Specialization interface of DecompositonSystem that allows basis permutations.
virtual void select_decomp(std::ostream *out, EOutputLevel olevel, ERunTests test_what, const Vector *nu, MatrixOp *Gc, Permutation *P_var, Range1D *var_dep, Permutation *P_equ, Range1D *equ_decomp, MatrixOp *Z, MatrixOp *Y, MatrixOpNonsing *R, MatrixOp *Uz, MatrixOp *Uy, EMatRelations mat_rel=MATRICES_INDEP_IMPS)=0
Client asks decompostion system object to select the basis for Gc(:,con_decomp)'. ...
Teuchos::RCP< const Teuchos::AbstractFactory< Permutation > > perm_fcty_ptr_t
virtual bool has_basis() const =0
Query to see if a current basis is already selected.