IpWsmpSolverInterface.hpp

Go to the documentation of this file.
00001 // Copyright (C) 2005, 2006 International Business Machines and others.
00002 // All Rights Reserved.
00003 // This code is published under the Common Public License.
00004 //
00005 // $Id: IpWsmpSolverInterface.hpp 759 2006-07-07 03:07:08Z andreasw $
00006 //
00007 // Authors:  Carl Laird, Andreas Waechter     IBM    2005-03-17
00008 
00009 
00010 #ifndef __IPWSMPSOLVERINTERFACE_HPP__
00011 #define __IPWSMPSOLVERINTERFACE_HPP__
00012 
00013 #include "IpSparseSymLinearSolverInterface.hpp"
00014 
00015 namespace Ipopt
00016 {
00017 
00022   class WsmpSolverInterface: public SparseSymLinearSolverInterface
00023   {
00024   public:
00028     WsmpSolverInterface();
00029 
00031     virtual ~WsmpSolverInterface();
00033 
00035     bool InitializeImpl(const OptionsList& options,
00036                         const std::string& prefix);
00037 
00038 
00042     virtual ESymSolverStatus InitializeStructure(Index dim, Index nonzeros,
00043         const Index *ia,
00044         const Index *ja);
00045 
00048     virtual double* GetValuesArrayPtr();
00049 
00051     virtual ESymSolverStatus MultiSolve(bool new_matrix,
00052                                         const Index* ia,
00053                                         const Index* ja,
00054                                         Index nrhs,
00055                                         double* rhs_vals,
00056                                         bool check_NegEVals,
00057                                         Index numberOfNegEVals);
00058 
00062     virtual Index NumberOfNegEVals() const;
00064 
00065     //* @name Options of Linear solver */
00067 
00069     virtual bool IncreaseQuality();
00070 
00074     virtual bool ProvidesInertia() const
00075     {
00076       return true;
00077     }
00081     EMatrixFormat MatrixFormat() const
00082     {
00083       return CSR_Format_1_Offset;
00084     }
00086 
00089     static void RegisterOptions(SmartPtr<RegisteredOptions> roptions);
00091 
00092   private:
00102     WsmpSolverInterface(const WsmpSolverInterface&);
00103 
00105     void operator=(const WsmpSolverInterface&);
00107 
00111     Index dim_;
00112 
00114     double* a_;
00116 
00120     Index wsmp_num_threads_;
00122     Index wsmp_ordering_option_;
00124     Number wsmp_pivtol_;
00126     Number wsmp_pivtolmax_;
00128     Index wsmp_scaling_;
00131     Number wsmp_singularity_threshold_;
00133     Index wsmp_write_matrix_iteration_;
00135 
00137     Index matrix_file_number_;
00138 
00142     Index negevals_;
00144 
00149     bool initialized_;
00152     bool pivtol_changed_;
00155     bool have_symbolic_factorization_;
00157 
00161     ipfint* IPARM_;
00163     double* DPARM_;
00165     ipfint* PERM_;
00167     ipfint* INVP_;
00169 
00174     ESymSolverStatus SymbolicFactorization(const Index* ia,
00175                                            const Index* ja);
00176 
00179     ESymSolverStatus Factorization(const Index* ia,
00180                                    const Index* ja,
00181                                    bool check_NegEVals,
00182                                    Index numberOfNegEVals);
00183 
00186     ESymSolverStatus Solve(const Index* ia,
00187                            const Index* ja,
00188                            Index nrhs,
00189                            double *rhs_vals);
00191   };
00192 
00193 } // namespace Ipopt
00194 #endif

Generated on Fri May 16 21:06:00 2008 for Bonmin by  doxygen 1.4.7