Panzer
Version of the Day
Toggle main menu visibility
Loading...
Searching...
No Matches
disc-fe
src
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp
Go to the documentation of this file.
1
// @HEADER
2
// ***********************************************************************
3
//
4
// Panzer: A partial differential equation assembly
5
// engine for strongly coupled complex multiphysics systems
6
// Copyright (2011) Sandia Corporation
7
//
8
// Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
9
// the U.S. Government retains certain rights in this software.
10
//
11
// Redistribution and use in source and binary forms, with or without
12
// modification, are permitted provided that the following conditions are
13
// met:
14
//
15
// 1. Redistributions of source code must retain the above copyright
16
// notice, this list of conditions and the following disclaimer.
17
//
18
// 2. Redistributions in binary form must reproduce the above copyright
19
// notice, this list of conditions and the following disclaimer in the
20
// documentation and/or other materials provided with the distribution.
21
//
22
// 3. Neither the name of the Corporation nor the names of the
23
// contributors may be used to endorse or promote products derived from
24
// this software without specific prior written permission.
25
//
26
// THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
27
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
28
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
29
// PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
30
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
31
// EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
32
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
33
// PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
34
// LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
35
// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
36
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
37
//
38
// Questions? Contact Roger P. Pawlowski (rppawlo@sandia.gov) and
39
// Eric C. Cyr (eccyr@sandia.gov)
40
// ***********************************************************************
41
// @HEADER
42
43
#ifndef __Panzer_BlockedVector_ReadOnly_GlobalEvaluationData_hpp__
44
#define __Panzer_BlockedVector_ReadOnly_GlobalEvaluationData_hpp__
45
47
//
48
// Include Files
49
//
51
52
// Panzer
53
#include "
Panzer_ReadOnlyVector_GlobalEvaluationData.hpp
"
54
56
//
57
// Forward Declarations
58
//
60
61
namespace
Thyra
62
{
63
template
<
typename
>
class
DefaultProductVectorSpace
;
64
}
65
66
namespace
panzer
67
{
72
class
BlockedVector_ReadOnly_GlobalEvaluationData
73
:
74
public
ReadOnlyVector_GlobalEvaluationData
75
{
76
public
:
77
81
BlockedVector_ReadOnly_GlobalEvaluationData
();
82
88
BlockedVector_ReadOnly_GlobalEvaluationData
(
89
const
BlockedVector_ReadOnly_GlobalEvaluationData
& src);
90
102
BlockedVector_ReadOnly_GlobalEvaluationData
(
103
const
Teuchos::RCP<
const
Thyra::VectorSpaceBase<double>
> ghostedSpace,
104
const
Teuchos::RCP<
const
Thyra::VectorSpaceBase<double>
> ownedSpace,
105
const
std::vector<Teuchos::RCP<ReadOnlyVector_GlobalEvaluationData>>&
106
gedBlocks);
107
111
virtual
~BlockedVector_ReadOnly_GlobalEvaluationData
()
112
{
113
}
// end of Destructor
114
130
void
131
initialize
(
132
const
Teuchos::RCP<
const
Thyra::VectorSpaceBase<double>
>& ghostedSpace,
133
const
Teuchos::RCP<
const
Thyra::VectorSpaceBase<double>
>& ownedSpace,
134
const
std::vector<Teuchos::RCP<ReadOnlyVector_GlobalEvaluationData>>&
135
gedBlocks);
136
142
virtual
bool
143
isInitialized
()
const
144
{
145
return
isInitialized_
;
146
}
// end of isInitialized()
147
156
virtual
void
157
globalToGhost
(
158
int
mem);
159
165
virtual
void
166
initializeData
();
167
174
virtual
void
175
setOwnedVector
(
176
const
Teuchos::RCP<
const
Thyra::VectorBase<double>
>& ownedVector);
177
183
virtual
Teuchos::RCP<const Thyra::VectorBase<double>>
184
getOwnedVector
()
const
;
185
191
virtual
Teuchos::RCP<Thyra::VectorBase<double>>
192
getGhostedVector
()
const
;
193
199
size_t
200
getBlockCount
()
const
201
{
202
return
gedBlocks_
.size();
203
}
// end of getBlockCount()
204
205
206
#ifdef PANZER_HAVE_EPETRA_STACK
212
Teuchos::RCP<ReadOnlyVector_GlobalEvaluationData>
213
getGEDBlock(
214
int
i)
215
{
216
return
gedBlocks_
[i];
217
}
// end of getGEDBlock()
218
224
Teuchos::RCP<const ReadOnlyVector_GlobalEvaluationData>
225
getGEDBlock(
226
int
i)
const
227
{
228
return
gedBlocks_
[i];
229
}
// end of getGEDBlock()
230
#endif
// PANZER_HAVE_EPETRA_STACK
231
239
bool
240
requiresDirichletAdjustment
()
const
241
{
242
return
false
;
243
}
// end of requiresDirichletAdjustment()
244
245
private
:
246
251
bool
isInitialized_
;
252
256
std::vector<Teuchos::RCP<ReadOnlyVector_GlobalEvaluationData>>
257
gedBlocks_
;
258
262
Teuchos::RCP<const Thyra::VectorBase<double>>
ownedVector_
;
263
267
Teuchos::RCP<const Thyra::DefaultProductVectorSpace<double>>
268
ghostedSpace_
;
269
270
};
// end of class BlockedVector_ReadOnly_GlobalEvaluationData
271
272
}
// end of namespace panzer
273
274
#endif
// __Panzer_BlockedVector_ReadOnly_GlobalEvaluationData_hpp__
Panzer_ReadOnlyVector_GlobalEvaluationData.hpp
Thyra::DefaultProductVectorSpace
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp:63
Thyra::VectorBase
Thyra::VectorSpaceBase
Definition
Panzer_ThyraObjFactory.hpp:52
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::getGhostedVector
virtual Teuchos::RCP< Thyra::VectorBase< double > > getGhostedVector() const
Get the ghosted vector.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.cpp:217
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::isInitialized_
bool isInitialized_
A flag indicating whether or not the object has been initialized.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp:251
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::initializeData
virtual void initializeData()
Initialize internal data for communication.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.cpp:160
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::requiresDirichletAdjustment
bool requiresDirichletAdjustment() const
Determine if a Dirichlet adjustment is necessary.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp:240
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::initialize
void initialize(const Teuchos::RCP< const Thyra::VectorSpaceBase< double > > &ghostedSpace, const Teuchos::RCP< const Thyra::VectorSpaceBase< double > > &ownedSpace, const std::vector< Teuchos::RCP< ReadOnlyVector_GlobalEvaluationData > > &gedBlocks)
Initialize this object using the sub-GlobalEvaluationData objects.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.cpp:109
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::ownedVector_
Teuchos::RCP< const Thyra::VectorBase< double > > ownedVector_
The owned vector.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp:262
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::ghostedSpace_
Teuchos::RCP< const Thyra::DefaultProductVectorSpace< double > > ghostedSpace_
The vector space corresponding to the ghosted vector.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp:268
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::gedBlocks_
std::vector< Teuchos::RCP< ReadOnlyVector_GlobalEvaluationData > > gedBlocks_
A vector of the GlobalEvaluationData blocks.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp:257
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::isInitialized
virtual bool isInitialized() const
Is this object initialized?
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp:143
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::globalToGhost
virtual void globalToGhost(int mem)
Communicate the owned data to the ghosted vector.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.cpp:141
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::setOwnedVector
virtual void setOwnedVector(const Teuchos::RCP< const Thyra::VectorBase< double > > &ownedVector)
Set the owned vector.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.cpp:178
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::getBlockCount
size_t getBlockCount() const
How many blocks do we have?
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp:200
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::~BlockedVector_ReadOnly_GlobalEvaluationData
virtual ~BlockedVector_ReadOnly_GlobalEvaluationData()
Destructor.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.hpp:111
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::getOwnedVector
virtual Teuchos::RCP< const Thyra::VectorBase< double > > getOwnedVector() const
Get the owned vector.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.cpp:205
panzer::BlockedVector_ReadOnly_GlobalEvaluationData::BlockedVector_ReadOnly_GlobalEvaluationData
BlockedVector_ReadOnly_GlobalEvaluationData()
Default Constructor.
Definition
Panzer_BlockedVector_ReadOnly_GlobalEvaluationData.cpp:66
panzer::ReadOnlyVector_GlobalEvaluationData
Definition
Panzer_ReadOnlyVector_GlobalEvaluationData.hpp:65
Thyra
Definition
Panzer_GatherSolution_BlockedEpetra_decl.hpp:79
panzer
Computes .
Definition
Panzer_BasisValues_Evaluator_decl.hpp:54
Generated by
1.17.0