SpECTRE Documentation Coverage Report
Current view: top level - NumericalAlgorithms/Interpolation - PolynomialInterpolation.hpp Hit Total Coverage
Commit: 3c072f0ce967e2e56649d3fa12aa2a0e4fe2a42e Lines: 1 2 50.0 %
Date: 2024-04-23 20:50:18
Legend: Lines: hit not hit

          Line data    Source code
       1           0 : // Distributed under the MIT License.
       2             : // See LICENSE.txt for details.
       3             : 
       4             : #pragma once
       5             : 
       6             : #include <cstddef>
       7             : 
       8             : #include "Utilities/Gsl.hpp"
       9             : 
      10             : namespace intrp {
      11             : /*!
      12             :  * \brief Interpolate `y_values` to `target_x` from tabulated `x_values` using a
      13             :  * polynomial interpolant of degree `Degree`.
      14             :  *
      15             :  * `error_in_y` is an estimate of the error of the interpolated value. Note that
      16             :  * at least in the tests this is a significant overestimate of the errors
      17             :  * (several orders of magnitude). However, this could be because in the test the
      18             :  * polynomial can be represented exactly when all terms are present, but incurs
      19             :  * significant errors when the largest degree term is omitted.
      20             :  */
      21             : template <size_t Degree>
      22           1 : void polynomial_interpolation(gsl::not_null<double*> y,
      23             :                               gsl::not_null<double*> error_in_y,
      24             :                               double target_x,
      25             :                               const gsl::span<const double>& y_values,
      26             :                               const gsl::span<const double>& x_values);
      27             : }  // namespace intrp

Generated by: LCOV version 1.14