devitocodes / devito

DSL and compiler framework for automated finite-differences and stencil computation
http://www.devitoproject.org
MIT License
536 stars 221 forks source link

dsl: Patch edge-case derivative specifications #2366

Closed EdCaunt closed 2 months ago

EdCaunt commented 2 months ago

Derivatives specified as Derivative(f, (x, 2), (y, 0)) (zeroth-order wrt one dimension) are a valid request, but the resultant derivatives were not equal to those specified as Derivative(f, (x, 2)) and certain routines such as substitution would fail. This PR patches this and adds a test.

codecov[bot] commented 2 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 86.74%. Comparing base (70fe897) to head (ca2d748). Report is 14 commits behind head on master.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #2366 +/- ## ========================================== + Coverage 78.34% 86.74% +8.39% ========================================== Files 232 233 +1 Lines 43618 43662 +44 Branches 8073 8078 +5 ========================================== + Hits 34174 37873 +3699 + Misses 8684 5079 -3605 + Partials 760 710 -50 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.