Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

performance improvement #64

Merged
merged 3 commits into from
Sep 2, 2021
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions src/LinearSolvers/richardson.jl
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,8 @@ function solve_refine!(x::StrideOneVector{Float64},
b::AbstractVector{Float64})
@debug(IS.logger,"Iterative solver initiated")
norm_b = norm(b,Inf)
# x.=b
# IS.div!(x)
# IS.mul!(IS.res,x)
x.=0
IS.res=.-b
IS.res.=.-b
norm_res = norm(IS.res,Inf)
residual_ratio = norm_res/(1+norm_b)

Expand Down
2 changes: 1 addition & 1 deletion src/MadNLP.jl
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import MathOptInterface
import Libdl: dlopen, dlext, RTLD_DEEPBIND, RTLD_GLOBAL
import Printf: @sprintf
import LinearAlgebra: BLAS, Adjoint, Symmetric, mul!, ldiv!, norm, dot
import LinearAlgebra.BLAS: libblas, liblapack, BlasInt, @blasfunc
import LinearAlgebra.BLAS: axpy!, libblas, liblapack, BlasInt, @blasfunc
import SparseArrays: AbstractSparseMatrix, SparseMatrixCSC, sparse, getcolptr, rowvals, nnz
import Logging: @debug, @info, @warn, @error
import Base: string, show, print, size, getindex, copyto!, @kwdef
Expand Down
Loading