<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://sqlblog.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Bin packing part 3: Need for speed</title><link>http://sqlblog.com/blogs/hugo_kornelis/archive/2008/01/12/bin-packing-part-3-need-for-speed.aspx</link><description>In the first post of this series, I explained the bin-packing problem and established a baseline solution. The second post investigated ways to increase the packing efficiency. In none of these posts did I pay particular attention to performance – and</description><dc:language>en</dc:language><generator>CommunityServer 2.1 SP2 (Build: 61129.1)</generator><item><title>re: Bin packing part 3: Need for speed</title><link>http://sqlblog.com/blogs/hugo_kornelis/archive/2008/01/12/bin-packing-part-3-need-for-speed.aspx#4521</link><pubDate>Sun, 13 Jan 2008 17:41:55 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:4521</guid><dc:creator>Joe Celko</dc:creator><description>&lt;p&gt;Did you ever see some of the solutions for Codd's t-join problem? &amp;nbsp;It is a &amp;quot;best fit&amp;quot; situation &amp;nbsp;-- given classrooms wtih various numbers of seat5s and classes with various numbers of students, how do you assign rooms to classes with the least wasted space? &amp;nbsp;&lt;/p&gt;
</description></item><item><title>re: Bin packing part 3: Need for speed</title><link>http://sqlblog.com/blogs/hugo_kornelis/archive/2008/01/12/bin-packing-part-3-need-for-speed.aspx#4528</link><pubDate>Mon, 14 Jan 2008 08:26:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:4528</guid><dc:creator>Hugo Kornelis</dc:creator><description>&lt;p&gt;Hi Joe,&lt;/p&gt;
&lt;p&gt;You mean those covered in your &amp;quot;SQL for smarties&amp;quot;? I checked those out when I tried to answer the usenet post that ultimately resulted in this series of blog post, but they didn't fit the problem - the solutions given in your book all relied on each classroom having a different size, and each class having a different number of students. Allso, none of those solution considered combining two classes in a single class room. (Which makes sense if you are teaching, but changes the problem from bin packing to best fit - a completely different problem, requiring a completely different solution).&lt;/p&gt;
&lt;p&gt;In part 5 of this series, I'll present an updated version of the code I originally posted in answer to said usenet post, which is MUCH faster than any of the other alternatives, and yields very acceptable packing efficiency. This code does utiilize a best fit strategy as part of the algorithm. You must be familiar with it, since I once sent you a copy when you asked for material for the third (?) edition of &amp;quot;Smarties&amp;quot;, but you ultimately chose not to include it. That's why I'm now writing this series.&lt;/p&gt;
&lt;p&gt;Best, Hugo&lt;/p&gt;
</description></item><item><title>Bin packing part 4: The set-based disaster</title><link>http://sqlblog.com/blogs/hugo_kornelis/archive/2008/01/12/bin-packing-part-3-need-for-speed.aspx#9675</link><pubDate>Sun, 26 Oct 2008 23:30:46 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:9675</guid><dc:creator>SELECT Hints, Tips, Tricks FROM Hugo Kornelis WHERE RDBMS = 'SQL Server'</dc:creator><description>&lt;p&gt;Almost a year ago now, I started a series of blog post on the bin packing problem . But after the first&lt;/p&gt;
</description></item><item><title>Bin packing part 5: Set-based iteration</title><link>http://sqlblog.com/blogs/hugo_kornelis/archive/2008/01/12/bin-packing-part-3-need-for-speed.aspx#39129</link><pubDate>Mon, 17 Oct 2011 22:11:51 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:39129</guid><dc:creator>SELECT Hints, Tips, Tricks FROM Hugo Kornelis WHERE RDBMS = 'SQL Server'</dc:creator><description>&lt;p&gt;One of the most common techniques authors use to keep their readers interested is to leave them with&lt;/p&gt;
</description></item></channel></rss>