Skip to content

Commit

Permalink
address comments and add compat for FastBroadcast
Browse files Browse the repository at this point in the history
  • Loading branch information
yonatanwesen committed Oct 31, 2023
1 parent 7390f71 commit abaf747
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
1 change: 1 addition & 0 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ ConcreteStructs = "0.2"
DiffEqBase = "6.130"
EnumX = "1"
Enzyme = "0.11"
FastBroadcast = "0.1.9, 0.2"
FastLevenbergMarquardt = "0.1"
FiniteDiff = "2"
ForwardDiff = "0.10.3"
Expand Down
2 changes: 1 addition & 1 deletion src/NonlinearSolve.jl
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import PrecompileTools

PrecompileTools.@recompile_invalidations begin
using DiffEqBase, LinearAlgebra, LinearSolve, SparseArrays, SparseDiffTools
using FastBroadcast: @.., True, False
using FastBroadcast: @..
import ArrayInterface: restructure

import ADTypes: AbstractFiniteDifferencesMode
Expand Down
4 changes: 1 addition & 3 deletions src/pseudotransient.jl
Original file line number Diff line number Diff line change
Expand Up @@ -167,9 +167,7 @@ function perform_step!(cache::PseudoTransientCache{false})
if linsolve === nothing
cache.du = fu1 / cache.J
else
linres = dolinsolve(alg.precs, linsolve; A = cache.J,
b = _vec(fu1),
linu = _vec(cache.du), p, reltol = cache.abstol)
linres = dolinsolve(alg.precs, linsolve; A = cache.J,b = _vec(fu1),linu = _vec(cache.du), p, reltol = cache.abstol)
cache.linsolve = linres.cache
end
cache.u = @. u - cache.du # `u` might not support mutation
Expand Down

0 comments on commit abaf747

Please sign in to comment.