improve examples.
This commit is contained in:
parent
172f59cee5
commit
7d4f83ca40
@ -10,6 +10,7 @@ t(dave).
|
||||
bayes p(X)::[t,f] ; [0.1, 0.3] ; [t(X)].
|
||||
|
||||
|
||||
?- p(ann,X), p(ann,f).
|
||||
% use standard Prolog queries: provide evidence first.
|
||||
?- p(ann,f), p(ann,X).
|
||||
|
||||
|
||||
|
@ -9,10 +9,8 @@ t(dave).
|
||||
|
||||
bayes p(X)::[t,f] ; [0.1, 0.3] ; [t(X)].
|
||||
|
||||
|
||||
p(ann,t).
|
||||
|
||||
|
||||
?- p(dave,X).
|
||||
|
||||
|
||||
|
23
packages/CLPBN/clpbn/bp/examples/markov.yap
Normal file
23
packages/CLPBN/clpbn/bp/examples/markov.yap
Normal file
@ -0,0 +1,23 @@
|
||||
|
||||
:- use_module(library(pfl)).
|
||||
|
||||
:- set_clpbn_flag(solver,fove).
|
||||
|
||||
t(ann).
|
||||
t(dave).
|
||||
t(lucy).
|
||||
t(john).
|
||||
t(kristian).
|
||||
t(sriraam).
|
||||
|
||||
markov p(X)::[t,f] ; [0.1, 0.3] ; [t(X)].
|
||||
|
||||
markov q(X)::[t,f], r(X)::[t,f] ; [0.9, 0.5, 0.5, 0.1] ; [t(X)].
|
||||
|
||||
markov q(X)::[t,f], p(X)::[t,f] ; [0.9, 0.5, 0.5, 0.1] ; [t(X)].
|
||||
|
||||
p(ann,t).
|
||||
|
||||
?- p(dave,X).
|
||||
|
||||
|
Reference in New Issue
Block a user