Browse Source

Runic

pull/35/head
termi-official 9 months ago
parent
commit
e8beb3acdb
  1. 2
      src/precs.jl
  2. 7
      test/runtests.jl

2
src/precs.jl

@ -5,7 +5,7 @@ end @@ -5,7 +5,7 @@ end
function LinearAlgebra.ldiv!(y::AbstractVector, prec::BoomerAMGPrecWrapper, x::AbstractVector)
fill!(y, eltype(y)(0.0))
HYPRE.solve!(prec.P, y, prec.A, x)
return HYPRE.solve!(prec.P, y, prec.A, x)
end
"""

7
test/runtests.jl

@ -27,7 +27,7 @@ end @@ -27,7 +27,7 @@ end
b = rand(100)
x = zeros(100)
# Solve
tol = 1e-9
tol = 1.0e-9
# function set_debug_printlevel(amg, A, p)
# HYPRE.HYPRE_BoomerAMGSetPrintLevel(amg, 3)
# end
@ -38,8 +38,8 @@ end @@ -38,8 +38,8 @@ end
)
prob = LinearProblem(A, b)
solver = KrylovJL_CG(precs = bamg)
x = solve(prob, solver, atol=1.0e-14)
@test x A \ b atol=tol
x = solve(prob, solver, atol = 1.0e-14)
@test x A \ b atol = tol
end
@ -784,4 +784,3 @@ end @@ -784,4 +784,3 @@ end
@test r.exitcode == 0
end
end

Loading…
Cancel
Save