Skip to content

Commit 41f1165

Browse files
committed
Add scalar rule for loggamma(a, x)
1 parent 52dd7d4 commit 41f1165

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/chainrules.jl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,3 +114,10 @@ ChainRulesCore.@scalar_rule(
114114
ChainRulesCore.@scalar_rule(logabsgamma(x), digamma(x), ChainRulesCore.Zero())
115115

116116
ChainRulesCore.@scalar_rule(loggamma(x), digamma(x))
117+
ChainRulesCore.@scalar_rule(
118+
loggamma(a, x),
119+
(
120+
ChainRulesCore.@thunk(error("not implemented")),
121+
-exp(- (x + Ω)) * x^(a - 1),
122+
)
123+
)

0 commit comments

Comments
 (0)