<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-1889118801038039949</id><updated>2011-04-21T20:51:32.931-07:00</updated><title type='text'>Christos' CSC236 SLOG</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>15</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-8468226271910320749</id><published>2008-12-05T17:09:00.000-08:00</published><updated>2008-12-05T18:18:13.906-08:00</updated><title type='text'>Polya's steps to solving a problem</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;I chose Problem # 1 from Assignment # 2 (that was originally Problem # 4 from Assignment # 1). I will present my solution using Polya's prescription for solving problems. &lt;/span&gt;&lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;The problem is the following:&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;Define the set of ternary trees T_3 as:&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;(a) The empty tree, \lambda, is an element of T_3,&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;(b) If trees T_L, T_M, T_R are elements of T_3 having no nodes in common, and R is a node that is not in T_L, T_M or T_R then T = (R, T_L, T_M, T_R) is an element of T_3. We call T_L the left subtree, T_M the middle subtree and T_R the right subtree, of T.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: center;"&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;For arbitrary natural number n, find a (possibly recursive) formula for the number of non-equivalent ternary trees with n nodes. Prove that your formula is correct.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;Polya's four steps are:&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;1) Understanding the problem.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;2) Devising a plan.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;3) Carrying out the plan.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;4) Looking back.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;1) First I had to read the problem carefully and make sure I understood what was asked. Understanding the definition of a ternary tree and what consists an equivalent ternary tree is key in order to avoid duplicates. &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;2) My first reaction was to draw the ternary trees with a small number of nodes say up to four or five nodes. I was expecting a pattern to emerge that would help me come up with the formula. Then I would have to prove that formula correct. &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;3) I started drawing the ternary trees with zero, one and two nodes. I got 1, 1 and 3 respectively. The I started drawing trees with three nodes. Things started to look a bit more complicated but nothing too hard. The total number was 12. When I moved to four nodes things got messy. I was working hard to avoid duplicates. I got 55 ternary trees with four nodes. &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;Just to get an idea of what my drawings looked like, here is a picture of some of the ternary trees with four nodes:&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 320px; height: 240px;" src="http://2.bp.blogspot.com/_wq-739a49rQ/STnZcjukBLI/AAAAAAAAAAM/I78V-7WjtK4/s320/DSC01134.JPG" border="0" alt="" id="BLOGGER_PHOTO_ID_5276487523091350706" /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; When I moved to n=5, after hours and hours of careful drawing, I got 300 ternary trees. I talked to Professor Heap and he told me that the correct number for n=5 is 273. So I was not able to avoid duplicates. I spent more hours trying to figure out where I went wrong. I managed to find the problem (symmetry was to blame together with carelessness on my part). Even with the correct number I was not able to find a pattern. Clearly my plan was not working.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;4) Looking back, it's obvious that my plan was not working. I had to come up with a new plan. The next thing that came to my mind was to approach the problem with a combinatorial perspective. So, I went back to step 3.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;3) Here is a proof of the problem using a combination of combinatorics and complete induction: &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="border-collapse: collapse; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;First let T(n) be the number of ternary trees with n nodes.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;blockquote type="cite"&gt;&lt;span class="Apple-style-span" style="border-collapse: collapse; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;The recursive formula that gives the number of ternary trees with n nodes is:&lt;br /&gt;&lt;br /&gt;(i)  T(n) = 1, for n=0&lt;br /&gt;(ii) T(n) = Sum_i={0}^{n-1}Sum_j={0}^{n-1-&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;&lt;wbr&gt;i}[T(i)*T(j)*T((n-1)-(i+j))], for n&gt;0&lt;br /&gt;&lt;br /&gt;A ternary tree has the root note and a left subtree, a middle subtree and a &lt;br /&gt;right subtree. Any of the subtrees can be the empty tree with zero nodes. In the&lt;br /&gt;forumla above i stands for the number of nodes the left subtree can have and&lt;br /&gt;of course it can have zero nodes up to (n-1) nodes (the other is the root node). &lt;br /&gt;j is for the number of nodes that the middle subtree can have. In this case, j&lt;br /&gt;can be zero, all the way up to (n-1)-i. Note that after i and j are selected,&lt;br /&gt;the number of nodes that the right subtree has is determined since all of the &lt;br /&gt;nodes must add up to (n-1).&lt;br /&gt;&lt;br /&gt;Next, I will prove the following statement (claim),&lt;br /&gt;&lt;br /&gt;P(n): "The recursive formula above gives the number of ternary trees with n &lt;br /&gt;      nodes."&lt;br /&gt;&lt;br /&gt;Proof (using the principle of complete induction):&lt;br /&gt;&lt;br /&gt;Base Case:             For n=0, when we have zero nodes, we have only one&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;       possibility, the empty tree. The recursive forumla above&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;       also tells us that T(0)=1 so P(0) holds.&lt;br /&gt;&lt;br /&gt;Induction hypothesis:  Assume that the formula is correct for ternary trees with&lt;br /&gt;                      one node, for ternary trees with two nodes, for ternary&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;       trees with three nodes, ..., for ternary trees with (n-2)&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;       nodes, for ternary trees with (n-1) nodes. That is, we &lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;       assume that all of P(1), P(2), P(3),..., P(n-1) are true.&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="white-space: pre; "&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;span class="Apple-style-span" style="font-size: medium;"&gt;       &lt;br /&gt;Now consider ternary trees with n nodes. If we exclude the root node, we have&lt;br /&gt;(n-1) nodes to distribute among the subtrees. When the number of nodes for the &lt;br /&gt;left and middle subtrees is determined, the number of nodes for the right&lt;br /&gt;subtree is also determined because they need to add up to n-1. So, if we have i&lt;br /&gt;nodes in the left subtree and j in the middle one, the right subtree has &lt;br /&gt;(n-1)-(i+j) nodes. The total number of subtrees for this particular case (for&lt;br /&gt;specific i and specific j) is the number of the different combinations of left,&lt;br /&gt;middle and right subtrees. We know that we get the total number of combinations &lt;br /&gt;by multiplying them. So, for a specific i and a specific j, the total number is&lt;br /&gt;given by T(i)*T(j)*T((n-1)-(i+j)). That's the expression we have inside the &lt;br /&gt;double sum. So, at each step, the formula counts the total number of ternary &lt;br /&gt;trees when we have i nodes in the left subtree, j nodes in the middle subtree &lt;br /&gt;and the remaining nodes in the right subtree. Note that i, j as well as&lt;br /&gt;(n-1)-(i+j) get values from zero to n-1 (including the end points), therefore&lt;br /&gt;they are in the range we want them to be for us to be able to use the induction&lt;br /&gt;hypothesis.&lt;br /&gt;&lt;br /&gt;So, by our assumption, we know that we have the correct number of ternary trees &lt;br /&gt;with one node, with two nodes, ..., with (n-1) nodes. Thus, we are considering &lt;br /&gt;all the different cases and at each case we have the mutliple of three numbers&lt;br /&gt;that we know are correct by our assumption.&lt;br /&gt;&lt;br /&gt;Therefore, we have that \forall n \in N, {P(0), P(1), ..., P(n-1)} \implies P(n) &lt;br /&gt;and we hence, by the principle of complete induction, we can conclude that P(n)&lt;br /&gt;holds for all natural numbers n. That is, we can conclude that the recursive&lt;br /&gt;formula defined in the beginning of the problem gives us the number of ternary &lt;span class="Apple-style-span" style="border-collapse: separate; -webkit-text-stroke-width: -1; "&gt;trees with n nodes, for all natural numbers n.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/blockquote&gt;&lt;blockquote type="cite"&gt;&lt;br /&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-8468226271910320749?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/8468226271910320749/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=8468226271910320749' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/8468226271910320749'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/8468226271910320749'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/12/polyas-steps-to-solving-problem.html' title='Polya&apos;s steps to solving a problem'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_wq-739a49rQ/STnZcjukBLI/AAAAAAAAAAM/I78V-7WjtK4/s72-c/DSC01134.JPG' height='72' width='72'/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-1155076277036632110</id><published>2008-12-05T16:35:00.000-08:00</published><updated>2008-12-05T16:50:30.361-08:00</updated><title type='text'>Week 13 - Thursday Dec 04, 2008</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: arial;"&gt;Last week of the term! I can't believe we are in December already. It's true, time does fly.&lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;We had test # 3 this week and it went very well. It was a fair test just like the other two tests we had for this course. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;After the test we continued with PDAs and at the end of the class, the professor talked a little bit about the exam. I expect the exam to be straight forward. This year my  exam schedule looks great I have lots of days to study in between the exams.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;Looking back, this was my favorite course for the semester (just like CSC165 last year). I enjoyed the lectures and found the material very interesting. I even enjoyed most of the homework problems! &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;Good luck on the exam everyone and happy holidays!&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;PS I still need to post a solution to a problem using Polya's steps.&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-1155076277036632110?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/1155076277036632110/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=1155076277036632110' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1155076277036632110'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1155076277036632110'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/12/week-13-thursday-dec-04-2008.html' title='Week 13 - Thursday Dec 04, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-7074585184218415199</id><published>2008-12-01T12:13:00.000-08:00</published><updated>2008-12-01T12:24:00.836-08:00</updated><title type='text'>Week 12 - Thursday Nov 27, 2008</title><content type='html'>&lt;span style="font-family: arial;"&gt;Another week gone by, we are getting closer and closer to the end of this semester.&lt;br /&gt;&lt;br /&gt;In this lecture we first saw the Pumping Lemma. I was a little bit confused in the beginning but after going over it in a couple of examples with Professor Heap I was able to understand what was really going on. I think it's very useful to have something to test whether a language is regular.&lt;br /&gt;&lt;br /&gt;With that, we concluded Chapter 7 and we moved to a new topic: context-free grammars.&lt;br /&gt;&lt;br /&gt;For some reason I really enjoyed constructing strings by following a set of rules. I found it really cool! The last few lectures were very interesting. I think I need to consider applying for the AI Subject POSt.&lt;br /&gt;&lt;br /&gt;Test # 3, the final test for this class is in a couple of days. It covers the material from Chapter 7. I have to say that I find the material interesting but at the same time a little hard. We will see how it will go, I am not too worried about it.&lt;br /&gt;&lt;br /&gt;I have a term paper for my Language and Society class due tomorrow (to go with the test for the same class) so I better continue my search for journals and articles!&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-7074585184218415199?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/7074585184218415199/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=7074585184218415199' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/7074585184218415199'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/7074585184218415199'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/12/week-12-thursday-nov-27-2008.html' title='Week 12 - Thursday Nov 27, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-6359510332824552130</id><published>2008-11-25T12:26:00.000-08:00</published><updated>2008-11-25T12:49:35.101-08:00</updated><title type='text'>Week 11 - Thursday Nov 20, 2008</title><content type='html'>&lt;span style="font-family: arial;"&gt;We started with a proof that was owed from the week before. Professor Heap proved the correctness of the DFSA we saw last week (accepting binary strings that are multiples of three). The proof used structural induction on string x.&lt;br /&gt;&lt;br /&gt;We continued the lecture with NFSAs. We saw that every regular expression has an FSA (if we allow empty transitions) and that every NFSA defines a DFSA.&lt;br /&gt;&lt;br /&gt;We also looked at the cartesian product method (if you paid attention to that then Problem # 4 on Assignment # 3 was easy to do).&lt;br /&gt;&lt;br /&gt;Assignment # 3, the last assignment for this course was due Monay, Nov 24 (so it was due yesterday as I am posting this on Tuesday, Nov 25). I found this HW the easiest of the three. The hardest problem for me was Problem # 2, where we had several regular expressions and we had to prove whether or not the regular expressions denoted a language L (L was the set of all binary strings with an even number of 1s). Most of the times I can see if a regex denotes a language with a certain property but I have a hard time proving it. I guess that's always the case. I am getting better though because Problem Set # 6 dealt with this thing and Problem # 2 of Assignment # 2 and we saw an example of this in class. Practice makes perfect.&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-6359510332824552130?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/6359510332824552130/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=6359510332824552130' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/6359510332824552130'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/6359510332824552130'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/11/week-11-thursday-nov-20-2008.html' title='Week 11 - Thursday Nov 20, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-1259686550887377952</id><published>2008-11-13T22:10:00.000-08:00</published><updated>2008-11-13T22:21:08.993-08:00</updated><title type='text'>Week 10 - Nov 13, 2008</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: arial;"&gt;We got Test 2 back today and I got exactly what I thought I would get. Not bad but not as good as Test 1. The important thing is that I know what my mistakes are and I also know how to avoid them. That's all I have to say about Test 2.&lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;In the lecture this week we saw DFSA (Deterministic Finite State Automata). Drawing states and arrows seems fun! &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;I really liked that fact that you can represent a language using a DFSA quite easily. We saw how hard it was to express (L1 \intersection L2) using a regular expression but we came up with the DFSA for it fairly easily. L1 was the language that contained all binary strings with an even number of zeroes and L2 the language that contained all binary strings with an odd number of ones. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;We did not see a proof of the correctness of the DFSA but it's something we will see next week. The professor felt that it was too late for that proof and that it was better suited for the first hour of next week's lecture. Couldn't agree more!&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-1259686550887377952?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/1259686550887377952/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=1259686550887377952' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1259686550887377952'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1259686550887377952'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/11/week-10-nov-13-2008.html' title='Week 10 - Nov 13, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-6578202563810672300</id><published>2008-11-11T15:44:00.000-08:00</published><updated>2008-11-11T15:54:05.737-08:00</updated><title type='text'>Week 9 - Thursday Nov 07, 2008</title><content type='html'>&lt;span style="font-family: arial;"&gt;Test 2!&lt;br /&gt;&lt;br /&gt;We had test #2 this week and I found it very fair. There were three problems all of them not hard. Professor Heap really knows how to write fair tests. It's as simple as that.&lt;br /&gt;&lt;br /&gt;Of course, I ran out of time and didn't have time to finish Problem 3 but that's pretty much the case with all of my tests. I really need to learn how to: 1) manage my time during a test more efficiently and 2) leave out the extra details from my answers.&lt;br /&gt;&lt;br /&gt;Other than the test, we started on Chapter 7 that deals with Languages, Regular Expressions and FSAs. Problem Set #5 is due this week and it has to do with the new material. I read the notes and I find the subject very interesting but a little bit confusing too. We will see how things will evolve. I am looking forward to the next lecture.&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-6578202563810672300?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/6578202563810672300/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=6578202563810672300' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/6578202563810672300'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/6578202563810672300'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/11/week-9-thursday-nov-07-2008.html' title='Week 9 - Thursday Nov 07, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-7272093090989048882</id><published>2008-11-04T22:10:00.000-08:00</published><updated>2008-11-04T22:18:51.383-08:00</updated><title type='text'>Week 8 - Thursday Oct 30, 2008</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: arial;"&gt;This week we continued looking at the correctness of algorithms. We moved from recursive correctness to iterative correctness. I don't have much to write today. I would just like to say that I found the iterative case much harder than the recursive case. I don't know why the idea is very similar. Just go through the code line by line and prove it works, prove that it does what we want it to do. &lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;Test 2 is on Thursday and I am a little worried because I do not feel well prepared. I still have a day to study but with three other assignments due in the next two days I am trying to juggle everything and so far I seem to be terrible at juggling...&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-7272093090989048882?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/7272093090989048882/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=7272093090989048882' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/7272093090989048882'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/7272093090989048882'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/11/week-8-thursday-oct-30-2008.html' title='Week 8 - Thursday Oct 30, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-1123533199008330497</id><published>2008-10-27T21:36:00.000-07:00</published><updated>2008-10-27T21:45:59.446-07:00</updated><title type='text'>Week 7 - Thursday Oct 23, 2008</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: arial;"&gt;Week 7 is gone. Time flies, that's for sure. I survived the worst week of this semester so I am happy about that. &lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;The deadline of Assignment 2 was approaching and I was glad I solved the ternary trees question a long time ago. It seemed that it was the hardest problem and it took everybody quite some time to figure it out.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;In the lecture we saw the correctness of algorithms. We looked at the binary search algorithm and we proved it's correct and we did the same with Euclid's algorithm for the gcd. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;Test 2 is coming up (in about a week) so I need to review the material. &lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-1123533199008330497?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/1123533199008330497/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=1123533199008330497' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1123533199008330497'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1123533199008330497'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/10/week-7-thursday-oct-23-2008.html' title='Week 7 - Thursday Oct 23, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-8530825109893948541</id><published>2008-10-19T18:10:00.000-07:00</published><updated>2008-10-19T18:26:28.715-07:00</updated><title type='text'>Week 6 - Thursday Oct 16, 2008</title><content type='html'>&lt;span style="font-family: arial;"&gt;Week 6 is already gone. Time really flies and that's not a bad thing as this week, i.e week 7, I have 4 midterms in three days, I have and three assignments.Too much work!&lt;br /&gt;&lt;br /&gt;Anyways, the lecture was shorter this week because the morning section missed the Monday lecture, it was Thanksgiving day. No complaints there, it was nice to finish at 20:00 instead of 21:00.&lt;br /&gt;&lt;br /&gt;We talked about two things:&lt;br /&gt;1) The time complexity of merge sort (n*log(n)).&lt;br /&gt;2) The master theorem.&lt;br /&gt;&lt;br /&gt;The master theorem basically gives the time complexity for divide-and-conquer algorithms. If you can write the time complexity of an algorithm in a specific recursive way then you can use the master theorem to get a bound on the time complexity of the algorithm.&lt;br /&gt;&lt;br /&gt;We also got Test 1 back and handed in Problem Set 3. Problem Set 3 was not hard, you just needed to follow an example we saw in class and then you could get the closed form that was needed. I learned that a finite sum is not considered closed form if it grows in n. I was wrong to think that infinite sums are not considered closed-form but finite are.&lt;br /&gt;&lt;br /&gt;Test 1 went OK. I made a stupid mistake that I now realize I was doing often when I was using the principle of complete induction. Need to be more careful from now on. Other than that, I was happy with my test.&lt;br /&gt;&lt;br /&gt;I think I am writing just to avoid studying for CSC260 so I better stop here.&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-8530825109893948541?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/8530825109893948541/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=8530825109893948541' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/8530825109893948541'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/8530825109893948541'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/10/week-6-thursday-oct-16-2008.html' title='Week 6 - Thursday Oct 16, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-1113042512957070615</id><published>2008-10-10T08:42:00.000-07:00</published><updated>2008-10-10T09:06:45.528-07:00</updated><title type='text'>Week 5 - Thursday Oct 09, 2008</title><content type='html'>&lt;span style="font-family:arial;"&gt;Attempt #2&lt;br /&gt;&lt;br /&gt;Firefox crashed on me and took my post with it to the realms of the unknown. This re-post is going to be significantly shorter than the previous one because I am still mad at Firefox...&lt;br /&gt;&lt;br /&gt;Week 5 ended and Test 1 is a thing of the past. This week we looked at structural induction, a flavor of induction that I found both more challenging and more interesting. We also looked at more recursive formulas and their closed forms. Specifically we saw how the Fibonacci sequence is related to the golden ratio. Interesting stuff I tell you! It makes me want to see Pi again...&lt;br /&gt;&lt;br /&gt;As for test 1, I found it fair. I finished just on time but it was mainly because of the way I function which is not the optimal way a human being should function.&lt;br /&gt;&lt;br /&gt;I solved one of the questions using combinatorics and I am sure it was because of the ternary trees problem on the Assignment. For a  couple of weeks now all I do is count stuff and make sure I subtract the duplicates! I think I did well, I will see if the TAs agree with me sometime soon.&lt;br /&gt;&lt;br /&gt;Have a great weekend and happy thanksgiving to all!&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-1113042512957070615?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/1113042512957070615/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=1113042512957070615' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1113042512957070615'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1113042512957070615'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/10/week-5-thursday-oct-09-2008.html' title='Week 5 - Thursday Oct 09, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-6606289648788347888</id><published>2008-10-05T10:56:00.001-07:00</published><updated>2008-10-05T11:15:04.110-07:00</updated><title type='text'>Week 4 - Thursday Oct 02, 2008</title><content type='html'>&lt;span style="font-family: arial;"&gt;This week was all about recursion and how it's related to induction. We looked at the Fibonacci sequence, a very interesting sequence that appears pretty much everywhere: in nature, in the golden ration etc.&lt;br /&gt;&lt;br /&gt;We looked at the sum of n Fibonacci numbers and found that it's given by F(n+2) - 1. The interesting thing is that when defining the Fibonacci numbers, you need two base cases, but when we proved the formula above we only used one.&lt;br /&gt;&lt;br /&gt;Test 1 is coming next Thursday so it's time for a quick review of everything we covered so far in the course. I should have done that over the weekend but I decided to just rest and spend some time with my family.&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-6606289648788347888?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/6606289648788347888/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=6606289648788347888' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/6606289648788347888'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/6606289648788347888'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/10/week-4-thursday-oct-02-2008.html' title='Week 4 - Thursday Oct 02, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-2210508022362523395</id><published>2008-09-27T13:33:00.000-07:00</published><updated>2008-10-05T11:03:14.740-07:00</updated><title type='text'>Week 3 - Thursday Sep 25, 2008</title><content type='html'>&lt;span style="font-family:arial;"&gt;Week 3 is gone already. We had to hand in Problem Set 2 on Thursday. It wasn't hard, the problem was very similar to one of the examples we saw in class last week.&lt;br /&gt;&lt;br /&gt;Assignment 1 is due this coming Monday and I am done. Problem 4 on the assignment is now due sometime in October. The assignment in general was a little bit challenging but Problem 4 is giving me some trouble. I have been thinking about it pretty much every day and I still can't figure it out.&lt;br /&gt;&lt;br /&gt;For those who are interested, we are asked to find a (recursive) formula for the number of ternary trees with n nodes. I started drawing trees on paper (I always start drawing pictures, it helps me understand the problem and gives me an idea of how to proceed, though in this case the picture did not help me with the latter...&lt;br /&gt;&lt;br /&gt;So for n=5 I was getting 300 trees instead of 273 and I until last night, I was unable to see where I was generating the duplicates. Talk about frustration...I was ready to explode until I spotted the duplications...Anyways, I am happy I figured where I was making the mistake but now I need to come up with a way to count them without producing duplicates. I am done with drawing trees for at least a couple of weeks!&lt;br /&gt;&lt;br /&gt;In class this week as continued with induction and the Principle of Well Ordering (PWO). We saw that if you believe one of PSI, PCI or PWO then you should accept all three because they are somewhat equivalent you can show that PWO implies the PSI that in turn implies the PCI.&lt;br /&gt;&lt;br /&gt;During the last hour of the lecture professor Heap presented three proofs that were all wrong and we had to spot the subtle mistakes. The most interesting for me was the one with the hexagons. The professor told us that it was similar to a famous false proof that all horses are of the same color. If you are like stuff like this, google: proof + "all horses are" and you will find the proof.&lt;br /&gt;&lt;br /&gt;Hm, a long post this week. I think it's because I am trying to avoid thinking about ternary trees...&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-2210508022362523395?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/2210508022362523395/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=2210508022362523395' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/2210508022362523395'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/2210508022362523395'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/09/week-3.html' title='Week 3 - Thursday Sep 25, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-6399004165133924423</id><published>2008-09-18T20:17:00.000-07:00</published><updated>2008-09-18T20:28:19.155-07:00</updated><title type='text'>Week 2 - Thursday Sep 18, 2008</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: arial;"&gt;Hm, I got home from class and I am really tired. I used to be a night person but I guess not anymore...I am considering switching to the morning section.&lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;The first problem set was due today and I found it to be on the easy side. The first homework is already out and I started working on it. It's definitely harder than the problem set but at the same time way more interesting. I really like the second and (especially) the third problem.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;In the lecture today we talked about complete induction. I understand that for certain problems it makes more sense to use complete induction but I don't like it as much I like the PSI. I find simple induction more logical. I am sure most of the people will disagree with me.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;I was having a hard time following the example with the trees. I consider myself green but for some reason I always have a hard time with trees. I really need to sit down and get more familiar with trees because I am sure I will see them again soon...&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-6399004165133924423?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/6399004165133924423/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=6399004165133924423' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/6399004165133924423'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/6399004165133924423'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/09/week-2-thursday-sep-18-2008.html' title='Week 2 - Thursday Sep 18, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-1133660892920677615</id><published>2008-09-13T20:11:00.000-07:00</published><updated>2008-09-13T20:31:10.059-07:00</updated><title type='text'>Week 1 - Thursday Sep 11, 2008</title><content type='html'>&lt;span class="Apple-style-span"  style="font-family:arial;"&gt;We had the first lecture and since I attend the evening section, the class is three hours long. I like the new style of the lectures with Professor Heap using his tablet.&lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:arial;"&gt;We went over the course information stuff and then we started with the principle of simple induction. We saw a couple of examples, like the one that we had to prove that  the units digit of 3^n belongs to the set {1,3,7,9}.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:arial;"&gt;In my opinion the most interesting was the one with the number of subsets of odd size of a set with n elements. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:arial;"&gt;Excluding zero, you can use induction to show that we have 2^(n-1) subsets of odd size. There was another clever approach to the proof that was suggested by one of our classmates. It used the 1-1 correspondence of the subsets of odd size to the subsets of even size.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-family:arial;"&gt;Problem Set 1 is due next week so I have to start this weekend!&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-1133660892920677615?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/1133660892920677615/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=1133660892920677615' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1133660892920677615'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/1133660892920677615'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/09/week-1-thursday-sep-11-2008.html' title='Week 1 - Thursday Sep 11, 2008'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1889118801038039949.post-7856920438066031582</id><published>2008-09-13T19:49:00.000-07:00</published><updated>2008-09-13T20:04:22.773-07:00</updated><title type='text'>Welcome!</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: arial;"&gt;Hello everybody and welcome to my SLOG. For those who are wondering, SLOG comes from selectively picking letters from the following two words: course log. &lt;/span&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;This is my second time slogging as I did the same thing last year for CSC165. I have to admit that in the beginning I was not looking forward to having to write about the class. By the end of the year I came to appreciate it.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: arial;"&gt;Well, once again, welcome to my SLOG . I am looking forward to the new school year and to all the interesting stuff we will discuss in CSC236.&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1889118801038039949-7856920438066031582?l=christos-csc236-slog.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://christos-csc236-slog.blogspot.com/feeds/7856920438066031582/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=1889118801038039949&amp;postID=7856920438066031582' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/7856920438066031582'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1889118801038039949/posts/default/7856920438066031582'/><link rel='alternate' type='text/html' href='http://christos-csc236-slog.blogspot.com/2008/09/welcome.html' title='Welcome!'/><author><name>Christos</name><uri>http://www.blogger.com/profile/08948001212716147397</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
