Skip to content

Commit

Permalink
Merge pull request #124 from MSeeker1340/jacobian
Browse files Browse the repository at this point in the history
Hotfix for #123
  • Loading branch information
ChrisRackauckas committed Jul 18, 2018
2 parents aa16264 + 93bc0e5 commit a29e55c
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/diffeqfunction.jl
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,11 @@ function ODEFunction{iip,true}(f;
paramjac = nothing,
syms = nothing) where iip
if jac == nothing && isa(jac_prototype, AbstractDiffEqLinearOperator)
jac = update_coefficients!
if iip
jac = update_coefficients! #(J,u,p,t)
else
jac = (u,p,t) -> update_coefficients!(deepcopy(jac_prototype),u,p,t)
end
end
ODEFunction{iip,typeof(f),typeof(analytic),typeof(tgrad),
typeof(jac),typeof(jac_prototype),typeof(invW),typeof(invW_t),
Expand All @@ -166,7 +170,11 @@ function ODEFunction{iip,false}(f;
paramjac = nothing,
syms = nothing) where iip
if jac == nothing && isa(jac_prototype, AbstractDiffEqLinearOperator)
jac = update_coefficients!
if iip
jac = update_coefficients! #(J,u,p,t)
else
jac = (u,p,t) -> update_coefficients!(deepcopy(jac_prototype),u,p,t)
end
end
ODEFunction{iip,Any,Any,Any,
Any,Any,Any,Any,
Expand Down

0 comments on commit a29e55c

Please sign in to comment.