Panzer Version of the Day
Loading...
Searching...
No Matches
Panzer_Response_IPCoordinates.hpp
Go to the documentation of this file.
1// @HEADER
2// *****************************************************************************
3// Panzer: A partial differential equation assembly
4// engine for strongly coupled complex multiphysics systems
5//
6// Copyright 2011 NTESS and the Panzer contributors.
7// SPDX-License-Identifier: BSD-3-Clause
8// *****************************************************************************
9// @HEADER
10
11#ifndef __Panzer_Response_IPCoordinates_hpp__
12#define __Panzer_Response_IPCoordinates_hpp__
13
14#include <string>
15
16
17#include <mpi.h> // need for comm
18
19#include "Teuchos_RCP.hpp"
20
21#include "Thyra_VectorBase.hpp"
22#include "Thyra_VectorSpaceBase.hpp"
23
24#include "Epetra_Map.h"
25#include "Epetra_Vector.h"
26#include "Epetra_MpiComm.h"
27
30
31
32namespace panzer {
33
38template <typename EvalT>
40public:
41 typedef typename EvalT::ScalarT ScalarT;
42
43 Response_IPCoordinates(const std::string & responseName)
44 : ResponseBase(responseName) {}
45
46 virtual void scatterResponse() {}
47
48 virtual void initializeResponse()
49 {
50 if(coords==Teuchos::null)
51 coords = Teuchos::rcp(new std::vector<panzer::Traits::Residual::ScalarT>);
52
53 coords->clear();
54 }
55
56 Teuchos::RCP<const std::vector<panzer::Traits::Residual::ScalarT> > getCoords() const
57 { return coords; }
58
59 Teuchos::RCP<std::vector<panzer::Traits::Residual::ScalarT> > getNonconstCoords()
60 { return coords; }
61
62private:
63 // hide these methods
66
67 Teuchos::RCP<std::vector<panzer::Traits::Residual::ScalarT> > coords;
68};
69
70}
71
72#endif
Teuchos::RCP< std::vector< panzer::Traits::Residual::ScalarT > > getNonconstCoords()
Response_IPCoordinates(const std::string &responseName)
Response_IPCoordinates(const Response_IPCoordinates &)
Teuchos::RCP< std::vector< panzer::Traits::Residual::ScalarT > > coords
virtual void scatterResponse()
Prepare the response for access by the user (do global communication)
Teuchos::RCP< const std::vector< panzer::Traits::Residual::ScalarT > > getCoords() const