<?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>psychobolt productions</title>
	<atom:link href="http://www.psychobolt.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.psychobolt.com</link>
	<description></description>
	<lastBuildDate>Mon, 06 Jun 2011 00:01:41 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.3</generator>
		<item>
		<title>Intelligent Mouse</title>
		<link>http://www.psychobolt.com/intelligent-mouse/</link>
		<comments>http://www.psychobolt.com/intelligent-mouse/#comments</comments>
		<pubDate>Wed, 26 Jan 2011 17:29:00 +0000</pubDate>
		<dc:creator>psychobolt</dc:creator>
				<category><![CDATA[Games]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://www.psychobolt.com/?p=391</guid>
		<description><![CDATA[A fun challenging game coming soon to Samsung Smart TVs!]]></description>
			<content:encoded><![CDATA[<div id="attachment_394" class="wp-caption aligncenter" style="width: 540px"><a href="http://www.psychobolt.com/wp-content/uploads/2011/01/imcomingsoon.jpg"><img class="size-full wp-image-394 " title="imcomingsoon" src="http://www.psychobolt.com/wp-content/uploads/2011/01/imcomingsoon.jpg" alt="" width="530" height="392" /></a><p class="wp-caption-text">Are you an intelligent mouse? Play the game to find out!</p></div>
<p>This was an game I help developed for one of my internship courses run by <a href="http://guiang.com/">Guiang Corporation</a>. The game targeted platform is Flash compatible Smart TVs. You play yourself as a mouse and escape the maze before time runs out. Answer any questions correctly to get points and hints. You can also collect cheeses in the maze for points.</p>
<p><span id="more-391"></span><br />
Update: I no longer work on this project since my employment at Parasoft. The game will be developed by some remaining and new developers. Initially the game was made for Samsung TV, but the latter developers realized the potential of becoming a web app.</p>
<p>Check out <a href="http://www.intelligentmouse.com" target="_blank">intelligentmouse.com</a> for more information on this game.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.psychobolt.com/intelligent-mouse/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Clearing Sky</title>
		<link>http://www.psychobolt.com/clearing-sky/</link>
		<comments>http://www.psychobolt.com/clearing-sky/#comments</comments>
		<pubDate>Wed, 12 Jan 2011 23:07:34 +0000</pubDate>
		<dc:creator>psychobolt</dc:creator>
				<category><![CDATA[Art]]></category>

		<guid isPermaLink="false">http://www.psychobolt.com/?p=363</guid>
		<description><![CDATA[Mountain Speed Painting #29]]></description>
			<content:encoded><![CDATA[<div class="wp-caption aligncenter" style="width: 802px"><a href="http://www.psychobolt.com/wp-content/uploads/2010/01/mountainspeed29.jpg"><img class="  " src="http://www.psychobolt.com/wp-content/uploads/2010/01/mountainspeed29.jpg" alt="" width="792" height="392" /></a><p class="wp-caption-text">&quot;The sun rises over the mountains...bringing forth a brand new day.&quot;</p></div>
<p>This was an artwork I worked on over last year. I wanted to create a new painting for the New Year of 2010 and this piece symbolizes it. I used Photoshop CS4 and painted this piece by using my personal pen tablet. Special thanks to <a href="http://www.cgpad.org">www.cgpad.org</a> for the community custom brushes.</p>
<p><span id="more-363"></span><br />
Deviant Art [<a href="http://fav.me/d2gkgw7">link</a>]</p>
]]></content:encoded>
			<wfw:commentRss>http://www.psychobolt.com/clearing-sky/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>LEGO Mindstorm Robot</title>
		<link>http://www.psychobolt.com/lego-mindstorm-robot/</link>
		<comments>http://www.psychobolt.com/lego-mindstorm-robot/#comments</comments>
		<pubDate>Wed, 12 Jan 2011 20:45:02 +0000</pubDate>
		<dc:creator>psychobolt</dc:creator>
				<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://www.psychobolt.com/?p=357</guid>
		<description><![CDATA[Robot design prototype: Steering and obstacle avoidance. Real-world robot model.]]></description>
			<content:encoded><![CDATA[<div class="wp-caption aligncenter" style="width: 394px"><a href="http://1.bp.blogspot.com/_LZD75HusD_A/TPRdX3kLrsI/AAAAAAAAABQ/x9jJwmR8alQ/s1600/DSC00007.JPG"><img class="  " src="http://1.bp.blogspot.com/_LZD75HusD_A/TPRdX3kLrsI/AAAAAAAAABQ/x9jJwmR8alQ/s1600/DSC00007.JPG" alt="" width="384" height="288" /></a><p class="wp-caption-text">Hello there, my name is Legocpp!</p></div>
<p>An classwork for my robotics class. This was an experimentation on robot steering and obstacle avoidance. My partner and I used <a href="http://lejos.sourceforge.net/">Lejos</a> for coding and the Lego Mindstorm unit was provided by our school. Lejos is an Java API we used.</p>
<p><span id="more-357"></span><br />
Here is the main robot loop:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
</pre></td><td class="code"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">while</span><span style="color: #009900;">&#40;</span>nav.<span style="color: #006633;">isMoving</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span><span style="color: #003399;">Button</span>.<span style="color: #006633;">ESCAPE</span>.<span style="color: #006633;">isPressed</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #666666; font-style: italic;">// if we press button to terminate early</span>
	<span style="color: #009900;">&#123;</span>
		nav.<span style="color: #006633;">stop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #000000; font-weight: bold;">return</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #000066; font-weight: bold;">boolean</span> crashed <span style="color: #339933;">=</span> touch.<span style="color: #006633;">isPressed</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000000; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span>detectObstacle<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">||</span> crashed<span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #003399;">Thread</span>.<span style="color: #006633;">sleep</span><span style="color: #009900;">&#40;</span><span style="color: #cc66cc;">50</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// wait 50ms for sonar update</span>
		<span style="color: #000000; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span>obstacleAvoid<span style="color: #009900;">&#40;</span>crashed, error<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #666666; font-style: italic;">// if we avoided the obstacle</span>
		<span style="color: #009900;">&#123;</span>
			<span style="color: #000000; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span>goaround<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #666666; font-style: italic;">// if we successfully &quot;gone around&quot;</span>
			<span style="color: #009900;">&#123;</span>
				nav.<span style="color: #000000; font-weight: bold;">goTo</span><span style="color: #009900;">&#40;</span><span style="color: #cc66cc;">0</span>, <span style="color: #cc66cc;">60</span>, <span style="color: #000066; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// continue to goal</span>
				error <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span>
			<span style="color: #009900;">&#125;</span>
		<span style="color: #009900;">&#125;</span>
		<span style="color: #000000; font-weight: bold;">else</span> error<span style="color: #339933;">+=</span><span style="color: #cc66cc;">2</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p><span class="post-header">Disadvantages</span></p>
<p>We used an dead reckoning behavior to keep track of the current position. Even though it wasn&#8217;t as effective, for example: If the robot was stuck and the wheels are moving, then the robot&#8217;s position is still updated.</p>
<p>The main goal of our project was to make the robot avoid obstacle. As long as the robot does move behind an obstacle, it is consistent with our goal.</p>
<p><span class="post-header">Strengths</span></p>
<p>The robot was able to decide how far to travel before we should check if we are clear of the obstacle. This was handled by calculating how many times it turned back and found an obstacle is still there.</p>
<p><span class="post-header">Video and Blog</span></p>
<p>You can view the video demonstration and more information on our Robot Design Blog [<a href="http://legocpp.blogspot.com/">link</a>].</p>
]]></content:encoded>
			<wfw:commentRss>http://www.psychobolt.com/lego-mindstorm-robot/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Connect 4 Game</title>
		<link>http://www.psychobolt.com/connect-4-game/</link>
		<comments>http://www.psychobolt.com/connect-4-game/#comments</comments>
		<pubDate>Mon, 10 Jan 2011 05:31:07 +0000</pubDate>
		<dc:creator>psychobolt</dc:creator>
				<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://www.psychobolt.com/?p=332</guid>
		<description><![CDATA[Connect 4 in a column or row. One player game against the computer.]]></description>
			<content:encoded><![CDATA[<div id="attachment_333" class="wp-caption aligncenter" style="width: 646px"><a href="http://www.psychobolt.com/wp-content/uploads/2011/01/prerview.png"><img class="size-full wp-image-333    " src="http://www.psychobolt.com/wp-content/uploads/2011/01/prerview.png" alt="" width="636" height="458" /></a><p class="wp-caption-text">Code vs Output</p></div>
<p style="text-align: left;">This was one of my projects I&#8217;ve completed for an AI class I took during my college term. The project goal is to implement an AI game using one of the key algorithms we learned, Alpha-beta pruning. The game idea is simple: The player is to play against an AI. The win factor is that the player should have 4 pieces consecutively in a row or column. The programming language used was  Python 3.1.</p>
<p><span id="more-332"></span><br />
<span class="post-header">What is Alpha-beta pruning?</span></p>
<p style="text-align: left;">Read an clear explanation on <a href="http://en.wikipedia.org/wiki/Alpha-beta_pruning">Wikipedia</a>, our implementation follows it directly. Here is the implementation for my code:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
</pre></td><td class="code"><pre class="python" style="font-family:monospace;"><span style="color: #ff7700;font-weight:bold;">def</span> alphabeta<span style="color: black;">&#40;</span>problem, alpha, beta, MaxPlayer, limit<span style="color: black;">&#41;</span>:
	<span style="color: #ff7700;font-weight:bold;">global</span> starttime
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: black;">&#40;</span><span style="color: #dc143c;">time</span>.<span style="color: black;">clock</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span> - starttime<span style="color: black;">&#41;</span> <span style="color: #66cc66;">&amp;</span>gt<span style="color: #66cc66;">;</span>= limit <span style="color: #ff7700;font-weight:bold;">or</span> problem<span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>.<span style="color: black;">isfull</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>: <span style="color: #ff7700;font-weight:bold;">return</span> problem
	<span style="color: #ff7700;font-weight:bold;">if</span> MaxPlayer: <span style="color: #ff7700;font-weight:bold;">return</span> maxstate<span style="color: black;">&#40;</span>problem<span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>, alpha, beta, MaxPlayer<span style="color: black;">&#41;</span>
	<span style="color: #ff7700;font-weight:bold;">else</span>: <span style="color: #ff7700;font-weight:bold;">return</span> minstate<span style="color: black;">&#40;</span>problem<span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>, alpha, beta, MaxPlayer<span style="color: black;">&#41;</span>
&nbsp;
<span style="color: #ff7700;font-weight:bold;">def</span> maxstate<span style="color: black;">&#40;</span>problem, alpha, beta, MaxPlayer<span style="color: black;">&#41;</span>:
	<span style="color: #ff7700;font-weight:bold;">for</span> child <span style="color: #ff7700;font-weight:bold;">in</span> problem.<span style="color: black;">getsuccessors</span><span style="color: black;">&#40;</span><span style="color: #483d8b;">'X'</span><span style="color: black;">&#41;</span>:
		clone = <span style="color: #dc143c;">copy</span>.<span style="color: black;">deepcopy</span><span style="color: black;">&#40;</span>problem<span style="color: black;">&#41;</span>
		clone.<span style="color: black;">move</span><span style="color: black;">&#40;</span>child<span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span><span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>, child<span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span><span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span>, <span style="color: #483d8b;">'X'</span><span style="color: black;">&#41;</span>
		node = <span style="color: black;">&#40;</span>clone, child<span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span><span style="color: black;">&#41;</span>
		alpha = <span style="color: #008000;">max</span><span style="color: black;">&#40;</span>alpha, alphabeta<span style="color: black;">&#40;</span>node, alpha, beta, <span style="color: #ff7700;font-weight:bold;">not</span> MaxPlayer, limit<span style="color: black;">&#41;</span><span style="color: black;">&#41;</span>
		<span style="color: #ff7700;font-weight:bold;">if</span> beta<span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>.<span style="color: black;">h</span> <span style="color: #66cc66;">&amp;</span>lt<span style="color: #66cc66;">;</span>= alpha<span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>.<span style="color: black;">h</span>: <span style="color: #ff7700;font-weight:bold;">break</span><span style="color: #66cc66;">;</span>
	<span style="color: #ff7700;font-weight:bold;">return</span> alpha
&nbsp;
<span style="color: #ff7700;font-weight:bold;">def</span> minstate<span style="color: black;">&#40;</span>problem, alpha, beta, MaxPlayer<span style="color: black;">&#41;</span>:
	<span style="color: #ff7700;font-weight:bold;">for</span> child <span style="color: #ff7700;font-weight:bold;">in</span> problem.<span style="color: black;">getsuccessors</span><span style="color: black;">&#40;</span><span style="color: #483d8b;">'O'</span><span style="color: black;">&#41;</span>:
		clone = <span style="color: #dc143c;">copy</span>.<span style="color: black;">deepcopy</span><span style="color: black;">&#40;</span>problem<span style="color: black;">&#41;</span>
		clone.<span style="color: black;">move</span><span style="color: black;">&#40;</span>child<span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span><span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>, child<span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span><span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span>, <span style="color: #483d8b;">'O'</span><span style="color: black;">&#41;</span>
		node = <span style="color: black;">&#40;</span>clone, child<span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span><span style="color: black;">&#41;</span>
		beta = <span style="color: #008000;">min</span><span style="color: black;">&#40;</span>beta, alphabeta<span style="color: black;">&#40;</span>node, alpha, beta, <span style="color: #ff7700;font-weight:bold;">not</span> MaxPlayer, limit<span style="color: black;">&#41;</span><span style="color: black;">&#41;</span>
		<span style="color: #ff7700;font-weight:bold;">if</span> beta<span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>.<span style="color: black;">h</span> <span style="color: #66cc66;">&amp;</span>lt<span style="color: #66cc66;">;</span>= alpha<span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>.<span style="color: black;">h</span>: <span style="color: #ff7700;font-weight:bold;">break</span><span style="color: #66cc66;">;</span>
	<span style="color: #ff7700;font-weight:bold;">return</span> beta</pre></td></tr></table></div>

<p><span class="post-header">How the AI chooses the best possible move:</span></p>
<p style="text-align: left;">I will give a very general explanation. Please read the Wikipedia link for a elaborate explanation.</p>
<p style="text-align: left;">1.) Given an player&#8217;s move, the AI will generate a minimax tree till the search limit time is reached. In other words: Predict player&#8217;s next move and then find my best move. Iterate this n-levels deep.</p>
<p style="text-align: left;">2.) For each move the AI predicts, give it an score. The evaluation function:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
</pre></td><td class="code"><pre class="python" style="font-family:monospace;"><span style="color: #ff7700;font-weight:bold;">def</span> getsum<span style="color: black;">&#40;</span><span style="color: #008000;">self</span>, <span style="color: #dc143c;">string</span><span style="color: black;">&#41;</span>:
	<span style="color: #008000;">sum</span> = <span style="color: #ff4500;">0</span>
	superbad = -<span style="color: #ff4500;">5000</span>
	bad1 = -<span style="color: #ff4500;">100</span>
	bad2 = -<span style="color: #ff4500;">75</span>
	bad3 = -<span style="color: #ff4500;">50</span>
	bad4 = -<span style="color: #ff4500;">25</span>
	bad5 = -<span style="color: #ff4500;">1</span>
	supergood = <span style="color: #ff4500;">5000</span>
	good1 = <span style="color: #ff4500;">100</span>
	good2 = <span style="color: #ff4500;">75</span>
	good3 = <span style="color: #ff4500;">50</span>
	good4 = <span style="color: #ff4500;">25</span>
	good5 = <span style="color: #ff4500;">1</span>
	<span style="color: #808080; font-style: italic;">#opponent</span>
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'OOOO'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += superbad
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'-OOO-'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad1
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'OOO-'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad1
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'-OOO'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad1
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'OO-O'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad2
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'O-OO'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad2
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'O-OO-'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad2
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'-OO-O'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad2
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'-O-OO'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad2
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'OO-O-'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad2
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'-OO-'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad2
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'-OO'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad3
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'OO-'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad3
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'O-O-'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad4
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'-O-O'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad4
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'-O-O-'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad2
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'O-O'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad5
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'OO'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad5
	<span style="color: #ff7700;font-weight:bold;">if</span> <span style="color: #483d8b;">'-O-'</span> <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">string</span>: <span style="color: #008000;">sum</span> += bad5
        .....</pre></td></tr></table></div>

<p>3.) The AI will consider all the player&#8217;s moves that are against itself and find its worse case.</p>
<p>4.) The AI evaluates itself to find it&#8217;s best move to counter the player&#8217;s move.</p>
<p><span class="post-header">Disadvantage:</span></p>
<p>Our Design: Too many combinations of player&#8217;s moves to evaluate, therefore AI may not make the best move in our consideration.</p>
<p><span class="post-header">Strength:</span></p>
<p>Python&#8217;s fast sorting. Alpha-beta pruning which cuts off any worse-off moves from consideration.</p>
<p><span class="post-header">Try it out!</span></p>
<p>An python installation is required. Please make sure you have already installed on your computer, <a href="http://www.python.org/download/">Python 3.1+</a>.</p>
<p>connect4.py [<a href="http://www.psychobolt.com/projects/connect4.py">Download</a>]</p>
<p>Download the above file and open it. Enter an time you want the AI to search for an solution. For example, enter 5 for 5 seconds.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.psychobolt.com/connect-4-game/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

