Skip to content

Commit

Permalink
More comments
Browse files Browse the repository at this point in the history
  • Loading branch information
FredericWantiez committed Feb 1, 2024
1 parent 4791835 commit bc9828e
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions examples/extended-kalman-filter/script.jl
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ function transition!!(::AbstractRNG, model::PendulumModel)
end

function transition!!(::AbstractRNG, model::PendulumModel, state::Gaussian)
# Jacobian - Linearization
Jf = jacobian(x -> f(x, model), state.μ)
Jh = jacobian(x -> h(x, model), state.μ)
pred = f(state.μ, model)
Expand All @@ -61,7 +60,7 @@ for t in 1:nstep
end

function ekf_correct(obs, state::Gaussian, model::PendulumModel)
Jf = jacobian(x -> f(x, model), state.μ)
Jf = jacobian(x -> f(x, model), state.μ)
Jh = jacobian(x -> h(x, model), state.μ)

S = model.R + Jh * state.Σ * Jh'
Expand Down

0 comments on commit bc9828e

Please sign in to comment.