Skip to content

Commit

Permalink
add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
gboehl committed Nov 12, 2024
1 parent fc28857 commit 27e767c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion econpizza/utilities/newton.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,9 @@ def inner_iteration_cond(carry):
def jvp_while_body(carry):
(x, y, _, _, cnt, fev, _), statics = carry
(jvp_func, jacobian, maxit, relaxation, nsteps, tol, factor, verbose) = statics
# first iteration
# apply newton
x -= relaxation*y
# first iteration
f, _ = jvp_func(x, jnp.zeros_like(x))
f = lu_solve(*jacobian[0], f, 0)[jacobian[1]]
# other iterations
Expand Down

0 comments on commit 27e767c

Please sign in to comment.