diff --git a/src/JSOSolvers.jl b/src/JSOSolvers.jl index 914ee092..2265fa1e 100644 --- a/src/JSOSolvers.jl +++ b/src/JSOSolvers.jl @@ -26,7 +26,6 @@ Notably, you can access, and modify, the following: - `stats.elapsed_time`: elapsed time in seconds. " - """ normM!(n, x, M, z) @@ -37,7 +36,7 @@ function normM!(n, x, M, z) return nrm2(n, x) else mul!(z, M, x) - return √(x⋅z) + return √(x ⋅ z) end end diff --git a/test/runtests.jl b/test/runtests.jl index 52d49958..0455b63d 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -83,10 +83,10 @@ end x0 = [-1.2; 1.0] nlp = ADNLPModel(x -> 100 * (x[2] - x[1]^2)^2 + (x[1] - 1)^2, x0) function DiagPrecon(x) - H = Matrix(hess(nlp, x)) - λmin = minimum(eigvals(H)) - Diagonal(H + λmin * I) - end + H = Matrix(hess(nlp, x)) + λmin = minimum(eigvals(H)) + Diagonal(H + λmin * I) + end M = DiagPrecon(x0) function LinearAlgebra.ldiv!(y, M::Diagonal, x) y .= M \ x @@ -94,6 +94,6 @@ end function callback(nlp, solver, stats) M[:] = DiagPrecon(solver.x) end - stats = trunk(nlp, callback=callback, M=M) + stats = trunk(nlp, callback = callback, M = M) @test stats.status == :first_order -end \ No newline at end of file +end