SensSchurDriver.hpp
Go to the documentation of this file.
1 // Copyright 2009, 2011 Hans Pirnay
2 // All Rights Reserved.
3 // This code is published under the Eclipse Public License.
4 //
5 // Date : 2009-05-06
6 
7 #ifndef __ASSCHURDRIVER_HPP__
8 #define __ASSCHURDRIVER_HPP__
9 
10 #include "SensSchurData.hpp"
11 #include "SensPCalculator.hpp"
12 #include "IpVector.hpp"
13 #include "IpIteratesVector.hpp"
14 
15 namespace Ipopt
16 {
17 
19  {
29  public:
30 
33  :
34  pcalc_(pcalc),
35  data_B_(data_B)
36  {
37  }
38 
39  virtual ~SchurDriver()
40  {
41  }
42 
44  virtual bool InitializeImpl(const OptionsList& options,
45  const std::string& prefix)
46  {
47  return true;
48  }
49 
52  {
53  return pcalc_->data_A();
54  }
55 
57  {
58  return ConstPtr(data_B_);
59  }
60 
62  {
63  return pcalc_->data_A_nonconst();
64  }
65 
67  {
68  return data_B_;
69  }
70 
72  {
73  return ConstPtr(pcalc_);
74  }
75 
77  {
78  return pcalc_;
79  }
80 
84  virtual bool SchurBuild() =0;
85 
87  virtual bool SchurFactorize() =0;
88 
90  virtual bool SchurSolve(SmartPtr<IteratesVector> lhs,
92  SmartPtr<Vector> delta_u,
93  SmartPtr<IteratesVector> sol=NULL)=0; // the vector K^(-1)*r_s which usually should have been computed before.
94 
95 
101  private:
103  {
104  }
105 
107 
109  };
110 }
111 
112 #endif