SlideShare a Scribd company logo
1 of 13
OTTER
(Organized Techniques
for Theorem-proving and
Effective Research)
Heuristics computing
2014/12/22 9:25 – 11:00
Keio University, SFC
Liar and truth-teller paradox:
problem is contradictory
the liar paradox or liar's paradox (pseudomenon in Ancient Greek) is
the statement "this sentence is false." Trying to assign to this
statement a classical binary truth value leads to a contradiction.
If "this sentence is false" is true, then the sentence is false,
which is a contradiction. Conversely, if "this sentence is false"
s false, then the sentence is true, which is also a contradiction.
%assign(max_proofs,-1).
set(hyper_res).
set(print_lists_at_end).
assign(stats_level,0).
list(usable).
-P(T(x)) | -P(Says(x,y)) | P(y).
-P(L(x)) | -P(Says(x,y)) | -P(y).
P(T(x)) | P(L(x)).
-P(T(x)) | -P(L(x)).
end_of_list.
list(sos).
P(Says(A, L(A))).
end_of_list.
【 A 】  Always true 【 B 】 Always false
A  ∩  B  →  empty set
B ∩ ¬ A  → empty set
+
+
+ -
-
-
Syntax “-A | B”: proof by contradiction
A
B
C
A  ⊃  B
B → A
There exists Ai where
B∪ ¬ A → Ф
1 [] -Greek(x)|Person(x).
2 [] -Person(x)|Mortal(x).
3 [] Greek(socrates).
4 [] -Mortal(socrates).
5 [hyper,3,1] Person(socrates).
6 [hyper,5,2] Mortal(socrates).
7 [binary,6.1,4.1] $F.
3 |list(usable).
4 | -Greek(x) | Person(x).
5 | -Person(x) | Mortal(x).
6 |end_of_list.
8 |list(sos).
9 | Greek(socrates).
10 |end_of_list.
12 |list(passive).
13 | -Mortal(socrates).
14 |end_of_list.
Liar paradox: Liar, Truth teller and spy
introduce XOR and power set
On a fictional island, all inhabitants are either knights, who always tell the
truth, or knaves, who always lie. In some variations, inhabitants may also
be alternators, who alternate between lying and telling the truth, or
normals, who can say whatever they want (as in the case of
Knight/Knave/Spy puzzles).
+
+
+ -
-
-
【 B 】 Always false
+ - ++
-
【 A 】  Always true
-P(T(x)) | -P(Says(x,y)) | P(y).
-P(L(x)) | -P(Says(x,y)) | Q(y).
P(T(x)) | P(L(x)) | P(N(x)).
-P(T(x)) | -P(L(x)).
-P(T(x)) | -P(N(x)).
-P(L(x)) | -P(N(x)).
-P(n(T(x))) | P(L(x)) | P(N(x)).
-P(n(L(x))) | P(T(x)) | P(N(x)).
A  ∩  B  →  empty set
B ∨ ¬ A  → not φ
φN(x )
【 C 】 Spy
+
-
Liar and Spy Paradox N(x): power set
+
+
+
+ + -
-
-
--
-
T(x) L(x)
N(x) = T(x) or L(x)
+
-
+
++
+ +
-
--
-
-
-
-P(T(x)) | -P(Says(x,y)) | P(y).
-P(L(x)) | -P(Says(x,y)) | Q(y).
P(T(x)) | P(L(x)) | P(N(x)).
-P(T(x)) | -P(L(x)).
-P(T(x)) | -P(N(x)).
-P(L(x)) | -P(N(x)).
1 [] -P(T(x))| -P(Says(x,y))|P(y).
2 [] -P(L(x))| -P(Says(x,y))| -P(y).
3 [] P(T(x))|P(L(x)).
4 [] -P(T(x))| -P(L(x)).
5 [] P(Says(A,L(A))).
6 [hyper,5,2,3,3] P(T(A)).
7 [hyper,5,1,3] P(L(A)).
8 [hyper,7,4,6] $F.
Law of
Excluded middle
Who is SPY ? : consistency and model
【 A 】  Always true 【 B 】 Always false
【 C 】  satisfiable (model) unsatisfiable
A  ∩  B  →  empty
set
B∪ ¬ A  → not Ф
If system is consistent
(not contradictory),
there should be a
model
A B
N = A  ∨  B  ∨  not Ф
Syntax “A | B”
(exclusive, fermi particle model)
AB
C
a
A  ∩  B  →  empty
set
B∪ ¬ A  → not Ф
b
c
fermi particle model bose particle model
X
Y
Z
X
Y
Z
a
ab
c
c
a
X(a) | Y(b)
either, exclusive
electron, proton
X(a) or Y(b)
inclusive
photon
N (power set) = P(x) Q(x) ?∨ ∨
P Q
list(usable).
-P(T(x)) | -P(Says(x,y)) | P(y).
-P(L(x)) | -P(Says(x,y)) | Q(y).
P(T(x)) | P(L(x)) | P(N(x)).
-P(T(x)) | -P(L(x)).
-P(T(x)) | -P(N(x)).
-P(L(x)) | -P(N(x)).
-P(n(T(x))) | P(L(x)) | P(N(x)).
-P(n(L(x))) | P(T(x)) | P(N(x)).
-Q(n(y)) | P(y).
end_of_list.
list(sos).
P(Says(A,n(L(B)))).
P(Says(B,n(T(A)))).
end_of_list.
N
-Q(n(y)) | P(y). :  排中律
Law of excluded middle
N
P
Q
If a system is non-contracition,
There should be Q(y) which cannot
be inversed or proved
Russel’s barber paradox
The barber paradox is a puzzle derived from Russell's
paradox. It was used by Bertrand Russell himself as an
illustration of the paradox, though he attributes it to an
unnamed person who suggested it to him. It shows that
an apparently plausible scenario is logically impossible.
Specifically, it describes a barber who is defined such that
he both shaves himself and does not shave himself.
In Prolog, one aspect of the barber paradox can be expressed by a self-referencing
clause:
shaves(barber, X) :- male(X), not shaves(X,X).
male(barber).
where negation as failure is assumed. If we apply the stratification test known
from Datalog, the predicate shaves is exposed as unstratifiable
since it is defined recursively over its negation.
list(usable).
-P(T(x)) | -P(Says(x,y)) | P(y).
-P(L(x)) | -P(Says(x,y)) | Q(y).
P(T(x)) | P(L(x)) | P(N(x)).
-P(T(x)) | -P(L(x)).
-P(T(x)) | -P(N(x)).
-P(L(x)) | -P(N(x)).
-P(n(T(x))) | P(L(x)) | P(N(x)).
-P(n(L(x))) | P(T(x)) | P(N(x)).
-Q(n(y)) | P(y).
end_of_list.
The Twelve-Coins Puzzle
■ You have 12 coins. All coins appears to be identical. But you are told that one
of them is a counterfeit (lighter or heavier than other genuine coins).
■ You can use an scale or scales which is an equal-arm balance. The balance
provides one of three possible indications: the right pan is heavier, or the pans
are in balance, or the left pan is heavier. The balance has sensitivity sufficient
for the task.
■ One objective is to identify the counterfeit coin, and to check whether it is
heavy or light.
■This time the balance may be used three times to determine if there is a
unique coin—and if there is, to isolate it and determine its weight relative to the
others.
achievable(state(hls(12),hs(0),ls(0),s(0),rem(3))).
-solvable(state(hls(12),hs(0),ls(0),s(0),rem(3))).
Clause representation:
deterministic or underterministic
IF A THEN B : -A | B
IF A & B THEN B : -A | -B | C
IF A THEN B or C : -A | B | C
achievable(state(hls(12),hs(0),ls(0),s(0),rem(3))).
-solvable(state(hls(12),hs(0),ls(0),s(0),rem(3))).
a b
a b c
a b
c
Alphametic Puzzle
BA
C D
y1y2y3
z1z2z3
gfe h
We wish to find all 8-tuples (a,b,c,d,e,f,g,h)
of distinct digits such that the product is
valid. For example, since 72 x 95 = 6840,
(7,2,9,5,6,8,4,0) is one such 8-tuple.
It is
understood that a, c, and e are non-zero.
We use the predicate CP(u,x,y,z,v) to
express that
... y ...
x
___________
... z ...
Alphametic Puzzle
list(sos).
-K(u) | -D(x) | -D(y) |
CS(u,x,y,$MOD($SUM($SUM(u,x),y),10),$DIV($SUM($SUM(u,x),y),10)).
-L(u) | -D(x) | -D(y) |
CP(u,x,y,$MOD($SUM(u,$PROD(x,y)),10),$DIV($SUM(u,$PROD(x,y)),10)).
-CP(0,xd,xb,y1,x1) | -CP(x1,xd,xa,y2,y3) |
-CP(0,xc,xb,z1,x2) | -CP(x2,xc,xa,z2,z3) |
-$LT(xa,xc) |
-CS(0,y1,0,xh,x3) | -CS(x3,y2,z1,xg,x4) | -CS(x4,y3,z2,xf,x5) |
-CS(x5,0,z3,xe,0) | S(xa,xb,xc,xd,xe,xf,xg,xh).
end_of_list.

More Related Content

What's hot

Predicates and Quantifiers
Predicates and Quantifiers Predicates and Quantifiers
Predicates and Quantifiers Istiak Ahmed
 
Lecture 2 predicates quantifiers and rules of inference
Lecture 2 predicates quantifiers and rules of inferenceLecture 2 predicates quantifiers and rules of inference
Lecture 2 predicates quantifiers and rules of inferenceasimnawaz54
 
1 polar coordinates
1 polar coordinates1 polar coordinates
1 polar coordinatesmath267
 
Predicates and Quantifiers
Predicates and QuantifiersPredicates and Quantifiers
Predicates and Quantifiersblaircomp2003
 
Appendix to MLPI Lecture 2 - Monte Carlo Methods (Basics)
Appendix to MLPI Lecture 2 - Monte Carlo Methods (Basics)Appendix to MLPI Lecture 2 - Monte Carlo Methods (Basics)
Appendix to MLPI Lecture 2 - Monte Carlo Methods (Basics)Dahua Lin
 
Constructing List Homomorphisms from Proofs
Constructing List Homomorphisms from ProofsConstructing List Homomorphisms from Proofs
Constructing List Homomorphisms from ProofsYun-Yan Chi
 
t7 polar equations and graphs
t7 polar equations and graphst7 polar equations and graphs
t7 polar equations and graphsmath260
 
Lecture 3 qualtifed rules of inference
Lecture 3 qualtifed rules of inferenceLecture 3 qualtifed rules of inference
Lecture 3 qualtifed rules of inferenceasimnawaz54
 
Multivariate Distributions, an overview
Multivariate Distributions, an overviewMultivariate Distributions, an overview
Multivariate Distributions, an overviewArthur Charpentier
 
slides CIRM copulas, extremes and actuarial science
slides CIRM copulas, extremes and actuarial scienceslides CIRM copulas, extremes and actuarial science
slides CIRM copulas, extremes and actuarial scienceArthur Charpentier
 
Quantile and Expectile Regression
Quantile and Expectile RegressionQuantile and Expectile Regression
Quantile and Expectile RegressionArthur Charpentier
 

What's hot (18)

Predicates and Quantifiers
Predicates and Quantifiers Predicates and Quantifiers
Predicates and Quantifiers
 
Hasse Diagram
Hasse DiagramHasse Diagram
Hasse Diagram
 
Predicate & quantifier
Predicate & quantifierPredicate & quantifier
Predicate & quantifier
 
Lecture 2 predicates quantifiers and rules of inference
Lecture 2 predicates quantifiers and rules of inferenceLecture 2 predicates quantifiers and rules of inference
Lecture 2 predicates quantifiers and rules of inference
 
Slides ineq-4
Slides ineq-4Slides ineq-4
Slides ineq-4
 
1 polar coordinates
1 polar coordinates1 polar coordinates
1 polar coordinates
 
Predicates and Quantifiers
Predicates and QuantifiersPredicates and Quantifiers
Predicates and Quantifiers
 
Appendix to MLPI Lecture 2 - Monte Carlo Methods (Basics)
Appendix to MLPI Lecture 2 - Monte Carlo Methods (Basics)Appendix to MLPI Lecture 2 - Monte Carlo Methods (Basics)
Appendix to MLPI Lecture 2 - Monte Carlo Methods (Basics)
 
Slides ensae 8
Slides ensae 8Slides ensae 8
Slides ensae 8
 
Constructing List Homomorphisms from Proofs
Constructing List Homomorphisms from ProofsConstructing List Homomorphisms from Proofs
Constructing List Homomorphisms from Proofs
 
t7 polar equations and graphs
t7 polar equations and graphst7 polar equations and graphs
t7 polar equations and graphs
 
Inequality #4
Inequality #4Inequality #4
Inequality #4
 
Lecture 3 qualtifed rules of inference
Lecture 3 qualtifed rules of inferenceLecture 3 qualtifed rules of inference
Lecture 3 qualtifed rules of inference
 
Multivariate Distributions, an overview
Multivariate Distributions, an overviewMultivariate Distributions, an overview
Multivariate Distributions, an overview
 
slides CIRM copulas, extremes and actuarial science
slides CIRM copulas, extremes and actuarial scienceslides CIRM copulas, extremes and actuarial science
slides CIRM copulas, extremes and actuarial science
 
Slides toulouse
Slides toulouseSlides toulouse
Slides toulouse
 
Quantile and Expectile Regression
Quantile and Expectile RegressionQuantile and Expectile Regression
Quantile and Expectile Regression
 
Slides dauphine
Slides dauphineSlides dauphine
Slides dauphine
 

Viewers also liked

Csec52 45 Ruo Ando
Csec52 45 Ruo AndoCsec52 45 Ruo Ando
Csec52 45 Ruo AndoRuo Ando
 
Isec2015 2015-03-01-02
Isec2015 2015-03-01-02Isec2015 2015-03-01-02
Isec2015 2015-03-01-02Ruo Ando
 
An annotated context-free grammar based vulnerability detection using LALR pa...
An annotated context-free grammar based vulnerability detection using LALR pa...An annotated context-free grammar based vulnerability detection using LALR pa...
An annotated context-free grammar based vulnerability detection using LALR pa...Ruo Ando
 
2015 03-31-03
2015 03-31-032015 03-31-03
2015 03-31-03Ruo Ando
 
Css2011 Ruo Ando
Css2011 Ruo AndoCss2011 Ruo Ando
Css2011 Ruo AndoRuo Ando
 
Ncm 2012 Ruo Ando
Ncm 2012 Ruo AndoNcm 2012 Ruo Ando
Ncm 2012 Ruo AndoRuo Ando
 
Statically detecting vulnerability under memory pressure using exhaustive search
Statically detecting vulnerability under memory pressure usingexhaustive searchStatically detecting vulnerability under memory pressure usingexhaustive search
Statically detecting vulnerability under memory pressure using exhaustive searchRuo Ando
 
An Empirical Study of Android APK Distribution Sites Using Headless Browser w...
An Empirical Study of Android APK Distribution Sites Using Headless Browser w...An Empirical Study of Android APK Distribution Sites Using Headless Browser w...
An Empirical Study of Android APK Distribution Sites Using Headless Browser w...Ruo Ando
 
Scis2015 ruo ando_2015-01-20-01
Scis2015 ruo ando_2015-01-20-01Scis2015 ruo ando_2015-01-20-01
Scis2015 ruo ando_2015-01-20-01Ruo Ando
 
Advnet2011 ruo ando
Advnet2011 ruo andoAdvnet2011 ruo ando
Advnet2011 ruo andoRuo Ando
 
An extension of cryptographic protocol in distributed in-memory caching syst...
An extension of cryptographic protocol in distributed in-memory caching syst...An extension of cryptographic protocol in distributed in-memory caching syst...
An extension of cryptographic protocol in distributed in-memory caching syst...Ruo Ando
 
法政大学情報科学部-2012年度コンピュータネットワーク-第13回授業-WEB公開用
法政大学情報科学部-2012年度コンピュータネットワーク-第13回授業-WEB公開用法政大学情報科学部-2012年度コンピュータネットワーク-第13回授業-WEB公開用
法政大学情報科学部-2012年度コンピュータネットワーク-第13回授業-WEB公開用Ruo Ando
 
Otter 2016-11-28-01-ss
Otter 2016-11-28-01-ssOtter 2016-11-28-01-ss
Otter 2016-11-28-01-ssRuo Ando
 
Making a Scalable Automated Hacking System by Artem Dinaburg
Making a Scalable Automated Hacking System by Artem DinaburgMaking a Scalable Automated Hacking System by Artem Dinaburg
Making a Scalable Automated Hacking System by Artem DinaburgShakacon
 
Otter 2016-11-14-ss
Otter 2016-11-14-ssOtter 2016-11-14-ss
Otter 2016-11-14-ssRuo Ando
 
Otter 2014-12-08-02
Otter 2014-12-08-02Otter 2014-12-08-02
Otter 2014-12-08-02Ruo Ando
 
Métodos de búsqueda en internet
Métodos de búsqueda en internetMétodos de búsqueda en internet
Métodos de búsqueda en internetjeissojavi
 
オペレーティングシステム 第2回-公開用
オペレーティングシステム 第2回-公開用オペレーティングシステム 第2回-公開用
オペレーティングシステム 第2回-公開用Ruo Ando
 
オペレーティングシステム 第1回-公開用
オペレーティングシステム 第1回-公開用オペレーティングシステム 第1回-公開用
オペレーティングシステム 第1回-公開用Ruo Ando
 
seminar-2015-05-28-RuoAndo
seminar-2015-05-28-RuoAndoseminar-2015-05-28-RuoAndo
seminar-2015-05-28-RuoAndoRuo Ando
 

Viewers also liked (20)

Csec52 45 Ruo Ando
Csec52 45 Ruo AndoCsec52 45 Ruo Ando
Csec52 45 Ruo Ando
 
Isec2015 2015-03-01-02
Isec2015 2015-03-01-02Isec2015 2015-03-01-02
Isec2015 2015-03-01-02
 
An annotated context-free grammar based vulnerability detection using LALR pa...
An annotated context-free grammar based vulnerability detection using LALR pa...An annotated context-free grammar based vulnerability detection using LALR pa...
An annotated context-free grammar based vulnerability detection using LALR pa...
 
2015 03-31-03
2015 03-31-032015 03-31-03
2015 03-31-03
 
Css2011 Ruo Ando
Css2011 Ruo AndoCss2011 Ruo Ando
Css2011 Ruo Ando
 
Ncm 2012 Ruo Ando
Ncm 2012 Ruo AndoNcm 2012 Ruo Ando
Ncm 2012 Ruo Ando
 
Statically detecting vulnerability under memory pressure using exhaustive search
Statically detecting vulnerability under memory pressure usingexhaustive searchStatically detecting vulnerability under memory pressure usingexhaustive search
Statically detecting vulnerability under memory pressure using exhaustive search
 
An Empirical Study of Android APK Distribution Sites Using Headless Browser w...
An Empirical Study of Android APK Distribution Sites Using Headless Browser w...An Empirical Study of Android APK Distribution Sites Using Headless Browser w...
An Empirical Study of Android APK Distribution Sites Using Headless Browser w...
 
Scis2015 ruo ando_2015-01-20-01
Scis2015 ruo ando_2015-01-20-01Scis2015 ruo ando_2015-01-20-01
Scis2015 ruo ando_2015-01-20-01
 
Advnet2011 ruo ando
Advnet2011 ruo andoAdvnet2011 ruo ando
Advnet2011 ruo ando
 
An extension of cryptographic protocol in distributed in-memory caching syst...
An extension of cryptographic protocol in distributed in-memory caching syst...An extension of cryptographic protocol in distributed in-memory caching syst...
An extension of cryptographic protocol in distributed in-memory caching syst...
 
法政大学情報科学部-2012年度コンピュータネットワーク-第13回授業-WEB公開用
法政大学情報科学部-2012年度コンピュータネットワーク-第13回授業-WEB公開用法政大学情報科学部-2012年度コンピュータネットワーク-第13回授業-WEB公開用
法政大学情報科学部-2012年度コンピュータネットワーク-第13回授業-WEB公開用
 
Otter 2016-11-28-01-ss
Otter 2016-11-28-01-ssOtter 2016-11-28-01-ss
Otter 2016-11-28-01-ss
 
Making a Scalable Automated Hacking System by Artem Dinaburg
Making a Scalable Automated Hacking System by Artem DinaburgMaking a Scalable Automated Hacking System by Artem Dinaburg
Making a Scalable Automated Hacking System by Artem Dinaburg
 
Otter 2016-11-14-ss
Otter 2016-11-14-ssOtter 2016-11-14-ss
Otter 2016-11-14-ss
 
Otter 2014-12-08-02
Otter 2014-12-08-02Otter 2014-12-08-02
Otter 2014-12-08-02
 
Métodos de búsqueda en internet
Métodos de búsqueda en internetMétodos de búsqueda en internet
Métodos de búsqueda en internet
 
オペレーティングシステム 第2回-公開用
オペレーティングシステム 第2回-公開用オペレーティングシステム 第2回-公開用
オペレーティングシステム 第2回-公開用
 
オペレーティングシステム 第1回-公開用
オペレーティングシステム 第1回-公開用オペレーティングシステム 第1回-公開用
オペレーティングシステム 第1回-公開用
 
seminar-2015-05-28-RuoAndo
seminar-2015-05-28-RuoAndoseminar-2015-05-28-RuoAndo
seminar-2015-05-28-RuoAndo
 

Similar to Otter 2014-12-22-01-slideshare

OTTER 2017-12-03
OTTER 2017-12-03OTTER 2017-12-03
OTTER 2017-12-03Ruo Ando
 
Otter 2014-12-15-01-slideshare
Otter 2014-12-15-01-slideshareOtter 2014-12-15-01-slideshare
Otter 2014-12-15-01-slideshareRuo Ando
 
RChain - Understanding Distributed Calculi
RChain - Understanding Distributed CalculiRChain - Understanding Distributed Calculi
RChain - Understanding Distributed CalculiPawel Szulc
 
A/B Testing for Game Design
A/B Testing for Game DesignA/B Testing for Game Design
A/B Testing for Game DesignTrieu Nguyen
 
Multinomial Model Simulations
Multinomial Model SimulationsMultinomial Model Simulations
Multinomial Model Simulationstim_hare
 
Discrete mathematics
Discrete mathematicsDiscrete mathematics
Discrete mathematicsM.Saber
 
Discrete mathematic question answers
Discrete mathematic question answersDiscrete mathematic question answers
Discrete mathematic question answersSamet öztoprak
 
Estimation Theory, PhD Course, Ghent University, Belgium
Estimation Theory, PhD Course, Ghent University, BelgiumEstimation Theory, PhD Course, Ghent University, Belgium
Estimation Theory, PhD Course, Ghent University, BelgiumStijn De Vuyst
 
A Comparative Study of Two-Sample t-Test Under Fuzzy Environments Using Trape...
A Comparative Study of Two-Sample t-Test Under Fuzzy Environments Using Trape...A Comparative Study of Two-Sample t-Test Under Fuzzy Environments Using Trape...
A Comparative Study of Two-Sample t-Test Under Fuzzy Environments Using Trape...inventionjournals
 
Approximate Bayesian Computation with Quasi-Likelihoods
Approximate Bayesian Computation with Quasi-LikelihoodsApproximate Bayesian Computation with Quasi-Likelihoods
Approximate Bayesian Computation with Quasi-LikelihoodsStefano Cabras
 
Discrete probability
Discrete probabilityDiscrete probability
Discrete probabilityRanjan Kumar
 

Similar to Otter 2014-12-22-01-slideshare (20)

FUZZY LOGIC
FUZZY LOGICFUZZY LOGIC
FUZZY LOGIC
 
OTTER 2017-12-03
OTTER 2017-12-03OTTER 2017-12-03
OTTER 2017-12-03
 
Otter 2014-12-15-01-slideshare
Otter 2014-12-15-01-slideshareOtter 2014-12-15-01-slideshare
Otter 2014-12-15-01-slideshare
 
X02PredCalculus.ppt
X02PredCalculus.pptX02PredCalculus.ppt
X02PredCalculus.ppt
 
RChain - Understanding Distributed Calculi
RChain - Understanding Distributed CalculiRChain - Understanding Distributed Calculi
RChain - Understanding Distributed Calculi
 
A/B Testing for Game Design
A/B Testing for Game DesignA/B Testing for Game Design
A/B Testing for Game Design
 
Multinomial Model Simulations
Multinomial Model SimulationsMultinomial Model Simulations
Multinomial Model Simulations
 
Abstract machines for great good
Abstract machines for great goodAbstract machines for great good
Abstract machines for great good
 
1. linear model, inference, prediction
1. linear model, inference, prediction1. linear model, inference, prediction
1. linear model, inference, prediction
 
Slides ineq-3b
Slides ineq-3bSlides ineq-3b
Slides ineq-3b
 
Discrete mathematics
Discrete mathematicsDiscrete mathematics
Discrete mathematics
 
Inequalities #3
Inequalities #3Inequalities #3
Inequalities #3
 
Discrete mathematic question answers
Discrete mathematic question answersDiscrete mathematic question answers
Discrete mathematic question answers
 
PTSP PPT.pdf
PTSP PPT.pdfPTSP PPT.pdf
PTSP PPT.pdf
 
Bayesian computation with INLA
Bayesian computation with INLABayesian computation with INLA
Bayesian computation with INLA
 
Estimation Theory, PhD Course, Ghent University, Belgium
Estimation Theory, PhD Course, Ghent University, BelgiumEstimation Theory, PhD Course, Ghent University, Belgium
Estimation Theory, PhD Course, Ghent University, Belgium
 
A Comparative Study of Two-Sample t-Test Under Fuzzy Environments Using Trape...
A Comparative Study of Two-Sample t-Test Under Fuzzy Environments Using Trape...A Comparative Study of Two-Sample t-Test Under Fuzzy Environments Using Trape...
A Comparative Study of Two-Sample t-Test Under Fuzzy Environments Using Trape...
 
Approximate Bayesian Computation with Quasi-Likelihoods
Approximate Bayesian Computation with Quasi-LikelihoodsApproximate Bayesian Computation with Quasi-Likelihoods
Approximate Bayesian Computation with Quasi-Likelihoods
 
Slides erasmus
Slides erasmusSlides erasmus
Slides erasmus
 
Discrete probability
Discrete probabilityDiscrete probability
Discrete probability
 

More from Ruo Ando

KISTI-NII Joint Security Workshop 2023.pdf
KISTI-NII Joint Security Workshop 2023.pdfKISTI-NII Joint Security Workshop 2023.pdf
KISTI-NII Joint Security Workshop 2023.pdfRuo Ando
 
Gartner 「セキュリティ&リスクマネジメントサミット 2019」- 安藤
Gartner 「セキュリティ&リスクマネジメントサミット 2019」- 安藤Gartner 「セキュリティ&リスクマネジメントサミット 2019」- 安藤
Gartner 「セキュリティ&リスクマネジメントサミット 2019」- 安藤Ruo Ando
 
解説#86 決定木 - ss.pdf
解説#86 決定木 - ss.pdf解説#86 決定木 - ss.pdf
解説#86 決定木 - ss.pdfRuo Ando
 
SaaSアカデミー for バックオフィス アイドルと学ぶDX講座 ~アイドル戦略に見るDXを専門家が徹底解説~
SaaSアカデミー for バックオフィス アイドルと学ぶDX講座  ~アイドル戦略に見るDXを専門家が徹底解説~SaaSアカデミー for バックオフィス アイドルと学ぶDX講座  ~アイドル戦略に見るDXを専門家が徹底解説~
SaaSアカデミー for バックオフィス アイドルと学ぶDX講座 ~アイドル戦略に見るDXを専門家が徹底解説~Ruo Ando
 
解説#83 情報エントロピー
解説#83 情報エントロピー解説#83 情報エントロピー
解説#83 情報エントロピーRuo Ando
 
解説#82 記号論理学
解説#82 記号論理学解説#82 記号論理学
解説#82 記号論理学Ruo Ando
 
解説#81 ロジスティック回帰
解説#81 ロジスティック回帰解説#81 ロジスティック回帰
解説#81 ロジスティック回帰Ruo Ando
 
解説#74 連結リスト
解説#74 連結リスト解説#74 連結リスト
解説#74 連結リストRuo Ando
 
解説#76 福岡正信
解説#76 福岡正信解説#76 福岡正信
解説#76 福岡正信Ruo Ando
 
解説#77 非加算無限
解説#77 非加算無限解説#77 非加算無限
解説#77 非加算無限Ruo Ando
 
解説#1 C言語ポインタとアドレス
解説#1 C言語ポインタとアドレス解説#1 C言語ポインタとアドレス
解説#1 C言語ポインタとアドレスRuo Ando
 
解説#78 誤差逆伝播
解説#78 誤差逆伝播解説#78 誤差逆伝播
解説#78 誤差逆伝播Ruo Ando
 
解説#73 ハフマン符号
解説#73 ハフマン符号解説#73 ハフマン符号
解説#73 ハフマン符号Ruo Ando
 
【技術解説20】 ミニバッチ確率的勾配降下法
【技術解説20】 ミニバッチ確率的勾配降下法【技術解説20】 ミニバッチ確率的勾配降下法
【技術解説20】 ミニバッチ確率的勾配降下法Ruo Ando
 
【技術解説4】assertion failureとuse after-free
【技術解説4】assertion failureとuse after-free【技術解説4】assertion failureとuse after-free
【技術解説4】assertion failureとuse after-freeRuo Ando
 
ITmedia Security Week 2021 講演資料
ITmedia Security Week 2021 講演資料 ITmedia Security Week 2021 講演資料
ITmedia Security Week 2021 講演資料 Ruo Ando
 
ファジングの解説
ファジングの解説ファジングの解説
ファジングの解説Ruo Ando
 
AI(機械学習・深層学習)との協働スキルとOperational AIの事例紹介 @ ビジネス+ITセミナー 2020年11月
AI(機械学習・深層学習)との協働スキルとOperational AIの事例紹介 @ ビジネス+ITセミナー 2020年11月AI(機械学習・深層学習)との協働スキルとOperational AIの事例紹介 @ ビジネス+ITセミナー 2020年11月
AI(機械学習・深層学習)との協働スキルとOperational AIの事例紹介 @ ビジネス+ITセミナー 2020年11月Ruo Ando
 
【AI実装4】TensorFlowのプログラムを読む2 非線形回帰
【AI実装4】TensorFlowのプログラムを読む2 非線形回帰【AI実装4】TensorFlowのプログラムを読む2 非線形回帰
【AI実装4】TensorFlowのプログラムを読む2 非線形回帰Ruo Ando
 
Intel Trusted Computing Group 1st Workshop
Intel Trusted Computing Group 1st WorkshopIntel Trusted Computing Group 1st Workshop
Intel Trusted Computing Group 1st WorkshopRuo Ando
 

More from Ruo Ando (20)

KISTI-NII Joint Security Workshop 2023.pdf
KISTI-NII Joint Security Workshop 2023.pdfKISTI-NII Joint Security Workshop 2023.pdf
KISTI-NII Joint Security Workshop 2023.pdf
 
Gartner 「セキュリティ&リスクマネジメントサミット 2019」- 安藤
Gartner 「セキュリティ&リスクマネジメントサミット 2019」- 安藤Gartner 「セキュリティ&リスクマネジメントサミット 2019」- 安藤
Gartner 「セキュリティ&リスクマネジメントサミット 2019」- 安藤
 
解説#86 決定木 - ss.pdf
解説#86 決定木 - ss.pdf解説#86 決定木 - ss.pdf
解説#86 決定木 - ss.pdf
 
SaaSアカデミー for バックオフィス アイドルと学ぶDX講座 ~アイドル戦略に見るDXを専門家が徹底解説~
SaaSアカデミー for バックオフィス アイドルと学ぶDX講座  ~アイドル戦略に見るDXを専門家が徹底解説~SaaSアカデミー for バックオフィス アイドルと学ぶDX講座  ~アイドル戦略に見るDXを専門家が徹底解説~
SaaSアカデミー for バックオフィス アイドルと学ぶDX講座 ~アイドル戦略に見るDXを専門家が徹底解説~
 
解説#83 情報エントロピー
解説#83 情報エントロピー解説#83 情報エントロピー
解説#83 情報エントロピー
 
解説#82 記号論理学
解説#82 記号論理学解説#82 記号論理学
解説#82 記号論理学
 
解説#81 ロジスティック回帰
解説#81 ロジスティック回帰解説#81 ロジスティック回帰
解説#81 ロジスティック回帰
 
解説#74 連結リスト
解説#74 連結リスト解説#74 連結リスト
解説#74 連結リスト
 
解説#76 福岡正信
解説#76 福岡正信解説#76 福岡正信
解説#76 福岡正信
 
解説#77 非加算無限
解説#77 非加算無限解説#77 非加算無限
解説#77 非加算無限
 
解説#1 C言語ポインタとアドレス
解説#1 C言語ポインタとアドレス解説#1 C言語ポインタとアドレス
解説#1 C言語ポインタとアドレス
 
解説#78 誤差逆伝播
解説#78 誤差逆伝播解説#78 誤差逆伝播
解説#78 誤差逆伝播
 
解説#73 ハフマン符号
解説#73 ハフマン符号解説#73 ハフマン符号
解説#73 ハフマン符号
 
【技術解説20】 ミニバッチ確率的勾配降下法
【技術解説20】 ミニバッチ確率的勾配降下法【技術解説20】 ミニバッチ確率的勾配降下法
【技術解説20】 ミニバッチ確率的勾配降下法
 
【技術解説4】assertion failureとuse after-free
【技術解説4】assertion failureとuse after-free【技術解説4】assertion failureとuse after-free
【技術解説4】assertion failureとuse after-free
 
ITmedia Security Week 2021 講演資料
ITmedia Security Week 2021 講演資料 ITmedia Security Week 2021 講演資料
ITmedia Security Week 2021 講演資料
 
ファジングの解説
ファジングの解説ファジングの解説
ファジングの解説
 
AI(機械学習・深層学習)との協働スキルとOperational AIの事例紹介 @ ビジネス+ITセミナー 2020年11月
AI(機械学習・深層学習)との協働スキルとOperational AIの事例紹介 @ ビジネス+ITセミナー 2020年11月AI(機械学習・深層学習)との協働スキルとOperational AIの事例紹介 @ ビジネス+ITセミナー 2020年11月
AI(機械学習・深層学習)との協働スキルとOperational AIの事例紹介 @ ビジネス+ITセミナー 2020年11月
 
【AI実装4】TensorFlowのプログラムを読む2 非線形回帰
【AI実装4】TensorFlowのプログラムを読む2 非線形回帰【AI実装4】TensorFlowのプログラムを読む2 非線形回帰
【AI実装4】TensorFlowのプログラムを読む2 非線形回帰
 
Intel Trusted Computing Group 1st Workshop
Intel Trusted Computing Group 1st WorkshopIntel Trusted Computing Group 1st Workshop
Intel Trusted Computing Group 1st Workshop
 

Recently uploaded

AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.arsicmarija21
 
Gas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxGas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxDr.Ibrahim Hassaan
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...jaredbarbolino94
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfMr Bounab Samir
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceSamikshaHamane
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfUjwalaBharambe
 
Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfMahmoud M. Sallam
 
Capitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptxCapitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptxCapitolTechU
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for BeginnersSabitha Banu
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 
Earth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatEarth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatYousafMalik24
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxAvyJaneVismanos
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxJiesonDelaCerna
 

Recently uploaded (20)

AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.
 
Gas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxGas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptx
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in Pharmacovigilance
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
 
Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdf
 
Capitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptxCapitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptx
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for Beginners
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 
Earth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatEarth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice great
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptx
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptx
 

Otter 2014-12-22-01-slideshare

  • 1. OTTER (Organized Techniques for Theorem-proving and Effective Research) Heuristics computing 2014/12/22 9:25 – 11:00 Keio University, SFC
  • 2. Liar and truth-teller paradox: problem is contradictory the liar paradox or liar's paradox (pseudomenon in Ancient Greek) is the statement "this sentence is false." Trying to assign to this statement a classical binary truth value leads to a contradiction. If "this sentence is false" is true, then the sentence is false, which is a contradiction. Conversely, if "this sentence is false" s false, then the sentence is true, which is also a contradiction. %assign(max_proofs,-1). set(hyper_res). set(print_lists_at_end). assign(stats_level,0). list(usable). -P(T(x)) | -P(Says(x,y)) | P(y). -P(L(x)) | -P(Says(x,y)) | -P(y). P(T(x)) | P(L(x)). -P(T(x)) | -P(L(x)). end_of_list. list(sos). P(Says(A, L(A))). end_of_list. 【 A 】  Always true 【 B 】 Always false A  ∩  B  →  empty set B ∩ ¬ A  → empty set + + + - - -
  • 3. Syntax “-A | B”: proof by contradiction A B C A  ⊃  B B → A There exists Ai where B∪ ¬ A → Ф 1 [] -Greek(x)|Person(x). 2 [] -Person(x)|Mortal(x). 3 [] Greek(socrates). 4 [] -Mortal(socrates). 5 [hyper,3,1] Person(socrates). 6 [hyper,5,2] Mortal(socrates). 7 [binary,6.1,4.1] $F. 3 |list(usable). 4 | -Greek(x) | Person(x). 5 | -Person(x) | Mortal(x). 6 |end_of_list. 8 |list(sos). 9 | Greek(socrates). 10 |end_of_list. 12 |list(passive). 13 | -Mortal(socrates). 14 |end_of_list.
  • 4. Liar paradox: Liar, Truth teller and spy introduce XOR and power set On a fictional island, all inhabitants are either knights, who always tell the truth, or knaves, who always lie. In some variations, inhabitants may also be alternators, who alternate between lying and telling the truth, or normals, who can say whatever they want (as in the case of Knight/Knave/Spy puzzles). + + + - - - 【 B 】 Always false + - ++ - 【 A 】  Always true -P(T(x)) | -P(Says(x,y)) | P(y). -P(L(x)) | -P(Says(x,y)) | Q(y). P(T(x)) | P(L(x)) | P(N(x)). -P(T(x)) | -P(L(x)). -P(T(x)) | -P(N(x)). -P(L(x)) | -P(N(x)). -P(n(T(x))) | P(L(x)) | P(N(x)). -P(n(L(x))) | P(T(x)) | P(N(x)). A  ∩  B  →  empty set B ∨ ¬ A  → not φ φN(x ) 【 C 】 Spy
  • 5. + - Liar and Spy Paradox N(x): power set + + + + + - - - -- - T(x) L(x) N(x) = T(x) or L(x) + - + ++ + + - -- - - - -P(T(x)) | -P(Says(x,y)) | P(y). -P(L(x)) | -P(Says(x,y)) | Q(y). P(T(x)) | P(L(x)) | P(N(x)). -P(T(x)) | -P(L(x)). -P(T(x)) | -P(N(x)). -P(L(x)) | -P(N(x)). 1 [] -P(T(x))| -P(Says(x,y))|P(y). 2 [] -P(L(x))| -P(Says(x,y))| -P(y). 3 [] P(T(x))|P(L(x)). 4 [] -P(T(x))| -P(L(x)). 5 [] P(Says(A,L(A))). 6 [hyper,5,2,3,3] P(T(A)). 7 [hyper,5,1,3] P(L(A)). 8 [hyper,7,4,6] $F. Law of Excluded middle
  • 6. Who is SPY ? : consistency and model 【 A 】  Always true 【 B 】 Always false 【 C 】  satisfiable (model) unsatisfiable A  ∩  B  →  empty set B∪ ¬ A  → not Ф If system is consistent (not contradictory), there should be a model A B N = A  ∨  B  ∨  not Ф
  • 7. Syntax “A | B” (exclusive, fermi particle model) AB C a A  ∩  B  →  empty set B∪ ¬ A  → not Ф b c fermi particle model bose particle model X Y Z X Y Z a ab c c a X(a) | Y(b) either, exclusive electron, proton X(a) or Y(b) inclusive photon
  • 8. N (power set) = P(x) Q(x) ?∨ ∨ P Q list(usable). -P(T(x)) | -P(Says(x,y)) | P(y). -P(L(x)) | -P(Says(x,y)) | Q(y). P(T(x)) | P(L(x)) | P(N(x)). -P(T(x)) | -P(L(x)). -P(T(x)) | -P(N(x)). -P(L(x)) | -P(N(x)). -P(n(T(x))) | P(L(x)) | P(N(x)). -P(n(L(x))) | P(T(x)) | P(N(x)). -Q(n(y)) | P(y). end_of_list. list(sos). P(Says(A,n(L(B)))). P(Says(B,n(T(A)))). end_of_list. N -Q(n(y)) | P(y). :  排中律 Law of excluded middle N P Q If a system is non-contracition, There should be Q(y) which cannot be inversed or proved
  • 9. Russel’s barber paradox The barber paradox is a puzzle derived from Russell's paradox. It was used by Bertrand Russell himself as an illustration of the paradox, though he attributes it to an unnamed person who suggested it to him. It shows that an apparently plausible scenario is logically impossible. Specifically, it describes a barber who is defined such that he both shaves himself and does not shave himself. In Prolog, one aspect of the barber paradox can be expressed by a self-referencing clause: shaves(barber, X) :- male(X), not shaves(X,X). male(barber). where negation as failure is assumed. If we apply the stratification test known from Datalog, the predicate shaves is exposed as unstratifiable since it is defined recursively over its negation. list(usable). -P(T(x)) | -P(Says(x,y)) | P(y). -P(L(x)) | -P(Says(x,y)) | Q(y). P(T(x)) | P(L(x)) | P(N(x)). -P(T(x)) | -P(L(x)). -P(T(x)) | -P(N(x)). -P(L(x)) | -P(N(x)). -P(n(T(x))) | P(L(x)) | P(N(x)). -P(n(L(x))) | P(T(x)) | P(N(x)). -Q(n(y)) | P(y). end_of_list.
  • 10. The Twelve-Coins Puzzle ■ You have 12 coins. All coins appears to be identical. But you are told that one of them is a counterfeit (lighter or heavier than other genuine coins). ■ You can use an scale or scales which is an equal-arm balance. The balance provides one of three possible indications: the right pan is heavier, or the pans are in balance, or the left pan is heavier. The balance has sensitivity sufficient for the task. ■ One objective is to identify the counterfeit coin, and to check whether it is heavy or light. ■This time the balance may be used three times to determine if there is a unique coin—and if there is, to isolate it and determine its weight relative to the others. achievable(state(hls(12),hs(0),ls(0),s(0),rem(3))). -solvable(state(hls(12),hs(0),ls(0),s(0),rem(3))).
  • 11. Clause representation: deterministic or underterministic IF A THEN B : -A | B IF A & B THEN B : -A | -B | C IF A THEN B or C : -A | B | C achievable(state(hls(12),hs(0),ls(0),s(0),rem(3))). -solvable(state(hls(12),hs(0),ls(0),s(0),rem(3))). a b a b c a b c
  • 12. Alphametic Puzzle BA C D y1y2y3 z1z2z3 gfe h We wish to find all 8-tuples (a,b,c,d,e,f,g,h) of distinct digits such that the product is valid. For example, since 72 x 95 = 6840, (7,2,9,5,6,8,4,0) is one such 8-tuple. It is understood that a, c, and e are non-zero. We use the predicate CP(u,x,y,z,v) to express that ... y ... x ___________ ... z ...
  • 13. Alphametic Puzzle list(sos). -K(u) | -D(x) | -D(y) | CS(u,x,y,$MOD($SUM($SUM(u,x),y),10),$DIV($SUM($SUM(u,x),y),10)). -L(u) | -D(x) | -D(y) | CP(u,x,y,$MOD($SUM(u,$PROD(x,y)),10),$DIV($SUM(u,$PROD(x,y)),10)). -CP(0,xd,xb,y1,x1) | -CP(x1,xd,xa,y2,y3) | -CP(0,xc,xb,z1,x2) | -CP(x2,xc,xa,z2,z3) | -$LT(xa,xc) | -CS(0,y1,0,xh,x3) | -CS(x3,y2,z1,xg,x4) | -CS(x4,y3,z2,xf,x5) | -CS(x5,0,z3,xe,0) | S(xa,xb,xc,xd,xe,xf,xg,xh). end_of_list.