Re: [請益] 有個邏輯寶箱問題

看板logic作者 (catso)時間18年前 (2005/10/04 11:42), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串6/14 (看更多)
首先假設黃金必然在箱子里,且只可能在甲乙中的一個箱子里。用FOL形式化系統: isT(x) :x說真話 isG(x) :黃金在x中 常量(constant):A為甲,B為乙 根据題意可得如下規則(rule): (1) isT(A) -> isT(B) ^ isG(A) (2) isT(B) -> not isT(A) ^ isG(A) (3) not isT(A) -> not isT(B) v not isG(A) (4) not isT(B) -> isT(A) v not isG(A) (5) not isG(A) -> isG(B) 分四种情況討論 (a) 甲乙都說真話: 即有事實:isT(A), isT(B) 根据(1),(2)此時系統認知為以下合取式(conjunction): isT(A) ^ isT(B) ^ isG(A) ^ not isT(A) 此式顯然永假,故命題(proposition)(a)不成立。 (b) 甲說假話并且乙說真話: 即有事實:not isT(A), isT(B) 根据(3),(2)此時系統認知為: not isT(A) ^ (not isT(B) v not isG(A)) ^ isT(B) ^ isG(A) 根据De Morgan法則,此式等价于: not isT(A) ^ not (isT(B) ^ isG(A)) ^ (isT(B) ^ isG(A)) 此時顯然永假,故命題(b)不成立。 (c) 甲說真話并且乙說假話: 即有事實:isT(A), not isT(B) 根据(1),(4)此時系統認知為: isT(A) ^ isT(B) ^ not isT(B) ^ isG(A) ^ (isT(A) v not isG(A)) 此式顯然永假,故命題(c)不成立。 (d) 甲乙都說假話: 即有事實:not isT(A), not isT(B) 根据(3),(4)此時系統認知為: not isT(A) ^ not isT(B) ^ (not isT(B) v not isG(A)) ^ (isT(A) v not isG(A)) 此式等价于: not isT(A) ^ not isT(B) ^ not isG(A) 此時當且僅當(iff)not isG(A)成立(根据(5),即isG(B)成立)時,命題(d)成立。 綜上所述,根据已知條件,可得甲乙說的都是假話,且黃金在乙箱中。 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 220.240.209.192 ※ 編輯: catso 來自: 220.240.209.192 (10/04 16:38)
文章代碼(AID): #13GVeOvo (logic)
討論串 (同標題文章)
文章代碼(AID): #13GVeOvo (logic)