void Albany::PoissonsEquationProblem:: buildProblem( Teuchos::ArrayRCP<Teuchos::RCP<Albany::MeshSpecsStruct> > meshSpecs, Albany::StateManager& stateMgr) { int physSets = meshSpecs.size(); *out << "Num MeshSpecs: " << physSets << '\n'; fm.resize(physSets); bool haveSidesets = false; *out << "Calling PoissonsEquationProblem::buildEvaluators" << '\n'; for (int ps = 0; ps < physSets; ++ps) { fm[ps] = Teuchos::rcp(new PHX::FieldManager<PHAL::AlbanyTraits>); buildEvaluators(*fm[ps], *meshSpecs[ps], stateMgr, BUILD_RESID_FM, Teuchos::null); if (meshSpecs[ps]->ssNames.size() > 0) haveSidesets = true; } constructDirichletEvaluators(*meshSpecs[0]); if( haveSidesets ) constructNeumannEvaluators(meshSpecs[0]); if( params->isType<Teuchos::RCP<ATO::Topology> >("Topology") ) setupTopOpt(meshSpecs,stateMgr); }
void Albany::HMCProblem:: buildProblem( Teuchos::ArrayRCP<Teuchos::RCP<Albany::MeshSpecsStruct>> meshSpecs, Albany::StateManager& stateMgr) { /* Construct All Phalanx Evaluators */ TEUCHOS_TEST_FOR_EXCEPTION(meshSpecs.size()!=1,std::logic_error,"Problem supports one Material Block"); fm.resize(1); fm[0] = Teuchos::rcp(new PHX::FieldManager<PHAL::AlbanyTraits>); buildEvaluators(*fm[0], *meshSpecs[0], stateMgr, BUILD_RESID_FM, Teuchos::null); if(meshSpecs[0]->nsNames.size() > 0) // Build a nodeset evaluator if nodesets are present constructDirichletEvaluators(*meshSpecs[0]); if(meshSpecs[0]->ssNames.size() > 0) // Build a sideset evaluator if sidesets are present constructNeumannEvaluators(meshSpecs[0]); #ifdef ALBANY_ATO if( params->isType<Teuchos::RCP<ATO::Topology>>("Topology") ) setupTopOpt(meshSpecs,stateMgr); #endif }