55 _fe_problem.subdomainSetup(_subdomain, _tid);
57 std::set<MooseVariableFEBase *> needed_moose_vars;
58 std::unordered_set<unsigned int> needed_mat_props;
59 std::set<TagID> needed_fe_var_matrix_tags;
60 std::set<TagID> needed_fe_var_vector_tags;
62 _fe_problem.getMaterialWarehouse().updateBlockFEVariableCoupledVectorTagDependency(
63 _subdomain, needed_fe_var_vector_tags, _tid);
65 std::vector<AuxKernelType *> kernels;
66 _query_subdomain.queryInto(kernels, _tid, _subdomain);
67 for (
const auto & aux : kernels)
69 aux->subdomainSetup();
70 const auto & mv_deps = aux->getMooseVariableDependencies();
71 const auto & mp_deps = aux->getMatPropDependencies();
72 needed_moose_vars.insert(mv_deps.begin(), mv_deps.end());
73 needed_mat_props.insert(mp_deps.begin(), mp_deps.end());
75 auto & fe_var_coup_vtags = aux->getFEVariableCoupleableVectorTags();
76 needed_fe_var_vector_tags.insert(fe_var_coup_vtags.begin(), fe_var_coup_vtags.end());
78 auto & fe_var_coup_mtags = aux->getFEVariableCoupleableMatrixTags();
79 needed_fe_var_matrix_tags.insert(fe_var_coup_mtags.begin(), fe_var_coup_mtags.end());
82 _fe_problem.setActiveElementalMooseVariables(needed_moose_vars, _tid);
83 _fe_problem.prepareMaterials(needed_mat_props, _subdomain, _tid);
84 _fe_problem.setActiveFEVariableCoupleableMatrixTags(needed_fe_var_matrix_tags, _tid);
85 _fe_problem.setActiveFEVariableCoupleableVectorTags(needed_fe_var_vector_tags, _tid);
92 std::vector<AuxKernelType *> kernels;
93 _query_subdomain.queryInto(kernels, _tid, _subdomain);
96 _fe_problem.prepare(elem, _tid);
97 _fe_problem.reinitElem(elem, _tid);
104 _fe_problem.reinitMaterials(elem->subdomain_id(), _tid);
106 for (
const auto & aux : kernels)
109 aux->variable().insert(_aux_sys.solution());
112 if (aux->hasWritableCoupledVariables())
114 for (
auto * var : aux->getWritableCoupledVariables())
115 var->insert(_aux_sys.solution());
117 _fe_problem.reinitElem(elem, _tid);
144 if (!_fe_problem.shouldPrintExecution(_tid))
147 std::vector<AuxKernelType *> all_kernels;
149 _all_kernels_query.clone().condition<
AttribThread>(_tid).queryInto(all_kernels);
150 if (all_kernels.empty())
153 const auto & console = _fe_problem.console();
154 const auto & execute_on = _fe_problem.getCurrentExecuteOnFlag();
155 console <<
"[DBG] Executing auxiliary kernels on elements on " << execute_on << std::endl;
162 if (!_fe_problem.shouldPrintExecution(_tid) || _blocks_exec_printed.count(_subdomain))
165 std::vector<AuxKernelType *> kernels;
166 _query_subdomain.queryInto(kernels, _tid, _subdomain);
170 const auto & console = _fe_problem.console();
171 console <<
"[DBG] Ordering of AuxKernels on block " << _subdomain << std::endl;
172 printExecutionOrdering<AuxKernelType>(kernels,
false);
173 _blocks_exec_printed.insert(_subdomain);