Rip out make_coherent, add CoherentPadOp.

This commit is contained in:
Antonio Sánchez
2024-02-29 23:15:02 +00:00
committed by Rasmus Munk Larsen
parent edaf9e16bc
commit 23f6c26857
4 changed files with 217 additions and 122 deletions

View File

@@ -175,15 +175,11 @@ void forward_jacobian(const Func& f) {
jref.setZero();
yref.setZero();
f(x, &yref, &jref);
// std::cerr << y.transpose() << "\n\n";;
// std::cerr << j << "\n\n";;
j.setZero();
y.setZero();
AutoDiffJacobian<Func> autoj(f);
autoj(x, &y, &j);
// std::cerr << y.transpose() << "\n\n";;
// std::cerr << j << "\n\n";;
VERIFY_IS_APPROX(y, yref);
VERIFY_IS_APPROX(j, jref);
@@ -277,8 +273,6 @@ double bug_1222() {
return denom.value();
}
#ifdef EIGEN_TEST_PART_5
double bug_1223() {
using std::min;
typedef Eigen::AutoDiffScalar<Eigen::Vector3d> AD;
@@ -338,8 +332,6 @@ double bug_1281() {
return (y1 + y2 + y3).value();
}
#endif
EIGEN_DECLARE_TEST(autodiff) {
for (int i = 0; i < g_repeat; i++) {
CALL_SUBTEST_1(test_autodiff_scalar<1>());