<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Artificial Intelligence Blog &#187; Artificial Intelligence Blog &#187; Logic</title>
	<atom:link href="http://artent.net/category/logic/feed/" rel="self" type="application/rss+xml" />
	<link>http://artent.net</link>
	<description>We&#039;re blogging machines!</description>
	<lastBuildDate>Sat, 14 Mar 2026 20:14:25 +0000</lastBuildDate>
	<language>en-US</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=4.0</generator>
	<item>
		<title>A Simple Minesweeper Puzzle</title>
		<link>http://artent.net/2021/02/08/a-simple-minesweeper-puzzle/</link>
		<comments>http://artent.net/2021/02/08/a-simple-minesweeper-puzzle/#comments</comments>
		<pubDate>Mon, 08 Feb 2021 15:42:06 +0000</pubDate>
		<dc:creator><![CDATA[hundalhh]]></dc:creator>
				<category><![CDATA[Games]]></category>
		<category><![CDATA[Logic]]></category>
		<category><![CDATA[Statistics]]></category>

		<guid isPermaLink="false">http://artent.net/?p=3163</guid>
		<description><![CDATA[Suppose that you are playing the game Minesweeper.  On your first move, you click on the lower left corner square and reveal a 1.  Then you click on the square above the corner and reveal a 2.  Then you click on the square above that and reveal a 3.  What is the &#8220;safest&#8221; next move? [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>Suppose that you are playing the game <a href="https://en.wikipedia.org/wiki/Minesweeper_(video_game)">Minesweeper</a>.  On your first move, you click on the lower left corner square and reveal a 1.  Then you click on the square above the corner and reveal a 2.  Then you click on the square above that and reveal a 3.  What is the &#8220;safest&#8221; next move?</p>
<p><a href="http://artent.net/wp-content/uploads/2021/02/Screen-Shot-2021-02-08-at-9.31.51-AM.png"><img class="aligncenter  wp-image-3164" src="http://artent.net/wp-content/uploads/2021/02/Screen-Shot-2021-02-08-at-9.31.51-AM.png" alt="Screen Shot 2021-02-08 at 9.31.51 AM" width="58" height="106" /></a></p>
<p>In order to talk about the contents of the blue squares, we will label them A,B,C,D, and E.</p>
<p><a href="http://artent.net/wp-content/uploads/2021/02/Screen-Shot-2021-02-08-at-9.35.35-AM.png"><img class="aligncenter  wp-image-3165" src="http://artent.net/wp-content/uploads/2021/02/Screen-Shot-2021-02-08-at-9.35.35-AM.png" alt="Screen Shot 2021-02-08 at 9.35.35 AM" width="62" height="117" /></a></p>
<p>There are only three possible scenarios:</p>
<p>a) A, B, C, and E have mines,</p>
<p>b) A, C, and D have mines, or</p>
<p>c) B, C, and D have mines.</p>
<p>But, not all of these scenarios are equally likely.  Suppose there are a total of $m$ mines on the board and $s$ squares left excluding the eight that we are looking at. Then the total number of possible distributions of the mines for scenarios a, b, and c are:</p>
<ul>
<li>$n_a = {s\choose m-4},$</li>
<li>$n_b= {s\choose m-3},$ and</li>
<li>$n_c ={s\choose m-3}.$</li>
</ul>
<p>These scenarios are not equally likely.  (Above we used <a href="https://en.wikipedia.org/wiki/Binomial_coefficient">choose notation</a>.  ${n\choose m}= \frac{n!}{m! (n-m)!}$ where $n!=1\cdot2\cdot3\cdot\cdots\cdot n$.  For example 4!=24 and ${5\choose 2}=\frac{5!}{2!\  \cdot\ 3!} = \frac{120}{2 \cdot 6}= 10$.)  In fact,</p>
<p>$$\begin{aligned} r=\frac{n_b}{n_a}&amp;=\frac{s\choose m-3}{s\choose m-4} \\&amp;=\frac{\frac{s!}{(m-3)! (s-(m-3))!}}{\frac{s!}{(m-4)! (s-(m-4))!}}\\&amp;=\frac{\frac{1}{(m-3)! (s-(m-3))!}}{\frac{1}{(m-4)! (s-(m-4))!}}\\&amp;= \frac{(m-4)! (s-(m-4))!}{(m-3)! (s-(m-3))!}\\&amp;= \frac{ (s-m+4)!}{(m-3) (s-m+3))!}\\&amp;= \frac{ s-m+4}{m-3 }.\end{aligned}$$</p>
<p>In the beginning of the game $r\approx s/m-1\approx 4$, so scenarios b and c are about four times as likely as scenario a.  We can now estimate the probabilities of scenarios a, b, and c to be about</p>
<ul>
<li>&#8220;probability of scenario a&#8221; = $p_a \approx 1/9,$</li>
<li>&#8220;probability of scenario b&#8221; = $p_b \approx 4/9, and$</li>
<li>&#8220;probability of scenario c&#8221; = $p_c \approx 4/9.$</li>
</ul>
<p>We can now conclude that the probability that square A has a mine is 5/9, that square B has a mine is 5/9, that square C has a mine is 100%, that square D has a mine is 8/9, and that square E has a mine is 1/9, so square E is the &#8220;safest&#8221; move.</p>
<p>Generally speaking, scenarios with more mines are less likely if less than half of the unknown squares have mines.</p>
<p>Another interesting way to think about it is that the 3 and 2 squares pulled the mines toward them making square E less likely to contain a mine.</p>
<p>You can approximate the probability of each scenario by just assuming that the squares are independent random variables (a false, but almost true assumption) each of which has probability $m/s$ of containing a mine.  Using that method gives the same results as the approximation above.</p>
<p>If you prefer an exact calculation, then use the formula</p>
<p>$$ r=\frac{ s-m+4}{m-3 }$$</p>
<p>to get the exact ratio of $\frac{p_b}{p_a} = \frac{p_c}{p_a}=r$.</p>
<p>&nbsp;</p>
<p>(PS:  Jennifer told me via email that you can play Minesweeper online at <a class="gmail-in-cell-link" href="https://www.solitaireparadise.com/games_list/minesweeper.html" target="_blank">https://www.solitaireparadise.com/games_list/minesweeper.htm</a>)</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://artent.net/2021/02/08/a-simple-minesweeper-puzzle/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Stanford online course &#8220;General Game Playing&#8221;</title>
		<link>http://artent.net/2015/03/30/stanford-online-course-general-game-playing/</link>
		<comments>http://artent.net/2015/03/30/stanford-online-course-general-game-playing/#comments</comments>
		<pubDate>Mon, 30 Mar 2015 12:50:34 +0000</pubDate>
		<dc:creator><![CDATA[hundalhh]]></dc:creator>
				<category><![CDATA[Games]]></category>
		<category><![CDATA[Logic]]></category>

		<guid isPermaLink="false">http://artent.net/?p=2701</guid>
		<description><![CDATA[Hey, I just enrolled in Stanford&#8217;s General Game Playing Course.  General game playing programs are programs that try to play almost any game after being given the rules.  There is a yearly competition of general game playing programs at the AAAI conference.  If you join the course, send me an email so that we can [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>Hey, I just enrolled in <a href="https://www.coursera.org/course/ggp">Stanford&#8217;s General Game Playing Course</a>.  <a href="http://en.wikipedia.org/wiki/General_game_playing">General game playing programs</a> are programs that try to play almost any game after being given the rules.  There is a yearly competition of general game playing programs at the<a href="http://en.wikipedia.org/wiki/Association_for_the_Advancement_of_Artificial_Intelligence"> AAAI conference</a>.  If you join the course, send me an email so that we can exchange ideas or notes.  (my email address is hundal followed by &#8220;hh&#8221; at yahoo.com)</p>
<p>Cheers, Hein</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://artent.net/2015/03/30/stanford-online-course-general-game-playing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Markov Logic Networks Tutorial</title>
		<link>http://artent.net/2013/01/06/markov-logic-networks-tutorial/</link>
		<comments>http://artent.net/2013/01/06/markov-logic-networks-tutorial/#comments</comments>
		<pubDate>Sun, 06 Jan 2013 16:30:28 +0000</pubDate>
		<dc:creator><![CDATA[hundalhh]]></dc:creator>
				<category><![CDATA[Graphical Models]]></category>
		<category><![CDATA[Logic]]></category>

		<guid isPermaLink="false">http://162.243.213.31/?p=1247</guid>
		<description><![CDATA[Garvesh Raskutti has some nice slides on Probabilistic Graphical Models and Markov Logic Networks (Richardson &#38; Domingos 2006).  Markov Logic Networks encode first order predicate logic into a Markov Random Field. The resulting networks can be quite large because statements like &#8220;for all x, y, and z, x is y&#8217;s parent and z is x&#8217;s parent imply [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>Garvesh Raskutti has some nice <a href="http://www.stat.berkeley.edu/~garveshr/Slides/mlntutorial.pdf">slides</a> on <a href="http://en.wikipedia.org/wiki/Graphical_model">Probabilistic Graphical Models</a> and <a href="http://en.wikipedia.org/wiki/Markov_logic_network">Markov Logic Networks</a> (<a href="http://homes.cs.washington.edu/~pedrod/papers/mlj05.pdf">Richardson &amp; Domingos 2006</a>).  Markov Logic Networks encode first order predicate logic into a <a href="http://en.wikipedia.org/wiki/Markov_random_field">Markov Random Field</a>. The resulting networks can be quite large because statements like &#8220;for all x, y, and z, x is y&#8217;s parent and z is x&#8217;s parent imply z is y&#8217;s grandparent&#8221; require the existence of $2n^2$ nodes in the graph where $n$ is the number of people considered.  The resulting networks are frequently solved by using <a href="http://en.wikipedia.org/wiki/Gibbs_sampling">Gibbs Sampling</a>.  For even more information Pedro Domingos has put an entire course online at</p>
<p><a href="http://homes.cs.washington.edu/~pedrod/803/">www.cs.washington.edu/homes/pedrod/803</a></p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://artent.net/2013/01/06/markov-logic-networks-tutorial/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Lifted Inference</title>
		<link>http://artent.net/2012/12/24/lifted-inference-seen-from-the-other-side-the-tractable-features/</link>
		<comments>http://artent.net/2012/12/24/lifted-inference-seen-from-the-other-side-the-tractable-features/#comments</comments>
		<pubDate>Mon, 24 Dec 2012 17:39:49 +0000</pubDate>
		<dc:creator><![CDATA[hundalhh]]></dc:creator>
				<category><![CDATA[Graphical Models]]></category>
		<category><![CDATA[Logic]]></category>

		<guid isPermaLink="false">http://162.243.213.31/?p=1256</guid>
		<description><![CDATA[Lifted Inference uses the rules of first order predicate logic to improve the speed of the standard Markov Random Field algorithms applied to Markov Logic Networks.  I wish I had been in Barcelona Spain in July last year for IJCAI11 because they had a cool tutorial on Lifted Inference.  Here&#8217;s a quote Much has been achieved [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>Lifted Inference uses the rules of first order predicate logic to improve the speed of the standard Markov Random Field algorithms applied to Markov Logic Networks.  I wish I had been in Barcelona Spain in July last year for <a href="http://ijcai-11.iiia.csic.es/">IJCAI11</a> because they had a cool <a href="http://www.biostat.wisc.edu/~natarasr/tutorials/lifted.htm">tutorial</a> on Lifted Inference.  Here&#8217;s a quote</p>
<blockquote><p>Much has been achieved in the field of AI, yet much remains to be done if we are to reach the goals we all imagine. One of the key challenges with moving ahead is closing the gap between logical and statistical AI. Recent years have seen an explosion of successes in combining probability and (subsets of) first-order logic respectively programming languages and databases in several subfields of AI: Reasoning, Learning, Knowledge Representation, Planning, Databases, NLP, Robotics, Vision, etc. Nowadays, we can learn probabilistic relational models automatically from millions of inter-related objects. We can generate optimal plans and learn to act optimally in uncertain environments involving millions of objects and relations among them. Exploiting shared factors can speed up message-passing algorithms for relational inference but also for classical propositional inference such as solving SAT problems. We can even perform exact lifted probabilistic inference avoiding explicit state enumeration by manipulating first-order state representations directly.</p></blockquote>
<p>In the related paper &#8220;<a href="http://books.nips.cc/papers/files/nips23/NIPS2010_0535.pdf">Lifted Inference Seen from the Other Side : The Tractable Features</a>&#8220;, Jha, Gogate, Meliou, Suciu (2010) reverse this notion.  Here&#8217;s the abstract:</p>
<blockquote><p>Lifted Inference algorithms for representations that combine ﬁrst-order logic and graphical models have been the focus of much recent research. All lifted algorithms developed to date are based on the same underlying idea: take a standard probabilistic inference algorithm (e.g., variable elimination, belief propagation etc.) and improve its efﬁciency by exploiting repeated structure in the ﬁrst-order model. In this paper, we propose an approach from the other side in that we use techniques from logic for probabilistic inference. In particular, we deﬁne a set of rules that look only at the logical representation to identify models for which exact efﬁcient inference is possible. Our rules yield new tractable classes that could not be solved efﬁciently by any of the existing techniques.</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://artent.net/2012/12/24/lifted-inference-seen-from-the-other-side-the-tractable-features/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What happens when you combine Relational Databases, Logic, and Machine Learning?</title>
		<link>http://artent.net/2012/12/22/what-happens-when-you-combine-relational-databases-logic-and-machine-learning/</link>
		<comments>http://artent.net/2012/12/22/what-happens-when-you-combine-relational-databases-logic-and-machine-learning/#comments</comments>
		<pubDate>Sat, 22 Dec 2012 18:05:41 +0000</pubDate>
		<dc:creator><![CDATA[hundalhh]]></dc:creator>
				<category><![CDATA[Graphical Models]]></category>
		<category><![CDATA[Logic]]></category>
		<category><![CDATA[Statistics]]></category>

		<guid isPermaLink="false">http://162.243.213.31/?p=1263</guid>
		<description><![CDATA[Answer:  Statistical Relational Learning.  Maybe I can get the book for Christmas.]]></description>
				<content:encoded><![CDATA[<p>Answer:  <a href="http://en.wikipedia.org/wiki/Statistical_relational_learning">Statistical Relational Learning</a>.  Maybe I can get the <a href="http://www.cs.umd.edu/srl-book/">book</a> for Christmas.</p>
]]></content:encoded>
			<wfw:commentRss>http://artent.net/2012/12/22/what-happens-when-you-combine-relational-databases-logic-and-machine-learning/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Euclidian Geometry is Decidable</title>
		<link>http://artent.net/2012/09/22/euclidian-geometry-is-decidable/</link>
		<comments>http://artent.net/2012/09/22/euclidian-geometry-is-decidable/#comments</comments>
		<pubDate>Sat, 22 Sep 2012 09:53:25 +0000</pubDate>
		<dc:creator><![CDATA[hundalhh]]></dc:creator>
				<category><![CDATA[Logic]]></category>

		<guid isPermaLink="false">http://162.243.213.31/?p=449</guid>
		<description><![CDATA[The other day, Carl mentioned that Euclidean Geometry was decidable.  I thought that was impossible because I thought it would have an isomorphic copy of Peano arithmetic which is not decidable.   Later he pointed me toward Tarski&#8217;s axioms.   Here&#8217;s a quote from the Wikipedia page &#8220;This fact allowed Tarski to prove that Euclidean [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>The other day, Carl mentioned that Euclidean Geometry was <a href="http://en.wikipedia.org/wiki/Decidable">decidable</a>.  I thought that was impossible because I thought it would have an isomorphic copy of <a href="http://en.wikipedia.org/wiki/Peano_axioms">Peano arithmetic</a> which is not decidable.   Later he pointed me toward <a href="http://en.wikipedia.org/wiki/Tarski%27s_axioms">Tarski&#8217;s axioms</a>.   Here&#8217;s a quote from the Wikipedia page &#8220;This fact allowed Tarski to prove that Euclidean geometry is <a title="Decidability (logic)" href="http://en.wikipedia.org/wiki/Decidability_(logic)">decidable</a>: there exists an <a title="Algorithm" href="http://en.wikipedia.org/wiki/Algorithm">algorithm</a> which can determine the truth or falsity of any sentence.&#8221;  I found the whole article to be pretty cool because I had never really dug into geometry as a first order predicate calculus.</p>
]]></content:encoded>
			<wfw:commentRss>http://artent.net/2012/09/22/euclidian-geometry-is-decidable/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Venn Diagrams</title>
		<link>http://artent.net/2012/08/20/venn-diagrams/</link>
		<comments>http://artent.net/2012/08/20/venn-diagrams/#comments</comments>
		<pubDate>Mon, 20 Aug 2012 18:22:02 +0000</pubDate>
		<dc:creator><![CDATA[hundalhh]]></dc:creator>
				<category><![CDATA[Logic]]></category>
		<category><![CDATA[Math]]></category>

		<guid isPermaLink="false">http://162.243.213.31/?p=299</guid>
		<description><![CDATA[Carl sent me a link to a Venn diagrams post, so that got me thinking. A Venn Diagram with $n$ atoms has to represent $2^n$ regions. For example if $n$ is $2$, then you have the standard Venn diagram below. Each time you increase $n$ by one, you double the number of regions.  This makes me think of [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>Carl sent me a <a href="http://cartesianproduct.wordpress.com/2012/08/12/venn-diagrams-for-11-sets/">link</a> to a <a href="https://en.wikipedia.org/wiki/Venn_diagram">Venn diagrams</a> post, so that got me thinking. A <a href="https://en.wikipedia.org/wiki/John_Venn">Venn</a> Diagram with $n$ atoms has to represent $2^n$ regions. For example if $n$ is $2$, then you have the standard Venn diagram below.</p>
<p><a href="http://www.louisianavoices.org/images/edu_venn_diagram2.GIF"><img class="alignnone" src="http://www.louisianavoices.org/images/edu_venn_diagram2.GIF" alt="" width="423" height="289" /></a></p>
<p>Each time you increase $n$ by one, you double the number of regions.  This makes me think of <a href="http://en.wikipedia.org/wiki/Binary_code">binary codes</a> and orthogonal functions. Everybody&#8217;s favorite orthogonal functions are the trig functions, so you should be able to draw Venn diagrams with wavy trig functions. Here was my first try.</p>
<p><a href="http://162.243.213.31/wp-content/uploads/2012/08/Ven1.png"><img class="alignnone size-full wp-image-307" title="Ven" src="http://162.243.213.31/wp-content/uploads/2012/08/Ven1.png" alt="" width="629" height="415" /></a></p>
<p>Those seemed kind of busy, so I dampened the amplitude on the high frequencies (making the slopes that same and possibly increasing artistic appeal.)</p>
<p><a href="http://162.243.213.31/wp-content/uploads/2012/08/Ven2.png"><img class="alignnone size-full wp-image-311" title="Ven2" src="http://162.243.213.31/wp-content/uploads/2012/08/Ven2.png" alt="" width="629" height="415" /></a></p>
<p>I really like the last one.</p>
<p><a href="http://162.243.213.31/wp-content/uploads/2012/08/Ven3.png"><img class="alignnone size-full wp-image-313" title="Ven3" src="http://162.243.213.31/wp-content/uploads/2012/08/Ven3.png" alt="" width="600" height="600" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://artent.net/2012/08/20/venn-diagrams/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

 Served from: artent.net @ 2026-05-12 20:41:15 by W3 Total Cache -->