21 #ifndef mia_core_splinekernel_hh
22 #define mia_core_splinekernel_hh
129 void operator () (
double x,
VWeight& weight,
VIndex& index)
const;
139 void operator () (
double x,
SCache& cache)
const;
151 void get_cached(
double x,
SCache& cache)
const;
162 void get_uncached(
double x,
SCache& cache)
const;
171 void derivative(
double x,
VWeight& weight,
VIndex& index)
const;
181 void derivative(
double x,
VWeight& weight,
VIndex& index,
int order)
const;
189 int get_indices(
double x,
VIndex& index)
const;
196 virtual void get_weights(
double x,
VWeight& weight)
const = 0;
203 virtual void get_derivative_weights(
double x,
VWeight& weight)
const = 0;
211 virtual void get_derivative_weights(
double x,
VWeight& weight,
int order)
const = 0;
220 virtual double get_weight_at(
double x,
int order)
const;
228 const std::vector<double>& get_poles()
const;
237 double get_nonzero_radius()
const;
240 int get_active_halfrange()
const;
248 int get_start_idx_and_value_weights(
double x,
VWeight& weights)
const;
256 int get_start_idx_and_derivative_weights(
double x,
VWeight& weights)
const;
262 void add_pole(
double x);
265 int get_start_idx(
double x)
const;
270 void fill_index(
short i,
VIndex& index)
const;
273 size_t m_half_degree;
277 std::vector<double> m_poles;
279 size_t m_support_size;
282 std::vector<short> m_indices;
332 static bool apply() {
337 template <
typename T>
338 struct max_hold_type {
348 typedef T value_type;
349 typedef double coeff_type;
356 struct coeff_map<float> {
357 typedef float value_type;
358 typedef float coeff_type;
365 return m_support_size;