00001 #ifndef EPETRA_MODEL_EVAL_2D_SIM_HPP
00002 #define EPETRA_MODEL_EVAL_2D_SIM_HPP
00003
00004 #include "EpetraExt_ModelEvaluator.h"
00005 #include "Epetra_Map.h"
00006 #include "Epetra_Vector.h"
00007 #include "Epetra_Comm.h"
00008 #include "Epetra_CrsGraph.h"
00009
00021 class EpetraModelEval2DSim : public EpetraExt::ModelEvaluator {
00022 public:
00023
00025 EpetraModelEval2DSim(
00026 const double d = 10.0
00027 ,const double p0 = 2.0
00028 ,const double p1 = 0.0
00029 ,const double x00 = 1.0
00030 ,const double x01 = 1.0
00031 ,const bool showGetInvalidArg = false
00032 );
00033
00036
00038 Teuchos::RefCountPtr<const Epetra_Map> get_x_map() const;
00040 Teuchos::RefCountPtr<const Epetra_Map> get_f_map() const;
00042 Teuchos::RefCountPtr<const Epetra_Vector> get_x_init() const;
00044 Teuchos::RefCountPtr<Epetra_Operator> create_W() const;
00046 InArgs createInArgs() const;
00048 OutArgs createOutArgs() const;
00050 void evalModel( const InArgs& inArgs, const OutArgs& outArgs ) const;
00051
00053
00054 private:
00055
00056
00057
00058
00059 double d_;
00060 bool showGetInvalidArg_;
00061
00062 bool isInitialized_;
00063
00064 Teuchos::RefCountPtr<const Epetra_Comm> epetra_comm_;
00065 Teuchos::RefCountPtr<const Epetra_Map> map_x_;
00066
00067 Teuchos::RefCountPtr<Epetra_Vector> x0_;
00068 Teuchos::RefCountPtr<Epetra_Vector> p_;
00069
00070 Teuchos::RefCountPtr<Epetra_CrsGraph> W_graph_;
00071
00072 };
00073
00074 #endif // EPETRA_MODEL_EVAL_2D_SIM_HPP