--- a/src/bisection_tree/btfn.rs Wed Nov 06 15:34:17 2024 -0500 +++ b/src/bisection_tree/btfn.rs Sat Nov 09 20:36:23 2024 -0500 @@ -424,12 +424,12 @@ for BTFN<F, G, BT, N> where BT : BTImpl<F, N>, G : SupportGenerator<F, N, Id=BT::Data>, - G::SupportType : LocalAnalysis<F, BT::Agg, N> + Differentiable<&'a Loc<F, N>, Output = V>, + G::SupportType : LocalAnalysis<F, BT::Agg, N> + Differentiable<&'a Loc<F, N>, Derivative = V>, V : Sum { - type Output = V; + type Derivative = V; - fn differential(&self, x : &'a Loc<F, N>) -> Self::Output { + fn differential(&self, x : &'a Loc<F, N>) -> Self::Derivative { self.bt.iter_at(x) .map(|&d| self.generator.support_for(d).differential(x)) .sum() @@ -440,12 +440,12 @@ for BTFN<F, G, BT, N> where BT : BTImpl<F, N>, G : SupportGenerator<F, N, Id=BT::Data>, - G::SupportType : LocalAnalysis<F, BT::Agg, N> + Differentiable<Loc<F, N>, Output = V>, + G::SupportType : LocalAnalysis<F, BT::Agg, N> + Differentiable<Loc<F, N>, Derivative = V>, V : Sum { - type Output = V; + type Derivative = V; - fn differential(&self, x : Loc<F, N>) -> Self::Output { + fn differential(&self, x : Loc<F, N>) -> Self::Derivative { self.bt.iter_at(&x) .map(|&d| self.generator.support_for(d).differential(x)) .sum()