12#include "libmesh/point.h"
24 _physical_bounds(2, 0.0),
25 _standardized_location({0.0}),
26 _are_physical_bounds_specified(
false),
27 _location(_domains.size(), 0.0)
32 const std::vector<std::size_t> & orders,
33 const unsigned int number_of_terms)
37 _physical_bounds(2, 0.0),
38 _standardized_location(1, 0.0),
39 _are_physical_bounds_specified(false),
40 _location(_domains.size(), 0.0)
65 if (orders.size() !=
_orders.size())
66 mooseError(
"SSBI: Invalid 'orders' use in setOrder()!");
104 std::vector<Real> oldLocation(
_location);
124 std::vector<Real> location(
_domains.size());
127 for (std::size_t index = 0; index <
_domains.size(); ++index)
128 location[index] = point(
_domains[index]);
void mooseError(Args &&... args)
This class provides the basis for any custom functional basis, and is the parent class of both Single...
unsigned int _number_of_terms
The number of terms in the series.
static MooseEnum _domain_options
An enumeration of the domains available to each functional series.
bool _is_cache_invalid
indicates if the evaluated values correspond to the current location
virtual void setPhysicalBounds(const std::vector< Real > &bounds) final
Sets the bounds of the series.
virtual void checkPhysicalBounds(const std::vector< Real > &bounds) const =0
Checks the physical bounds according to the actual implementation.
virtual void setLocation(const Point &point) final
Set the location that will be used by the series to compute values.
virtual std::vector< Real > getStandardizedLocation(const std::vector< Real > &location) const =0
Standardize the location according to the requirements of the underlying basis, which may actually co...
std::vector< Real > _physical_bounds
The physical bounds of the series.
SingleSeriesBasisInterface()
std::size_t getOrder(std::size_t domain) const
Returns the order of the particular domain index.
virtual void evaluateGeneration() override
Evaluate the generation form of the functional basis.
virtual ~SingleSeriesBasisInterface()
const std::vector< MooseEnum > _domains
An ordered list of the x, y, and/or z domains needed by the functional basis to convert a point to a ...
std::vector< Real > extractLocationFromPoint(const Point &point) const
Convert a spatial point to a location that the series will use to determine the value at which to eva...
std::vector< std::size_t > _orders
The order of the series.
std::function< void()> _evaluateGenerationWrapper
The generation evaluation wrapper.
std::vector< Real > _standardized_location
The standardized location of evaluation.
virtual void setOrder(const std::vector< std::size_t > &orders) final
Set the order of the series.
virtual bool isCacheInvalid() const final
Whether the cached values correspond to the current point.
virtual std::size_t calculatedNumberOfTermsBasedOnOrder(const std::vector< std::size_t > &order) const =0
Returns the number of terms in the single series given a value for the order.
virtual void clearBasisEvaluation(const unsigned int &number_of_terms)
Set all entries of the basis evaluation to zero.
std::function< void()> _evaluateExpansionWrapper
The expansion evaluation wrapper.
bool _are_physical_bounds_specified
Flag for if the physical bounds are specified for this series.
std::vector< Real > _location
The domain locations of the current evaluation.
virtual void evaluateExpansion() override
Evaluate the expansion form of the functional basis.