We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ee8598f commit 438c186Copy full SHA for 438c186
math/mathcore/inc/Math/CladDerivator.h
@@ -151,8 +151,8 @@ ValueAndPushforward<T, T> Log2_pushforward(T x, T d_x)
151
return {::TMath::Log2(x), (1.0 / (x * ::TMath::Log(2.0))) * d_x};
152
}
153
154
-template <typename T>
155
-ValueAndPushforward<T, T> Power_pushforward(T x, T y, T d_x, T d_y)
+template <typename T, typename U>
+ValueAndPushforward<T, T> Power_pushforward(T x, U y, T d_x, U d_y)
156
{
157
T pushforward = y * ::TMath::Power(x, y - 1) * d_x;
158
if (d_y) {
@@ -161,8 +161,8 @@ ValueAndPushforward<T, T> Power_pushforward(T x, T y, T d_x, T d_y)
161
return {::TMath::Power(x, y), pushforward};
162
163
164
-template <typename T, typename U>
165
-void Power_pullback(T x, T y, U p, clad::array_ref<T> d_x, clad::array_ref<T> d_y)
+template <typename T, typename U, typename V>
+void Power_pullback(T x, U y, V p, clad::array_ref<T> d_x, clad::array_ref<U> d_y)
166
167
auto t = pow_pushforward(x, y, 1, 0);
168
*d_x += t.pushforward * p;
0 commit comments