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 : #include "Limiter.h" 13 : #include "MathFVUtils.h" 14 : 15 : namespace Moose 16 : { 17 : namespace FV 18 : { 19 : 20 : /** 21 : * Implements a limiter which reproduces a central-differencing scheme, defined by 22 : * $\beta(r_f) = 1$ 23 : */ 24 : template <typename T> 25 : class CentralDifferenceLimiter : public Limiter<T> 26 : { 27 : public: 28 3113513 : T limit(const T &, 29 : const T &, 30 : const VectorValue<T> *, 31 : const VectorValue<T> *, 32 : const RealVectorValue &, 33 : const Real &, 34 : const Real &, 35 : const FaceInfo *, 36 : const bool &) const override final 37 : { 38 3113513 : return 1; 39 : } 40 0 : bool constant() const override final { return true; } 41 0 : InterpMethod interpMethod() const override final { return InterpMethod::Average; } 42 : 43 417585 : CentralDifferenceLimiter() = default; 44 : }; 45 : } 46 : }