Skip to content

Commit b3f3ba1

Browse files
committed
Use @not_implemented
1 parent d485d8c commit b3f3ba1

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

src/chainrules.jl

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@ derivatives of Bessel functions with respect to the order are not implemented cu
33
https://github.com/JuliaMath/SpecialFunctions.jl/issues/160
44
"""
55

6+
const INCOMPLETE_GAMMA_INFO = """
7+
derivatives of the incomplete Gamma functions with respect to parameter `a` are not
8+
implemented currently:
9+
https://github.com/JuliaMath/SpecialFunctions.jl/issues/317
10+
"""
11+
612
ChainRulesCore.@scalar_rule(airyai(x), airyaiprime(x))
713
ChainRulesCore.@scalar_rule(airyaiprime(x), x * airyai(x))
814
ChainRulesCore.@scalar_rule(airybi(x), airybiprime(x))
@@ -29,20 +35,20 @@ ChainRulesCore.@scalar_rule(gamma(x), Ω * digamma(x))
2935
ChainRulesCore.@scalar_rule(
3036
gamma(a, x),
3137
(
32-
ChainRulesCore.@thunk(error("not implemented")),
38+
ChainRulesCore.@not_implemented(INCOMPLETE_GAMMA_INFO),
3339
- exp(-x) * x^(a - 1),
3440
),
3541
)
3642
ChainRulesCore.@scalar_rule(
3743
gamma_inc(a, x, IND),
3844
@setup(z = exp(-x) * x^(a - 1) / gamma(a)),
3945
(
40-
ChainRulesCore.@thunk(error("not implemented")),
46+
ChainRulesCore.@not_implemented(INCOMPLETE_GAMMA_INFO),
4147
z,
4248
ChainRulesCore.DoesNotExist(),
4349
),
4450
(
45-
ChainRulesCore.@thunk(error("not implemented")),
51+
ChainRulesCore.@not_implemented(INCOMPLETE_GAMMA_INFO),
4652
-z,
4753
ChainRulesCore.DoesNotExist(),
4854
),
@@ -122,7 +128,7 @@ ChainRulesCore.@scalar_rule(loggamma(x), digamma(x))
122128
ChainRulesCore.@scalar_rule(
123129
loggamma(a, x),
124130
(
125-
ChainRulesCore.@thunk(error("not implemented")),
131+
ChainRulesCore.@not_implemented(INCOMPLETE_GAMMA_INFO),
126132
-exp(- (x + Ω)) * x^(a - 1),
127133
)
128134
)

0 commit comments

Comments
 (0)