Skip to content

Fix for dual numbers#41

Merged
Expander merged 5 commits intomainfrom
fix-dual
Mar 23, 2026
Merged

Fix for dual numbers#41
Expander merged 5 commits intomainfrom
fix-dual

Conversation

@Expander
Copy link
Owner

See issue #40

@Expander Expander self-assigned this Mar 22, 2026
@Expander Expander merged commit 4239684 into main Mar 23, 2026
16 checks passed
@Expander Expander deleted the fix-dual branch March 23, 2026 06:55
@NAThompson
Copy link

@Expander : This looks great thanks!

One more thing just to perhaps head off future problems: I found this because I was trying to autodiff some code, so eventually I want to get derivatives.

I wonder if we could add a unit test for the derivatives computed via ForwardDiff? To wit, maybe use $z \frac{\partial Li_s}{\partial_z} = Li_{s-1}(z)$?

@Expander
Copy link
Owner Author

Good point, but there are such unit test already. :)

To be precise, there are tests for the real functions li0, reli1, reli2, reli3, reli4 and the general reli. To find the tests, just grep ForwardDiff test/*.jl. They have been implemented by @longemen3000 when he added the support for ForwardDiff and ChainRules.

Back then, @longemen3000 said that ForwardDiff does support derivatives of (holomorphic) complex functions. When this is added, the complex polylogarithms will get derivative support as well (including tests).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants