Skip to content

Commit

Permalink
Fix typo Linear part
Browse files Browse the repository at this point in the history
  • Loading branch information
briochemc committed Jul 11, 2019
1 parent 78899cd commit b868a4d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/multiTracer.jl
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function split_state_function_and_Jacobian(Ts::Tuple, Ls::Tuple, NLs::Tuple, nb)
return F, L, NL, ∇ₓF, ∇ₓL, ∇ₓNL, T
end
function split_state_function_and_Jacobian(T, L, NL, nb)
F(x,p) = NL(x,p) + L(p) * x - T(p) * x # full 𝐹(𝑥)
F(x,p) = NL(x,p) + L(x,p) - T(p) * x # full 𝐹(𝑥)
∇ₓNL(x,p) = sparse(Diagonal(𝔇(NL(x .+ ε,p)))) # Jacobian of nonlinear part
∇ₓL(p) = sparse(Diagonal(𝔇(L(zeros(nb) .+ ε,p)))) # Jacobian of nonlinear part
∇ₓF(x,p) = ∇ₓNL(x,p) + ∇ₓL(p) - T(p) # full Jacobian ∇ₓ𝐹(𝑥) = -T + ∇ₓ𝐺(𝑥)
Expand Down
4 changes: 2 additions & 2 deletions src/time_steppers.jl
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,8 @@ end
Returns the Crank-Nicolson-leapfrog-step increment (out of place) using stored factors.
See [`crank_nicolson_leapfrog_step_A⁺_and_A⁻`](@ref) for more information.
"""
function crank_nicolson_leapfrog_step(xᵢ, xᵢ₋₁, p, A⁺::Factorization, A⁻, G)
return A⁺ \ (G(xᵢ,p) + A⁻ * xᵢ₋₁)
function crank_nicolson_leapfrog_step(xᵢ, xᵢ₋₁, p, A⁺::Factorization, A⁻, NL)
return A⁺ \ (NL(xᵢ,p) + A⁻ * xᵢ₋₁)
end
"""
crank_nicolson_leapfrog_step_A⁺_and_A⁻(p, δt, T, ∇ₓL)
Expand Down

0 comments on commit b868a4d

Please sign in to comment.