Line data Source code
1 : //* This file is part of the MOOSE framework 2 : //* https://mooseframework.inl.gov 3 : //* 4 : //* All rights reserved, see COPYRIGHT for full restrictions 5 : //* https://github.com/idaholab/moose/blob/master/COPYRIGHT 6 : //* 7 : //* Licensed under LGPL 2.1, please see LICENSE for details 8 : //* https://www.gnu.org/licenses/lgpl-2.1.html 9 : 10 : // MOOSE includes 11 : #include "InterfaceMaterial.h" 12 : 13 : InputParameters 14 86244 : InterfaceMaterial::validParams() 15 : { 16 : 17 86244 : InputParameters params = MaterialBase::validParams(); 18 86244 : params += TwoMaterialPropertyInterface::validParams(); 19 86244 : params.set<bool>("_interface") = true; 20 86244 : params.set<Moose::MaterialDataType>("_material_data_type") = Moose::INTERFACE_MATERIAL_DATA; 21 : 22 : // Interface materials always need one layer of ghosting to be safe 23 86244 : params.addRelationshipManager("ElementSideNeighborLayers", 24 : Moose::RelationshipManagerType::GEOMETRIC | 25 : Moose::RelationshipManagerType::ALGEBRAIC); 26 86244 : return params; 27 0 : } 28 : 29 348 : InterfaceMaterial::InterfaceMaterial(const InputParameters & parameters) 30 : : MaterialBase(parameters), 31 : NeighborCoupleable(this, false, false), 32 : TwoMaterialPropertyInterface(this, blockIDs(), boundaryIDs()), 33 696 : _q_point(_assembly.qPointsFace()), 34 348 : _qrule(_assembly.qRuleFace()), 35 348 : _JxW(_assembly.JxWFace()), 36 348 : _current_elem(_assembly.elem()), 37 348 : _neighbor_elem(_assembly.neighbor()), 38 348 : _current_side(_assembly.side()), 39 696 : _neighbor_side(_assembly.neighborSide()) 40 : { 41 : // Fill in the MooseVariable dependencies 42 348 : const std::vector<MooseVariableFEBase *> & coupled_vars = getCoupledMooseVars(); 43 1500 : for (const auto & var : coupled_vars) 44 1152 : addMooseVariableDependency(var); 45 348 : } 46 : 47 : void 48 4185 : InterfaceMaterial::computeProperties() 49 : { 50 12837 : for (_qp = 0; _qp < _qrule->n_points(); ++_qp) 51 8652 : computeQpProperties(); 52 4185 : }