<?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-4855694620634958911</id><updated>2011-04-21T14:50:56.656-07:00</updated><category term='Artificial Intelligence'/><category term='Book Review'/><category term='Bayesian Classification'/><title type='text'>ALGORITHM?</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://algorithmus.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://algorithmus.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>ghatak,kausik</name><uri>http://www.blogger.com/profile/07007827973529310642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://1.bp.blogspot.com/_RWYRe3pO0To/SZCumhUU67I/AAAAAAAAAE4/60bgb2yDP3A/S220/DSC00366B.JPG'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>8</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-4855694620634958911.post-2910690506886707155</id><published>2009-04-14T09:46:00.000-07:00</published><updated>2009-04-14T10:08:12.303-07:00</updated><title type='text'>Lake</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_RWYRe3pO0To/SeS-MuyD-3I/AAAAAAAAAHY/jwqLWVQaPi8/s1600-h/IMG-a.jpg"&gt;&lt;img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 288px; DISPLAY: block; HEIGHT: 400px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5324589785384483698" border="0" alt="" src="http://4.bp.blogspot.com/_RWYRe3pO0To/SeS-MuyD-3I/AAAAAAAAAHY/jwqLWVQaPi8/s400/IMG-a.jpg" /&gt;&lt;/a&gt; Acrylic on canvas cloth&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4855694620634958911-2910690506886707155?l=algorithmus.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://algorithmus.blogspot.com/feeds/2910690506886707155/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4855694620634958911&amp;postID=2910690506886707155' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/2910690506886707155'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/2910690506886707155'/><link rel='alternate' type='text/html' href='http://algorithmus.blogspot.com/2009/04/lake.html' title='Lake'/><author><name>ghatak,kausik</name><uri>http://www.blogger.com/profile/07007827973529310642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://1.bp.blogspot.com/_RWYRe3pO0To/SZCumhUU67I/AAAAAAAAAE4/60bgb2yDP3A/S220/DSC00366B.JPG'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_RWYRe3pO0To/SeS-MuyD-3I/AAAAAAAAAHY/jwqLWVQaPi8/s72-c/IMG-a.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4855694620634958911.post-394070976537492816</id><published>2009-04-14T09:28:00.000-07:00</published><updated>2009-04-14T09:44:15.452-07:00</updated><title type='text'>Nature</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_RWYRe3pO0To/SeS69GSZqxI/AAAAAAAAAHQ/jnKQzF1S8rw/s1600-h/IMG_0001-a.jpg"&gt;&lt;img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 290px; DISPLAY: block; HEIGHT: 400px; CURSOR: hand" id="BLOGGER_PHOTO_ID_5324586218281347858" border="0" alt="" src="http://4.bp.blogspot.com/_RWYRe3pO0To/SeS69GSZqxI/AAAAAAAAAHQ/jnKQzF1S8rw/s400/IMG_0001-a.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div&gt;&lt;a href="http://3.bp.blogspot.com/_RWYRe3pO0To/SeS5_DK4AyI/AAAAAAAAAHI/A_uEVAdB7YY/s1600-h/IMG_0001-a.jpg"&gt;&lt;/a&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;Acrylic on canvas paper - Finger Paint&lt;br /&gt;&lt;br /&gt;&lt;div&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/4855694620634958911-394070976537492816?l=algorithmus.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://algorithmus.blogspot.com/feeds/394070976537492816/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4855694620634958911&amp;postID=394070976537492816' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/394070976537492816'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/394070976537492816'/><link rel='alternate' type='text/html' href='http://algorithmus.blogspot.com/2009/04/nature.html' title='Nature'/><author><name>ghatak,kausik</name><uri>http://www.blogger.com/profile/07007827973529310642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://1.bp.blogspot.com/_RWYRe3pO0To/SZCumhUU67I/AAAAAAAAAE4/60bgb2yDP3A/S220/DSC00366B.JPG'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_RWYRe3pO0To/SeS69GSZqxI/AAAAAAAAAHQ/jnKQzF1S8rw/s72-c/IMG_0001-a.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4855694620634958911.post-5968288023399055376</id><published>2009-03-31T22:01:00.000-07:00</published><updated>2009-03-31T22:03:48.256-07:00</updated><title type='text'>Painting Brahmaputra - Majuli, India</title><content type='html'>&lt;a href="http://3.bp.blogspot.com/_RWYRe3pO0To/SdL1hAaKM9I/AAAAAAAAAGw/G12G3FKIt5I/s1600-h/DSC00410.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5319584057272185810" style="DISPLAY: block; MARGIN: 0px auto 10px; WIDTH: 370px; CURSOR: hand; HEIGHT: 336px; TEXT-ALIGN: center" alt="" src="http://3.bp.blogspot.com/_RWYRe3pO0To/SdL1hAaKM9I/AAAAAAAAAGw/G12G3FKIt5I/s400/DSC00410.JPG" border="0" /&gt;&lt;/a&gt;                               Pastle on paper&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4855694620634958911-5968288023399055376?l=algorithmus.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://algorithmus.blogspot.com/feeds/5968288023399055376/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4855694620634958911&amp;postID=5968288023399055376' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/5968288023399055376'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/5968288023399055376'/><link rel='alternate' type='text/html' href='http://algorithmus.blogspot.com/2009/03/painting-brahmaputra-majuli-india.html' title='Painting Brahmaputra - Majuli, India'/><author><name>ghatak,kausik</name><uri>http://www.blogger.com/profile/07007827973529310642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://1.bp.blogspot.com/_RWYRe3pO0To/SZCumhUU67I/AAAAAAAAAE4/60bgb2yDP3A/S220/DSC00366B.JPG'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_RWYRe3pO0To/SdL1hAaKM9I/AAAAAAAAAGw/G12G3FKIt5I/s72-c/DSC00410.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4855694620634958911.post-8383574164230598666</id><published>2009-03-31T21:54:00.000-07:00</published><updated>2009-03-31T22:00:48.009-07:00</updated><title type='text'>Painting Aasam, India</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_RWYRe3pO0To/SdL0Mz1GV_I/AAAAAAAAAGo/_-hIycHs1yY/s1600-h/DSC00408.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5319582610786506738" style="DISPLAY: block; MARGIN: 0px auto 10px; WIDTH: 400px; CURSOR: hand; HEIGHT: 307px; TEXT-ALIGN: center" alt="" src="http://2.bp.blogspot.com/_RWYRe3pO0To/SdL0Mz1GV_I/AAAAAAAAAGo/_-hIycHs1yY/s400/DSC00408.JPG" border="0" /&gt;&lt;/a&gt;                            Pastle on paper&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4855694620634958911-8383574164230598666?l=algorithmus.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://algorithmus.blogspot.com/feeds/8383574164230598666/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4855694620634958911&amp;postID=8383574164230598666' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/8383574164230598666'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/8383574164230598666'/><link rel='alternate' type='text/html' href='http://algorithmus.blogspot.com/2009/03/painting-aasam-india.html' title='Painting Aasam, India'/><author><name>ghatak,kausik</name><uri>http://www.blogger.com/profile/07007827973529310642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://1.bp.blogspot.com/_RWYRe3pO0To/SZCumhUU67I/AAAAAAAAAE4/60bgb2yDP3A/S220/DSC00366B.JPG'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_RWYRe3pO0To/SdL0Mz1GV_I/AAAAAAAAAGo/_-hIycHs1yY/s72-c/DSC00408.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4855694620634958911.post-1750753109331445523</id><published>2009-03-31T19:13:00.000-07:00</published><updated>2009-04-01T10:31:46.167-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Bayesian Classification'/><category scheme='http://www.blogger.com/atom/ns#' term='Artificial Intelligence'/><category scheme='http://www.blogger.com/atom/ns#' term='Book Review'/><title type='text'>Effective review and its depiction:</title><content type='html'>I was thinking what makes a review effective and I put my ideas below using an example of book-review.&lt;br /&gt;&lt;br /&gt;A book review in the context of this discussion (what is an effective book review) has two generic types – one in which the reviewer provides his background along with how he likes or dislikes the book and the other in which the reviewer provides same information on the book without mentioning his background.&lt;br /&gt;&lt;br /&gt;Arguments can be used to deduce that the reviews containing reviewer’s background information are more useful for new users in making a decision (such as to read or to buy) compared to the reviews which do no contain reviewer’s background information.&lt;br /&gt;&lt;br /&gt;A typical argument could be explained by considering a review of a book on a subject like artificial intelligence done by two reviewers. Since the book uses good amount of statistics we collect the background information of the two reviewers focusing their exposures to statistics. We assume for the clarity of this explanation that one reviewer say R1 is expert in statistics while other say R2 does not have any exposure to statistics. Now we can see various effects of the reviews on a user’s decision from the table below. For ease of understanding we also assume there are two users who use the reviews to make their decision and one of the users say U1 has an expert level understanding on statistics while other say U2 has no exposure to statistics at all.&lt;br /&gt;&lt;br /&gt;&lt;table bordercolor="white" border="1"&gt;&lt;tbody&gt;&lt;br /&gt;&lt;tr&gt;&lt;th&gt;R1’s rating&lt;/th&gt;&lt;th&gt;R2’s rating&lt;/th&gt;&lt;th&gt;Without reviewers’ background&lt;/th&gt;&lt;th&gt;With reviewers’ background&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;High &lt;/td&gt;&lt;td&gt;High &lt;/td&gt;&lt;td&gt;U1 decides to buy&lt;/td&gt;&lt;td&gt;U1 decides to buy&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;High &lt;/td&gt;&lt;td&gt;High &lt;/td&gt;&lt;td&gt;U2 decides to buy&lt;/td&gt;&lt;td&gt;U2 decides to buy&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;High &lt;/td&gt;&lt;td&gt;Low&lt;/td&gt;&lt;td&gt;&lt;span style="color:#ffcc33;"&gt;U1 confused&lt;/span&gt;&lt;/td&gt;&lt;td&gt;U1 decides to buy&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;High&lt;/td&gt;&lt;td&gt;Low&lt;/td&gt;&lt;td&gt;&lt;span style="color:#ffcc33;"&gt;U2 confused&lt;/span&gt;&lt;/td&gt;&lt;td&gt;U2 decides NOT to buy&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Low&lt;/td&gt;&lt;td&gt;High&lt;/td&gt;&lt;td&gt;&lt;span style="color:#ffcc33;"&gt;U1 confused&lt;/span&gt;&lt;/td&gt;&lt;td&gt;U1 decides NOT to buy&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Low &lt;/td&gt;&lt;td&gt;High&lt;/td&gt;&lt;td&gt;&lt;span style="color:#ffcc33;"&gt;U2 confused&lt;/span&gt;&lt;/td&gt;&lt;td&gt;U2 decides to buy&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Low&lt;/td&gt;&lt;td&gt;Low&lt;/td&gt;&lt;td&gt;U1 decides NOT to buy&lt;/td&gt;&lt;td&gt;U1 decides NOT to buy&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Low&lt;/td&gt;&lt;td&gt;Low&lt;/td&gt;&lt;td&gt;U2 decides NOT to buy&lt;/td&gt;&lt;td&gt;U2 decides NOT to buy&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;&lt;br /&gt;We can see that when R1's and R2’s backgrounds are exposed to users, U1 finds R1 having similar background to him and that R2 doesn’t not have his background. This causes U1 to be influenced by R1’s reviews and to be unaffected by R2’s review. Similarly U2 gets influenced by R2 and stays unaffected by R1. Under this argument we see that a decision is made in all situations when reviewer’s background is exposed (see 4th column of the table above).&lt;br /&gt;&lt;br /&gt;The assumption that similar background has higher influence and the argument provided above reveals few interesting information.&lt;br /&gt;&lt;br /&gt;1) A review can be more effective if it contains reviewers’ background information.&lt;br /&gt;2) A close relation to Bayesian Classification can be established.&lt;br /&gt;Pr (buy  background) = Pr (background  buy) x Pr (buy) / Pr (background)&lt;br /&gt;&lt;br /&gt;A more effective review summary depiction would be one that contains reviewer’s background.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;A prediction system would work better if it includes reviewer’s background information.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4855694620634958911-1750753109331445523?l=algorithmus.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://algorithmus.blogspot.com/feeds/1750753109331445523/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4855694620634958911&amp;postID=1750753109331445523' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/1750753109331445523'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/1750753109331445523'/><link rel='alternate' type='text/html' href='http://algorithmus.blogspot.com/2009/03/effective-review-and-its-depiction.html' title='Effective review and its depiction:'/><author><name>ghatak,kausik</name><uri>http://www.blogger.com/profile/07007827973529310642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://1.bp.blogspot.com/_RWYRe3pO0To/SZCumhUU67I/AAAAAAAAAE4/60bgb2yDP3A/S220/DSC00366B.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4855694620634958911.post-1326701575626261898</id><published>2007-10-02T14:56:00.000-07:00</published><updated>2007-10-02T15:44:40.275-07:00</updated><title type='text'>Generating Random Number of Higher Range from Lower Range Function</title><content type='html'>I came up with a question on random number few months ago and the question was somewhat like, - How to generate a random number of ranges [1,7] from a given random number generator which produces random numbers of the range [1,5]!&lt;br /&gt;While trying to find a solution for it, I found few interesting ideas and in this article I put them down.&lt;br /&gt;&lt;br /&gt;I see generating a set of five numbers by running the given random function five times and summing them will give me a number range [5,25]. There are 21 numbers {5, 6, .. 24, 25} in this range and we can group them in 7 groups – like {5,6,7} {8,9,10} { 11,12,13} and so on. Since all we want a function to generate numbers in the range [1,7] with equal probability, we need to group the numbers in such a way that probability of occurrence of each group is same. We can then map each group with a number {1, 2.., 7} and return the associated numbers when a group occurs. Thus we can achieve a random number generator of the range [1,7]&lt;br /&gt;&lt;br /&gt;To calculate occurrences of each group we can calculate occurrence of each element in the group and add each elements occurrence group wise. Now we need a way to find out occurrences of each number from [5,25] when we run our given random generator 5 times.&lt;br /&gt;&lt;br /&gt;This is same as finding co-efficient of each terms in the expansion (x^1+x^2+...+x^5) ^5.&lt;br /&gt;&lt;br /&gt;Extending this idea we see that each group needs not to have equal elements as long as each group has same value of occurrence. In our case, to generate 7 numbers with uniform pdf (probability density function), all we need is Sg1=Sg2=...=Sg7, no matter how many elements each group has. Sg1 denotes occurrences of group one = sum of occurrences of each elements in group one. Similarly Sg2 identifies for group 2 and so on.&lt;br /&gt;&lt;br /&gt;Moreover, since Sg1=Sg2=...=Sg7, sum of all groups (∑Sg) is a multiple of 7, which means:&lt;br /&gt;[sum (coefficient of each element)] mod 7 =0 [divisible by 7]&lt;br /&gt;This is a necessary property but not enough alone. We can use this property to improve our algorithms.&lt;br /&gt;&lt;br /&gt;In general, if we run the random function with range [1,5] for k times, we get a sum of range [1.k, 5.k]. We can group all the sums in 7 groups such that Sg1=Sg2=...=Sg7 to ensure no of occurrence of each group is same. If each group maps a number from {1, 2, .. 6, 7} the probability of getting a number from [1,7] will be equal as well.&lt;br /&gt;&lt;br /&gt;Thus the problem translates into&lt;br /&gt;&lt;br /&gt;1. Finding the coefficients of the expansion (x^1+x^2+...+x^n) ^k where n=5 in our case and k is an integer such that no of terms in the expansion is more than N (in our case N=7) i.e. (n.k) ≥ N&lt;br /&gt;&lt;br /&gt;2. For a specific k, group the coefficients into N groups such that sum of coefficients in each group is same.&lt;br /&gt;&lt;br /&gt;3. If this is not possible take a new value of K where K = K +1 and repeat steps 1-2.&lt;br /&gt;&lt;br /&gt;4. Once we find a group of N satisfying the equal sum property (i.e. equi-probable) we number each group by [1,N].&lt;br /&gt;&lt;br /&gt;5. Whenever a number obtained by summing the numbers obtained by k execution of original random function belongs to a group, we return the group’s number. Since the probability that a number (sum of k trials/execution) belongs to one of the group is equal; the probability that we return a group number from [1,N] is equal. So we achieved a random function of range [1,N] from another random function [1,n] where n ≤ N&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Sample trial: n=5, N=7, k=5&lt;br /&gt;&lt;br /&gt;(x^1+x^2+x^3+x^4+x^5) ^5&lt;br /&gt;&lt;br /&gt;=x^5 + 5.x^6 + 15.x^7 + 35.x^8 + 70.x^9 + 121.x^10 + 185.x^11 + 255.x^12 + 320.x^13 + 365.x^14 + 379.x^15 + 363.x^16 + 318.x^17 + 253.x^18 + 183.x^19 + 121.x^20 + 70.x^21 + 35.x^22 + 15.x^23 + 5.x^24 + x^25&lt;br /&gt;&lt;br /&gt;Observe that ∑Sg = ∑ Coefficients =&lt;br /&gt;(1+5+15+35+70+121+185+255+320+365+379+363+318+253+183+121+70+35+15+5+1)&lt;br /&gt;=3115&lt;br /&gt;∑Sg mod N = 3115 mod 7 = 0 -- implies we may get 7 groups with sg1=sg2=…=sg7&lt;br /&gt;&lt;br /&gt;But when I tried to create 7 groups I found that its not possible to have 7 groups such that each goups sum is 445 (=3115/7) . I still tried to get the best grouping I can and is as follows&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;table bordercolor="white" border="2"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;th&gt;Group #&lt;/th&gt;&lt;th&gt;Elements in Group(co-eff. in the expansion)&lt;/th&gt;&lt;th&gt;Sum of coefficients in a group&lt;/th&gt;&lt;th&gt;Probability of a group&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;1&lt;/td&gt;&lt;td&gt;8, 15, 21&lt;/td&gt;&lt;td&gt;449&lt;/td&gt;&lt;td&gt;14.414 %&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;2&lt;/td&gt;&lt;td&gt;7, 9, 14&lt;/td&gt;&lt;td&gt;450&lt;/td&gt;&lt;td&gt;14.446 %&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;3&lt;/td&gt;&lt;td&gt;16, 21, 24&lt;/td&gt;&lt;td&gt;448&lt;/td&gt;&lt;td&gt;14.382 %&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;4&lt;/td&gt;&lt;td&gt;5, 10, 13&lt;/td&gt;&lt;td&gt;442&lt;/td&gt;&lt;td&gt;14.189 %&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;5&lt;/td&gt;&lt;td&gt;17, 20, 25&lt;/td&gt;&lt;td&gt;440&lt;/td&gt;&lt;td&gt;14.125 %&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;6&lt;/td&gt;&lt;td&gt;6, 12, 19&lt;/td&gt;&lt;td&gt;443&lt;/td&gt;&lt;td&gt;14.222 %&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;7&lt;/td&gt;&lt;td&gt;11, 18, 24&lt;/td&gt;&lt;td&gt;443&lt;/td&gt;&lt;td&gt;14.222 %&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;/td&gt;&lt;td&gt;&lt;/td&gt;&lt;td&gt;∑=3115&lt;/td&gt;&lt;td&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This means if we try our original random generator for n=5 times, we obtain a set of n values; say 4, 2, 2, 3 and 1. The sum of these values is 12. Since the coefficient of x^12 belongs to group 6, we return 6.&lt;br /&gt;&lt;br /&gt;Even when we have almost equi-probable groups, they are not perfectly same. Thus we should try with another value of k, say k=6&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4855694620634958911-1326701575626261898?l=algorithmus.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://algorithmus.blogspot.com/feeds/1326701575626261898/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4855694620634958911&amp;postID=1326701575626261898' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/1326701575626261898'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/1326701575626261898'/><link rel='alternate' type='text/html' href='http://algorithmus.blogspot.com/2007/10/generating-random-number-of-higher.html' title='Generating Random Number of Higher Range from Lower Range Function'/><author><name>ghatak,kausik</name><uri>http://www.blogger.com/profile/07007827973529310642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://1.bp.blogspot.com/_RWYRe3pO0To/SZCumhUU67I/AAAAAAAAAE4/60bgb2yDP3A/S220/DSC00366B.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4855694620634958911.post-4761333412507493634</id><published>2007-09-24T23:57:00.000-07:00</published><updated>2009-04-06T00:56:33.420-07:00</updated><title type='text'>Painting at Alki, Seattle</title><content type='html'>&lt;a href="http://2.bp.blogspot.com/_RWYRe3pO0To/Sdm1p-HjNDI/AAAAAAAAAHA/0FgluYJio4I/s1600-h/seattle-alki3.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5321484167368881202" style="DISPLAY: block; MARGIN: 0px auto 10px; WIDTH: 400px; CURSOR: hand; HEIGHT: 237px; TEXT-ALIGN: center" alt="" src="http://2.bp.blogspot.com/_RWYRe3pO0To/Sdm1p-HjNDI/AAAAAAAAAHA/0FgluYJio4I/s400/seattle-alki3.JPG" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div&gt;&lt;a href="http://2.bp.blogspot.com/_RWYRe3pO0To/Sdm1DPAqanI/AAAAAAAAAG4/YYD51WlwVss/s1600-h/seattle-alki2.JPG"&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;div&gt;&lt;a href="http://4.bp.blogspot.com/_RWYRe3pO0To/RviyIrh7PJI/AAAAAAAAAAU/BugyRN7UgmM/s1600-h/seattle-alki1.JPG"&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;div&gt;&lt;/div&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/4855694620634958911-4761333412507493634?l=algorithmus.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://algorithmus.blogspot.com/feeds/4761333412507493634/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4855694620634958911&amp;postID=4761333412507493634' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/4761333412507493634'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/4761333412507493634'/><link rel='alternate' type='text/html' href='http://algorithmus.blogspot.com/2007/09/painting-at-alki-seattle.html' title='Painting at Alki, Seattle'/><author><name>ghatak,kausik</name><uri>http://www.blogger.com/profile/07007827973529310642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://1.bp.blogspot.com/_RWYRe3pO0To/SZCumhUU67I/AAAAAAAAAE4/60bgb2yDP3A/S220/DSC00366B.JPG'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_RWYRe3pO0To/Sdm1p-HjNDI/AAAAAAAAAHA/0FgluYJio4I/s72-c/seattle-alki3.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4855694620634958911.post-2969174694547954386</id><published>2007-09-13T01:18:00.001-07:00</published><updated>2007-09-13T01:21:55.442-07:00</updated><title type='text'>Home</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_RWYRe3pO0To/RujzAS0oOSI/AAAAAAAAAAM/6HOn80xlsRU/s1600-h/DSC01844.JPG"&gt;&lt;img id="BLOGGER_PHOTO_ID_5109600963629955362" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; CURSOR: hand" alt="" src="http://4.bp.blogspot.com/_RWYRe3pO0To/RujzAS0oOSI/AAAAAAAAAAM/6HOn80xlsRU/s400/DSC01844.JPG" border="0" /&gt;&lt;/a&gt;&lt;br /&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/4855694620634958911-2969174694547954386?l=algorithmus.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://algorithmus.blogspot.com/feeds/2969174694547954386/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4855694620634958911&amp;postID=2969174694547954386' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/2969174694547954386'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4855694620634958911/posts/default/2969174694547954386'/><link rel='alternate' type='text/html' href='http://algorithmus.blogspot.com/2007/09/home.html' title='Home'/><author><name>ghatak,kausik</name><uri>http://www.blogger.com/profile/07007827973529310642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://1.bp.blogspot.com/_RWYRe3pO0To/SZCumhUU67I/AAAAAAAAAE4/60bgb2yDP3A/S220/DSC00366B.JPG'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_RWYRe3pO0To/RujzAS0oOSI/AAAAAAAAAAM/6HOn80xlsRU/s72-c/DSC01844.JPG' height='72' width='72'/><thr:total>0</thr:total></entry></feed>
