Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Mark Song
particles
Commits
f37094b2
Commit
f37094b2
authored
Oct 07, 2015
by
Frédéric Karamé
Browse files
Minor modifications in the inputs of the function.
parent
18059c01
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/gaussian_densities.m
View file @
f37094b2
...
...
@@ -43,9 +43,6 @@ prior = probability2(st_t_1,sqr_Pss_t_t_1,particles) ;
% likelihood
yt_t_1_i
=
measurement_equations
(
particles
,
ReducedForm
,
ThreadsOptions
)
;
eta_t_i
=
bsxfun
(
@
minus
,
obs
,
yt_t_1_i
)
'
;
%yt_t_1 = sum(yt_t_1_i*weigths1,2) ;
%tmp = bsxfun(@minus,yt_t_1_i,yt_t_1) ;
%Pyy = bsxfun(@times,weigths2',tmp)*tmp' + H ;
Pyy
=
H
;
sqr_det
=
sqrt
(
det
(
Pyy
))
;
foo
=
(
eta_t_i
/
Pyy
)
.*
eta_t_i
;
...
...
src/probability2.m
View file @
f37094b2
...
...
@@ -34,5 +34,4 @@ function [density] = probability2(mu,S,X)
dim
=
size
(
X
,
1
)
;
normfact
=
bsxfun
(
@
power
,(
2
*
pi
),(
dim
/
2
))
;
foo
=
S
\(
bsxfun
(
@
minus
,
X
,
mu
))
;
density
=
exp
(
-
0.5
*
sum
(
foo
.*
foo
)
'
)
.
/
abs
((
normfact
*
prod
(
diag
(
S
))))
+
1e-99
;
density
=
exp
(
-
0.5
*
sum
(
foo
.*
foo
)
'
)
.
/
abs
((
normfact
*
prod
(
diag
(
S
))))
+
1e-99
;
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment