00001 //*****************************************************************// 00002 // Albany 2.0: Copyright 2012 Sandia Corporation // 00003 // This Software is released under the BSD license detailed // 00004 // in the file "license.txt" in the top-level Albany directory // 00005 //*****************************************************************// 00006 #ifndef MOR_FULLSTATERECONSTRUCTOR_HPP 00007 #define MOR_FULLSTATERECONSTRUCTOR_HPP 00008 00009 #include "NOX_Epetra_Observer.H" 00010 00011 #include "Epetra_Vector.h" 00012 00013 #include "Teuchos_RCP.hpp" 00014 00015 namespace MOR { 00016 00017 class ReducedSpace; 00018 00019 class FullStateReconstructor : public NOX::Epetra::Observer { 00020 public: 00021 FullStateReconstructor( 00022 const Teuchos::RCP<const ReducedSpace> &reducedSpace, 00023 const Teuchos::RCP<NOX::Epetra::Observer> &decoratedObserver); 00024 00026 virtual void observeSolution(const Epetra_Vector& solution); 00027 00029 virtual void observeSolution(const Epetra_Vector& solution, double time_or_param_val); 00030 00031 private: 00032 Teuchos::RCP<const ReducedSpace> reducedSpace_; 00033 Teuchos::RCP<NOX::Epetra::Observer> decoratedObserver_; 00034 00035 Epetra_Vector lastFullSolution_; 00036 void computeLastFullSolution(const Epetra_Vector& reducedSolution); 00037 00038 // Disallow copy & assignment 00039 FullStateReconstructor(const FullStateReconstructor &); 00040 FullStateReconstructor operator=(const FullStateReconstructor &); 00041 }; 00042 00043 } // namespace MOR 00044 00045 #endif /* MOR_FULLSTATERECONSTRUCTOR_HPP */