Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007 #ifndef ALBANY_ORDINARYSTKFIELDCONT_HPP
00008 #define ALBANY_ORDINARYSTKFIELDCONT_HPP
00009
00010 #include "Albany_GenericSTKFieldContainer.hpp"
00011
00012 namespace Albany {
00013
00014 template<bool Interleaved>
00015
00016 class OrdinarySTKFieldContainer : public GenericSTKFieldContainer<Interleaved> {
00017
00018 public:
00019
00020 OrdinarySTKFieldContainer(const Teuchos::RCP<Teuchos::ParameterList>& params_,
00021 stk::mesh::fem::FEMMetaData* metaData_,
00022 stk::mesh::BulkData* bulkData_,
00023 const int neq_,
00024 const AbstractFieldContainer::FieldContainerRequirements& req,
00025 const int numDim_,
00026 const Teuchos::RCP<Albany::StateInfoStruct>& sis);
00027
00028 ~OrdinarySTKFieldContainer();
00029
00030 bool hasResidualField(){ return (residual_field != NULL); }
00031 bool hasSurfaceHeightField(){ return buildSurfaceHeight; }
00032 bool hasTemperatureField(){ return buildTemperature; }
00033 bool hasBasalFrictionField(){ return buildBasalFriction; }
00034 bool hasThicknessField(){ return buildThickness; }
00035 bool hasFlowFactorField(){ return buildFlowFactor; }
00036 bool hasSurfaceVelocityField(){ return buildSurfaceVelocity; }
00037 bool hasVelocityRMSField(){ return buildVelocityRMS; }
00038
00039 AbstractSTKFieldContainer::VectorFieldType* getSolutionField(){ return solution_field; };
00040
00041 void fillSolnVector(Epetra_Vector& soln, stk::mesh::Selector& sel, const Teuchos::RCP<Epetra_Map>& node_map);
00042 void saveSolnVector(const Epetra_Vector& soln, stk::mesh::Selector& sel, const Teuchos::RCP<Epetra_Map>& node_map);
00043 void saveResVector(const Epetra_Vector& res, stk::mesh::Selector& sel, const Teuchos::RCP<Epetra_Map>& node_map);
00044
00045 void transferSolutionToCoords();
00046
00047 private:
00048
00049 void initializeSTKAdaptation();
00050
00051 bool buildSurfaceHeight;
00052 bool buildTemperature;
00053 bool buildBasalFriction;
00054 bool buildThickness;
00055 bool buildFlowFactor;
00056 bool buildSurfaceVelocity;
00057 bool buildVelocityRMS;
00058
00059 AbstractSTKFieldContainer::VectorFieldType* solution_field;
00060 AbstractSTKFieldContainer::VectorFieldType* residual_field;
00061
00062 };
00063
00064 }
00065
00066
00067
00068
00069 #define ORDINARYSTKFIELDCONTAINER_INSTANTIATE_TEMPLATE_CLASS_NONINTERLEAVED(name) \
00070 template class name<false>;
00071 #define ORDINARYSTKFIELDCONTAINER_INSTANTIATE_TEMPLATE_CLASS_INTERLEAVED(name) \
00072 template class name<true>;
00073
00074 #define ORDINARYSTKFIELDCONTAINER_INSTANTIATE_TEMPLATE_CLASS(name) \
00075 ORDINARYSTKFIELDCONTAINER_INSTANTIATE_TEMPLATE_CLASS_NONINTERLEAVED(name) \
00076 ORDINARYSTKFIELDCONTAINER_INSTANTIATE_TEMPLATE_CLASS_INTERLEAVED(name)
00077
00078
00079 #endif