81 validateDerivativeOutput(*
this, out);
83 throw std::invalid_argument(
"InextensionalDOFSet requires an ITS3 measurement context");
88 const double z = ctx.
measZ;
90 for (
int n = 2;
n <= mMaxOrder; ++
n) {
91 const double sn = std::sin(
n * phi);
92 const double cn = std::cos(
n * phi);
93 const double n2 =
static_cast<double>(
n *
n);
96 out(0, off + 0) = -(
z /
r) * (
n * sn + ctx.
dydx * n2 * cn);
97 out(1, off + 0) = -cn - ctx.
dzdx * (
z /
r) * n2 * cn;
99 out(0, off + 1) = (
z /
r) * (
n * cn - ctx.
dydx * n2 * sn);
100 out(1, off + 1) = -sn * (1. + ctx.
dzdx * (
z /
r) * n2);
102 out(0, off + 2) = -cn + ctx.
dydx *
n * sn;
103 out(1, off + 2) = ctx.
dzdx *
n * sn;
105 out(0, off + 3) = -sn - ctx.
dydx *
n * cn;
106 out(1, off + 3) = -ctx.
dzdx *
n * cn;
void fillDerivatives(const DerivativeContext &ctx, Eigen::Ref< Eigen::MatrixXd > out) const override