KJB
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Namespaces | Functions
diff_gradient_mt.h File Reference
#include <m_cpp/m_vector.h>
#include <diff_cpp/diff_util.h>
#include <boost/thread.hpp>
#include <boost/ref.hpp>
#include <vector>
#include <algorithm>
#include <sys/time.h>

Go to the source code of this file.

Namespaces

 kjb
 Classes and functions for dealing with trajectory files.
 

Functions

template<class Func , class Model , class Adapter >
void kjb::gradient_cfd_mt_worker (const Func &f, const Model &x, const std::vector< double > &dx, const Adapter &adapter, size_t i_start, size_t i_end, Vector &v)
 Helper function for gradient_cfd_mt. More...
 
template<class Func , class Model , class Adapter >
void kjb::gradient_ffd_mt_worker (const Func &f, const Model &x, const std::vector< double > &dx, const Adapter &adapter, double fx, size_t i_start, size_t i_end, Vector &v)
 Helper function for gradient_ffd_mt. More...
 
template<class Func , class Model , class Adapter >
Vector kjb::gradient_cfd_mt (const Func &f, const Model &x, const std::vector< double > &dx, const Adapter &adapter, size_t nt)
 Computes the gradient of a function, evaluated at a point, using central finite differences. Multi-threaded version. More...
 
template<class Func , class Vec >
Vector kjb::gradient_cfd_mt (const Func &f, const Vec &x, const std::vector< double > &dx, size_t nt=0)
 Computes the gradient of a function, evaluated at a point, using central finite differences, for a vectory-style model. Multi-threaded version. More...
 
template<class Func , class Model , class Adapter >
Vector kjb::gradient_ffd_mt (const Func &f, const Model &x, const std::vector< double > &dx, const Adapter &adapter, size_t nt)
 Computes the gradient of a function, evaluated at a point, using forward finite differences. Multi-threaded version. More...
 
template<class Func , class Vec >
Vector kjb::gradient_ffd_mt (const Func &f, const Vec &x, const std::vector< double > &dx, size_t nt=0)
 Computes the gradient of a function, evaluated at a point, using forward finite differences, for a vectory-style model. Multi-threaded version. More...
 
template<class Func , class Model , class Adapter >
void kjb::gradient_ind_cfd_mt_worker (const Func &f, const Model &x, const std::vector< double > &dx, const Adapter &adapter, size_t i_start, size_t i_end, Vector &v)
 Helper function for gradient_ind_cfd_mt. More...
 
template<class Func , class Model , class Adapter >
Vector kjb::gradient_ind_cfd_mt (const Func &f, const Model &x, const std::vector< double > &dx, const Adapter &adapter, size_t nt)
 Computes the gradient of a function, evaluated at a point, using central finite differences. Multithreaded version. More...
 
template<class Func , class Vec >
Vector kjb::gradient_ind_cfd_mt (const Func &f, const Vec &x, const std::vector< double > &dx, size_t nt=0)
 Computes the gradient of a function, evaluated at a point, using central finite differences for a vector-style model. Multi-threaded version. More...