Skip to content

Commit

Permalink
do not repeat code
Browse files Browse the repository at this point in the history
  • Loading branch information
HDembinski committed Sep 15, 2022
1 parent 0314e69 commit ac03200
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/jacobi/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -319,13 +319,6 @@ def fn(x):
so the Jacobian computed from fn(x) has zero off-diagonal entries. In this case,
one can speed up the calculation significantly with a special keyword::
def fn(x):
return x ** 2 + 1
x = [1, 2]
xcov = [[3, 1],
[1, 4]]
# same result as before, but faster and uses much less memory
y, ycov = propagate(fn, x, xcov, diagonal=True)
Expand Down

0 comments on commit ac03200

Please sign in to comment.