Skip to content

Commit 2da9858

Browse files
committed
Update the function for the lagrangian
1 parent b6a1e3e commit 2da9858

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/enzyme.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ function SparseEnzymeADHessian(
217217
grad = similar(x0)
218218
function ℓ(x, y, obj_weight, cx)
219219
res = obj_weight * f(x)
220-
if ncon == 0
220+
if ncon != 0
221221
c!(cx, x)
222222
res += sum(cx[i] * y[i] for i = 1:ncon)
223223
end

0 commit comments

Comments
 (0)