Skip to content

Commit

Permalink
Fix some conflicts from merging
Browse files Browse the repository at this point in the history
  • Loading branch information
ErikQQY committed Dec 24, 2024
1 parent 0297d87 commit 162d14b
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 12 deletions.
15 changes: 5 additions & 10 deletions lib/BoundaryValueDiffEqCore/src/utils.jl
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,9 @@ end
return resid
end

function eval_bc_residual(::StandardSecondOrderBVProblem, bc::BC, y, p, mesh) where {BC}
function eval_bc_residual(::StandardSecondOrderBVProblem, bc::BC, y, dy, p, mesh) where {BC}
L = length(mesh)
res_bc = bc(y[(L + 1):end], y[1:L], p, mesh)
res_bc = bc(dy, y, p, mesh)
return res_bc
end
function eval_bc_residual(
Expand All @@ -123,17 +123,12 @@ end
function eval_bc_residual!(resid, ::StandardBVProblem, bc!::BC, sol, p, t) where {BC}
bc!(resid, sol, p, t)
end
function eval_bc_residual!(
resid, ::StandardSecondOrderBVProblem, bc!::BC, dsol, sol, p, t) where {BC}
bc!(resid, dsol, sol, p, t)
end

function eval_bc_residual!(
resid, ::StandardSecondOrderBVProblem, bc!::BC, y, p, mesh) where {BC}
M = length(y[1])
L = length(mesh)
resid, ::StandardSecondOrderBVProblem, bc!::BC, soly, dsol, p, mesh) where {BC}
M = length(sol[1])
res_bc = vcat(resid[1], resid[2])
bc!(res_bc, y[(L + 1):end], y[1:L], p, mesh)
bc!(res_bc, dsol, sol, p, mesh)
copyto!(resid[1], res_bc[1:M])
copyto!(resid[2], res_bc[(M + 1):end])
end
Expand Down
2 changes: 1 addition & 1 deletion lib/BoundaryValueDiffEqFIRK/src/BoundaryValueDiffEqFIRK.jl
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ using BoundaryValueDiffEqCore: BoundaryValueDiffEqAlgorithm, BVPJacobianAlgorith
MaybeDiffCache, __extract_mesh, __extract_u0,
__has_initial_guess, __initial_guess_length,
__initial_guess_on_mesh, __flatten_initial_guess,
__build_solution, __Fix3, get_dense_ad
__build_solution, __Fix3, get_dense_ad, _sparse_like

using ConcreteStructs: @concrete
using DiffEqBase: DiffEqBase
Expand Down
2 changes: 1 addition & 1 deletion lib/BoundaryValueDiffEqMIRK/src/BoundaryValueDiffEqMIRK.jl
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ using BoundaryValueDiffEqCore: BoundaryValueDiffEqAlgorithm, BVPJacobianAlgorith
__extract_mesh, __extract_u0, __has_initial_guess,
__initial_guess_length, __initial_guess_on_mesh,
__flatten_initial_guess, __build_solution, __Fix3,
_sparse_like, get_dense_ad
_sparse_like, get_dense_ad, _sparse_like

using ConcreteStructs: @concrete
using DiffEqBase: DiffEqBase
Expand Down

0 comments on commit 162d14b

Please sign in to comment.