From: Ulf L. <ul...@wa...> - 2014-12-11 22:15:38
|
Hi, just had a chat with Yan Wang on a rewrite of the interpolation code (task #48). Summary: * some chit-chat, big picture of the rewrite etc. - make an interpolation class as a functor - add functions to load data from file and set up interpolation - rewrite builder/uncorrelated/InterpolatedState and add a few new operators that take arbitrary functors (which may be interpolated data) * first task: basic interpolation class - constructor: - takes two const RTensor&: x0, y(x0) - throw std::invalid_argument if sizes < 3 - throw std::invalid_argument if sizes do not match - ignore dimensions of input tensors - sort automatically if input is unsorted - double operator()(double x) - return the interpolated value Ulf |