Quinoa all test code coverage report
Current view: top level - Inciter - ElemDiagnostics.hpp (source / functions) Hit Total Coverage
Commit: -128-NOTFOUND Lines: 2 2 100.0 %
Date: 2024-11-22 08:51:48 Functions: 2 2 100.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 0 0 -

           Branch data     Line data    Source code
       1                 :            : // *****************************************************************************
       2                 :            : /*!
       3                 :            :   \file      src/Inciter/ElemDiagnostics.hpp
       4                 :            :   \copyright 2012-2015 J. Bakosi,
       5                 :            :              2016-2018 Los Alamos National Security, LLC.,
       6                 :            :              2019-2021 Triad National Security, LLC.
       7                 :            :              All rights reserved. See the LICENSE file for details.
       8                 :            :   \brief     ElemDiagnostics class for collecting diagnostics
       9                 :            :   \details   ElemDiagnostics class for collecting diagnostics, e.g., residuals,
      10                 :            :     and various norms of errors while solving partial differential equations.
      11                 :            : */
      12                 :            : // *****************************************************************************
      13                 :            : #ifndef ElemDiagnostics_h
      14                 :            : #define ElemDiagnostics_h
      15                 :            : 
      16                 :            : #include "Discretization.hpp"
      17                 :            : #include "PUPUtil.hpp"
      18                 :            : #include "Diagnostics.hpp"
      19                 :            : 
      20                 :            : namespace inciter {
      21                 :            : 
      22                 :            : //! ElemDiagnostics class used to compute diagnostics while integrating PDEs
      23                 :            : class ElemDiagnostics {
      24                 :            : 
      25                 :            :   public:
      26                 :            :     //! Configure Charm++ custom reduction types initiated from this class
      27                 :            :     static void registerReducers();
      28                 :            : 
      29                 :            :     //! Compute diagnostics, e.g., residuals, norms of errors, etc.
      30                 :            :     bool compute( Discretization& d,
      31                 :            :                   const std::size_t nchGhost,
      32                 :            :                   const tk::Fields& geoElem,
      33                 :            :                   const std::vector< std::size_t >& ndofel,
      34                 :            :                   const tk::Fields& u,
      35                 :            :                   const tk::Fields& un ) const;
      36                 :            : 
      37                 :            :     /** @name Charm++ pack/unpack serializer member functions */
      38                 :            :     ///@{
      39                 :            :     //! \brief Pack/Unpack serialize member function
      40                 :      16256 :     void pup( PUP::er& ) {}
      41                 :            :     //! \brief Pack/Unpack serialize operator|
      42                 :            :     //! \param[in,out] p Charm++'s PUP::er serializer object reference
      43                 :            :     //! \param[in,out] d Diagnostics object reference
      44                 :      16256 :     friend void operator|( PUP::er& p, ElemDiagnostics& d ) { d.pup(p); }
      45                 :            :     //@}
      46                 :            : 
      47                 :            :   private:
      48                 :            :     //! Compute diagnostics for DG
      49                 :            :     void compute_diag( const Discretization& d,
      50                 :            :                        const std::size_t ndofel,
      51                 :            :                        const std::size_t nchGhost,
      52                 :            :                        const tk::Fields& geoElem,
      53                 :            :                        const std::vector< std::size_t >& pIndex,
      54                 :            :                        const tk::Fields& u,
      55                 :            :                        const tk::Fields& un,
      56                 :            :                        std::vector< std::vector< tk::real > >& diag ) const;
      57                 :            : };
      58                 :            : 
      59                 :            : } // inciter::
      60                 :            : 
      61                 :            : #endif // ElemDiagnostics_h

Generated by: LCOV version 1.14