LCOV - code coverage report
Current view: top level - include/transfers - MultiAppGeometricInterpolationTransfer.h (source / functions) Hit Total Coverage
Test: idaholab/moose framework: 2bf808 Lines: 1 1 100.0 %
Date: 2025-07-17 01:28:37 Functions: 1 1 100.0 %
Legend: Lines: hit not hit

          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             : #pragma once
      11             : 
      12             : // MOOSE includes
      13             : #include "MultiAppConservativeTransfer.h"
      14             : #include "MooseVariableFieldBase.h"
      15             : 
      16             : #include "libmesh/mesh_base.h"
      17             : 
      18             : class MultiAppCoordTransform;
      19             : namespace libMesh
      20             : {
      21             : template <unsigned int>
      22             : class InverseDistanceInterpolation;
      23             : }
      24             : 
      25             : /**
      26             :  * Interpolate variable values using geometry/mesh-based coefficients.
      27             :  */
      28             : class MultiAppGeometricInterpolationTransfer : public MultiAppConservativeTransfer
      29             : {
      30             : public:
      31             :   static InputParameters validParams();
      32             : 
      33             :   MultiAppGeometricInterpolationTransfer(const InputParameters & parameters);
      34             : 
      35             :   virtual void execute() override;
      36             : 
      37             : protected:
      38             :   void fillSourceInterpolationPoints(
      39             :       FEProblemBase & from_problem,
      40             :       const MooseVariableFieldBase & from_var,
      41             :       const MultiAppCoordTransform & from_app_transform,
      42             :       std::unique_ptr<libMesh::InverseDistanceInterpolation<Moose::dim>> & idi);
      43             : 
      44             :   void interpolateTargetPoints(
      45             :       FEProblemBase & to_problem,
      46             :       MooseVariableFieldBase & to_var,
      47             :       NumericVector<Real> & to_solution,
      48             :       const MultiAppCoordTransform & to_app_transform,
      49             :       const std::unique_ptr<libMesh::InverseDistanceInterpolation<Moose::dim>> & idi);
      50             : 
      51             :   void
      52             :   subdomainIDsNode(MooseMesh & mesh, const Node & node, std::set<subdomain_id_type> & subdomainids);
      53             : 
      54             :   void computeTransformation(const MooseMesh & mesh,
      55             :                              std::unordered_map<dof_id_type, Point> & transformation);
      56             : 
      57             :   unsigned int _num_points;
      58             :   Real _power;
      59             :   MooseEnum _interp_type;
      60             :   Real _radius;
      61             :   // How much we want to shrink gap
      62             :   Real _shrink_gap_width;
      63             :   // Which mesh we want to shrink
      64             :   MooseEnum _shrink_mesh;
      65             :   // Which gap blocks want to exclude during solution transfers
      66             :   std::vector<SubdomainName> _exclude_gap_blocks;
      67             :   // How small we can consider two points are identical
      68             :   Real _distance_tol;
      69             : 
      70             : private:
      71          80 :   bool usesMooseAppCoordTransform() const override { return true; }
      72             : };

Generated by: LCOV version 1.14