Derivatives in C C++? - Stack Overflow To calculate higher order derivatives should be done using truncated taylor series You could also apply above mentioned class to itself -- the type for the value and derivative values should be a template argument But this means calculation and storing of derivatives more than once
Interpolate eigen splines with derivatives - Stack Overflow Eigen::MatrixXd derivatives(2, 1); derivatives setZero(); Derivatives zero for this example Since these are parametric splines, you have to provide derivatives for both x and y, for each of the two points you have chosen, so the correct size is: